Connecting to Your Server: SFTP, FTP, and SSH | Welcome to docs.nine.ch

  • 20,000
  • Tác giả: admin
  • Ngày đăng:
  • Lượt xem: 20
  • Tình trạng: Còn hàng

This article will guide you through the process of connecting to tướng your server using the three common protocols SFTP, FTP, and SSH.

The different protocols

  • SFTP: Use SFTP when you need a secure and encrypted way to tướng transfer files, especially for sensitive data.
  • FTP: FTP is for tệp tin transfers and does not use encryption. It should only be used if no other option is available.
  • FTPS FTPS is FTP with added security through TLS/SSL encryption. It is suitable for secure tệp tin transfers.
  • SSH: To remotely connect to tướng your server

Preparation​

Before we begin, ensure you have the following information ready:

  • Server IP address or hostname
  • Username and password for the user you'd lượt thích to tướng connect with
  • A Client, if needed
  • Port number:
ProtocolPort Number
SSH22
FTP, FTPS21
SFTP1122

Connecting to tướng Your Server​

Using FTP (File Transfer Protocol) or FTPS (FTP over TLS/SSL)​

  • Port: Port 21 is used for both FTP and FTPS.
  • User: Users created via FTPAdmin, nine-manage-vhosts, Linux OS users, and www-data users can use FTP and FTPS.

To connect to tướng your server, you can use the ftp command:

ftp userName@Server-IP_Address

Using SSH (Secure Shell)​

  • Port: Port 22 is used for access via the SSH protocol
  • User: Only users created with nine-manage-vhosts and the www-data user

You can simply use the command ssh:

ssh userName@Server-IP_Address

Using SFTP (Secure File Transfer Protocol)​

  • Port: Port 1122 and 22 are used for access via the SFTP protocol depending on the kind of user
  • User: the users that are created using FTPAdmin, the users created with nine-manage-vhosts and the www-data user can access

To connect to tướng your FTP server, you have to tướng use the sftp command:

FTPAdmin users:

sftp -P 1122 userName@Server-IP_Address

www-data and nine-manage-vhost users:

sftp -P 22 userName@Server-IP_Address

Access via Client​

  • Client: A client should be installed, for example, FileZilla.
  • Protocol: Protocols should be given, for example, if you want to tướng connect via SFTP: sftp://

Connect to tướng your server with FileZilla​

FileZilla is a client application that makes connecting to tướng servers via FTP or SFTP a simple task. Follow these steps to tướng connect to tướng your server with FileZilla.

Step 1: Start FileZilla

First, open FileZilla on your local computer (if not installed, you will have to tướng install it). The FileZilla user interface should look similar to tướng the screenshot below.

Image 1

Step 2: Configure the connection details

In the top section of FileZilla, enter the required connection details and click the "Connect" button.

Server: enter the IP or host name of your server. For this example, "saad-test01".

Important: you will to tướng enter the protocol you want to tướng use before the host name or ip:

  • FTP Connection: ftp://saad-test01
  • SFTP Connection: sftp://saad-test01
  • SSH Connection: saad-test01

Username: Enter the username. In this case, we use "saad".

Password: Enter the password of the user

Port: choose the port that you want to tướng connect to:

  • SSH: 22
  • FTP: 21
  • SFTP: 1122

Image 2

Step 3: Access Server Files

As soon as the connection to tướng your trang web hosting is established, FileZilla displays the server-side directory structure on the right side of the user interface.

Image 3

Access via SCP/SFTP​

  • Port: To connect to tướng the server via SCP or SFTP, you must use port 1122.
  • Users: All users phối up through FTPAdmin can connect to tướng the server using both FTP(S) and SFTP.

When using scp, the port can be specified with the command line option -P as follows:

scp -P 1122 your_file userName@Server-IP_Address:/path/to/destination/