{"id":5572,"date":"2023-12-01T11:47:28","date_gmt":"2023-12-01T11:47:28","guid":{"rendered":"https:\/\/natsav.com\/blog\/?p=5572"},"modified":"2024-01-31T12:26:19","modified_gmt":"2024-01-31T12:26:19","slug":"install-ftp-on-ubuntu","status":"publish","type":"post","link":"https:\/\/natsav.com\/blog\/install-ftp-on-ubuntu\/","title":{"rendered":"A Step-by-Step Guide: Installing an FTP Server on Ubuntu"},"content":{"rendered":"<div id=\"ez-toc-container\" class=\"ez-toc-v2_0_68_1 counter-hierarchy ez-toc-counter ez-toc-light-blue ez-toc-container-direction\">\n<div class=\"ez-toc-title-container\">\n<p class=\"ez-toc-title \" >Table of Contents<\/p>\n<span class=\"ez-toc-title-toggle\"><a href=\"#\" class=\"ez-toc-pull-right ez-toc-btn ez-toc-btn-xs ez-toc-btn-default ez-toc-toggle\" aria-label=\"Toggle Table of Content\"><span class=\"ez-toc-js-icon-con\"><span class=\"\"><span class=\"eztoc-hide\" style=\"display:none;\">Toggle<\/span><span class=\"ez-toc-icon-toggle-span\"><svg style=\"fill: #999;color:#999\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\" class=\"list-377408\" width=\"20px\" height=\"20px\" viewBox=\"0 0 24 24\" fill=\"none\"><path d=\"M6 6H4v2h2V6zm14 0H8v2h12V6zM4 11h2v2H4v-2zm16 0H8v2h12v-2zM4 16h2v2H4v-2zm16 0H8v2h12v-2z\" fill=\"currentColor\"><\/path><\/svg><svg style=\"fill: #999;color:#999\" class=\"arrow-unsorted-368013\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"10px\" height=\"10px\" viewBox=\"0 0 24 24\" version=\"1.2\" baseProfile=\"tiny\"><path d=\"M18.2 9.3l-6.2-6.3-6.2 6.3c-.2.2-.3.4-.3.7s.1.5.3.7c.2.2.4.3.7.3h11c.3 0 .5-.1.7-.3.2-.2.3-.5.3-.7s-.1-.5-.3-.7zM5.8 14.7l6.2 6.3 6.2-6.3c.2-.2.3-.5.3-.7s-.1-.5-.3-.7c-.2-.2-.4-.3-.7-.3h-11c-.3 0-.5.1-.7.3-.2.2-.3.5-.3.7s.1.5.3.7z\"\/><\/svg><\/span><\/span><\/span><\/a><\/span><\/div>\n<nav><ul class='ez-toc-list ez-toc-list-level-1 ' ><li class='ez-toc-page-1 ez-toc-heading-level-4'><a class=\"ez-toc-link ez-toc-heading-1\" href=\"https:\/\/natsav.com\/blog\/install-ftp-on-ubuntu\/#Step_1_Update_and_Upgrade_Your_Server\" title=\"Step 1: Update and Upgrade Your Server\">Step 1: Update and Upgrade Your Server<\/a><ul class='ez-toc-list-level-6' ><li class='ez-toc-heading-level-6'><ul class='ez-toc-list-level-6' ><li class='ez-toc-heading-level-6'><a class=\"ez-toc-link ez-toc-heading-2\" href=\"https:\/\/natsav.com\/blog\/install-ftp-on-ubuntu\/#sudo_apt_update_sudo_apt_upgrade\" title=\"#sudo apt update \n#sudo apt upgrade\">#sudo apt update \n#sudo apt upgrade<\/a><\/li><\/ul><\/li><\/ul><\/li><li class='ez-toc-page-1 ez-toc-heading-level-4'><a class=\"ez-toc-link ez-toc-heading-3\" href=\"https:\/\/natsav.com\/blog\/install-ftp-on-ubuntu\/#Step_2_Install_vsftpd\" title=\"Step 2: Install vsftpd\">Step 2: Install vsftpd<\/a><ul class='ez-toc-list-level-6' ><li class='ez-toc-heading-level-6'><ul class='ez-toc-list-level-6' ><li class='ez-toc-heading-level-6'><a class=\"ez-toc-link ez-toc-heading-4\" href=\"https:\/\/natsav.com\/blog\/install-ftp-on-ubuntu\/#sudo_apt_install_vsftpd\" title=\"#sudo apt install vsftpd\">#sudo apt install vsftpd<\/a><\/li><\/ul><\/li><\/ul><\/li><li class='ez-toc-page-1 ez-toc-heading-level-4'><a class=\"ez-toc-link ez-toc-heading-5\" href=\"https:\/\/natsav.com\/blog\/install-ftp-on-ubuntu\/#Step_3_Configure_vsftpd\" title=\"Step 3: Configure vsftpd\">Step 3: Configure vsftpd<\/a><ul class='ez-toc-list-level-6' ><li class='ez-toc-heading-level-6'><ul class='ez-toc-list-level-6' ><li class='ez-toc-heading-level-6'><a class=\"ez-toc-link ez-toc-heading-6\" href=\"https:\/\/natsav.com\/blog\/install-ftp-on-ubuntu\/#sudo_nano_etcvsftpdconf\" title=\"#sudo nano \/etc\/vsftpd.conf\">#sudo nano \/etc\/vsftpd.conf<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-6'><a class=\"ez-toc-link ez-toc-heading-7\" href=\"https:\/\/natsav.com\/blog\/install-ftp-on-ubuntu\/#sudo_systemctl_restart_vsftpd\" title=\"#sudo systemctl restart vsftpd\">#sudo systemctl restart vsftpd<\/a><\/li><\/ul><\/li><\/ul><\/li><li class='ez-toc-page-1 ez-toc-heading-level-4'><a class=\"ez-toc-link ez-toc-heading-8\" href=\"https:\/\/natsav.com\/blog\/install-ftp-on-ubuntu\/#Step_4_Open_FTP_Ports_in_Firewall\" title=\"Step 4: Open FTP Ports in Firewall\">Step 4: Open FTP Ports in Firewall<\/a><ul class='ez-toc-list-level-6' ><li class='ez-toc-heading-level-6'><ul class='ez-toc-list-level-6' ><li class='ez-toc-heading-level-6'><a class=\"ez-toc-link ez-toc-heading-9\" href=\"https:\/\/natsav.com\/blog\/install-ftp-on-ubuntu\/#sudo_ufw_allow_21\" title=\"#sudo ufw allow 21\">#sudo ufw allow 21<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-6'><a class=\"ez-toc-link ez-toc-heading-10\" href=\"https:\/\/natsav.com\/blog\/install-ftp-on-ubuntu\/#sudo_ufw_enable\" title=\"#sudo ufw enable\">#sudo ufw enable<\/a><\/li><\/ul><\/li><\/ul><\/li><li class='ez-toc-page-1 ez-toc-heading-level-4'><a class=\"ez-toc-link ez-toc-heading-11\" href=\"https:\/\/natsav.com\/blog\/install-ftp-on-ubuntu\/#Step_5_Test_the_FTP_Server\" title=\"Step 5: Test the FTP Server\">Step 5: Test the FTP Server<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-4'><a class=\"ez-toc-link ez-toc-heading-12\" href=\"https:\/\/natsav.com\/blog\/install-ftp-on-ubuntu\/#Conclusion\" title=\"Conclusion:\">Conclusion:<\/a><\/li><\/ul><\/nav><\/div>\n<h4><span class=\"ez-toc-section\" id=\"Step_1_Update_and_Upgrade_Your_Server\"><\/span>Step 1: Update and Upgrade Your Server<span class=\"ez-toc-section-end\"><\/span><\/h4>\n<p>Before you begin the installation process, it&#8217;s essential to ensure that your Ubuntu Server is up to date. Open a terminal and run the following commands:<\/p>\n<div class=\"bg-black rounded-md\">\n<div class=\"flex items-center relative text-gray-200 bg-gray-800 dark:bg-token-surface-primary px-4 py-2 text-xs font-sans justify-between rounded-t-md\"><\/div>\n<h6 class=\"p-4 overflow-y-auto\"><span class=\"ez-toc-section\" id=\"sudo_apt_update_sudo_apt_upgrade\"><\/span><code class=\"!whitespace-pre hljs language-bash\">#sudo apt update<br \/>\n#sudo apt upgrade<br \/>\n<\/code><span class=\"ez-toc-section-end\"><\/span><\/h6>\n<\/div>\n<p>This will update the package lists and upgrade the installed packages on your Server.<\/p>\n<h4><span class=\"ez-toc-section\" id=\"Step_2_Install_vsftpd\"><\/span>Step 2: Install vsftpd<span class=\"ez-toc-section-end\"><\/span><\/h4>\n<p>For this guide, we&#8217;ll use vsftpd (Very Secure FTP Daemon), a fast and secure FTP server for Unix-like systems. To install vsftpd, run the following command:<\/p>\n<div class=\"bg-black rounded-md\">\n<div class=\"flex items-center relative text-gray-200 bg-gray-800 dark:bg-token-surface-primary px-4 py-2 text-xs font-sans justify-between rounded-t-md\"><\/div>\n<h6 class=\"p-4 overflow-y-auto\"><span class=\"ez-toc-section\" id=\"sudo_apt_install_vsftpd\"><\/span><code class=\"!whitespace-pre hljs language-bash\">#sudo apt install vsftpd<br \/>\n<\/code><span class=\"ez-toc-section-end\"><\/span><\/h6>\n<\/div>\n<p>During the installation process, you may be prompted to confirm the installation. Type &#8216;Y&#8217; and press Enter to proceed.<\/p>\n<h4><span class=\"ez-toc-section\" id=\"Step_3_Configure_vsftpd\"><\/span>Step 3: Configure vsftpd<span class=\"ez-toc-section-end\"><\/span><\/h4>\n<p>Once the installation is complete, you&#8217;ll need to configure vsftpd to meet your specific requirements. Open the configuration file using a text editor. In this example, we&#8217;ll use nano:<\/p>\n<div class=\"bg-black rounded-md\">\n<div class=\"flex items-center relative text-gray-200 bg-gray-800 dark:bg-token-surface-primary px-4 py-2 text-xs font-sans justify-between rounded-t-md\"><\/div>\n<h6 class=\"p-4 overflow-y-auto\"><span class=\"ez-toc-section\" id=\"sudo_nano_etcvsftpdconf\"><\/span><code class=\"!whitespace-pre hljs language-bash\">#sudo nano \/etc\/vsftpd.conf<br \/>\n<\/code><span class=\"ez-toc-section-end\"><\/span><\/h6>\n<\/div>\n<p>Inside the configuration file, you can make various adjustments. For example, you might want to enable anonymous FTP or restrict users to their home directories. Save the changes and exit the editor.<\/p>\n<p>After making changes, restart vsftpd to apply the new configurations:<\/p>\n<div class=\"bg-black rounded-md\">\n<div class=\"flex items-center relative text-gray-200 bg-gray-800 dark:bg-token-surface-primary px-4 py-2 text-xs font-sans justify-between rounded-t-md\"><\/div>\n<h6 class=\"p-4 overflow-y-auto\"><span class=\"ez-toc-section\" id=\"sudo_systemctl_restart_vsftpd\"><\/span><code class=\"!whitespace-pre hljs language-bash\">#sudo systemctl restart vsftpd<br \/>\n<\/code><span class=\"ez-toc-section-end\"><\/span><\/h6>\n<\/div>\n<h4><span class=\"ez-toc-section\" id=\"Step_4_Open_FTP_Ports_in_Firewall\"><\/span>Step 4: Open FTP Ports in Firewall<span class=\"ez-toc-section-end\"><\/span><\/h4>\n<p>If you have a firewall enabled on your server, you need to open the FTP ports (default is 21) to allow external connections. Use the following command to open port 21:<\/p>\n<div class=\"bg-black rounded-md\">\n<div class=\"flex items-center relative text-gray-200 bg-gray-800 dark:bg-token-surface-primary px-4 py-2 text-xs font-sans justify-between rounded-t-md\"><\/div>\n<h6 class=\"p-4 overflow-y-auto\"><span class=\"ez-toc-section\" id=\"sudo_ufw_allow_21\"><\/span><code class=\"!whitespace-pre hljs language-bash\">#sudo ufw allow 21<br \/>\n<\/code><span class=\"ez-toc-section-end\"><\/span><\/h6>\n<\/div>\n<p>Don&#8217;t forget to enable the firewall if it&#8217;s not already running:<\/p>\n<div class=\"bg-black rounded-md\">\n<div class=\"flex items-center relative text-gray-200 bg-gray-800 dark:bg-token-surface-primary px-4 py-2 text-xs font-sans justify-between rounded-t-md\"><\/div>\n<h6 class=\"p-4 overflow-y-auto\"><span class=\"ez-toc-section\" id=\"sudo_ufw_enable\"><\/span><code class=\"!whitespace-pre hljs language-bash\">#sudo ufw <span class=\"hljs-built_in\">enable<\/span><br \/>\n<\/code><span class=\"ez-toc-section-end\"><\/span><\/h6>\n<\/div>\n<h4><span class=\"ez-toc-section\" id=\"Step_5_Test_the_FTP_Server\"><\/span>Step 5: Test the FTP Server<span class=\"ez-toc-section-end\"><\/span><\/h4>\n<p>To ensure that your FTP server is working correctly, you can test it by connecting to it using an FTP client. Open your preferred FTP client and enter your server&#8217;s IP address, username, and password. If everything is set up correctly, you should be able to establish a connection and transfer files.<\/p>\n<h4><span class=\"ez-toc-section\" id=\"Conclusion\"><\/span>Conclusion:<span class=\"ez-toc-section-end\"><\/span><\/h4>\n<p>Congratulations! You&#8217;ve successfully installed and configured an FTP server on your Ubuntu system.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Step 1: Update and Upgrade Your Server Before you begin the installation process, it&#8217;s essential to ensure that your Ubuntu Server is up to date. Open a terminal and run the following commands: #sudo apt update #sudo apt upgrade This will update the package lists and upgrade the installed packages on your Server. Step 2: [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":5573,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_jetpack_memberships_contains_paid_content":false,"footnotes":""},"categories":[255],"tags":[],"jetpack_sharing_enabled":true,"jetpack_featured_media_url":"https:\/\/i0.wp.com\/natsav.com\/blog\/wp-content\/uploads\/2023\/12\/ftp.png?fit=497%2C271&ssl=1","jetpack-related-posts":[],"_links":{"self":[{"href":"https:\/\/natsav.com\/blog\/wp-json\/wp\/v2\/posts\/5572"}],"collection":[{"href":"https:\/\/natsav.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/natsav.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/natsav.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/natsav.com\/blog\/wp-json\/wp\/v2\/comments?post=5572"}],"version-history":[{"count":6,"href":"https:\/\/natsav.com\/blog\/wp-json\/wp\/v2\/posts\/5572\/revisions"}],"predecessor-version":[{"id":5579,"href":"https:\/\/natsav.com\/blog\/wp-json\/wp\/v2\/posts\/5572\/revisions\/5579"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/natsav.com\/blog\/wp-json\/wp\/v2\/media\/5573"}],"wp:attachment":[{"href":"https:\/\/natsav.com\/blog\/wp-json\/wp\/v2\/media?parent=5572"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/natsav.com\/blog\/wp-json\/wp\/v2\/categories?post=5572"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/natsav.com\/blog\/wp-json\/wp\/v2\/tags?post=5572"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}