|
Posted by Jerry Stuckle on 11/28/47 11:57
nigel.t@by.uk wrote:
> In article <BNudneEBxth0dmPZnZ2dnUVZ_rmdnZ2d@comcast.com>,
> jstucklex@attglobal.net says...
>
>>nigel.t@by.uk wrote:
>>
>>>Using linux
>>>
>>><?php
>>>exec("/bin/tar -cvzf myfile.tgz /home/",$arrayout,$returnval);
>>>?>
>>>
>>>or perhaps try it on your system and tell me if it does/doesnt and what
>>>your linux is?
>>>
>>>I've also tried
>>>
>>><?php
>>> exec("/bin/tar -c * \| gzip \> myfile.tgz",$arrayout,$returnval);
>>>?>
>>>
>>>Both work fine from the command line neither work at all from PHP
>>>
>>>-nigel-
>>
>>What kind of error do you get?
>>
>>--
>
>
> Hi Jerry - $returnval contains '2' in each case.
> $arrayout never seems to contain anything.
>
> I can however do -
> tar --help
> which does return the help.
>
> I've also tried to archive a single file with the same result
> ie. tar -cf myfile.tar foo
> returns an error of 2
>
> and i've tried the --ignore-failed-read flag to no avail.
>
> -nigel-
Nigel,
Does the cron job user have write access to the directory where you're
writing myfile.tar? And does it have read access to /home?
--
==================
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp.
jstucklex@attglobal.net
==================
Navigation:
[Reply to this message]
|