I\'m trying to process a file in the background with the following command, but it does nothing.
exec(\"php csv.php $file $user > /dev/null &\", $outp
Have you considered using screen? You can start up a screen session that runs in a detached process. Output will go to the screen session, which you can reattach to in another terminal while it is still running.
exec("screen -d -m -S my_php_session csv.php $file $user", $output);