The rest on Administration


The 'man' command

To view a 'man' page for any Linux command, you can type man command-name For example:
% man ls
LS(1)                            User Commands                           LS(1)
NAME
       ls - list directory contents

SYNOPSIS
       ls [OPTION]... [FILE]...

DESCRIPTION
       List  information  about  the FILEs (the current directory by default).
       Sort entries alphabetically if...

To get a list of any manual page that has a specific keyword you are interested in, you can using the man -k keyword command. For example, if you wanted to see a list of any commands that have something to do with calculator, then you could type:

% man -k calculator
bc                   (1)  - An arbitrary precision calculator language
dc                   (1)  - an arbitrary precision calculator
gnome-calculator     (1)  - GNOME Calculator
xcalc                (1x)  - scientific calculator for X
% man gnome-calculator
    ...

In some cases, there is a man page by the same name, but in different sections of the manual. In this case, you can specify which section you want the manual to be displayed. This example searches for man pages that have to do with shadow and then requests the man page from section 5 to be displayed:

% man -k shadow
shadow               (3)  - encrypted password file routines
shadow               (5)  - encrypted password file

% man 5 shadow
SHADOW(5)                                                            SHADOW(5)

NAME
       shadow - encrypted password file

DESCRIPTION
       shadow  contains the encrypted password information for users'
       accounts....

If you want to print a man page to the printer you can use the man -t command-namd syntax. For example, to print the gnome-calculator man page, you could type:

% man -t gnome-calculator | lpr

If you want to know what a command is, you can type whatis command-name:

% whatis pdf2ps
pdf2ps  (1)  - Ghostscript PDF to PostScript translator

Backing up the system

UNIX systems have historically been backed up with dump and restore. However, dump and restore have not kept up with advances in Linux filesystems. Consequently it is recommended to choose an alternative as shown in the following examples: For enterprises with multiple clients to backup, a powerful solution is also available:
Amanda. For more information:

System logs

When the system is booting and running the startup scripts in /etc/rc.d/* the output from these commands are logged in: /var/log/boot.log and /var/log/messages (along with lots of other messages here, too).

The command: initlog(8) is what logs the information to the log files.

Configure what you want logged in the files /etc/initlog.conf and /etc/syslog.conf

The initlog -q option makes everything very quiet unless there is an error.


Using serial ports

The serial port is usually on the back of the machine with a 9-pin male "DIN" connector with the |O|O| symbol.

If you want to access the serial port on a Linux system, the file /dev/ttyS0 is usually used.

To send characters to the serial port:

minicom -s
If your serial port is not connected to a modem, then take out the modem init string (at least at the top of the config screen).

Many device speak: 9600 baud, 8 bits, no parity, 1 stop bit

Minicom communication parameters: Control-A (C-A) P

To send a 'break' on the serial line: control-A F

To log output to a file: control-A P To get help on minicom commands: control-A Z

If the communication on the serial port does not appear to be working, you can make sure the serial port is connected to a UART (a serial chip that "drives" the serial port - some connectors on some PCs do not actually work):

# setserial /dev/ttyS0
 /dev/ttyS0, UART: 16550A, Port: 0x03f8, IRQ: 4
                   ^^^^^^
                   This serial port has a UART

# setserial /dev/ttyS1
 /dev/ttyS1, UART: unknown, Port: 0x02f8, IRQ: 3
                   ^^^^^^^
                   This serial port doesn't have a UART
Note that when it says UART: unknown it probably means that no UART exists. In other words you probably have no such serial port support on that device and the other information on that line can be ignored.

For more information:


Time: Synchronize your system's clock

Using Start-->System Settings->Date & Time, you can: For more information:
The Official Red Hat Linux Customization Guide, Chapter 23. Time and Date Configuration.

Or if you want to use the command-line to set your system's clock, you can, as super-user:

date --set 11:57

Everything about the system and processes: /proc

You won't believe what information resides under the /proc directory. Check out /proc on your system:
cd /proc
ls

cat cpuinfo
    ...
cat meminfo
    ...
cat pci
    ...
cat swaps
    ...
cat version
    ...
For more information:

Making a boot disk after system installation

You can make a boot floppy disk after installation using: mkbootdisk. Here is an example:

mkbootdisk -v --device /dev/fd0 2.4.18-14
                                ^^^^^^^^^
                            (This is the version of the
                            kernel.  There will be a
                            directory with the version
                            of the kernel in the
                            /lib/modules directory.)

Adding swap space

If you don't have any spare disk partitions available for swapping, you can create a file that is used for swapping:
    Create the swap file
dd if=/dev/zero of=/swap bs=1024 count=20000
mkswap /swapfile
swapon /swap
For more information:
The Official Red Hat Linux Customization Guide, Chapter 2. Swap Space

Where to get more information

Linux Quick Reference Home
Linux Migration Home