?
Solved

Redhat 4.2 and ncftpd

Posted on 1998-05-04
3
Medium Priority
?
282 Views
Last Modified: 2010-05-18
I am running web and ftp services on a Redhat 4.2 LINUX box.  The ftp software is ncftpd.  All processes are running but I can't get the ftp services to run.  I am kinda new at LINUX so bear with me.  I used the TOP command and it displays a 'D' next to the ncftpd.  Any suggestions
0
Comment
Question by:Gimmie
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
3 Comments
 

Expert Comment

by:dps96r
ID: 1584197
D means blocking in a device driver last time I saw it. If something
is staying a long time in that state something bad is probably
happening. Use strace to determine the last system call before it
becomes wedged.

Yopur logs are liable to fill up with messages from the kernel about
devices failing, so you might like to look there too.
0
 
LVL 3

Expert Comment

by:marcelofr
ID: 1584198
You should check your you name service (DNS).

Try using ip numbers, if it works, DNS is the problem
0
 

Accepted Solution

by:
NetDudeFL earned 280 total points
ID: 1584199
NCFTP is actually just a client, not a server as WSFTP (Windows FTP Client) is not a server, it's a client.  Have you tried to ftp to your IP address?  Many forms of Unix (redhat being one) does NOT start ftpd (the daemon) until there is an actual connection.  If not, you need to concentrate on your system initialization files.  Below should help:

Init is the program that gets run by the kernel at boot time. It is in charge of starting all the normal processes that need to run at boot time. These
include the gettys that allow you to log in, NFS daemons, FTP daemons, and anything else you want to run when your machine boots.

SysV Init is fast becoming the standard in the Linux world to control the startup of software at boot time. This is because it is easier to use and more
powerful and flexible than the traditional BSD init.

SysV init also differs from BSD init in that the config files are in a subdirectory of /etc instead of residing directly in /etc. This directory is called
rc.d. In there you will find rc.sysinit and the following directories:

     init.d
     rc0.d
     rc1.d
     rc2.d
     rc3.d
     rc4.d
     rc5.d
     rc6.d

init.d contains a bunch of scripts. Basically, you need one script for each service you may need to start at boot time or when entering another
runlevel. Services include things like networking, nfs, sendmail, httpd, etc. Services do not include things like setserial that must only be run once and
then exited. Things like that should go in rc.local or rc.serial.

If you want rc.local, it should be in /etc/rc.d. Most systems include one even though it doesn't do much. You can also include an rc.serial in
/etc/rc.d if you need to do serial port specific things at boot time.

The chain of events is as follows:

     The kernel looks in several places for init and runs the first one it finds
     init runs /etc/rc.d/rc.sysinit
     rc.sysinit does a bunch of necessary things and then runs rc.serial (if it exists)
     init runs all the scripts for the default runlevel.
     init runs rc.local

The default runlevel is decided in /etc/inittab. You should have a line close to the top like:

     id:3:initdefault:

From this, you'd look in the second column and see that the default runlevel is 3, as should be the case for most systems. If you want to change it,
you can edit /etc/inittab by hand and change the 3. Be very careful when you are messing with the inittab. If you do mess up, you can fix it by
rebooting and doing:

     LILO boot:  linux single

This should allow you to boot into single user mode so you can fix inittab.

Now, how does it run all the right scripts? If you enter ls -l on rc3.d, you might see something like:

     lrwxrwxrwx 1 root root 17 3:11 S10network -> ../init.d/network
     lrwxrwxrwx 1 root root 16 3:11 S30syslog -> ../init.d/syslog
     lrwxrwxrwx 1 root root 14 3:32 S40cron -> ../init.d/cron
     lrwxrwxrwx 1 root root 14 3:11 S50inet -> ../init.d/inet
     lrwxrwxrwx 1 root root 13 3:11 S60nfs -> ../init.d/nfs
     lrwxrwxrwx 1 root root 15 3:11 S70nfsfs -> ../init.d/nfsfs
     lrwxrwxrwx 1 root root 18 3:11 S90lpd -> ../init.d/lpd.init
     lrwxrwxrwx 1 root root 11 3:11 S99local -> ../rc.local

What you'll notice is that there are no real ``files'' in the directory. Everything there is a link to one of the scripts in the init.d directory. The links also
have an ``S'' and a number at the beginning. The ``S'' means to start this particular script and a ``K'' would mean to stop it. The number is there just
for ordering purposes. Init will start all the services based on the order they appear. You can duplicate numbers, but it will only confuse you
somewhat. You just need to use a two digit number only, along with an upper case ``S'' or ``K'' to start or stop the services you need to.

How does init start and stop services? Simple. Each of the scripts is written to accept an argument which can be ``start'' and ``stop''. You can
execute those scripts by hand in fact with a command like:

     /etc/rc.d/init.d/httpd.init stop

to stop the httpd server. Init just reads the name and if it has a ``K'', it calls the script with the ``stop'' argument. If it has an ``S'' it calls the script with
a ``start'' argument. Why all these runlevels? Some people want an easy way to set up machines to be multi-purpose. I could have a ``server''
runlevel that just runs httpd, sendmail, networking, etc. Then I could have a ``user'' runlevel that runs xdm, networking, etc.
0

Featured Post

Fill in the form and get your FREE NFR key NOW!

Veeam® is happy to provide a FREE NFR server license to certified engineers, trainers, and bloggers.  It allows for the non‑production use of Veeam Agent for Microsoft Windows. This license is valid for five workstations and two servers.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

I have seen several blogs and forum entries elsewhere state that because NTFS volumes do not support linux ownership or permissions, they cannot be used for anonymous ftp upload through the vsftpd program.   IT can be done and here's how to get i…
Note: for this to work properly you need to use a Cross-Over network cable. 1. Connect both servers S1 and S2 on the second network slots respectively. Note that you can use the 1st slots but usually these would be occupied by the Service Provide…
If you're a developer or IT admin, you’re probably tasked with managing multiple websites, servers, applications, and levels of security on a daily basis. While this can be extremely time consuming, it can also be frustrating when systems aren't wor…
In this video, Percona Director of Solution Engineering Jon Tobin discusses the function and features of Percona Server for MongoDB. How Percona can help Percona can help you determine if Percona Server for MongoDB is the right solution for …
Suggested Courses

650 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question