Link to home
Start Free TrialLog in
Avatar of allwebnow
allwebnow

asked on

command not working

I have a client that has 2 cpanel servers with me running joomla installations.  He needs to execute this command within joomla I believe.  One of the servers the command works just fine, the other though, it doesn't even though they're very similar builds.

$command="nohup mysql -u ".$user." -p".$password." ".$dbname." < ".$sqlfile;
passthru($command);

It's not seeming to work and he did get it sort of work, but he's sitll saying there are problems.  He used this command to get past it:

$command="/usr/bin/mysql -u ".$user." -p".$password." ".$dbname." < ".$sqlfile;
$sqlit=passthru($command);

What Changed was:"nohup mysql -u " to  "/usr/bin/mysql -u "

Does anyone know what's going on and why nohup would work on the one server and not on the other.
ASKER CERTIFIED SOLUTION
Avatar of Beverley Portlock
Beverley Portlock
Flag of United Kingdom of Great Britain and Northern Ireland image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial