• If you are still using CentOS 7.9, it's time to convert to Alma 8 with the free centos2alma tool by Plesk or Plesk Migrator. Please let us know your experiences or concerns in this thread:
    CentOS2Alma discussion

proftpd w/o inetd

J

jwthompson2

Guest
Are there any potential problems associated with setting proftpd up to use standalone instead of inetd types? Does Plesk care and will an upgrade potentially break this config in the future?
 
hi,

i am wondering if you managed to get it into standalone mode and if so, could you share how? Thanks in advance
 
Comment out the ftp line in your inetd.conf file (where this is at depends on your Operating System).

Add a line in your /etc/rc.local (or equiv fille) which fires off /path/to/psa/ftpd/sbin/proftpd -c /path/to/psa/ftpd/etc/proftpd.conf

Edit /path/to/psa/ftpd/etc/proftpd.conf, change the line at the top that says ServerType inetd to ServerType standalone.

Refresh the inetd config by typing 'killall -HUP inetd', then type /path/to/psa/sbin/proftpd -c /path/to/psa/etc/proftpd.conf

on the commandline to fire it off. (after you restart inetd, you won't have any ftp daemon running until you start it by hand. The rc.local entry just makes sure it fires off on the next reboot.

Obviously, paths will change between operating systems.

As to drawback, I don't see any. The inetd has served just about zero purpose for the past 5+ years anyway, running proftpd from inetd is just dumb as it adds another layer of complexity to something that's supposed to be pretty straightforward.

History lesson: Inetd was needed WAAAY back in the day as most *nix boxes didn't have the memory/proc to run FTP/Web/Mail/ETC all at the same time. So the Inetd wrapper was written. It runs and listens on the appropriate TCP ports and calls whatever program is necessary AS it's needed, rather than having everything run at once.

Plesk pisses away an incredible amount of resources by default on tomcat and drweb and chose to "save some resources" by wrapping ftp in inetd. LOL.
'
edit: Depending on your instance of Inetd, it may actually stop answering when the loads hit a certain level on your server (my FreeBSD 4.9 boxes do this), consequently, on a small load spike, FTP and SMTP shut down. I just changed all my boxes to run ProFTPD standalone today to get around this annoying "feature". When I upgrade Plesk next, I fully expect the PSA Upgrade utility to wipe all of my customizations as it does every damned time. =\ I'll probabally write a "fix things" script so that after PSA Update mangles one of my boxes, I can have all my configs back the way they should be in short order, rather than doing it by hand every time.
 
Hi there,

thanks for your detailed reply.

Glad to hear i'm not the only one! heh.

Em i seem to have a problem locating my inetd.conf file,

i can find a /etc/xinetd.conf file containing:

Code:
# xinetd.conf
#
# Copyright (c) 1998-2001 SuSE GmbH Nuernberg, Germany.
# Copyright (c) 2002 SuSE Linux AG, Nuernberg, Germany.
#
 
defaults
{
        log_type        = FILE /var/log/xinetd.log
        log_on_success  = HOST EXIT DURATION
        log_on_failure  = HOST ATTEMPT
#        only_from       = localhost  
        instances       = 30
        cps             = 50 10

#
# The specification of an interface is interesting, if we are on a firewall.
# For example, if you only want to provide services from an internal
# network interface, you may specify your internal interfaces IP-Address.
#
#       interface       = 127.0.0.1

}
 
includedir /etc/xinetd.d

but nothing about ftp

Theres no actuall "inet.d.conf" file i can find. Am running Suse 9.1 & Fedora Core 2.

Any ideas.
 
Check which psa-proftpd you actually have installed:

rpm -q psa-proftpd

It's either going to be
psa-proftpd-xinetd-1.2.10-xxxx
or
psa-proftpd-1.2.10-xxxx

If you have the last one, I believe all you have to do is change the servertype in the proftpd.conf file from 'inetd' to 'standalone'
 
rpm -q psa-proftpd
psa-proftpd-1.2.10-suse9.1.build75050506.13
 
I'm trying to verify my statement in my last post about only having to change the ServerType line in proftpd.conf

My memory is not what it used to be and lack of sleep is having a toll as well...
 
Ahhh, I did forget something, the file is located at:

/etc/xinetd.d

[root@ns2 xinetd.d]# cat ftp_psa

service ftp
{
disable = yes
socket_type = stream
protocol = tcp
wait = no
user = root
instances = UNLIMITED
server = /usr/sbin/in.proftpd
server_args = -c /etc/proftpd.conf
}
 
Originally posted by jamesyeeoc
Ahhh, I did forget something, the file is located at:

/etc/xinetd.d

[root@ns2 xinetd.d]# cat ftp_psa

service ftp
{
disable = yes
socket_type = stream
protocol = tcp
wait = no
user = root
instances = UNLIMITED
server = /usr/sbin/in.proftpd
server_args = -c /etc/proftpd.conf
}

So i comment out the above lines and set proftp to start on startup?

do i daemonize it?

In suse
Code:
chkconfig proftpd
chkconfig --level 345 proftpd on
?

Or what run level is required? Or do i add it somewhere else to start it up.

Thanks
 
Originally posted by dstanley
So i comment out the above lines and set proftp to start on startup?

do i daemonize it?

In suse
Code:
chkconfig proftpd
chkconfig --level 345 proftpd on
?

Or what run level is required? Or do i add it somewhere else to start it up.

Thanks

Runlevel 3 is going to be the normal runlevel on most Linux boxen, so that's where you'll want it to be. In the xinetd config file for it, as long as you have 'disable = yes' in there, you're golden.

Remember to restart xinetd so the new change takes effect.
 
i added the proftpd -c configfile

to my boot.local

and started it up.

Running in standalone works perfect!

Thanks guys!
 
little more help

ok I can change the
/etc/xinetd.d/ftp_psa to disable
but how do I then stop it and what other changes do I need to make to get it into stand alone mode?

Redhat rc2
psa-proftpd-1.2.10-rh9.build75050128.10
 
connection hanging

ok I did all this and now have proftpd running in standalone mode.

I'm still having the same problem. Connection happens quick but then it sits at:
"connection data channel to..." for about 60-120 seconds.

Anyone have anything else to try?
 
Re: connection hanging

[QUOTEConnection happens quick but then it sits at:
"connection data channel to..." for about 60-120 seconds.[/QUOTE] Did you already check/edit your /etc/proftpd.conf file for these options:

ServerIdent Off
UseReverseDNS off

Then restart your standalone proFTPd service.

And also made sure your firewall was not limiting the normal passive port range? I think some had an issue with that as well in other posts...
 
thanks for the reply.

Yeah I made those changes to the proftpd.conf and still see the problem.

How do I make sure the firewall is not limiting the ports as you suggest.

I have the firewall set to allow all outgoing ports.
 
I have a domain which has Multiple web user which work as FTP users.
I need to manage all FTP Users under one main User. So that Admin can manage and download data from one admin login.
How can this be done on Plesk 7.5.4 on RH ESIV.

I have been told that it can be done by custom configuration of the proftpd daemon, but HOW?

Please let me know how by Admin FTP Login, I can manage all FTP / Web User Folders.
 
Back
Top