June 27th, 2004, 12:13 AM
Change VSFTPD Server root directory?
How do I change the root ftp directory in VSFTPD on Redhat 9.0 to point to the apache web root /var/www/html directory instead? So i can upload all my files automatically to the web root.
June 27th, 2004, 12:59 AM
The only workaround I could find is just to create a seperate user that has the web root dir as it's home dir. Then in VSFTPD just have it make the root dir the users home dir.
It works but not what i had in mind. This will actually work better having a seperate restricted user account that can be used.
June 28th, 2004, 06:42 AM
Here's what you need to do
1. vi /etc/vsftpd.conf
2. Add the line 'user_config_dir=/etc/vsftpd_user_conf' (no quotes)
3. mkdir /etc/vsftpd_user_conf; cd /etc/vsftpd_user_conf
4. vi <username you want to use>
5. Enter the line 'local_root=/var/www/html'
Now when that user logs in the file /etc/vsftpd_user_conf/<username> will be used to read the users config parameters. (man vsftpd.conf for more info)
IT Blog: .:Computer Defense:.
(Pronounced Pinched): Acronym - Point 'n Click Hacked. As in: "That website was pinched" or "The skiddie pinched my computer because I forgot to patch".