Eric Shubert schreef op 7-4-2014 22:49: > On 04/07/2014 01:24 PM, Peter Peterse wrote: >> Eric Shubert schreef op 7-4-2014 22:19: >>> On 04/07/2014 01:12 PM, Peter Peterse wrote: >>>> Eric Shubert schreef op 7-4-2014 22:01: >>>>> On 04/07/2014 12:46 PM, Peter Peterse wrote: >>>>>> Eric Shubert schreef op 7-4-2014 20:54: >>>>>>> On 04/07/2014 11:47 AM, Peter Peterse wrote: >>>>>>>> Eric Shubert schreef op 7-4-2014 18:29: >>>>>>>>> What was the error? Same? >>>>>>>>> >>>>>>>>> I take it doing a cd before the command and omitting --directory >>>>>>>>> worked? >>>>>>>>> >>>>>>>>> Thanks. >>>>>>>>> >>>>>>>> Hello Eric, >>>>>>>> >>>>>>>> Yes when I've change the script to: >>>>>>>> ========== >>>>>>>> cd $backupdest >>>>>>>> tar -C $backupdest \ >>>>>>>> -czf $backupdest/$curlfile $DATENAME-* > /dev/null 2>&1 >>>>>>>> ========== >>>>>>>> >>>>>>>> The script worked correctly. >>>>>>>> It look like the last $DATENAME-* don't work with the tar >>>>>>>> command on >>>>>>>> this way. >>>>>>>> >>>>>>>> $ touch /tmp/testfile.txt >>>>>>>> $ tar -C /tmp -czf /tmp/test.tgz testfile* >>>>>>>> tar: testfile*: Cannot stat: No such file or directory >>>>>>>> tar: Error exit delayed from previous errors >>>>>>>> >>>>>>>> While it will work when I use the next command >>>>>>>> $ tar -C /tmp -czf /tmp/test.tgz testfile.txt >>>>>>>> >>>>>>>> There are more backup files not correct: >>>>>>>> -rw-r--r-- 1 root root 46 Apr 7 06:35 >>>>>>>> 201404070635-squirrelmail-plugins.tar.bz2 >>>>>>>> -rw-r--r-- 1 root root 46 Apr 7 06:35 >>>>>>>> 201404070635-squirrelmail-prefs.tar.bz2 >>>>>>>> These to are empty tar files. >>>>>>>> >>>>>>>> Regards, >>>>>>>> Peter >>>>>>>> >>>>>>>> --------------------------------------------------------------------- >>>>>>>> >>>>>>>> >>>>>>> >>>>>>> That's very strange to me. Using the -C option is supposed to be >>>>>>> preferable to doing a cd before the tar command. >>>>>>> >>>>>>> Would someone care to look into this in detail? This needs to be >>>>>>> fixed >>>>>>> so that it works on both COS5 and COS6. It might be a while >>>>>>> before I >>>>>>> get to look at it, as what time I have is being spent on >>>>>>> finishing up >>>>>>> the COS6 release. >>>>>>> >>>>>>> Thanks. >>>>>>> >>>>>>> >>>>>> >>>>>> Hi Eric, >>>>>> >>>>>> It looks like a issue with the combination between shell and tar: >>>>>> <http://superuser.com/questions/266422/tar-c-with-a-wildcard-file-pattern> >>>>>> >>>>>> >>>>>> >>>>>> >>>>>> Does it work on your CentOS 6 system, because I've test it on one >>>>>> of my >>>>>> CentOS 6.5 systems and the result is: >>>>>> # ls -l /tmp/testfile.txt >>>>>> -rw-r--r-- 1 root root 0 Apr 7 21:41 /tmp/testfile.txt >>>>>> # tar -C /tmp -czf /tmp/test.tgz testfile* >>>>>> tar: testfile*: Cannot stat: No such file or directory >>>>>> tar: Exiting with failure status due to previous errors >>>>>> >>>>>> Regards, >>>>>> Peter >>>>>> >>>>>> --------------------------------------------------------------------- >>>>>> >>>>> >>>>> I should've caught that. >>>>> >>>>> Does "testfile*" work? >>>>> (putting the string with wildcard in quotes) >>>>> I expect it will. >>>>> >>>> Hi Eric, >>>> >>>> Sorry but on both of my systems it don't work: >>>> >>>> CentOS 5.10: >>>> # touch /tmp/testfile.txt >>>> # tar -C /tmp -zcvf /tmp/testbackup.tgz "testfile*" >>>> tar: testfile*: Cannot stat: No such file or directory >>>> tar: Error exit delayed from previous errors >>>> >>>> On CentOS 6.5: >>>> # touch /tmp/testfile.txt >>>> # tar -C /tmp -zcvf /tmp/testbackup.tgz "testfile*" >>>> tar: testfile*: Cannot stat: No such file or directory >>>> tar: Exiting with failure status due to previous errors >>>> >>>> Regards, >>>> Peter >>>> >>>> --------------------------------------------------------------------- >>> >>> What about with single quotes? e.g.: >>> 'testfile*' >> >> Still the same. >> >> CentOS 5.10: >> # tar -C /tmp -zcvf /tmp/testbackup.tgz 'testfile*' >> tar: testfile*: Cannot stat: No such file or directory >> tar: Error exit delayed from previous errors >> >> CentOS 6.5: >> # tar -C /tmp -zcvf /tmp/testbackup.tgz 'testfile*' >> tar: testfile*: Cannot stat: No such file or directory >> tar: Exiting with failure status due to previous errors >> >> --------------------------------------------------------------------- >> To unsubscribe, e-mail: [email protected] >> For additional commands, e-mail: [email protected] >> >> > > Ok, I think I've fixed both backup and restore scripts now, including > the squirrelmail prefs. > > Please try scripts in qtp svn repo: > http://qtp.qmailtoaster.com/trac/export/178/bin/qtp-backup > http://qtp.qmailtoaster.com/trac/export/178/bin/qtp-restore > > If they work I'll cut another qtp release. > > Thanks. Your help is greatly appreciated. > Hello Eric,
when I do a: wget http://qtp.qmailtoaster.com/trac/export/178/bin/qtp-backup I get an file which is created on May 30 2013 I don't see any changes between the version on my system and the one Ive júst downloaded. Regards, Peter -- Met vriendelijke groet, Peter Peterse --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
