how to start starting vsftpd from xinetd ? - Redhat
This is a discussion on how to start starting vsftpd from xinetd ? - Redhat ; Hello,
what do I need to do in order to configure xinetd to start vsftpd
FTP server automatically ? I am running Fedora Core 2. The vsftpd
is installed and works just fine if I start it from shell.
Thanks ...
-
how to start starting vsftpd from xinetd ?
Hello,
what do I need to do in order to configure xinetd to start vsftpd
FTP server automatically ? I am running Fedora Core 2. The vsftpd
is installed and works just fine if I start it from shell.
Thanks in advance,
- Andray
-
Re: how to start starting vsftpd from xinetd ?
In article <8x5rc.43809$kc2.655956@nnrp1.uunet.ca>, Andray Kaganovsky wrote:
> Hello,
>
> what do I need to do in order to configure xinetd to start vsftpd
> FTP server automatically ? I am running Fedora Core 2. The vsftpd
> is installed and works just fine if I start it from shell.
In general, you change the line:
disable = yes
to
disable = no
in the appropriate config file under /etc/xinetd.d (I'm not running Fedora, so
I don't know the specific file - its probably /etc/xinetd.d/vsftpd). Then you
need to tell xinetd to re-read its configs:
# /sbin/service xinetd reload
Kevin
-
Re: how to start starting vsftpd from xinetd ?
Kevin Collins wrote:
> In article <8x5rc.43809$kc2.655956@nnrp1.uunet.ca>, Andray Kaganovsky
> wrote:
>> Hello,
>>
>> what do I need to do in order to configure xinetd to start vsftpd
>> FTP server automatically ? I am running Fedora Core 2. The vsftpd
>> is installed and works just fine if I start it from shell.
>
> In general, you change the line:
>
> disable = yes
>
> to
>
> disable = no
>
> in the appropriate config file under /etc/xinetd.d (I'm not running
> Fedora, so I don't know the specific file - its probably
> /etc/xinetd.d/vsftpd). Then you need to tell xinetd to re-read its
> configs:
>
> # /sbin/service xinetd reload
>
> Kevin
[AndrayK 2]. Well, there is no file named /etc/xinetd.d/vsftpd or
/ect/xinetd.d/ftp in Fedora Core 2 installation, so it's not that
easy. This probably has to do with the fact that vsftpd is meant
to be started outside of xinetd (which man page for vsftpd seems
to suggest). I assume I will need to create such file from
scratch, but I don't know what contents of that file would be,
and what should be the name of this file.
regards,
-Andray
-
Re: how to start starting vsftpd from xinetd ?
spamtotrash@toomuchfiction.com (Kevin Collins) writes:
>In article <8x5rc.43809$kc2.655956@nnrp1.uunet.ca>, Andray Kaganovsky wrote:
>> Hello,
>>
>> what do I need to do in order to configure xinetd to start vsftpd
>> FTP server automatically ? I am running Fedora Core 2. The vsftpd
>> is installed and works just fine if I start it from shell.
>
>In general, you change the line:
>
>disable = yes
>
>to
>
>disable = no
Actually, the recommended method is to use the chkconfig command:
# checkconfig vsftpd on
scott
-
Re: how to start starting vsftpd from xinetd ?
Scott Lurndal wrote:
> spamtotrash@toomuchfiction.com (Kevin Collins) writes:
>>In article <8x5rc.43809$kc2.655956@nnrp1.uunet.ca>, Andray Kaganovsky
>>wrote:
>>> Hello,
>>>
>>> what do I need to do in order to configure xinetd to start vsftpd
>>> FTP server automatically ? I am running Fedora Core 2. The vsftpd
>>> is installed and works just fine if I start it from shell.
>>
>>In general, you change the line:
>>
>>disable = yes
>>
>>to
>>
>>disable = no
>
> Actually, the recommended method is to use the chkconfig command:
>
> # checkconfig vsftpd on
>
> scott
[AndrayK 2]. I executed "chkconfig vsftpd on", it didn't do anything -
no error message, but no FTP server neither. The vsftpd doesn't show
up in the list produced by 'pas -aux'. Any ideas ?
Regards,
-Andray
-
Re: how to start starting vsftpd from xinetd ?
Andray Kaganovsky writes:
>Scott Lurndal wrote:
>
>> spamtotrash@toomuchfiction.com (Kevin Collins) writes:
>>>In article <8x5rc.43809$kc2.655956@nnrp1.uunet.ca>, Andray Kaganovsky
>>>wrote:
>>>> Hello,
>>>>
>>>> what do I need to do in order to configure xinetd to start vsftpd
>>>> FTP server automatically ? I am running Fedora Core 2. The vsftpd
>>>> is installed and works just fine if I start it from shell.
>>>
>>>In general, you change the line:
>>>
>>>disable = yes
>>>
>>>to
>>>
>>>disable = no
>>
>> Actually, the recommended method is to use the chkconfig command:
>>
>> # checkconfig vsftpd on
# chkconfig -- duh.
>>
>> scott
>
>[AndrayK 2]. I executed "chkconfig vsftpd on", it didn't do anything -
>no error message, but no FTP server neither. The vsftpd doesn't show
>up in the list produced by 'pas -aux'. Any ideas ?
It is an on-demand server. xinetd will fire it up when an
incoming connection on the ftp port is received.
Try this:
$ netstat -a | grep LIST | grep ftp
tcp 0 0 *:ftp *:* LISTEN
Adding the -p option to netstat should show the process id for xinetd
as the listener on the ftp port.
scott
-
Re: how to start starting vsftpd from xinetd ?
Scott Lurndal wrote:
> Andray Kaganovsky writes:
>>Scott Lurndal wrote:
>>
>>> spamtotrash@toomuchfiction.com (Kevin Collins) writes:
>>>>In article <8x5rc.43809$kc2.655956@nnrp1.uunet.ca>, Andray Kaganovsky
>>>>wrote:
>>>>> Hello,
>>>>>
>>>>> what do I need to do in order to configure xinetd to start vsftpd
>>>>> FTP server automatically ? I am running Fedora Core 2. The vsftpd
>>>>> is installed and works just fine if I start it from shell.
>>>>
>>>>In general, you change the line:
>>>>
>>>>disable = yes
>>>>
>>>>to
>>>>
>>>>disable = no
>>>
>>> Actually, the recommended method is to use the chkconfig command:
>>>
>>> # checkconfig vsftpd on
>
> # chkconfig -- duh.
>
>>>
>>> scott
>>
>>[AndrayK 2]. I executed "chkconfig vsftpd on", it didn't do anything -
>>no error message, but no FTP server neither. The vsftpd doesn't show
>>up in the list produced by 'pas -aux'. Any ideas ?
>
> It is an on-demand server. xinetd will fire it up when an
> incoming connection on the ftp port is received.
>
> Try this:
> $ netstat -a | grep LIST | grep ftp
> tcp 0 0 *:ftp *:* LISTEN
>
> Adding the -p option to netstat should show the process id for xinetd
> as the listener on the ftp port.
>
> scott
[AndrayK 3]. I executed the "netstat -a", but 'ftp' isn't there. I can see
telnet (which I specifically enabled) but not ftp. Executing
"chkconfig vsftpd on" and trying to ftp into this machine
from other machine didn't change anything - attempt to connect to
FTP server fails, and "netstat -a" didn't show ftp.
My feeling is that xinetd fails to figure out that it needs to
launch 'vsftpd' in response to FTP connection request. I have older
Fedore Core 1 box with wu-ftpd, and there xinetd can figure out
that it has to launch wu-ftpd, because there is a file
/ect/xinetd.d/wu-ftpd with the follwoing contents:
# default: on
# description: The wu-ftpd FTP server serves FTP connections. It uses \
# normal, unencrypted usernames and passwords for authentication.
service ftp
{
socket_type = stream
wait = no
user = root
server = /usr/sbin/vsftpd
server_args = -l -a
log_on_success += DURATION
nice = 10
disable = no
}
I think I need something similar for vsftpd.
regards, Andray
-
Re: how to start starting vsftpd from xinetd ?
Andray Kaganovsky wrote:
> Scott Lurndal wrote:
>
>> Andray Kaganovsky writes:
>>>Scott Lurndal wrote:
>>>
>>>> spamtotrash@toomuchfiction.com (Kevin Collins) writes:
>>>>>In article <8x5rc.43809$kc2.655956@nnrp1.uunet.ca>, Andray Kaganovsky
>>>>>wrote:
>>>>>> Hello,
>>>>>>
>>>>>> what do I need to do in order to configure xinetd to start vsftpd
>>>>>> FTP server automatically ? I am running Fedora Core 2. The vsftpd
>>>>>> is installed and works just fine if I start it from shell.
>>>>>
>>>>>In general, you change the line:
>>>>>
>>>>>disable = yes
>>>>>
>>>>>to
>>>>>
>>>>>disable = no
>>>>
>>>> Actually, the recommended method is to use the chkconfig command:
>>>>
>>>> # checkconfig vsftpd on
>>
>> # chkconfig -- duh.
>>
>>>>
>>>> scott
>>>
>>>[AndrayK 2]. I executed "chkconfig vsftpd on", it didn't do anything -
>>>no error message, but no FTP server neither. The vsftpd doesn't show
>>>up in the list produced by 'pas -aux'. Any ideas ?
>>
>> It is an on-demand server. xinetd will fire it up when an
>> incoming connection on the ftp port is received.
>>
>> Try this:
>> $ netstat -a | grep LIST | grep ftp
>> tcp 0 0 *:ftp *:*
>> LISTEN
>>
>> Adding the -p option to netstat should show the process id for xinetd
>> as the listener on the ftp port.
>>
>> scott
>
> [AndrayK 3]. I executed the "netstat -a", but 'ftp' isn't there. I can see
> telnet (which I specifically enabled) but not ftp. Executing
> "chkconfig vsftpd on" and trying to ftp into this machine
> from other machine didn't change anything - attempt to connect to
> FTP server fails, and "netstat -a" didn't show ftp.
>
> My feeling is that xinetd fails to figure out that it needs to
> launch 'vsftpd' in response to FTP connection request. I have older
> Fedore Core 1 box with wu-ftpd, and there xinetd can figure out
> that it has to launch wu-ftpd, because there is a file
> /ect/xinetd.d/wu-ftpd with the follwoing contents:
>
> # default: on
> # description: The wu-ftpd FTP server serves FTP connections. It uses
> # \
> # normal, unencrypted usernames and passwords for
> # authentication.
> service ftp
> {
> socket_type = stream
> wait = no
> user = root
> server = /usr/sbin/vsftpd
> server_args = -l -a
> log_on_success += DURATION
> nice = 10
> disable = no
> }
>
> I think I need something similar for vsftpd.
> regards, Andray
[AndrayK 4]. I added the file /etc/xinetd.d/vsftpd with the following
contents:
service ftp
{
socket_type = stream
wait = no
user = root
server = /usr/sbin/vsftpd
log_on_success += DURATION
nice = 10
disable = no
}
and modified file /etc/vsftpd/vsftpd.conf (commented out statement
"listen=YES"). Now vsftpd is started automatically by xinetd whenever
FTP connection to the machine is attempted.
Does configuration file above looks right ? Do I need to pass vsftpd
any flags ?
regards,
-Andray
-
Re: how to start starting vsftpd from xinetd ?
In article <%K6rc.69912$wy2.53284@newssvr25.news.prodigy.com>, Scott Lurndal
wrote:
> spamtotrash@toomuchfiction.com (Kevin Collins) writes:
>>In article <8x5rc.43809$kc2.655956@nnrp1.uunet.ca>, Andray Kaganovsky wrote:
>>> Hello,
>>>
>>> what do I need to do in order to configure xinetd to start vsftpd
>>> FTP server automatically ? I am running Fedora Core 2. The vsftpd
>>> is installed and works just fine if I start it from shell.
>>
>>In general, you change the line:
>>
>>disable = yes
>>
>>to
>>
>>disable = no
>
> Actually, the recommended method is to use the chkconfig command:
>
> # checkconfig vsftpd on
Wrong - chkconfig is for starting up processed via various run-levels at boot
time. It does not have control over xinetd.
It is possible that vsftpd is setup to run as a standalone daemon, and then
running:
# chkconfig vsftpd on
would configure it to run at boot, but it will not start it. For that, you
would need to also run:
# service vsftpd start
Again, I am not running Fedora so I don't know which way its configured, but
previous versions (7.x thru 9.0) used xinetd to start ftpd.
Kevin
-
Re: how to start starting vsftpd from xinetd ?
In article , Andray Kaganovsky wrote:
-snip-
>
> [AndrayK 4]. I added the file /etc/xinetd.d/vsftpd with the following
> contents:
>
> service ftp
> {
> socket_type = stream
> wait = no
> user = root
> server = /usr/sbin/vsftpd
> log_on_success += DURATION
> nice = 10
> disable = no
> }
>
> and modified file /etc/vsftpd/vsftpd.conf (commented out statement
> "listen=YES"). Now vsftpd is started automatically by xinetd whenever
> FTP connection to the machine is attempted.
>
> Does configuration file above looks right ? Do I need to pass vsftpd
> any flags ?
That looks right to me. Does it work as you expected? That are many other
options you can specify, read 'man xinetd.conf' for more details.
Kevin
-
Re: how to start starting vsftpd from xinetd ?
spamtotrash@toomuchfiction.com (Kevin Collins) writes:
>In article <%K6rc.69912$wy2.53284@newssvr25.news.prodigy.com>, Scott Lurndal
>wrote:
>> Actually, the recommended method is to use the chkconfig command:
>>
>> # checkconfig vsftpd on
>
>Wrong - chkconfig is for starting up processed via various run-levels at boot
>time. It does not have control over xinetd.
Wrong. Try it and find out. chkconfig does handle the xinetd services
as of Redhat 8 (and possibly earlier). It handles modification of the
service configuration in /etc/xinetd.d and signals xinetd to re-read its
configuration.
(BTW - chkconfig does _not_ start up processes. The service command is
used for that. All chkconfig does for non-xinetd services is make and
remove links in /etc/rc.d/rc?.d)
The OP was missing the service configuration file in /etc/xinetd.d which is
normally installed as part of the vsftpd Redhat provided RPM.
scott
FYI:
$ strings /sbin/chkconfig | grep xin
/etc/init.d/xinetd reload >/dev/null 2>&1
xinetd
xinetd based services:
/etc/xinetd.d
/etc/xinetd.d/%s
$