How to customize backup network files

Source: Internet
Author: User
Tags robocopy

Q: Due to work requirements, I need to regularly back up several data files of the three servers in the LAN to my PC. Do you have any good Network Timing backup software, you only need to set the task to perform scheduled backup.

A: If you do not want to use third-party software to complete the task, you can use the batch processing and scheduled task to achieve the automatic backup function you mentioned. This requires you to be familiar with batch processing.

For example, use Microsoft's robocopy tool to share the file you want to back up (Windows 2008 has been built in, Windows2003 also needs to Download Windows Server 2003 Resource Kit tools before installation ). Here is only an example for your reference:

Host a 192.168.10.1

Host B 192.168.10.254

If you want to back up the X Files shared by machine a, a folder named "backup" is automatically created under the e disk "backup" folder of machine B at every night, then copy all the data in the X folder on machine A to this folder.CodeAs follows:

@ Echo off

MD "E: \ x \ % Date :~ 0, 4%"

C:

Cd "C: \ Program Files \ Windows resource kits \ tools \"

Robocopy \ 192.168.10.1 \ x "E: \ backup \ % Date :~ 0, 4% "/e/copyall/MIR

Write the above Code into notepad and save it as a "*. Bat" batch processing file, and then use the scheduled task to call it regularly on a daily basis. If the batch processing contains Chinese characters, you 'd better select ANSI encoding.

Net use \ 192.168.10.1 PWD/User: Administrator

Contact Us

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.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.