
Mailing List Archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [tlug] Backup sites with FTP access
- Date: Tue, 30 Nov 2010 13:30:50 +0900
- From: Darren Cook <darren@example.com>
- Subject: Re: [tlug] Backup sites with FTP access
- References: <4CF47934.5040308@example.com>
- User-agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.1.15) Gecko/20101027 Thunderbird/3.0.10
> So, I've been working recently on PHP scripts that create back ups for
> my web sites. ...the back up files is going
> to be too large to handle by email. ...
> ...
> If there are other ways of transferring files, I'm open to suggestions,
I would (and do) scp files like this. Make a key pair with no
passphrase, with half the key pair on the web site machine, the other
half on your backup machine. Everyone supports ssh and you don't need
any PHP modules, just use a system call:
system("scp mybig.tar example.com:~/somewhere/");
Darren
P.S. I'm assuming your php script is doing something else special, or
you need a web front-end on this; otherwise you could do the whole thing
in bash, called from cron:
rm -f /tmp/backup.tar.gpg
tar -c /back/me/up/ | gpg -r dave -e -o /tmp/backup.tar.gpg
scp /tmp/backup.tar.gpg example.com:~/somewhere/
--
Darren Cook, Software Researcher/Developer
http://dcook.org/gobet/ (Shodan Go Bet - who will win?)
http://dcook.org/work/ (About me and my work)
http://dcook.org/blogs.html (My blogs and articles)
Home |
Main Index |
Thread Index