简体   繁体   English

使用pid =查找有效的id euid用于进程<some number>

[英]find effective id euid for process with pid=<some number>

How to find euid of a process if I know its pid I tried I get process id using : 如果我知道进程的pid,如何查找进程的euid,我尝试使用以下方法获取进程ID:

ps -f -u user1

then I tried ps aux , ps -ef with grep pid but can not see euid 然后我用grep pid尝试了ps aux , ps -ef但看不到euid

I always try to get info from man pages but man ps seems too confusing for a newbie like me. 我总是尝试从手册页中获取信息,但是对于像我这样的新手来说, man ps似乎太令人困惑了。

You are looking for the ps option: -o euid 您正在寻找ps选项: -o euid

Examples: 例子:

  • Display a pid's euid 显示pid的euid

    ps -eo pid,euid | grep YOUR_PID_HERE

  • Display a pid's euid, ruid and suid 显示pid的euid,ruid和suid

    ps -eo pid,euid,ruid,suid | grep YOUR_PID_HERE

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM