Service Troubleshooting on Linux

Troubleshooting Internet services

This article series provides a set of steps for troubleshooting general issues accessing a network service, like sending an e-mail using your mail server or viewing a webpage on your web server.

There are two main topics covered by the articles in this series. The first part of the series details some techniques for testing that the correct program is running and accessible. The second section discusses checking connectivity between the client and server.

Before continuing to the articles, let's discuss some concepts that are useful to keep in mind while running through these troubleshooting techniques.


Logs are one of the most powerful tools you have when troubleshooting.

Unfortunately we can't describe all the messages you may find in the logs for all possible services. But the tools described in this series can help you narrow down what logs to check and what to look for in them.


Before we start going through the tests it’s worth covering what a super-server is and how this may change the way you troubleshoot your issue.

inetd and xinetd are examples of super-servers - they are designed to listen for requests on behalf of programs and then launch the required program when requested, thus saving resources if you have one configured to handle multiple daemons. This means it's possible a super-server could be listening on a port on behalf of your program.

If you’re unsure, netstat (see below) can be used to confirm if a super-server is listening on a specific port. Alternatively, check the super-server configuration file for the service.

For example, by default xinetd should have each service listed in a separate file found in /etc/xinetd.d/. Make sure the correct service-daemon is associated with the service. If you're not sure which file to look in try searching the files in /etc/xinetd.d/ for the service name or service daemon name.

Super-server configuration

Xinetd configuration files should list the service they relate to and the program to launch when a connection is received. The following example shows a basic configuration for the FTP service, in a file in the /etc/xinetd.d directory.

$ cat /etc/xinetd.d/vsftpd
service ftp
socket_type = stream
user = root
server = /usr/sbin/vsftpd
wait = no

You can use the grep command to search files in the config directory for references to a service. Searching for an ftp service would look like this:

$ grep "ftp" /etc/xinetd.d/*
/etc/xinetd.d/vsftpd:service ftp
/etc/xinetd.d/vsftpd:server = /usr/sbin/vsftpd

In the above example we find that the ftp service is specified in /etc/xinetd.d/vsftpd.


Now that you have an understanding of how a super-server is used and how to recognise when your system is making use of one, we’re ready to start troubleshooting your issue.

These articles will walk you through a set of tests that can be used to identify the common causes of issues with network-enabled services.

They will help you confirm that there is connectivity between the client and server; that the server is not experiencing excessive load; and that the application is running, accessible and responding to requests. If they don't directly help you identify the cause of your issue hopefully they will at least be able to point you in the right direction.

These guides assume that you are able to access your cloud server either via ssh or the console in the Cloud control panel.

We'll start by checking to see if the service is running.

Was this content helpful?

© 2011-2013 Rackspace US, Inc.


See license specifics and DISCLAIMER