Change VSFTPD Server root directory?
Results 1 to 3 of 3

Thread: Change VSFTPD Server root directory?

  1. #1
    Senior Member
    Join Date
    Jun 2002
    Posts
    102

    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.

    Thanks
    Good Grief

  2. #2
    Senior Member
    Join Date
    Jun 2002
    Posts
    102
    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.
    Good Grief

  3. #3
    Super Moderator
    Know-it-All Master Beaver

    Join Date
    Jan 2003
    Posts
    3,914
    Hey Hey,

    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)

    Peace,
    HT
    IT Blog: .:Computer Defense:.
    PnCHd (Pronounced Pinched): Acronym - Point 'n Click Hacked. As in: "That website was pinched" or "The skiddie pinched my computer because I forgot to patch".

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  

 Security News

     Patches

       Security Trends

         How-To

           Buying Guides