Previous Thread
Next Thread
Print Thread
Rate Thread
rodrigo1 #212054 10/17/2001 11:33 AM
Joined: May 1999
Posts: 241
Coder
Coder
Offline
Joined: May 1999
Posts: 241
Carl,

here is how I have my backup setup... I telneted to my machine, created a .sh file (shell script) called dodump.sh. The contents are a series of commands to create/update 5 days worth of database backups for you... contents are:


#!/bin/sh

mv /home/mattyj/db_dumps/w3t.dump.4 /home/mattyj/db_dumps/w3t.dump.5
mv /home/mattyj/db_dumps/w3t.dump.3 /home/mattyj/db_dumps/w3t.dump.4
mv /home/mattyj/db_dumps/w3t.dump.2 /home/mattyj/db_dumps/w3t.dump.3
mv /home/mattyj/db_dumps/w3t.dump.1 /home/mattyj/db_dumps/w3t.dump.2
mv /home/mattyj/db_dumps/w3t.dump /home/mattyj/db_dumps/w3t.dump.1

/usr/local/bin/mysqldump --password=mydbPasswd myDBname > /home/mattyj/db_dumps/w3t.dump


obviously, you need to create the appropriate folders and make sure the paths are correct....
save your file, exit, and be sure to chmod 755 dodump.sh to make it executable...

Then, set up a crontab entry by typing crontab -e and entering something similar to: 15 2 * * * /home/mattyj/bin/dodump.sh

That's it!

you might want to run it a couple of times manually to make sure it is creating the files you need...

Does this help at all?

Matt


--------------------
Matt Reinfeldt
http://www.mattreinfeldt.com/
Sponsored Links
Entire Thread
Subject Posted By Posted
Database backup roger20 10/06/2001 8:34 AM
Re: Database backup caymuc 10/07/2001 3:39 PM
Re: Database backup Deathwalker 10/16/2001 8:25 PM
Re: Database backup caymuc 10/17/2001 12:24 AM
Re: Database backup MattyJ 10/17/2001 6:33 PM

Link Copied to Clipboard
Donate Today!
Donate via PayPal

Donate to UBBDev today to help aid in Operational, Server and Script Maintenance, and Development costs.

Please also see our parent organization VNC Web Services if you're in the need of a new UBB.threads Install or Upgrade, Site/Server Migrations, or Security and Coding Services.
Recommended Hosts
We have personally worked with and recommend the following Web Hosts:
Stable Host
bluehost
InterServer
Visit us on Facebook
Member Spotlight
hatter
hatter
USA
Posts: 69
Joined: January 2001
Forum Statistics
Forums63
Topics37,574
Posts293,926
Members13,850
Most Online5,166
Sep 15th, 2019
Today's Statistics
Currently Online
Topics Created
Posts Made
Users Online
Birthdays
Top Posters
AllenAyres 21,079
JoshPet 10,369
LK 7,394
Lord Dexter 6,708
Gizmo 5,833
Greg Hard 4,625
Top Posters(30 Days)
Top Likes Received
isaac 82
Gizmo 20
Brett 7
WebGuy 2
Morgan 2
Top Likes Received (30 Days)
None yet
The UBB.Developers Network (UBB.Dev/Threads.Dev) is ©2000-2024 VNC Web Services

 
Powered by UBB.threads™ PHP Forum Software 8.0.0
(Preview build 20240506)