Get the App
SLTechnology News&Howtos  ›  Servers  › 

Scp remote replication

Shulou Source: shulou.com Published: 2022-06-03 01:55:28 09月22日 Update

Experiment content: use SCP remote copy file to copy hosts file from one host to another host hosts and use DNS parsing

Experimental environment: two hosts, one host A (192.168.195.128) and the other host B (192.168.109.132)

1. Synchronize local files to other servers

Scp local synchronization file path user @ ip: remote server file path

[root@localhost ~] # scp / etc/hosts root@192.168.195.129:/etc/hosts synchronizes the local / etc/hosts file to the / etc/hosts of the server with IP 129

2. Synchronize each other's server files locally

Scp user @ ip: remote server file path local synchronization file path

[root@localhost ~] # scp root@192.168.195.128:/etc/hosts / etc/hosts synchronizes the / etc/hosts file from the server with IP 128to the local / etc/hosts

The scp remote replication experiment is completed.

Tags: Files hosts servers synchronization services paths labs users content each other environment Apple Docker Huawei Linux macOS MariaDB Microsoft MySQL NVidia OPPO Reno Shulou Tech Info Docker Shulou Technology NVidia MariaDB