Search Results

Search: Posts Made By: enriquegm82
17,934
Posted By Don Cragun
The grep -v grep gets rid of the grep...
The
grep -v grep
gets rid of the grep commands in the ps output that are used to search for the user and command names.
17,934
Posted By alister
If the ps in Don's pipeline obtains the process...
If the ps in Don's pipeline obtains the process listing after the grep processes in the pipeline have been created, the pid of grep 'CAL255.4ge, if run by wilruiz0, will be part of the result. The...
17,934
Posted By alister
If your system has it (I believe most do), just...
If your system has it (I believe most do), just use pkill:
pkill -9 -u wilruiz0 '^CAL255\.4ge$'

I have backslash escaped the dot so that it is no longer a wildcard, but a literal dot. Also, I...
17,934
Posted By Chubler_XL
How about using -u param of ps and here I combine...
How about using -u param of ps and here I combine two greps and awk into 1 awk script:

kill -9 `ps -fu wilruiz0 | awk '/[C]AL255.4ga/ {print $2}'`

You should try kill -15 before using -9 as...
17,934
Posted By Don Cragun
Try: kill -9 $(ps -aef | grep 'CAL255.4ge' |...
Try:
kill -9 $(ps -aef | grep 'CAL255.4ge' | grep 'wilruiz0' | grep -v grep | awk '{print $2}')
2,491
Posted By Don Cragun
This discussion assumes that you are using a...
This discussion assumes that you are using a shell that uses basic Bourne shell redirection syntax (such as bash, ksh, or sh). The csh shell and its derivatives handle redirection differently.
...
2,491
Posted By Don Cragun
You have 4 commands that are using redirection: ...
You have 4 commands that are using redirection:
nohup nice -10 programA 2>&1 > logfileA.txt
nohup nice -10 program1a 2>&1 > logfile1a.txt
nohup nice -10 program1b 2>&1 > logfile1b.txt
nohup nice...
2,491
Posted By DGPickett
Usually the log is merged for coherency, so...
Usually the log is merged for coherency, so stderr and stdout are logged contemporaneously in the same log, give or take some stdout buffering. Use redirection ">log_file 2>&1". You are making...
Showing results 1 to 8 of 8

 
All times are GMT -4. The time now is 02:11 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy