How to transfer two files on different Linux computer

There are many methods to transfer files on different Linux computer, but you can try scp and sftp. It was using SFTP, a network protocol that enables file transfer and manipulation functionality over any reliable data stream.

it was enabled by using SSH-2 protocol (TCP port 22) to provide secure file transfer,

  1. First, define the ip address of both computer, and make sure both computer can communicate each other, you could use ping to know whether the computer can talk each other.
    ping 192.168.0.1
  2. Check whether ssh is enabled, you could use ssh user@remoteComputer
  3. If the command makes error, it means the ssh server and client haven’t yet installed, install it by executing # sudo apt-get install openssh-server openssh-client.
  4. To test, whether your computer already can be ssh-ed, execute # ssh localhost user@192.168.0.10
    Connecting to 192.168.0.107…
    vhazrati@192.168.0.10
    password: <enter the password>
    sftp>
  5. To get the files, you could execute sftp> get file_name /home/user/documents

Tags: , , ,

Google
 

Leave a Reply

54 views