How to Install FTP Server in Linux

How to Install FTP Server in Linux thumbnail
Install FTP Server in Linux

File Transfer Protocol, or FTP, is a robust, secure way of sharing files via a client-server model. As a Unix variant, Linux is an ideal platform for an FTP server. A popular, and very secure, FTP server available for almost all Linux systems is vsftp (Very Secure FTP). Installing and setting up vsftp in a Linux environment is a simple process.

Instructions

    • 1

      Download and install the Linux package vsftp. The exact procedure will vary depending on the type and version of Linux you are running. In most cases, for example with Red Hat, Suse or Ubuntu, vsftp is a stable package that is included in the repositories that are used to update your version of Linux. In many Linux installations, vsftp is installed by default, but not started.

    • 2

      Configure VSFTP. The exact location and name of the configuration file will vary slightly depending on the version of Linux you are using. In Ubuntu, the configuration file is "vsftpd.conf." Edit this file to change the following settings:
      *ftpd_banner: Edits the message that is displayed when someone connects to the server.
      *listen: Enables vsfppd to run in stand alone mode.
      *xferlog_enable: Enables a detailed log of uploads and downloads.
      *connect_from_port_20: Defines whether PORT style connections use port 20 on the server.
      *hide_ids: Hides user IDs, listing all group users as "ftp."
      *max_client: Defines the maximum number of connections allowed in standalone mode.
      *max_per_ip: Defines the highest number of connections allowed from a particular IP in standalone mode.
      *anon_root: Defines the root directory for anonymous FTP users.
      *anonymous_enable: Enables anonymous users.
      *anon_mkdir_write_enable: Allows anonymous users to create directories. For this option to work, the server must have anonymous uploads enabled, and the ftp user and group must have write permissions on the directory where the new directories will be created.

    • 3

      Once the file vsftpd.conf has been edited to your satisfaction, save the file.

    • 4

      Stop the vsftpd server by typing "sudo /etc/init.d/vsftpd stop." You should see a message confirming that the server has stopped.

    • 5

      Restart the vsftp server with the new configuration data in /etc/vsftpd.conf by typing "sudo /etc/init.d/vsftpd start." You should see a message confirming that the server has started.

Tips & Warnings

  • You must have root/superuser privileges to edit vsftp.conf. In systems with root disabled, using sudo to run vi to edit vsftpd.conf will work. The above list of vsftp configuration options is not exhaustive, but they are the most common options.

  • Running an FTP daemon will open port 20 and 21 on your computer, although vsftp is very secure, it could still create a slightly higher risk on highly secure systems.

Related Searches:

Resources

  • Photo Credit Photo: T. Al Nakib, stock.xchng

Comments

You May Also Like

Related Ads

Featured