Error Cannot Execute /usr/sbin/in.ftpd
to work on Ubuntu 12.04 For what I can remember it has always been possible (at least) since Ubuntu 7.04 to simply do a sudo apt-get install proftpd to get a working FTP server running. It seems that starting with Ubuntu 12.04 no more! After installing proftpd on 12.04 (the package is now called proftpd-basic) you'll be unable to start the service. I've tried it both as standalone and using inetd but neither would work. ProFTPD, or rather its init.d script will report ProFTPD warning: cannot start neither in standalone nor in inetd/xinetd mode. Check your configuration. Yes, that helps a lot. Looking at the syslog I found the following message when trying to connect to the FTP server: error: cannot execute /usr/sbin/in.ftpd: No such file or directory. It turns out that this path is defined in /etc/inetd.conf and for Ubuntu 12.04 it appears that the proftpd-basic package doesn't install these. If you don't have the FTP service defined in inetd/xinetd it simply rejects any connection, giving less helpful error messages. So the fix to this problem is rather easy. If the file doesn't exist yet create /etc/inetd.conf (regardless if you use inetd or xinetd). Then, simply add the following line, or replace the existing one with the following: ftp stream tcp nowait root /usr/sbin/tcpd /usr/sbin/proftpd Now restart the service: sudo service inetd restart or sudo service xinetd restart. So the only change you really need to make is change the path to the FTP server. This fix works for both inetd and xinetd. For a proper solution for xinetd please see the section below. Proper xinetd fix I reckon that the creators of xinetd decided to support inetd compatibility by supporting the /etc/inetd.conf file. If you want to configure xinetd the proper way you can create a config file for it in /etc/xinetd.d/ftp and stick the following lines in it: service ftp { disable = no flags = REUSE socket_type = stream wait = no user = root server = /usr/sbin/proftpd server_args = -c /etc/proftpd/proftpd.conf } socket_type: Sets the network socket type to stream. protocol: Sets the protocol type to TCP wait: You can set the value to yes or no only. It Defines whether the service is single-threaded (if set to yes) or multi-threaded (if set to no). user: User who will run proftpd And finally restart the service: sudo service xinetd restart. (Source for setting up a service for xinetd). Posted on December 2, 2012 by Christiaan Kras, Comments off Posted in Linux, News, Ubuntu, Xubuntu and tagged as 12.04, inetd, ProFTPD, Ubuntu, xinetd < Previous Ne
ProFTPD » Support » ProFTPD warning: cannot start neither in standalone nor in inetd/xinetd mode. « previous next » Print Pages: [1] Author Topic: ProFTPD warning: cannot start neither in standalone nor in inetd/xinetd mode. (Read 21358 times) blkgsl New user Posts: 7 ProFTPD warning: cannot start neither in standalone nor in inetd/xinetd mode. « on: October 20, 2012, 12:33:41 pm » Hi everyone,I have installed Proftpd, and when i want to start the proftpd'service, i've got the following message :"ProFTPD warning: cannot start https://blog.htbaa.com/news/getting-proftpd-to-work-on-ubuntu-12-04 neither in standalone nor in inetd/xinetd mode. Check your configuration."Has someone already get this message ?Thanks in advance for helping me Logged castaglia Administrator Support Hero Posts: 5109 Re: ProFTPD warning: cannot start neither in standalone nor in inetd/xinetd mode. « Reply #1 on: October 20, 2012, 03:53:43 pm » That message does not come from the proftpd software itself; https://forums.proftpd.org/smf/index.php?topic=11183.0 it looks like it is coming from whatever script/command your system is using to try to run proftpd. Therefore the fix would be to see just what that script/command is doing. Logged blkgsl New user Posts: 7 Re: ProFTPD warning: cannot start neither in standalone nor in inetd/xinetd mode. « Reply #2 on: October 20, 2012, 10:38:01 pm » Thanks for your message, do you have an idea of how i could find this script/command ?I'm a newbie so it's hard to find for me :S Logged castaglia Administrator Support Hero Posts: 5109 Re: ProFTPD warning: cannot start neither in standalone nor in inetd/xinetd mode. « Reply #3 on: October 20, 2012, 10:59:09 pm » OK. First, try this command: # find /etc -type f -name "proftpd*" -printThis searches recursively through all files under /etc, and prints out any files whose name starts with "proftpd". Run that command, and tell us the results. We'll go from there. Logged blkgsl New user Posts: 7 Re: ProFTPD warning: cannot start neither in standalone nor in inetd/xinetd mode. « Reply
more complicated tasks. Stopping and/or restarting can be accomplish either using signals or ftpshut, depending on your needs. Use http://www.proftpd.org/docs/howto/Stopping.html of signals will fulfill most requirements; the ftpshut program is used https://www.redhat.com/archives/redhat-list/1999-September/msg02594.html for a specific way of shutting down a proftpd server. Starting proftpd The ServerType configured in your proftpd.conf determines how you should start your proftpd daemon. A ServerType of "inetd" means that you are letting inetd/xinetd handle the starting of the server; using error cannot "standalone" means that you will probably end up using some kind of script (e.g. init.d shell scripts). All start scripts end up using, in some form or another, the various command-line options supported by proftpd: /usr/local/sbin/proftpd [options] where /usr/local/sbin is determined by configure and [options] are described below (or in proftpd(8)): -h, --help Display proftpd error cannot execute usage -n, --nodaemon Disable background daemon mode and send all output to stderr) -q, --quiet Don't send output to stderr when running with -n or --nodaemon -d [level], --debug Set debugging level (0-9, 9 = most debugging) -D [definition], --define Set arbitrary IfDefine definition -c [config-file], --config Specify alternate configuration file -p [0|1], --persistent Enable/disable default persistent passwd support -l, --list List all compiled-in modules -t, --configtest Test the syntax of the specified config -v, --version Print version number and exit -vv, --version-status Print extended version information and exit Signals You will notice many proftpd processess running on your system, but you should not send signals to any of them except the parent, whose PID is in the PidFile. That is to say, you should not ever need to send signals to any process except the parent. There are two signals that you can send the parent: TERM and HUP, which will be described below. To send a signal to the parent
entry in /var/log/messages Date: Thu, 23 Sep 1999 13:38:46 -0700 (PDT) Thanks John! This is what I found: [root uplink log]# cat secure [root uplink log]# [root uplink log]# cat secure.2 Sep 7 22:58:14 uplink login: FAILED LOGIN 1 FROM (null) FOR mstarnes, Authentication failure Sep 10 19:37:48 uplink login: FAILED LOGIN 1 FROM (null) FOR root, Authentication failure [root uplink log]# cat secure.3 Sep 4 17:20:35 uplink in.telnetd[974]: connect from 206.13.50.105 Sep 4 17:20:44 uplink ipop3d[976]: connect from 206.13.50.105 Sep 4 17:20:44 uplink ipop3d[976]: error: cannot execute /usr/sbin/ipop3d: No such file or directory Sep 4 17:20:53 uplink imapd[977]: connect from 206.13.50.105 Sep 4 17:20:53 uplink imapd[977]: error: cannot execute /usr/sbin/imapd: No such file or directory Sep 4 17:20:59 uplink in.ftpd[978]: connect from 206.13.50.105 Sep 4 17:20:59 uplink in.ftpd[978]: error: cannot execute /usr/sbin/in.ftpd: No such file or directory Sep 4 21:53:56 uplink in.ftpd[1010]: connect from 210.0.3.155 Sep 4 21:53:56 uplink in.ftpd[1010]: error: cannot execute /usr/sbin/in.ftpd: No such file or directory Sep 4 21:53:58 uplink in.ftpd[1011]: connect from 210.0.3.155 Sep 4 21:53:58 uplink in.ftpd[1011]: error: cannot execute /usr/sbin/in.ftpd: No such file or directory [root uplink log]# cat secure.4 Aug 22 16:51:16 uplink in.telnetd[2236]: connect from 206.12.31.28 Aug 22 16:51:19 uplink ipop3d[2238]: connect from 206.12.31.28 Aug 22 16:51:19 uplink ipop3d[2238]: error: cannot execute /usr/sbin/ipop3d: No such file or directory Aug 22 16:51:25 uplink imapd[2239]: connect from 206.12.31.28 Aug 22 16:51:25 uplink imapd[2239]: error: cannot execute /usr/sbin/imapd: No such file or directory Aug 22 16:51:31 uplink in.ftpd[2240]: connect from 206.12.31.28 Aug 22 16:51:31 uplink in.ftpd[2240]: error: cannot execute /usr/sbin/in.ftpd: No such file or directory I didn't find a /var/log/xferlog file but thanks very much for telling me about it and /var/log/secure. Do these look like hack/crack attemps? This is just a personal workstation so I want to be able to download, ftp and telnet but don't want other internet users to upload or download anything from it. I will wo