|
|||||||
| Forums | Search Forums | Register | Forum Rules | Man Pages | Albums | FAQ | Members | Calendar | Search | Today's Posts | Mark Forums Read |
| UNIX for Dummies Questions & Answers If you're not sure where to post a UNIX or Linux question, post it here. All UNIX and Linux newbies welcome !! |
|
|
|
Thread Tools | Search this Thread | Display Modes |
|
#1
|
|||
|
|||
|
PS Command in shell script
Hi all,
Am facing issue in using ps -auxww command inside my shell script. Please find the eeror which I got when executing my script, "ps: unknown user xww" NOTE : The same command was working when I execute outside the script. |
| Sponsored Links | ||
|
|
#2
|
||||
|
||||
|
In solaris,
ps -auxww will be treated as userid. In my machine, Code:
$ uname -sr SunOS 5.9 $ ps -auxww ps: unknown user xww $ ps -auroot PID TTY TIME CMD 17306 pts/19 0:00 gzgrep 13727 pts/9 0:00 bash Code:
NAME
ps - report process status
-a Lists information about all processes most frequently
requested: all those except session leaders and
processes not associated with a terminal.
-u uidlist
Lists only process data whose effective user ID number
or login name is given in uidlist. In the listing, the
numerical user ID will be printed unless you give the
-f option, which prints the login name.What OS you are using and i am not sure, how that command works for you when executing in command prompt. |
| Sponsored Links | ||
|
|
#3
|
||||
|
||||
|
Perhaps you need a space: Code:
ps -a uxww |
|
#4
|
|||
|
|||
|
On which OS are you ?
If on SunOS, make sure the "ps" used is the one in /usr/ucb/ps |
| Sponsored Links | |
|
|
#5
|
|||
|
|||
|
Further to ctsgnb.
Check the ouput of type ps in both environments to make sure that they are the same. |
| Sponsored Links | ||
|
![]() |
| Thread Tools | Search this Thread |
| Display Modes | |
More UNIX and Linux Forum Topics You Might Find Helpful
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| When i am trying to execute export command within a shell script it is saying command not found. | dchoudhury | Shell Programming and Scripting | 4 | 06-18-2012 01:13 AM |
| Shell script running command in different shell | gr8_usk | Shell Programming and Scripting | 9 | 05-23-2011 06:30 PM |
| help with shell script: cp command not working, but mv command works... | udelalv | Shell Programming and Scripting | 1 | 04-12-2011 04:34 AM |
| can anyone help with shell script command about searching word with grep command? | aintour | Shell Programming and Scripting | 2 | 10-14-2009 04:51 PM |
| Need to Write Shell Script based off of this shell command | Rally_Point | Shell Programming and Scripting | 3 | 06-10-2009 05:19 PM |
|
|