Auto-backup script


 
Thread Tools Search this Thread
Top Forums Shell Programming and Scripting Auto-backup script
# 1  
Old 12-18-2017
Auto-backup script

hello guys
i need a script to automatically backup a whole directory in linux like

/var/www

and the whole sql db

and upload to an ftp server daily (as a cron job)

is there something like this? I read about rsync but I don't know if it will suit this.
# 2  
Old 12-19-2017
Hi,

You'll have to be a bit more specific here, decide what you want from your backup solution and depending on requirements and budget make a more detailed request.

Regards

Gull04
# 3  
Old 12-19-2017
I fully second gull04 in that people in here need more info to start from. There have been many similar if not identical requests in here in the recent weeks; try searching for them to get to a good starting point.
# 4  
Old 12-19-2017
You also need to consider, if you lose the whole server for some reason (physical loss, corrupt boot disk etc.) then how do you recover?

You do need to specify clearly what you have (output from uname -a to get us started perhaps) and what part you need to be recoverable. Remember that the backup is easy, it's restoring that's a problem if you didn't get the backup process correct and complete. It is vital to test your restore process.




Robin
# 5  
Old 01-04-2018
are there freelancers on this forum that can code something for me like this?
# 6  
Old 01-08-2018
We are an educational forum, not a coding service.
# 7  
Old 01-18-2018
Quote:
Originally Posted by galapagos8000
hello guys
i need a script to automatically backup a whole directory in linux like

/var/www

and the whole sql db

and upload to an ftp server daily (as a cron job)

is there something like this? I read about rsync but I don't know if it will suit this.
Yes- you can use Rsync. Works for backup and restore. Cron is perfect for this.
There are some neat things you can do with a bash script utilizing Rsync, including timestamped file versioning.
Don't forget to create a permanent mount entry in your /etc/fstab for the target FTP server to make things easy
Login or Register to Ask a Question

Previous Thread | Next Thread

9 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

Vi editor auto backup

Hi I am looking for some option in vi config options to set so that any time any user update/change any file then one backup file (before change) is created automatically which can be used for diff or to revert back during any issue of accidental or wrong update I had heard some option to... (2 Replies)
Discussion started by: reldb
2 Replies

2. Shell Programming and Scripting

How to provide auto inputs for a sub-script within a script?

Hi All, I am writing a shell script. #!/bin/bash cat /etc/hosts mkdir -p /var/tmp mount 113.123.35.37:/vol/vol615/syb /var/tmp In above script I am trying to add below predefined script/command (/var/tmp/db_tools) This command in turn ask for user input, which will be always option... (17 Replies)
Discussion started by: madhur.baharani
17 Replies

3. Shell Programming and Scripting

Help with Backup Shell Script for Network Device Configuration backup

HI all, im new to shell scripting. need your guidence for my script. i wrote one script and is attached here Im explaining the requirement of script. AIM: Shell script to run automatically as per scheduled and backup few network devices configurations. Script will contain a set of commands... (4 Replies)
Discussion started by: saichand1985
4 Replies

4. Shell Programming and Scripting

auto kill script

Hi, I have created a shell script which is used by many users to change their password/unlock, etc., via menu. There is possibility users just close the putty window without proper exit from menu. I want a solution so that if anybody forgets to stop that session, it should kill automatically... (9 Replies)
Discussion started by: prashant2507198
9 Replies

5. Shell Programming and Scripting

rsync backup mode(--backup) Are there any options to remove backup folders on successful deployment?

Hi Everyone, we are running rsync with --backup mode, Are there any rsync options to remove backup folders on successful deployment? Thanks in adv. (0 Replies)
Discussion started by: MVEERA
0 Replies

6. Shell Programming and Scripting

Auto restart script does not work

I have a service that are not 100% stable and stops from time to time. So I have a script that do restart the service if it does not run. This script works win on Ubuntu 9.04 but will not start the service in Ubuntu 10.10 If I run the part that do starts the service from CLI, it starts... (2 Replies)
Discussion started by: Jotne
2 Replies

7. Windows & DOS: Issues & Discussions

auto login script

can any one help me for auto login bat file from windows to unix,to check the server daily.. Thanks Mohan (1 Reply)
Discussion started by: mohankasi
1 Replies

8. UNIX for Dummies Questions & Answers

Shell Script to Auto Run PHP Script

Hello All! I am looking to build a monitoring script. The script should always run as a system service of some type and should always check that a PHP script is running. Maybe there is a way to assign a PHP script to a certain PID so that the monitor script that check for the PID in top... (4 Replies)
Discussion started by: elDeuce
4 Replies

9. Shell Programming and Scripting

Auto Alias Script

Hi All, as you can guess, I'm a newb here, and to shell scripting. I use Linux(CentOS) at home and want to get into scritping. I was creating some aliases on a Laptop the other day, and thought, god this is tedious, and then I thought, heck, why not use it as a 1st script project. Please see... (3 Replies)
Discussion started by: coolboarderguy
3 Replies
Login or Register to Ask a Question