Logs. Always look in the logs. Which log depends on your OS and the proftpd package in use (which we don’t know). There’s probably something in /var/log/messages, and possibly something in /var/log/proftpd*.
Well, for some reason there was nothing in the log file /var/log/messages.
I am running ProFTPd version 1.31. I was able to get proFTPd started by adding a virtual server, even though it worked previously without one. Unfortunately, I cannot connect to the server. When I try to telnet to port 21 from a remote server or telnet from the localhost port 21, I get a connection refused.
I turned log level up to “info” and still see no error messages.
I checked the server from the desktop level, and the firewall (still) has port 21 tcp open.
Where did you proftpd package come from? There are known to be a few that have broken PAM configurations out in the wild in third party repositories.
An empty /var/log/messages makes no sense. Everything logs to messages. If it’s empty, I think I’d be quite worried…at the very least, syslogd isn’t running, and should be.
What I meant was that there were no obviously ftpd related error message in /var/log/messsages- at least as reported by webmin. I didnt look with vi. /var/log/proftpd is a truly empty directory.
There was no “Virtual server” configured but ftpd was still running fine as I had another server saving backups to it. ftpd suddenly stopped working the other day, but I’ve done nothing to the box that I am aware of. If there was an update that was automated, I’m not aware of it. In order to get ProFTP even working again, I tried adding a virtual ftp server, which apparently worked somewhat as now the server starts.
So: Webmin reports that ProFTPd is running. The firewall claims the port is open, but I get connection refused when I try to telnet or use an FTP client. The proftpd config file is nearly identical to the one on the working server. This version of FTP was installed when I ran an installer to add virtualmin to the Webmin installation a few months ago.
Assume I attempt to connect right now. I get a “connection refused”. Should I be seeing a message about that in /var/log/messages? Somewhere else?
There are no entries made to /var/log/secure when I try to ftp into the server box. However when I ssh in to the server box, a message is added to the var/log/secure. Additionally, continuous messages are added about other services to /var/log/messages as well, but not about proftp. ProFTP log level is set to “info”
I get the “connection refused” message so quickly, I originally suspected the problem was with the client computer, but, I’ve tried three of them at two different geographic places/networks, so, that’s not it. Additionally, I get the same thing if I log in to the server computer itself and try to “ftp localhost”
Webmin System Information reports ProFTP is up and furthermore
You’re not by chance running your server behind a NAT router, are you?
I guess I’m asking if it’s possible that the provider your server is located at could be blocking FTP, or if you need to do some port forwarding in order for it to work.
Also, if you SSH into your server, can you FTP (or telnet) into ProFTp (port 21) from there?
The server is on my own business line. Nothing is blocked. I am running ftpd on another server through the same router, both servers ran together simultaneously for the last few months, and I have historically ran anywhere from two to five servers through this same connection for years.
The ftp server in question was working till the other day then stopped mysteriously. I was making backups from ns1(client) to ns2(server) every night till one night it didn’t work. I had thought I may have changed some packages, but, upon reflection, I don’t think I did.
I can’t telnet or ftp to localhost from the machine in question.
telnet localhost 21
telnet: connect to address 127.0.0.1: Connection refused
ftp localhost
ftp: connect: Connection refused
Tried that. I get no log entries to /var/log/messages, /var/log/secure. or /var/log/proftpd when I try it either…
I should point out that those zeroes are the REAL output of the command, I did not change them… and furthermore, 54321 is the port usermin is listening on. That seems like it’s probably important
Well, the 0’s don’t surprise me – 0.0.0.0 is a fancy way of saying “listen on all IP’s”.
What surprises me is that you searched on the string “:21”, yet “:21” doesn’t actually exist in the output you have there (the 21 by itself does, but not a 21 with a : in front of it).
But I chalked that up to a typo
What it looks like is that proftp is not listening on port 21. Maybe it’s listening on another port; maybe it’s not listening at all, I’m not sure yet. But I don’t see anything that suggests it’s listening on the normal FTP port.
So I guess the next step is to determine if it’s listening anywhere at all. We can do that with the “lsof” command (which should be available on nearly every distro, but may not be installed by default).
Yeah, doesn’t look like it’s listening. That’s certainly not running as expected
I guess what I’d try is launching the ProFTP daemon by hand to see if maybe the init script is hiding some error messages that it would otherwise be throwing out.
So, stop ProFTP, then just launch it from the command line (which is /usr/sbin/proftpd on my Ubuntu system), and see what happens
As I recall “ns2” is the listed somewhere as a nickname for the server. I can’t for the life of me remember where or how to change it though. If I get rid of the nickname/shortcut/servername(???) I assume that will be useful.