Problems getting pure-ftpd working in 11.4

I got a new computer a couple weeks ago, and figured I may as well wait until 11.4 is released instead of putting on 113. and then upgrading in a few days. So, now that 11.4 is out, I’ve got it up and running and am trying to get everything installed and setup. I’m trying to get pure-ftpd up and running, butt have run into some issues.

I’ve installed it, and it shows as running, but when I try to login in a terminal window, I get the following output:


naskie18@linux-2o57:~> ftp localhost
Trying ::1...
Connected to localhost.
220-Welcome to Pure-FTPd.
220-You are user number 1 of 50 allowed.
220-Local time is now 12:06. Server port: 21.
220 You will be disconnected after 15 minutes of inactivity.
Name (localhost:naskie18): naskie18
331 User naskie18 OK. Password required
Password:
530 Login authentication failed
ftp: Login failed.

When I try to login from another computer on my network, I get an “unable to connect” message.

I’ve tried another username/password combination as well, I know I’m typing both passwords correctly, and both usernames are members of the _pure-ftpd group.

Any help would be greatly appreciated.

Thanks!

On 03/13/2011 11:36 AM, naskie18 wrote:
>
> I got a new computer a couple weeks ago, and figured I may as well wait
> until 11.4 is released instead of putting on 113. and then upgrading in
> a few days. So, now that 11.4 is out, I’ve got it up and running and am
> trying to get everything installed and setup. I’m trying to get
> pure-ftpd up and running, butt have run into some issues.
>
> I’ve installed it, and it shows as running, but when I try to login in
> a terminal window, I get the following output:
>
> Code:
> --------------------
>
> naskie18@linux-2o57:~> ftp localhost
> Trying ::1…
> Connected to localhost.
> 220-Welcome to Pure-FTPd.
> 220-You are user number 1 of 50 allowed.
> 220-Local time is now 12:06. Server port: 21.
> 220 You will be disconnected after 15 minutes of inactivity.
> Name (localhost:naskie18): naskie18
> 331 User naskie18 OK. Password required
> Password:
> 530 Login authentication failed
> ftp: Login failed.
>
> --------------------
>
>
> When I try to login from another computer on my network, I get an
> “unable to connect” message.
>
> I’ve tried another username/password combination as well, I know I’m
> typing both passwords correctly, and both usernames are members of the
> _pure-ftpd group.
>
> Any help would be greatly appreciated.

I don’t know about the passwords, but the “unable to connect” is usually a
firewall issue.

Good call, I’d forgotten about the firewall. I added pure-ftpd to the allowed programs and that’s fixed the unable to connect errors.

I’m still unable to login to the ftp server, however, regardless of what username I use, I still get the login failed errors mentioned in my first post.

Any thoughts?

Thanks.

IIRC PureFTP is supported by YAST.

Should be as simple as

  • Install PureFTP from OSS
  • Open up YAST, you find an FTP Server icon which didn’t exist before.

When you configure in YAST, your SuSE FW and authentication issues should be addressed automatically.

HTH,
Tony

I installed it through YAST, but I don’t have an FTP server icon in YAST. It shows up as a running process, and I can try to login through a terminal or through another computer and both see the server and verify the username is acceptable, but I still can’t actually login, I continue to get “login failed” messages when it tries to verify the password.

Create another FTP user account and try to login with it


pure-pw useradd -u <some_uid> -g <some_gid> -d </path/to/ftp_root/>

Similar result:


Living-Room:/home/naskie18 # pure-pw useradd naskie18 -u 1000 -g 1000 -D /windows/D/
Password: 
Enter it again: 
Living-Room:/home/naskie18 # ftp localhost
Trying ::1...
Connected to localhost.
220-Welcome to Pure-FTPd.
220-You are user number 1 of 10 allowed.
220-Local time is now 21:38. Server port: 21.
220-This is a private system - No anonymous login
220 You will be disconnected after 15 minutes of inactivity.
Name (localhost:naskie18): naskie18
331 User naskie18 OK. Password required
Password:
530 Login authentication failed
ftp: Login failed.
ftp> 

Same results with another username and root

Are you sure the logged in User has proper file permissions to that location? That would be typical of your problem, successfully logging into the app but unable to access files.
What is your default FTP root directory? You can check, you need at least read and possibly write permissions on the directory and files for the specified User.

BTW - I find it suspicious you didn’t find an FTP Server icon in YAST > Network Services

Tony

Let’s try to get some more logging.
Edit the /etc/pure-ftpd/pure-ftpd.conf file, change the following.
Set VerboseLog to “yes” and restart pure-ftpd


/etc/init.d/pure-ftpd restart

Try logging in again the check /var/log/messages for errors.

Hiatt

I am having the same problem. I been using pure-ftpd from suse 10 to 11.2, never had such weird problem. Don’t worry about firewall, and those things, I already checked. Still keep getting 530 authentication error. But, I installed on several machines, not happening on everyone, it’s just weird. I suggest you guys install pure-ftpd and try it, it’s very easy to see.

In general, I just don’t feel 11.4 is robust enough to use. Before 11.2, never had so much stability issues. Starting from 11.3, it gets all the random freeze (still happens in 11.4). I have been looking forward to upgrading my system, and each time, I had to downgrade to 11.2 because of all these issues :frowning: It looks as though I would have to wait for 11.5 this time.

OK, I think I figured it out. I looks like pure-ftp is using PAM by default.

First let’s stop using PAM and use the Pure FTP DB file
In the /etc/pure-ftpd/pure-ftpd.conf file set PAM authentication to no


PAMAuthentication             no

Then uncomment the PureDB line in the /etc/pure-ftpd/pure-ftpd.conf file


PureDB                        /etc/pure-ftpd/pureftpd.pdb

Then create the password database


sudo /usr/bin/pure-pw mkdb

And finally restart the pure-ftpd server


sudo /etc/init.d/pure-ftpd restart

Good luck,
Hiatt

Hi Hiatt,

Tried your way, no luck. It had problem while try to create password file “pure-pw mkdb” returned “no password file” or something.

Sam

Try ftp to 127.0.0.1 instead of localhost. The ::1 means you are getting the IPv6 localhost and I believe there are some quirks you must deal with if you want to run the transport over IPv6.

it doesn’t seem to be a connection problem. Tried it with localhost or 127.0.0.1, it works fine. Just can’t log in from outside.

Sam

If you want serve from behind a NAT firewall there are various things you must do because ftp is a two port protocol and what’s more the port number of the data connection is sent inside the control connection.

If you have a firewall but no NAT you still need the ftp conntrack module in iptables.

Let’s start all over from the beginning
Create your virtual user


sudo /usr/bin/pure-pw useradd <usename> -u <uid> -g <gid>  -d /path/to/ftp_dir

Make sure the password file has been created with your user


sudo cat /etc/pure-ftpd/pureftpd.passwd

Create the password database


sudo /usr/bin/pure-pw mkdb

Make sure the password database was created


ls /etc/pure-ftpd/pureftpd.pdb

Restart Pure FTP


sudo /etc/init.d/pure-ftpd restart

Login to the FTP server to test.
If you get an error while running any of the above commands you have other problems.

Good luck,
Hiatt

blows dust off thread

Alright, now that I’m back from a lot of extended travel and am caught up, I’m starting to try to get this working again.

So, here’s what I’ve done tonight:

  1. Downloaded a new copy of and reinstalled 11.4, and performed updates. Yay fun.
  2. Installed pure-ftpd using Yast. I still don’t have an FTP icon in the network services section of Yast.

I’ve got the ftp server running, but I can’t login with a username and password, I get the following:


linux-988z:/home/naskie18 # ftp localhost
Trying ::1...
Connected to localhost.
220-Welcome to Pure-FTPd.
220-You are user number 2 of 50 allowed.
220-Local time is now 22:58. Server port: 21.
220 You will be disconnected after 15 minutes of inactivity.
Name (localhost:naskie18): naskie18
331 User naskie18 OK. Password required
Password:
530 Login authentication failed
ftp: Login failed.
ftp> 

I can, however, login as Anyomous, with the following results:

Connected to localhost.
220-Welcome to Pure-FTPd.
220-You are user number 2 of 50 allowed.
220-Local time is now 22:58. Server port: 21.
220 You will be disconnected after 15 minutes of inactivity.
Name (localhost:naskie18): Anonymous
230 Anonymous user logged in
Remote system type is UNIX.
Using binary mode to transfer files.
ftp> 

I get the above results when using an ftp client on another device to connect as well, both on my network and outside of my network.

I’ve edited the config file in /etc/pure-ftpd/ to the following:


# Don't allow authenticated users - have a public anonymous FTP only.

AnonymousOnly               no



# Disallow anonymous connections. Only allow authenticated users.

NoAnonymous                 yes

Now, if I understand correctly, what I’ve done here should disallow anonymous logins and allow user logins, correct? If that’s the case, any ideas why this isn’t working, and, more importantly, how to fix it?

On Wed May 25 2011 10:06 pm, naskie18 wrote:

>
> blows dust off thread
>
> Alright, now that I’m back from a lot of extended travel and am caught
> up, I’m starting to try to get this working again.
>
> So, here’s what I’ve done tonight:
> 1. Downloaded a new copy of and reinstalled 11.4, and performed
> updates. Yay fun.
> 2. Installed pure-ftpd using Yast. I still don’t have an FTP icon in
> the network services section of Yast.
>
> I’ve got the ftp server running, but I can’t login with a username and
> password, I get the following:
>
> Code:
> --------------------
>
> linux-988z:/home/naskie18 # ftp localhost
> Trying ::1…
> Connected to localhost.
> 220-Welcome to Pure-FTPd.
> 220-You are user number 2 of 50 allowed.
> 220-Local time is now 22:58. Server port: 21.
> 220 You will be disconnected after 15 minutes of inactivity.
> Name (localhost:naskie18): naskie18
> 331 User naskie18 OK. Password required
> Password:
> 530 Login authentication failed
> ftp: Login failed.
> ftp>
>
> --------------------
>
>
> I can, however, login as Anyomous, with the following results:
>
> Code:
> --------------------
> Connected to localhost.
> 220-Welcome to Pure-FTPd.
> 220-You are user number 2 of 50 allowed.
> 220-Local time is now 22:58. Server port: 21.
> 220 You will be disconnected after 15 minutes of inactivity.
> Name (localhost:naskie18): Anonymous
> 230 Anonymous user logged in
> Remote system type is UNIX.
> Using binary mode to transfer files.
> ftp>
>
> --------------------
>
>
> I get the above results when using an ftp client on another device to
> connect as well, both on my network and outside of my network.
>
> I’ve edited the config file in /etc/pure-ftpd/ to the following:
>
> Code:
> --------------------
>
> # Don’t allow authenticated users - have a public anonymous FTP only.
>
> AnonymousOnly no
>
>
>
> # Disallow anonymous connections. Only allow authenticated users.
>
> NoAnonymous yes
>
> --------------------
>
> Now, if I understand correctly, what I’ve done here should disallow
> anonymous logins and allow user logins, correct? If that’s the case,
> any ideas why this isn’t working, and, more importantly, how to fix it?
>
>
naskie18;

What have you done to create users?

Have you read: /usr/share/doc/packages/pure-ftpd/ ?

P. V.
“We’re all in this together, I’m pulling for you.” Red Green

naskie18 wrote:

> 2. Installed pure-ftpd using Yast. I still don’t have an FTP icon in
> the network services section of Yast.
>
Did you install the package yast2-ftp-server? Without it you will not have
an ftp entry in yast.


PC: oS 11.3 64 bit | Intel Core2 Quad Q8300@2.50GHz | KDE 4.6.3 | GeForce
9600 GT | 4GB Ram
Eee PC 1201n: oS 11.4 64 bit | Intel Atom 330@1.60GHz | KDE 4.6.0 | nVidia
ION | 3GB Ram

I have setup pure-ftpd according to the readme file in that folder. I’ve got two users setup right now, my username and a user _pure-ftpd. Both are members of the _pure-ftpd group, as well as the ftp group.

I originally did not install that. Now I have, and there is an ftp entry in yast, although there doesn’t seem to be anything useful in there. When I open it, I get a window which says that a TFTP server is enabled, and lists a boot image directory of “/srv/tftpboot”