Community

[Pure-FTPD] pam_listfile(pure-ftpd:auth): Couldn't open /etc/ftpusers

ic
itdev_cs #1

Today i created some ftp user. And then i try to connect with Filezilla. But i can’t connect to the server.

This log from FIlezilla
Status: Resolving address of xxx.blablabla.com
Status: Connecting to xx.xx.xx.xx:21…
Status: Connection established, waiting for welcome message…
Response: 220---------- Welcome to Pure-FTPd [privsep] [TLS] ----------
Response: 220-You are user number 1 of 50 allowed.
Response: 220-Local time is now 16:31. Server port: 21.
Response: 220-IPv6 connections are also welcome on this server.
Response: 220 You will be disconnected after 15 minutes of inactivity.
Command: USER ftp_user
Response: 331 User ftp_user OK. Password required
Command: PASS *********
Response: 530 Login authentication failed
Error: Critical error: Could not connect to server
`

And when i login to ssh, and hit systemctl status pure-ftpd

pure-ftpd.service - Pure-FTPd FTP server
Loaded: loaded (/usr/lib/systemd/system/pure-ftpd.service; enabled; vendor preset: disabled)
Active: active (running) since Mon 2018-07-30 16:24:31 WIB; 56s ago
Process: 2850 ExecStart=/usr/sbin/pure-config.pl /etc/pure-ftpd/pure-ftpd.conf --daemonize (code=exited, status=0/SUCCESS)
Main PID: 2851 (pure-ftpd)
CGroup: /system.slice/pure-ftpd.service
├─2851 pure-ftpd (SERVER)
├─2858 pure-ftpd (IDLE)
├─2859 pure-ftpd (PRIV)
├─2870 pure-ftpd (IDLE)
└─2871 pure-ftpd (PRIV)

Jul 30 16:24:31 xxx.blablabla.com systemd[1]: Starting Pure-FTPd FTP server…
Jul 30 16:24:31 xxx.blablabla.com systemd[1]: PID file /var/run/pure-ftpd.pid not readable (yet?) after start.
Jul 30 16:24:31 xxx.blablabla.com pure-ftpd[2851]: (?@?) [DEBUG] Couldn’t load the DH parameters file /etc/ssl/private/pure-ftpd-dhparams.pem
Jul 30 16:24:31 xxx.blablabla.com systemd[1]: Started Pure-FTPd FTP server.
Jul 30 16:25:25 xxx.blablabla.com pure-ftpd[2870]: (?@xx.xx.xx.xx) [INFO] New connection from xx.xx.xx.xx
Jul 30 16:25:25 xxx.blablabla.com pure-ftpd[2870]: pam_listfile(pure-ftpd:auth): Couldn’t open /etc/ftpusers
Jul 30 16:25:25 xxx.blablabla.com pure-ftpd[2870]: pam_unix(pure-ftpd:auth): check pass; user unknown
Jul 30 16:25:25 xxx.blablabla.com pure-ftpd[2870]: pam_unix(pure-ftpd:auth): authentication failure; logname= uid=0 euid=0 tty=pure-ftpd ruser=…s rhost=
Hint: Some lines were ellipsized, use -l to show in full.
`

Pliss help me. Thank You

us
usmannasir #2

Did you remove and re-install pure-ftpd?

ic
itdev_cs #3
Did you remove and re-install pure-ftpd?

No. I just restart the service via systemctl.

us
usmannasir #4
Did you remove and re-install pure-ftpd?

No. I just restart the service via systemctl.

Submit ticket.

ic
itdev_cs #5
Did you remove and re-install pure-ftpd?

No. I just restart the service via systemctl.

Submit ticket.

How to submit a ticket?

al
ali #7

Did you find any solution? I’m having same issue.

Cy
CyberPanel #8
Did you find any solution? I'm having same issue.

Which OS and virtualization?

al
ali #9

Did you find any solution?

Did you find any solution? I’m having same issue.

Which OS and virtualization?

Thank’s for your reply. We figured out our problem. We updated root mysql password from pureftpd-mysql.conf conf file. And that’s works.

tb
tbaldur #11

If the file /etc/ftpusers doesn’t exist, create one with this inside for example:

# /etc/ftpusers: list of users disallowed FTP access.
root
daemon
bin
sys
sync
games
man
lp
mail
news
uucp
proxy
majordom
postgres
www-data
backup
msql
operator
list
irc
nobody
MK
Mirza Khadnezar S [sick] #12

already touch /etc/ftpusers
but the result now … no user
lol
now i try with upgrade script… how can be fixed

MK
Mirza Khadnezar S [sick] #13

Jul 02 01:11:49 secure pure-ftpd[303944]: pam_unix(pure-ftpd:auth): check pass; user unknown

no luck… :frowning:

tb
tbaldur #14
systemctl stop pure-ftpd
yum remove pure-ftp* -y
dnf install pure-ftpd -y
groupadd -g 2001 ftpgroup
useradd -u 2001 -s /bin/false -d /bin/null -c "pureftpd user" -g ftpgroup ftpuser
systemctl start pure-ftpd
mkdir /etc/ssl/private
openssl req -newkey rsa:1024 -new -nodes -x509 -days 3650 -subj "/C=US/ST=Denial/L=Springfield/O=Dis/CN=www.example.com" -keyout /etc/ssl/private/pure-ftpd.pem -out /etc/ssl/private/pure-ftpd.pem
rm -R /etc/pure-ftpd
mkdir /etc/pure-ftpd
cp /usr/local/CyberCP/install/pure-ftpd-one/* /etc/pure-ftpd/
systemctl restart pure-ftpd

Not sure if i forgot any

Sign in to reply