FTP user for only joomla instalation using vsftpd on ubuntu

Need help with the Administration of your Joomla! 1.5 site? This is the spot for you.

Moderator: General Support Moderators

Forum rules
Forum Rules
Absolute Beginner's Guide to Joomla! <-- please read before posting, this means YOU.
Forum Post Assistant - If you are serious about wanting help, you will use this tool to help you post.
Locked
cesine
Joomla! Fledgling
Joomla! Fledgling
Posts: 1
Joined: Sun Jun 15, 2008 4:31 pm

FTP user for only joomla instalation using vsftpd on ubuntu

Post by cesine » Sun Jun 15, 2008 4:53 pm

I figured out how to follow the advice on the install page which says:

FTP Configuration:

Due to file system permission restrictions, within Linux and other Unix sytems, and PHP Safe Mode restrictions in order that all users can utilize the Joomla! installers an FTP Layer exists to handle file system manipulation.
Enter an FTP Username and Password with access to the Joomla! root directory, this will be the FTP Account that handles all file system operations when Joomla! requires FTP access to complete a task.
For security reasons, it is best if a separate FTP User Account is created with access only to the Joomla! installation, and not the whole Web server if this option is available to you.

Note: If the installation is on a Windows Operating System the FTP Layer is not required

I added a user for my joomla pages as a system user,
# adduser joomlaftp

then changed its home diretory to the joomla install
# usermod -d /my/joomla/directory joomlaftp

then i installed vsftpd
# apt-get install vsftpd

then i edited the vsftpd config file following this website
http://ubuntuforums.org/showthread.php?t=518293
since i'm only allowing ftp for joomla's use i changed these lines:
# vim /etc/vsftpd.conf
anonymous_enable=NO
local_enable=YES (this lets local users log in)
write_enable=YES
chroot_local_user=YES
userlist_deny=NO
userlist_enable=YES (this lets only certain local users log in)
userlist_file=/etc/vsftpd.allowed_users

then i created the allowed users file
# vim /etc/vsftpd.allowed_users

and i typed one line in that file:
joomlaftp

then i restarted the vsftpd server
# /etc/init.d/vsftpd restart

so now, i can log in with my joomlaftp via normal ftp methods:
(From MAC OS 10.5 leopard terminal)
$ ftp [email protected] 21
Connected to my.domain.com
220 (vsFTPd 2.0.4)
331 Please specify the password.

but the Joomla Web Installer cant do either Autofind FTP Path or Verify FTP Settings.

I get this error message:
The page at http://my.domain.com says:
FTP settings are not valid or your FTP server is not compatible with Joomla!:
Could not connect to the FTP server

-ive tried it with and without the Enable FTP File System Layer,
-ive tried it with the server's real IP address
-ive tried it with ports 20,21,22
-ive tried it with and without the FTP Root Path
-ive tried it with and without jailing the user to their local directory (changing chroot_local_user=NO in the vsftp.conf file)

I'm using firefox 2.0.0.14 on a Leopard install of Mac OS 10.5.2 i hope that's not a factor? (I have a version of Joomla 1.0 running on the same server, and i can edit and do administrator things just fine)

User avatar
humvee
Joomla! Master
Joomla! Master
Posts: 14704
Joined: Wed Aug 17, 2005 10:27 pm
Location: Kent, England

Re: FTP user for only joomla instalation using vsftpd on ubuntu

Post by humvee » Sun Jun 15, 2008 5:52 pm

[Mod Note] Moved from Installation Questions

merchiston
Joomla! Fledgling
Joomla! Fledgling
Posts: 1
Joined: Wed Sep 30, 2009 9:45 pm

Re: FTP user for only joomla instalation using vsftpd on ubuntu

Post by merchiston » Wed Sep 30, 2009 9:52 pm

Hi

I'm a Joomla newbie, but I have the same problem as cesine. I'm not sure why there was no answer to this and why it was moved from installation questions?!

My stats: Joomla 1.5.14, php 5.2.6, Ubuntu 9.04 (Jaunty), vsftpd locked down to allow joomlaftp user only.

Test FTP connection with CoreFTP - all works fine, redirects to /var/www/joomla as home directory as expected. When I verify FTP settings in the Joomla install I get

"The FTP settings are not valid or your FTP server is not compatible with Joomla! Could not login to the FTP server."

Also, if I remove "@localhost" from the username, and set the target directory to ./ (as I've seen suggested in a post elsewhere) I get the message "The function STOR failed." ???

This is driving me nuts! Like cesine I've tried every possible tweak without success! Can anyone help?

TiA

James.

juser345
Joomla! Fledgling
Joomla! Fledgling
Posts: 1
Joined: Wed Mar 24, 2010 2:29 pm

Re: FTP user for only joomla instalation using vsftpd on ubuntu

Post by juser345 » Wed Mar 24, 2010 2:39 pm

This is a permissions issue - you need to make sure that the joomlaftp user can write to that directory. You could make them the owner with:

sudo chown -R joomlaftp /var/www

And set the permissions with:

sudo chmod -R 755 /var/www

(var/www being the joomla root directory)


Locked

Return to “Administration 1.5”