Skip to content
View in the app

A better way to browse. Learn more.

Unraid

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

A guide to run VSFTPD on your Unraid-server.

Featured Replies

DISCLAIMER: There are some commands that can lead to loss of data if misspelled or if you don't know what they perform. Please read the guide first, berfore tempting to make any changes, and make sure you understand the consequences of making changes to your system. I take no responsibility for others system. You make your own decisions.

 

Since upgrading to UR 7.0 broke the well known ProFTPD, I decided to try and give you a simple guide on how to configure VSFTPD.

 

As some of you know, VSFTPD come as a built-in service in Unraid, but many find it hard to setup.

One of the main reasons, are due to reset of the config and the service on the next restart of UR.

 

Bare in mind, that there might be some configuration faults in the vsftpd.conf file, so please guide me if there is something wrong.

This have worked for my setup, so there might be other configs you rather prefere.

 

Lets get started.

The first thing you need to do, is setup a user account in Unraids "Users" settings. There are many guides on the net, on how to create this.

I decided to create some Test-users (test, test1, test2), but you can use whatever name you want. 

 

It is not necessary to give the user any share rights, but it will be usefull if you want the user to be able to map shares locally in your network.

image.png.a2fead6057ddfa565c4144c24e54cd36.png|

You also need to create a share to allow FTP into. Mine says FTP, and contains no files. :)

image.png.6789c11826a7c874bae72f3a324247a3.png

 

Next, start the Terminal windows in your upper right corner of UR, and type the following.

 

nano /boot/config/vsftpd.conf

 

This will open an linux editor. Paste the following lines into the editor.

 

# vsftpd.conf for unRAID
# with suggestions from forum user 'nars'
#
connect_from_port_20=YES
write_enable=YES
chroot_local_user=YES
allow_writeable_chroot=YES
local_root=/mnt/user/FTP
local_umask=0
#
# No anonymous logins
anonymous_enable=NO
#
# Allow only local vsftpd.user_list users to log in.
local_enable=YES
userlist_enable=YES
userlist_deny=NO
userlist_file=/boot/config/vsftpd.user_list
check_shell=NO
#
# Logging to syslog
syslog_enable=YES
log_ftp_protocol=NO
xferlog_enable=NO
#
# Misc.
dirmessage_enable=NO
ls_recurse_enable=YES
listen=NO
seccomp_sandbox=NO
#
# Enable PASSIVE mode
pasv_enable=Yes
pasv_min_port=60000
pasv_max_port=65535

 

To exit the editor simply press the key comination of CTRL and X. You will be asked to "Save modified buffer?", press Y, and next hit ENTER when asked "File Name to Write:"

 

You have now created a general config for use with VSFTPD, with some extra parameters.

# To jail the user to specific folder

chroot_local_user=YES

allow_writeable_chroot=YES

# You might want to change this setting into your share folder. Mine share folder is FTP, see pic. above.

local_root=/mnt/user/FTP

# Prevent the user from seeing and accessing shares higher up in the tree.

ls_recurse_enable=NO

# Enable PASSIVE mode, is usefull behind router/firewalls, and need to open ports.

pasv_enable=Yes
pasv_min_port=60000
pasv_max_port=65535

 

Now open up Apps in your UR menu and search for User scripts, and install it.

image.png.f19359ec596c8c289578ae642b850884.png

 

The reason why I choose this plugins instead of writing everything into /boot/config/go file, is to simplify the configuration of users accessing the FTP-server, and to do some other tweaks i.e. add some share folders.

 

Start the plugin, and chose "ADD NEW SCRIPT" and give it a name, then paste the following lines into the editor, and save.

 

cp /boot/config/vsftpd.conf /etc/vsftpd.conf
/usr/local/emhttp/plugins/dynamix/scripts/ftpusers '1' 'test test1 test2'

 

image.thumb.png.ecea2c6f62ef9a315f325140fc852872.png

 

Explaining the config:

# This line copies the newly created config file, and replaces the original in /etc/vsftpd.conf. Don't worry, this will make no harm to the original config file, as it resets when you reboot your server

cp /boot/config/vsftpd.conf /etc/vsftpd.conf

# This line enables the service, and allow the users test, test1 and test2 to access the FTP-server.
/usr/local/emhttp/plugins/dynamix/scripts/ftpusers '1' 'test test1 test2'

 

Notice that if you have other users, just name them in this config, with spaces for each user. Also rememer that these users will have to be added in your UR USERS configuration mentioned above.

 

To autostart the service at every restart, just click on the dropdown menu on the right side of your script, and choose "At First Array Start Only"

image.png.be5b284225a91a402740838d3ef1d12d.png

 

Now you have a working FTP-server with no shares, other than an empty folder.

To add shares into your FTP-Server, you can either edit your newly created script in the "User Scripts" app, or you can create a new one. I choose the last option.

"ADD NEW SCRIPT" and give it a name, then paste the following lines into the editor, and save.

 

mkdir /mnt/user/FTP/Movies
mount --bind /mnt/user/multimedia/Movies/ /mnt/user/FTP/Movies
mount -o bind,remount,ro /mnt/user/FTP/Movies/

 

image.png.814ad431de5bed058f95ef321c790db1.png

 

Explaining the config:

# mkdir creates a new folder in my FTP share, where I can mount my shared folder Movies

mkdir /mnt/user/FTP/Movies

# mount command binds my shared folder /mnt/user/FTP/Movies to the newly created folder on my FTP-share.

mount --bind /mnt/user/multimedia/Movies/ /mnt/user/FTP/Movies
# another mount command to make my shared folder /mnt/user/FTP/Movies READ ONLY on my FTP-share.

mount -o bind,remount,ro /mnt/user/FTP/Movies/

 

If you want to autostart the share, just follow the method mentioned above.

 

By using this plugin, you can add as many shares from your UR to your FTP-server as you like, and it's way easier to do than editing the /boot/config/go file every time.

 

To unmount the share just make a new script and add the lines.

 

umount /mnt/user/FTP/Movies
rmdir /mnt/user/FTP/Movies

 

image.png.d5c1add7e205c9a39485cabd83dbe347.png

 

I think the config explains it self.

 

That's it, and I hope this guide can be usefull for some UR members.

Edited by j44rs4

Hi and first of all thank you for this guide. I wasn't able to get SFTPgo running (admin user wasn't created) so I search for an alternative.

 

First I was struggeling but then I read your guide again and in my case this was the Problem as I use the share for my surveillance cams.

On 3/4/2025 at 9:14 PM, j44rs4 said:

# another mount command to make my shared folder /mnt/user/FTP/Movies READ ONLY on my FTP-share.

mount -o bind,remount,ro /mnt/user/FTP/Movies/

 

So I delete this line and everything works fine so far.

Edited by Raz3r

  • Author

The reason for that line is that if you want to share your movies with others, you make it read only for them. I would'nt advice you to delete that line, in stead make another folder in your ftp-share called surveilance or cams to record your stream. With this configuration/guide, you also have read/write access to your FTP's root-folder, so you are free to make a folder for uploading and record what ever you like.

Edited by j44rs4

As I use FTP only for this usecase, there is no problem with read/write access for me. I use SMB only on my network so I can limit the access for the other users in that way. But I understand your configuration if you want to share files via FTP.

  • 3 weeks later...

Just wanted to say thanks, it worked great. Easy to follow instructions!

Ever since ProFTP took a crap, my buddy wasn't able to log in. I did a bunch of drive maintenance and upgrades while I was at it. It's like a new server. :)

  • 8 months later...

Thank you for this - have been looking for a solution for ftp over tailscale for my friend.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.