LinuxQuestions.org
Latest LQ Deal: Complete CCNA, CCNP & Red Hat Certification Training Bundle
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 05-23-2004, 06:09 PM   #1
anthill
LQ Newbie
 
Registered: Mar 2003
Posts: 11

Rep: Reputation: 0
rsync and contab


Hi,

I am running a couple of mirrors from my server. At the moment I am updating the sites manually using rsync, but i am going on holiday soon, and need to do this automatically.

I have tried inserting a script into cron.daily but it doesn't seem to work. The script being

#!/bin/sh

rsync -rtzp ftp.mirror.org::mirror /var/www/mirror

so i changed it to #!/bin/bash, but that didn't work either...What am i doing wrong?

Thanks for reading this, sorry for my newbieism.

Ant
 
Old 05-23-2004, 06:48 PM   #2
ToniT
Senior Member
 
Registered: Oct 2003
Location: Zurich, Switzerland
Distribution: Debian/unstable
Posts: 1,357

Rep: Reputation: 47
Is there rsync in the PATH that is passed to the cronjob? Do you have any mail from your cron? Have you chmodded the script to have an executable flag on?
 
Old 05-24-2004, 05:16 AM   #3
anthill
LQ Newbie
 
Registered: Mar 2003
Posts: 11

Original Poster
Rep: Reputation: 0
Hi

I just popped the file into the cron.daily directory.

I don't have any mail from the cron

I haven't chmoded the file, would there be a log created if it couldn't perfom the action? i.e. telling me the privileges are all wrong?

Thanks for your reply

Ant
 
Old 05-24-2004, 11:32 AM   #4
ToniT
Senior Member
 
Registered: Oct 2003
Location: Zurich, Switzerland
Distribution: Debian/unstable
Posts: 1,357

Rep: Reputation: 47
Well, according to the sources of run-parts (the program that is used in debian cron), the files without executable flag on are silently ignored.

SuSE uses a script named 'run-crons', that gives a warning message: "WARNING: $SCRIPT is not executable, script is ignored !".

Redhat(atleast 7.3; I don't have access to other RH boxes at the moment) has a script that is similar to the debian run-parts, and it also silently ignores the files without -x flag.

Conclusion: It doesn't work without the x flag, and it doesn't necessary inform a thing about it.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Contab -- What is the problem in my cron configure file? -- please help me b:z Linux - General 2 05-16-2005 10:21 PM
Windows Rsync Upload to Linux Rsync - permissions inspleak Linux - Software 0 10-12-2004 03:49 PM
Rsync help tricky1234 Solaris / OpenSolaris 3 09-07-2004 11:08 AM
rsync DropHit Linux - Software 2 02-18-2004 09:54 PM
rsync slack66 Slackware 1 07-29-2003 10:33 PM


All times are GMT -5. The time now is 04:37 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration