Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Possible Duplicate:
Best way to do Subversion backups?

I'm not a Linux admin so a full walkthrough is needed. I'm running Gentoo 1.16 I believe.

I know the elements I need as I can do it "manually".

-run svnadmin hotcopy /shared/svnrepos /svnbackup -tar the /svnbackup folder

That's really it. I just need a script of some kind and be told explicitly how to add it to cron in Gentoo to make it run nightly.

I will then use pscp from a Windows backup server to grab the archive and copy it to the backup server.

I'm happy to answer any questions, file locations, etc. I'm just still learning this stuff.

share|improve this question

marked as duplicate by mailq, rnxrx, Magellan, Ward, John Gardeniers Oct 19 '12 at 10:27

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

I know how to do it, that was the original link I read. I just didn't know how to schedule/automate it. – TheCleaner Oct 8 '11 at 7:38
up vote 1 down vote accepted

add to crontab by $crontab -e this string (2 0 is time)

2 0 * * * /path/to/my/

create, open, and wite into it all you shell commands one at line with full paths.

Instead run pscp from windows, you can start copiyng from gentoo.

For that start ssh server on windows ( a lot of on + key auth.

and put in

scp /.././././my.tar user@my-windows-host:path/...

share|improve this answer
good deal. I will test this weekend. The reason I was going to run pscp from windows is because I have a batch file that creates 7 days worth in "Mon" etc. folders. I suppose I could do the same here and simply create 7 scripts. Just have to read on what the cron "timing" is. – TheCleaner Oct 8 '11 at 7:40

Not the answer you're looking for? Browse other questions tagged or ask your own question.