I am looking to simply backup a complete local directory tree to an ftp server...... I can get the lftp to work however I have been digging for days to get the damn automatic part of it.... I am new to linux but understand some code, everything i read kept saying how easy it was to schedule a crob job. I have since had cron job nightmares, I was working from multiple forumns, tuts, and questions and in the end came to find that everything i researched was outdated! the commands have changed.... I dont understand were to put the line of text or what the syntax should be.
I'm Using the newest debian lenny and and newest cronjob( think its 8)
user * *
mirror --reverse --delete --only-newer /esxi/backup/ /GoFlex\ Home\ Backup/
I can run the following command and it works:
lftp -f /lftp/lftp/lftpbackup.txt
the cron job line I want to use is(run every weekday at 11PM and create a logfile):
* 23 * 1-5 * root lftp -f /lftp/lftpbackup.txt > /lftp/cron.log
is the username needed in every cron file or just the cron.d??? i have tried that line in other places with and without the user part...
tried putting in a few different locations.... tried adding to crontab -e without username, tried making a file name lftp within the cron.d directory with the username.... i think i put it in a few other places i dont remember..... i have tried start, stop restart service...(later read this is not necessary in this version?) super lost.......
I have root access, i just need to know the cron job line and where to put it, also if i need to restart the cronjobby.
Super big thank you in advance!