-   Linux - General (
-   -   how to find a looooooooong command line (

acid_kewpie 11-20-2002 11:56 AM

how to find a looooooooong command line
anyone aware of a way to get a command line that's too long to fit on one line? i have a 200 character command line, and i can't find out what it actualy is, as ps let's it run off the end of the screen.... the command is listed in /proc/[pid]/cmdline but it's got no spaces in it....

chrisharkness 11-20-2002 11:59 AM

i guess if you look in a console window in X, and whack your resolution up high it may all fit one one screen, as for a proper way, i dont know

acid_kewpie 11-20-2002 12:17 PM

yeah i'd rather have a "proper" way. thanks.

unSpawn 11-20-2002 12:32 PM

It's the damn <CTRL+V CTRL+J>: strings /proc/[pid]/cmdline | xargs (echo (-n)) should do the trick.

acid_kewpie 11-20-2002 12:58 PM

ahh super, except for the brackets... i knew that the cmdline "file" was more than just a file with0uot spaces.. but it was more a case of how to format it usefully. cheers.

vladkrack 11-20-2002 01:02 PM

If you want to see it in ps, you could add 'w' s to see longer lines as:

# ps auxwwwwwww
vladimir 1397 3.0 1.3 3216 1680 tty11 S 16:01 0:00 aterm -bg black - fg gray -tr -sh 30 -title vladterm +sb -sl 5000 -fn -misc-console-medium-r-norma l--16-160-72-72-c-160-iso10646-1 -fb -misc-console-medium-r-normal--16-160-72-72 -c-160-iso10646-1
vladimir 1403 0.0 0.7 2776 944 pts/3 R 16:01 0:00 ps auxwwww

hope that fits :)

acid_kewpie 11-20-2002 01:37 PM

ahh two w's also make it wrap better.

All times are GMT -5. The time now is 11:40 PM.