Home PC Games Linux Windows Database Network Programming Server Mobile  
           
  Home \ Server \ Cross server / client backup command: rsync use     - MBR partitions under Linux (Linux)

- Terminal Linux command prints - echo (Linux)

- The Linux role of each directory contents (Linux)

- Binary tree traversal algorithm summary (recursive and non-recursive) (Programming)

- Linux, modify / retrieve the root password (Linux)

- Git uses a small mind (Linux)

- CentOS Linux firewall configuration and Close (Linux)

- MySQL composite partition (Database)

- Deploy Apache Spark cluster environment in Ubuntu (Server)

- Nginx log cutting and MySQL script regular backup script (Server)

- Django Signals from practice to source code analysis (Programming)

- Linux common network tools: batch scanning of hosting services netcat (Linux)

- Run two MySQL service on one server (Database)

- Java reflection mechanism explained in detail and Method.invoke explanation (Programming)

- netfilter- in kernel mode network packet operation (Linux)

- Configuring automatic mail GAMIT under CentOS system (Linux)

- Depth understanding of C language (Programming)

- How to use secure FTP file transfer (Server)

- Use LKM change the default linux security level (Linux)

- Transplant spider to MySQL 5.6 (Database)

 
         
  Cross server / client backup command: rsync use
     
  Add Date : 2017-08-31      
         
         
         
  Often recently deployed on a new server environment, a lot of things can be directly from other servers back up without having to re-download the installation.

Is to use the rsync command: first to download rsync and install to the "source server", the specific process of the connection at the end of this article.

Then configure the rsync.conf file in the "source server", typically in /etc/rsyncd.conf.

Add the following statement to the file:

[test]
Path = / data1 / test/
Uid = root
Gid = root
Read only = no
Hosts allow = 127.0.0.1/16 ***** / 255.255.255.0

Save and run the command: usr / bin / rsync --daemon --config = / etc / rsyncd.conf

And then run the command in the target server: rsync -avzP root @ **. **. **. **: test/ data1 / test/ test / (where ******* is the "source server" IP)

Then if there is no problem will see the progress bar.

Clear the rsync error report

Rsync configure:

Configuration 1:

Ignore errors

Note: This option is best to add, or a lot of crontab often wrong when you do not know, because you can not see every day to see every moment of the log, without the probability of this error will be relatively high , Because any large point of the project and system, disk IO is a bottleneck

Rsync error:
Error one:
@ERROR: auth failed on module xxxxx
Rsync: connection unexpectedly closed (90 bytes read so far)
Rsync error: error in rsync protocol data stream (code 12) at io.c (150)
Description: This is because the password is set wrong, can not log in successfully, check rsync.pwd, to see whether the customer service match. There is no server-side services will start rsync This happens.

Error two:
Password file must not be other-accessible
Continuing without password file
Password:
Explanation: This is because rsyncd.pwd rsyncd.sec permissions are wrong, it should be set to 600. For example: chmod 600 rsyncd.pwd

Error three:
@ERROR: chroot failed
Rsync: connection unexpectedly closed (75 bytes read so far)
Rsync error: error in rsync protocol data stream (code 12) at io.c (150)
Note: This is because you set the path in rsync.conf path does not exist, to create a new directory to start synchronization

Error four:
Rsync: failed to connect to 218.107.243.2: No route to host (113)
Rsync error: error in socket IO (code 10) at clientserver.c (104) [receiver = 2.6.9]
Note: Firewall problems, this is best to completely turn off the firewall, the basic method of troubleshooting is the case, whether it is S or C, as well as ignore errors option problem will lead to

Error 5:

@ERROR: access denied to www from unknown (192.168.1.123)
Rsync: connection unexpectedly closed (0 bytes received so far) [receiver]
Rsync error: error in rsync protocol data stream (code 12) at io.c (359)

Note: This problem is obvious, is the configuration option host allow problem, beginners like to allow a segment into a configuration, and then the module is the same, resulting in

Error six:

Rsync error: received SIGINT, SIGTERM, or SIGHUP (code 20) at rsync.c (244) [generator = 2.6.9]
Rsync error: received SIGUSR1 (code 19) at main.c (1182) [receiver = 2.6.9]

Note: Most of this problem is caused by the server does not start the normal service to the server up to check whether the service is started, and then check / var / run / rsync.pid file exists, the most simple way is to kill has started Service, and then start the service again or allow the script to join the system startup service level and then shutdown-r now server

Error seven:

Rsync: read error: Connection reset by peer (104)
Rsync error: error in rsync protocol data stream (code 12) at io.c (604) [sender = 2.6.9]

Explanation: There is no data in the original data directory
     
         
         
         
  More:      
 
- Oracle TDE transparent data encryption (Database)
- Recycle Bin function realization in Linux (Linux)
- RHEL5 establish a local yum source (Linux)
- Linux server alarms using Java (Server)
- Linux `dirname $ 0` (Linux)
- C ++ you can become a new scripting language (Programming)
- Nodejs complete installation instructions for Express (Linux)
- Examples 14 grep command (Linux)
- CentOS installation Docker series (Linux)
- Introduction to Linux Shell (Programming)
- Install JDK 1.7 + Eclipse in CentOS 6.4 in (Linux)
- Use Spring cache and ehcache (Programming)
- MyCAT log analysis (Database)
- Linux system security settings (Linux)
- The maximum subsequence algorithm and optimization problems (Programming)
- Gnu Linux - Ubuntu System Clean-term consolidation (Linux)
- Ubuntu terminal command - see the port occupied and off (Linux)
- Oracle database, some basic grammatical structures (Database)
- mysqldump issue a note (Database)
- Git / Github use notes (Linux)
     
           
     
  CopyRight 2002-2020 newfreesoft.com, All Rights Reserved.