print stdout and stderr for background process