Use securecrt to transfer files between Linux and Windows

Source: Internet
Author: User
Tags ftp commands

 

SecurecrtThis SSH client software has both terminal simulators andFileTransmission function. It is much more convenient than FTP commands, and the server no longer needs to enable the FTP service. Rz, SZ isLinux/Same as UNIXWindowsPerform zmodemFileThe command line tool for transmission.

  WindowsThe client must support the zmodem Telnet/ssh client,SecurecrtYou can useSecurecrtLog on to UNIX/LinuxHost (either telnet or SSH ).

UploadFileEnter the command "RZ" in the shell terminal simulator to selectFileAnd use zmodem to upload data to the server. DownloadFileJust enter the command "SZ" in the shell terminal SimulatorFileYou can use zmodemFileDownload to "path/Securecrt-5.1.3/download/"directory. You can use "file transfer" to modify the default upload and download paths. Set the default directory: options --> session options -->File Transfer.

Note:Options --> global options --> terminal, you can set the copy and paste of the mouse.

If you wantChangeSecurecrtTerminal background color andFileName color. You only need to click "option"-"session option" on the menu bar ", select "ANSI color" and "select a backup keyboard simulation" in the "terminal"-"simulation" category's right window-Linux".

 

 

 

 

 

SummarySecurecrtThree methods for transferring files.

1. SCP
SCP can be used between two Linux HostsCopy a file
SCP [-1246 bcpqrv] [-C cipher] [-F ssh_config] [-I identity_file] [-l limit] [-O ssh_option] [-P port] [-s program] [[user @] host1:] file1 [...] [[user @] host2:] file2

 

SCP-P port user @ serverip:/home/user/filename

The above Port uses uppercase P as the parameter, the port user is the SSH user serverip is the remote server IP or domain name, And/home/user/filename is the remote server'sFileThe name/home/user/filename is the name of the Local Service server. This command is used to copy the remote filename to the local directory.

For example, upload the file to the Management Server [root @ localhost ~] # SCP./load. Sh yinliu@59.53.86.118

*Copy a file:
* Command format:
SCP local_file remote_username @ remote_ip: remote_folder
Or
SCP local_file remote_username @ remote_ip: remote_file
Or
SCP local_file remote_ip: remote_folder
Or
SCP local_file remote_ip: the username is specified for the remote_file, And the password is required after the command is executed. Only the remote directory is specified for the 1st files, the file name remains the same, and the file name is specified for the 2nd files;
No user name is specified for the 3 and 4 commands. After the command is executed, enter the user name and password. Only the remote directory is specified for the 3rd commands. The file name remains the same and the file name is specified for the 4th commands;

* Copy directory:
* Command format:
SCP-r local_folder remote_username @ remote_ip: remote_folder
Or
SCP-r local_folder remote_ip: remote_folder

1st user names are specified, and the password needs to be entered after the command is executed;
2nd user names are not specified. After the command is executed, enter the user name and password;
* Routine:
SCP-r/home/SPACE/music/root@www.cumt.edu.cn:/home/root/Others/
SCP-r/home/SPACE/music/www.cumt.edu.cn:/home/root/Others/

The above Command copies the local music directory to the remote others directory, that is, there is a remote ../Others/music/directory after the copy.

======
Copy from remote to local
======
From remote to local, you only need to replace the last two parameters of the local command to remote;

For example:
SCP root@www.cumt.edu.cn:/home/root/Others/music/home/SPACE/music/ithers
SCP-r www.cumt.edu.cn:/home/root/Others/home/SPACE/music/

SCP is easy to use, but it cannot list remote directories or change directories.

2. zmodem file send/Recv
RZ: to upload a file, you only need to enter the command "RZ" in the shell terminal simulator to select the file on the local disk from the pop-up dialog box and use zmodem to upload the file to the server, for example, upload an rsyncd. CONF file to the server ):
[Root @ localhost ~] # Rz
Rz waiting to receive.
Zmodem transmission is starting. Press Ctrl + C to cancel.
Transmitting rsyncd. conf...
100% 715 bytes 715 Bytes/s 00:00:01 0 Error
SZ: to download a file, you only need to enter the command "SZ file name" in the shell terminal simulator to download the file to the "path/Securecrt-5.1.3/download/"directory, for example, download the rsyncd. conf file in the current directory of the server to a local directory ):
[Root @ localhost ~] # SZ rsyncd. conf
Rz
Zmodem transmission is starting. Press Ctrl + C to cancel.
Transmitting rsyncd. conf...
100% 715 bytes 715 Bytes/s 00:00:01 0 Error

3. SFTP
SecurecrtPress Alt + P to start a new session for FTP operation.
Enter the "help" command to display all commands provided by the FTP.
PWD: query the directory of the Linux host (that is, the remote host directory)
Lpwd: query the local directory (generally refers to the directory of files uploaded by Windows: we can view the "session option" in the "option" drop-down box. 2: we know that the local upload directory is: D: /My Documents)
Ls: query the files in the directory of the current Linux host.
LLS: queries the files in the current local upload directory.
LCD: change the path of the local upload directory
CD: Change the remote upload directory
Get: downloads files from the remote directory to the local directory.
Put: upload files in the local directory to the remote host (Linux)
Quit: disconnect FTP

 

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.