1

I'm studying for the first LPIC exam. In a quiz, I've found this question:

How can you tell whether your system is using inetd or xinetd as a super server?

And the right answer should be:

Type ps ax | grep inetd, and examine the output for signs of inetd (or xinetd).

In my desktop (Fedora 21), this is the output of both cases:

15844 pts/0    S+     0:00 grep --color=auto inetd

15848 pts/0    S+     0:00 grep --color=auto xinetd

How should I tell which one is running, if one is running at all?

0

It's almost certainly xinetd since regular inetd is older than dirt but you can check the RPM database:

[root@xxx01 ~]# rpm -qa xinetd
xinetd-2.3.14-39.el6_4.x86_64
[root@xxx01 ~]# rpm -qa inetd
[root@xxx01 ~]#

For your commands you can probably just start the xinetd service to get the commands to work (since one isn't running it looks like).

Also, probably a better command to run than ps ax | grep <some binary> is to just use -C for example:

[root@xxx01 ~]# ps -C xinetd
  PID TTY          TIME CMD
 1823 ?        00:00:00 xinetd
[root@xxx01 ~]#

Which eliminates extra output like you saw if you just grep the output of ps.

2

The process you found running the command

ps ax | grep inetd

is the grep process itself, no (x)inetd server is running.

0

These answers are distribution specific, but you are taking a quiz about administering a machine that you didn't configure. You have no idea whether or not xinetd was renamed to act more like the traditional inetd. Querying a package database may not do any good. The best thing to do is to learn about each program so that you can distinguish between them.

I prefer to use ldd on the executables to determine the libraries that are linked to it. With xinetd, you should see links to libcrypt and libnsl, but you will not find those two libs linked to the traditional inetd.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.