My PID using which CPU?

Clash Royale CLAN TAG#URR8PPP
up vote
0
down vote
favorite
I have a ubuntu box in which contains 4 CPU's (0,1,2,3). Let's say If i hit a webservice, that is taking some time to get the output (2 min). Let's say my webservice PID is xxxx , I want to check this process is using which CPU (0/1/2/3 ?) Can someone tell me i can check this by which command
process cpu
add a comment |Â
up vote
0
down vote
favorite
I have a ubuntu box in which contains 4 CPU's (0,1,2,3). Let's say If i hit a webservice, that is taking some time to get the output (2 min). Let's say my webservice PID is xxxx , I want to check this process is using which CPU (0/1/2/3 ?) Can someone tell me i can check this by which command
process cpu
add a comment |Â
up vote
0
down vote
favorite
up vote
0
down vote
favorite
I have a ubuntu box in which contains 4 CPU's (0,1,2,3). Let's say If i hit a webservice, that is taking some time to get the output (2 min). Let's say my webservice PID is xxxx , I want to check this process is using which CPU (0/1/2/3 ?) Can someone tell me i can check this by which command
process cpu
I have a ubuntu box in which contains 4 CPU's (0,1,2,3). Let's say If i hit a webservice, that is taking some time to get the output (2 min). Let's say my webservice PID is xxxx , I want to check this process is using which CPU (0/1/2/3 ?) Can someone tell me i can check this by which command
process cpu
asked Jun 28 at 6:24
Sudhakar
31
31
add a comment |Â
add a comment |Â
1 Answer
1
active
oldest
votes
up vote
0
down vote
accepted
Just use ps -aF . Here PSR number shoes processor number process is currently assigned to
psr PSR processor that process is currently assigned to.
$ ps -aF
UID PID PPID C SZ RSS PSR STIME TTY TIME CMD
arushir+ 7183 6916 0 12382 6884 0 10:51 pts/19 00:00:00 ssh arushi.rai@localhost
arushir+ 8672 5820 0 9341 3224 3 11:55 pts/2 00:00:00 ps -aF
Or you can get the processor of a pid directly , using
ps -q -o psr
$ ps -q 7810 -o psr
PSR
2
add a comment |Â
1 Answer
1
active
oldest
votes
1 Answer
1
active
oldest
votes
active
oldest
votes
active
oldest
votes
up vote
0
down vote
accepted
Just use ps -aF . Here PSR number shoes processor number process is currently assigned to
psr PSR processor that process is currently assigned to.
$ ps -aF
UID PID PPID C SZ RSS PSR STIME TTY TIME CMD
arushir+ 7183 6916 0 12382 6884 0 10:51 pts/19 00:00:00 ssh arushi.rai@localhost
arushir+ 8672 5820 0 9341 3224 3 11:55 pts/2 00:00:00 ps -aF
Or you can get the processor of a pid directly , using
ps -q -o psr
$ ps -q 7810 -o psr
PSR
2
add a comment |Â
up vote
0
down vote
accepted
Just use ps -aF . Here PSR number shoes processor number process is currently assigned to
psr PSR processor that process is currently assigned to.
$ ps -aF
UID PID PPID C SZ RSS PSR STIME TTY TIME CMD
arushir+ 7183 6916 0 12382 6884 0 10:51 pts/19 00:00:00 ssh arushi.rai@localhost
arushir+ 8672 5820 0 9341 3224 3 11:55 pts/2 00:00:00 ps -aF
Or you can get the processor of a pid directly , using
ps -q -o psr
$ ps -q 7810 -o psr
PSR
2
add a comment |Â
up vote
0
down vote
accepted
up vote
0
down vote
accepted
Just use ps -aF . Here PSR number shoes processor number process is currently assigned to
psr PSR processor that process is currently assigned to.
$ ps -aF
UID PID PPID C SZ RSS PSR STIME TTY TIME CMD
arushir+ 7183 6916 0 12382 6884 0 10:51 pts/19 00:00:00 ssh arushi.rai@localhost
arushir+ 8672 5820 0 9341 3224 3 11:55 pts/2 00:00:00 ps -aF
Or you can get the processor of a pid directly , using
ps -q -o psr
$ ps -q 7810 -o psr
PSR
2
Just use ps -aF . Here PSR number shoes processor number process is currently assigned to
psr PSR processor that process is currently assigned to.
$ ps -aF
UID PID PPID C SZ RSS PSR STIME TTY TIME CMD
arushir+ 7183 6916 0 12382 6884 0 10:51 pts/19 00:00:00 ssh arushi.rai@localhost
arushir+ 8672 5820 0 9341 3224 3 11:55 pts/2 00:00:00 ps -aF
Or you can get the processor of a pid directly , using
ps -q -o psr
$ ps -q 7810 -o psr
PSR
2
edited Jun 28 at 6:33
answered Jun 28 at 6:27
Arushix
9968
9968
add a comment |Â
add a comment |Â
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f452352%2fmy-pid-using-which-cpu%23new-answer', 'question_page');
);
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password