Prerequisites
- Virtualmin Access: Administrative access to the Virtualmin panel.
- FTP Server Configured: Virtualmin typically uses ProFTPD or vsftpd. Ensure it’s installed and running.
- Domain Configured: The domain/website must be set up in Virtualmin.
Step-by-Step Guide
1. Log in to Virtualmin
Access the Virtualmin panel with admin credentials and select the desired domain from the dropdown menu in the top-left corner. Check ACCESS section of the desired domain.
2. Create an FTP User
- Go to the Users Section:
- In the sidebar, click
Edit Users
orEdit Mail/FTP Users
(depending on your Virtualmin version).
- In the sidebar, click
- Add a New User:
- Click
Add a User
. - Fill in the details:
- Username: FTP user’s name (e.g.,
ftpuser1
). - Password: Set a strong password.
- Home Directory: Specify the folder (e.g.,
/home/domain/public_html/ftpuser1
). Virtualmin can create it if it doesn’t exist. - Quota: Set a storage limit if needed.
- Enable FTP Access: Check this option.
- Username: FTP user’s name (e.g.,
- Leave other settings as default unless specific configurations are needed.
- Click
- Save:
- Click
Create
to finalize.
- Click
3. Configure Access to Specific Folders
By default, the user is restricted to the Home Directory. To customize access:
- Edit the User:
- Go to
Edit Users
, select the user, and clickEdit
. - Change the
Home Directory
if needed.
- Go to
- Folder Permissions:
- Use the
File Manager
in Virtualmin: - Navigate to the folder (e.g.,
/home/domain/public_html/ftpuser1
). - Right-click and select
File Permissions
. - Set the owner to the FTP user (e.g.,
ftpuser1
) and adjust permissions (e.g.,700
for exclusive access).
- Use the
- Restrict Access:
- Ensure the FTP server uses chroot to lock the user to their home directory.
- Check in
Webmin > Servers > ProFTPD > Files and Directories
and enablechroot jail
.
4. Test FTP Access
- Use an FTP client like FileZilla or WinSCP.
- Configure the connection:
- Host: Server IP or domain (e.g.,
yourdomain.com
). - Username: The created user (e.g.,
ftpuser1
). - Password: The set password.
- Port: 21 (default for FTP).
- Host: Server IP or domain (e.g.,
- Connect and verify access is limited to the configured folder.
5. Create Multiple Users with Access to Different Folders
Repeat the process for each user, changing:
- The username (e.g.,
ftpuser2
). - The home directory (e.g.,
/home/domain/public_html/ftpuser2
). - Folder permissions to ensure exclusive access.
For further assistance, consult Virtualmin documentation or contact support.