I would like to have a properly secured PHP web tool to run mysqlcheck for the general state of the database table, but I do not want the password to be visible in the process list. I would like to run something like this:
$output = shell_exec('mysqlcheck -Ac -uroot -pxxxxx -hhostname'); // strip lines that OK echo '<pre>'.preg_replace('/^.+\\sOK$\\n?/m', '', $output).'</pre>';
Unfortunately, with shell_exec() , I have to specify the password on the command line, but I am worried that the password will be displayed in the process list ( ps -A | grep mysqlcheck ).
Using mariadb 5.5 on my test machine, mysqlcheck does not display the password in the process list, but my production machine does not start mariadb and does not start another OS, and I would like to be safe and not run these tests on the production side.
Do all mysql versions also hide the password in the process list? Is my problem not a problem?
source share