I failed to copy a backup script like laruence, and nobody was here-Linux general technology-Linux technology and application information. Here is the details. Z is a newbie, the level is shit, Mo Xiao: 0w223dc ...... To make an automatic backup can only be like this
Bird b
sentences that follow the script, or simply make it an empty file. 3) initialized, no data has been backed up at this time: Svnsync initfile:///home/backup/svn/svnsync/project1/http:// svntest.subversion.com/repos/project1 syntax is: Svnsync init {The library URL you just created} {Source Library url} Note The local URL is a three slash:/// 4) Start Backup
This article refers to the concise python after modifying#!/usr/bin/pythonimporttimeimportos#1.thefilesanddirectoriesto bebackeduparespecifiedinalist.source=['/root ', '/tmp ']#ifyouareusingwindows,usesource=[r ' c \ Documents ', r ' D:\Work ']orsomethinglikethat#2.thebackup mustbestoredinamainbackupdirectorytarget_dir= '/mnt/e/ backup/' #Remembertochangethistowhatyouwillbe Using#3.thefilesarebackedupintoazipfile.#4. thecurrentdayisthenameofthesubdir
= Time.strftime ('%h%m%s ')# Take a comment from the user to create the name of the tar fileComment = raw_input (' Enter a Comment: ')If len (comment) = = 0:target = Target_dir + today + os.sep + Now + '. tar.gz 'Elsetarget = Target_dir + today + os.sep + comment.replace ("', '-') + ' _ ' + Now + '. tar.gz '# Create The subdirectory if it isn ' t already thereIf not os.path.exists (target_dir+today):Os.mkdir (Target_dir+today)print ' Successfully created directory ', today# 5, We use the tar co
MySQL backup and crontab regular backup in Linux
1. back up a database
######################################## ########################### Back up a database ########## ######################################## ################# root user, create the backup directory mkdir-p/usr/local/cncounter/mysql_dumpcd/usr/local/
Quick Guide to Linux backup and recovery
Level: Entry
Chris Walden (cmwalden-at-us.ibm.com)E-commerce architect, IBM developer relationsJanuary 2004
IBM e-commerce architect Chris Walden willDeveloperWorksThe nine articles published in this article will guide you how to use your Windows Operating Skills in Linux. This section describes the content
The loss of important data can mean fatal damage. Still, countless professionals are ignoring the backup of their data. Although the reasons may vary, one of the most common explanations is that performing routine backups is really cumbersome. Because machines are adept at accomplishing common and repetitive tasks, automating the backup process is key to reducing the intrinsic tedium of work and the propens
It features multiple platforms. a script can back up multiple databases and package and upload them to ftp for backup. Mysqldump and tar are called for database dump and packaging. For detailed parameter descriptions, see source files.
The code is as follows:
#! /Usr/bin/pythonImport OSImport timeImport ftplibImport traceback# Config varsSystempathchr = "/" # path delimiter, * nix "/" win32 "\\"Dbuser = "
Set the script for regular execution in Linux, and run the script in linux.
The following section describes the differences between ubuntu and non-ubuntu environments.
In Linux, you often need to regularly execute some scripts to implement some functions.
In
The program needs to overwrite the backup file because of the project.
(The original solution is to use VB6 to traverse the file, do not spit slot)
Requirement 1: Check the modification time of each file, if it is less than the date parameter, then backup (and delete);
Requirement 2: Keep the directory structure of the backed up files.
Backing up files under Linux
(The example in this article is implemented based on FreeBSD/Linux, and you need to modify it on your own in the Windows environment)An important mission of configuration management is to ensure data security and prevent the catastrophic consequences of the failure to recover data due to disk damage or misoperations on the server. Therefore, it is very important to develop a complete backup policy.
Generall
For ease of management, we can hang Windows shared folders under Linux so that the backed-up data can be viewed at any time through windows, and the corresponding scheduled tasks are made for the script to run automatically.
1. Mount Windows share to/mnt/share
[Root@game-syslog-o/]mount-t Cifs-o
Username=switchbackup@game-inc.com,password=p@ssw0rd
192.168.36.74/back
In the ordinary work need to back up the switch configuration regularly, if a manual backup, the workload is very large, there is no good tool to reduce the workload of our backup? After searching for data, it is found that expect scripts can be used to implement, expect can interact with the shell to enable the Linux shell to support interaction. Allows us to lo
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.