Mysql.pipe connection check by script!
Dear ALL, I am writing a script to check the existence of the “MySQL –u root –password=password syslog < /tmp/mysql.pipe &”. I have tried to grep the string as the following command, #> ps aux | grep “mysql –u root” | grep “syslog” When I try to run this command, the PS cannot not show the command but “-bash”. How could I use “ps” command to show the full detail of this “-bash”. Thanks. Regards, Wilson Lai System Engineer IT Dept., SJM Office ( : (853)2978585 Mobile ( : (853)66506709 Email +: : wilsonlai@macausjm.com
Set the first line to #!/bin/bash, run the script explicitly (forget if this is necessary), and the name of the script (as filename) will show up in the process table as such. /eli Wilson Lai wrote:
Dear ALL,
I am writing a script to check the existence of the “MySQL –u root –password=password syslog < /tmp/mysql.pipe &”.
I have tried to grep the string as the following command,
#> ps aux | grep “mysql –u root” | grep “syslog”
When I try to run this command, the PS cannot not show the command but “-bash”. How could I use “ps”
command to show the full detail of this “-bash”.
Thanks.
*Regards,*
*Wilson Lai*
System Engineer
IT Dept., SJM
Office ( : (853)2978585
Mobile ( : (853)66506709
Email +: : _wilsonlai@macausjm.com_
participants (2)
-
Eli Stair
-
Wilson Lai