Red Hat Linux 7 Unleashed

Red Hat Linux 7 Unleashed

By William Ball

linuxconf and Managing Your Services

One of the great things about Red Hat Linux is the number of tools included in the distribution to help you manage your system. One important tool is Jacque Gelinas's linuxconf, which can be called from a command line in a terminal window while you're running X, from the command line of your console screen, or through your favorite Web browser. You should use linuxconf for a number of reasons:

linuxconf is found under the /bin directory and weighs in at nearly 950,000 bytes. The program, written with more than 80,000 lines of C++ code, also comes with a support directory, /usr/lib/linuxconf, containing nearly 32MB of data, help files in several languages, and code modules.

After you log in as the root operator, start the linuxconf program from the command line with the following and press the Enter key:


   # linuxconf &

When you first run linuxconf you'll see a dialog of help text. If you're running X, have installed the GNOME software libraries, and run linuxconf a second time, the program's main window will appear as shown in Figure 9.1. Note that you can also use linuxconf without running X.

When used without GNOME libraries or from the console, the program (which started life as a configuration tool for the XFree86 X11 distribution) responds to keyboard commands just like Red Hat's Linux installation tool. Navigate around the program's dialog box by pressing the Tab key and then use the Enter key when the cursor is on a desired button or item in a list.

09fig01.gif

Figure 9.1 The linuxconf client features a new generation of graphical Linux administration tools.

linuxconf can be used not only interactively, but also from the command line. The following related commands (and perhaps others by the time you read this) will be found in your filesystem after you install linuxconf (part of Red Hat Linux since version 5.1):

Each program is a symbolic link to linuxconf. For example, to delete the user cloobie from the command line, use linuxconf's symbolic link userconf:


   # userconf --deluser cloobie

You can get help for each utility by using the --help command-line option, or if using X11, by clicking the Help button in the utility's main dialog box.

The linuxconf command will also help you properly start and stop services under Linux while the system is running. Although you can selectively "kill" processes with the following code, where pid is the number of the running process, this is a crude, ineffective, and potentially harmful way to stop processes and system services.


   # kill -9 pid

However, based on the information you have learned so far about the init scripts, you can use the following approach to stop the httpd Web server (as an example):


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

Both of these are manual approaches, but the Red Hat folks have taken great pains to make system administration easier, so why not take advantage of menu convenience? When you use linuxconf, you can see at one glance which processes are going to be enabled or disabled.

If you manually configure your system's services by hand editing configuration files, be careful—making changes to default runlevels in /etc/inittab or indiscriminately using administration tools to change services or runlevels can put your system into an unusable state. If you run into trouble, reset your computer and enter runlevel 1.

Booting into single-user mode might allow you to fix any problems (a similar approach to another operating system's "safe mode"). When you boot into single-user mode, you go directly into a root operator command line, which is handy for enabling a quick fix or performing other system administration tasks.

You should also know that linuxconf is a work in progress; not every item in the program is documented or has an associated Help menu or complete help text. For some additional details about linuxconf, tips on using modules, or other errata, see linuxconf's home page at http://www.solucorp.qc.ca/linuxconf/.

You can also subscribe to the linuxconf mailing list, linuxconf@hub.xc.org, or read archives of discussions about linuxconf through this site.

Share ThisShare This

Informit Network