Beefy Boxes and Bandwidth Generously Provided by pair Networks
good chemistry is complicated,
and a little bit messy -LW
 
PerlMonks  

Re: Perl Module Not Working In Crontab

by dailyoliver (Initiate)
on Jan 11, 2012 at 22:26 UTC ( [id://947443]=note: print w/replies, xml ) Need Help??


in reply to Perl Module Not Working In Crontab

Thank you all for your comments -

The Archive::Extract module works fine if invoked manually. However it fails to extract using crontab.

As suggested I have turned debugging on $Archive::Extract::DEBUG=1;

<BELOW> are the results - would anybody have an idea what this means? I see the term 'write error (disk full?)' comes up several times??? Any help would be appreciated.. thanks again..

# Extracting with ->_unzip_bin Running [/usr/bin/unzip -Z -1 /work/locust1/swarmsdata/RasterData/gree +ning/MCD_GreenArea_20111211_LocustArea.zip]... MCD_GreenArea_20111211_LocustArea.tif Running [/usr/bin/unzip -qq -o /work/locust1/swarmsdata/RasterData/gre +ening/MCD_GreenArea_20111211_LocustArea.zip]... MCD_GreenArea_20111211_LocustArea.tif: write error (disk full?). Con +tinue? (y/n/^C) warning: MCD_GreenArea_20111211_LocustArea.tif is probably truncated Unable to unzip '/work/locust1/swarmsdata/RasterData/greening/MCD_Gree +nArea_20111211_LocustArea.zip': MCD_GreenArea_20111211_LocustArea.tif +: write error (disk full?). Continue? (y/n/^C) warning: MCD_GreenArea_20111211_LocustArea.tif is probably truncated at /usr/lib/perl5/site_perl/5.8.8/Archive/Extract.pm line 1106 Archive::Extract::_unzip_bin('Archive::Extract=HASH(0x1f96b990)') +called at /usr/lib/perl5/site_perl/5.8.8/Archive/Extract.pm line 415 Archive::Extract::extract('Archive::Extract=HASH(0x1f96b990)') cal +led at /work/locust1/swarmsdata/RasterData/greening/modis_greening.pl + line 340 at /work/locust1/swarmsdata/RasterData/greening/modis_greening.pl lin +e 340 # Extraction method failed # Extracting with ->_unzip_az IO error: write error during copy : No space left on device at /work/locust1/swarmsdata/RasterData/greening/modis_greening.pl lin +e 340 Extraction of 'MCD_GreenArea_20111211_LocustArea.tif' from '/work/locu +st1/swarmsdata/RasterData/greening/MCD_GreenArea_20111211_LocustArea. +zip' failed at /usr/lib/perl5/site_perl/5.8.8/Archive/Extract.pm line + 1166 Archive::Extract::_unzip_az('Archive::Extract=HASH(0x1f96b990)') c +alled at /usr/lib/perl5/site_perl/5.8.8/Archive/Extract.pm line 415 Archive::Extract::extract('Archive::Extract=HASH(0x1f96b990)') cal +led at /work/locust1/swarmsdata/RasterData/greening/modis_greening.pl + line 340 at /work/locust1/swarmsdata/RasterData/greening/modis_greening.pl lin +e 340 # Extraction method failed Extract failed due to errors at /usr/lib/perl5/site_perl/5.8.8/Archive +/Extract.pm line 439 Archive::Extract::extract('Archive::Extract=HASH(0x1f96b990)') cal +led at /work/locust1/swarmsdata/RasterData/greening/modis_greening.pl + line 340 at /work/locust1/swarmsdata/RasterData/greening/modis_greening.pl lin +e 340 Can't extract: Unable to unzip '/work/locust1/swarmsdata/RasterData/gr +eening/MCD_GreenArea_20111211_LocustArea.zip': MCD_GreenArea_20111211 +_LocustArea.tif: write error (disk full?). Continue? (y/n/^C) warning: MCD_GreenArea_20111211_LocustArea.tif is probably truncated Extraction of 'MCD_GreenArea_20111211_LocustArea.tif' from '/work/locu +st1/swarmsdata/RasterData/greening/MCD_GreenArea_20111211_LocustArea. +zip' failed Extract failed due to errors at /work/locust1/swarmsdata/RasterData/gr +eening/modis_greening.pl line 340.

Replies are listed 'Best First'.
Re^2: Perl Module Not Working In Crontab
by Anonymous Monk on Jan 12, 2012 at 08:12 UTC

    What do you think this message is trying to tell you

    MCD_GreenArea_20111211_LocustArea.tif: write error (disk full?). Continue? (y/n/^C)

    ...

    IO error: write error during copy : No space left on device

    Are you ready to stop blaming Perl Module Archive::Extract?

      Thanks you for your response - I eventually found out that I needed to add 'cd /my/working/directory/' into the bash script. This was a privilege issue - Archive::Extract module could not extract the file to the required directory and adding 'cd ...' to the calling script managed to solve it! Thank you to the guy that mentioned TURN ON DEBUG

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://947443]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others chilling in the Monastery: (2)
As of 2024-03-19 10:25 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found