Make your own free website on

A Brief Beginner's Guide
Using Debian GNU/Linux

Version 7.0b


This basic guide assumes you have already successfully installed Debian GNU/Linux, and have a root and at least one user account (called here user1) with the X server configured.

It is not intended to be a complete guide to using Debian GNU/Linux but rather a brief collection of helpful practical notes to help you to use Debian. This guide will enable you to, among other things, connect to the Internet, and configure proper E-mail facilities using superb packages like Exim and Fetchmail.

The guide assumes that IceWM (a fast, simple and very elegant Window Manager) is the default X Window Manager - but the notes apply to most X Window Managers.

Note: This Guide is based upon Debian 2.1 (Slink) but is also applicable to 2.2 (Potato) except where marked (NA 2.2).

Powering On and Logging In:

When you turn the system on (boot the machine) there will be a brief pause at Lilo boot... and then GNU/Linux will load, with information scrolling down the screen until the xdm graphical prompt is reached which will read:

Debian GNU/Linux

login: password:

To login, type either root or user1, press the Return key, then enter the password. Note - passwords when typed on GNU/Linux systems are not echoed/shadowed by ******** as on some Operating Systems. If you make a mistake, you will simply be returned to the login prompt and will need to login again and then enter the password.

When logged in, the default Window Manager will start and you will be presented with a 'desktop' with some icons. You are now ready to use GNU/Linux.

For the IceWM you will find a 'start' button at the bottom left (Debian 2.1) and then various other icons. To open an Xterminal (or xterm) left click once on the icon that shows a small computer (it will say XTerm when you place your cursor over it). The numbers 1,2,3,4 represent the four virtual desktops available by default, and the xconsole will show system messages. The window at extreme right shows the CPU Status and can be very useful for monitoring the system - for instance, if a process is misbehaving you will be able to spot it here.

Learning About GNU/Linux:

The best way to learn is to use GNU/Linux. If you login as, and use, a user account, you can move around the system and discover how things work without doing any damage to the system itself (unlike some other Operating Systems). At the very worst, your X Window will freeze - and you can simply exit by pressing the Control, Alt and Backspace keys. And if ever the system itself seems to you to be frozen, then press Alt and Fx (where x is 2, 3, 4, 5 or 6) and you will open another virtual terminal with a prompt - or, if you are already using an X Window, Control-Alt-Fx which will again bring you to a command prompt.

To get back to X from a virtual terminal (console mode) press Control, Alt and F7. Note that many programmes - such as dselect, lynx (a Web Browser) and mutt (a Mail User Agent (see below) - look better when run in console mode, and many people prefer to use the console (see Do You Really Need X? ).

Xterminals and the Su Command:

Xterminals are a powerful feature of GNU/Linux - they give you access to the shell, the 'command line', where you can enter (i.e. type in) commands. Such commands enable you to start processes ('programmes') and interact with your system. A lot of the power and flexibility of GNU/Linux derives from using the shell, and by using it, you can configure and control your system.

When logged in as an ordinary user, there is a special command - su - which allows you access to the root shell (if you know and enter the root password). To use this, open an Xterminal and type su - you will be asked for the root password.

The su command is very useful, and saves logging out as a user and logging in as root. Be aware, though, that when you are logged in as root, either directly or when using the su command, it is possible to cause problems or damage your GNU/Linux Operating System, especially when editing configuration files.

Using IceWM:

If you are using Linux for the first time, a good way to find your way around is to use FTE, for which there is an icon in IceWM. However, you may find this a little daunting, as it is also a powerful editor, in which case an icon-based File-Manager may be better. An excellent one is included in Tkdesk - enter tkdesk in an xterm. It is recommended to place a space after this command and then the symbol & after the space. This returns the xterm to a prompt and gives you a PID (process ID) which can be useful (see Top and Kill Commands, below). You can do this with all similar commands which are non-interactive (i.e. which do not require further input).

Adding New Users:

To add a new user, login/su as root, then type:

adduser <username>

where <username> is the name of the user. This will create a directory for the user in /home and other directories, and you will be prompted for a full name and then asked to specify a password.

To change the password for a user at any time, login as the user, and type:


You will then be prompted to enter a new password.

Editing Files as Root:

You will often need to edit or create files. You must login as root, or (better) use the su command in a user Xterminal. The easiest editor to use and editor such as Vi or Vim - see the manual page (e.g. enter man vim in an Xterminal). To start Vim simply enter


followed by the path to the file you want to edit (e.g. /etc/fstab ).

Vim starts in Command mode - to enter text, press the i key, and then move the cursor to the desired position. When finished editing, press the Escape key (Esc), which brings you back to command mode. To save and exit, you must be in command mode, and enter


where w means 'write' and q, quit. Remember to add the : symbol also before wq. To delete text, enter command mode - pressing the x key deletes what is under the cursor.

Some Basic Commands:

A command can be a combination of letters, a single letter, a name, or a combination of all these. The basic structure of commands is:

commandname/indicator <flag(s)> <argumentA> <argumentB> ....... <argumentX>

Simple commands consist of just a name or some letters - such as cd. Most simple commands can have a flag and arguments applied to them which can be said to 'refine' the basic command or make it perform a specific function. The flags and arguments for a particular command are given in the man page (manual page) associated with the command - enter man <command> in an xterminal to view the manual. Flags are often preceded by a minus sign, or two minus signs ( --) and the flag is always separated from the command, and the arguments from the flags, by a space. Note that all directories begin with a / and this must be written - e.g. to specify the /home/user1 directory, it must be written with / first.

cd <name> change to the directory <name>. Here, cd is the command, and <name> an argument of the command

ls list the files in the current directory (except hidden ones)

ls -a list all the files in the current directory

mkdir <name> create a new directory with the name <name>

Accessing Floppy and CD-ROM Drives:

(NA 2.2)

The default installation of Debian does not allow you to directly access these drives. To access them you can, as root, or via su, edit the /etc/fstab file and change it to read:

/dev/hda1 / ext2 default,errors=remount-ro 0 1

/dev/hda2 none swap sw 0 0

proc /proc proc defaults 0 0

/dev/hdc /cdrom iso9660 ro,noauto,user 0 0

/dev/fd0 /floppy auto noauto,user 0 0

Note: hda1, hda2 will vary depending on the partitions on your hard drive. hdc is a CD-ROM drive as master on secondary IDE controller.

This will allow users access to both drives.

To access the floppy drive, use the su command, enter the root password, then

mount /floppy

When finished, you must unmount the floppy using

umount /floppy

Please note the space after mount and before /floppy; and after umount and before /floppy. Such spaces are important when entering commands in GNU/Linux. To mount the CD-ROM drive:

mount /cdrom

This must also be unmounted when finished with:

umount /cdrom


To find your hostname (needed for IP and mail configuration - see later) enter


in an xterm. The name is also given in the /etc/hostname file. Also, as root, run the command ifconfig and it should give you basic network configuration information.

Adding New Software:

On Debian, new software should be installed in /usr/local/

To install software from CD-ROM (e.g. Applixware Office) you can mount the CD-ROM manually from the command line, as root, or use the command su in a user Xterminal which will bring you to a root prompt. You can then type:

mount /dev/hdc -o ro /cdrom

This will give execute access to the CD-ROM. Alternatively, you could, as root, change (by adding 'exec') the /etc/fstab file, then change it back after the install. To do this, change the /dev/hdc /cdrom line to read:

/dev/hdc /cdrom iso9660 noauto,ro,exec 0 0

Note: It is best to use dselect to install .deb packages to update the system, either from the supplied CD's or via the Internet using the apt method of dselect (see below: dselect-apt). You can also use the excellent apt-get method (see below: Updating Packages).

Logging Out:

To logout - e.g. to change from root to user1 and vice versa - either use the Close button after opening the Debian 'start menu' or right click on an empty Desktop area, then click on 'Close'.

If you are using a text console (e.g. the display has frozen and/or you used Ctrl-Alt-Fx ) then to logout - e.g. to change from root to user1 and vice versa - type


Shutting Down:

It is important to shut GNU/Linux down correctly, otherwise the file system may be damaged. To shut down, login/su as root then type:

shutdown -h now

When you see:

system halted

it is safe to turn the system off.

If you just wish to re-boot the system, enter

shutdown -r now

Internet Configuration:

If you are new to GNU/Linux, writing your own configuration scripts to enable your system to connect to the Internet may seem daunting, but it is fairly simple and does not take much time. Once done, and your connection is up and running, you will have a sense of achievement - something you do not get by simply clicking on an icon. You will also have developed a better understanding of how your system - and GNU/Linux - works. You will have completed your first adventure in a new world.

Several web browsers are installed by default - including lynx and Amaya [go Programs->Apps->Net]. Amaya is good, but remember that this is still 'beta' software and so may have some 'bugs' - once connected to the Internet, you can download the latest version (currently 2.1 which is good but does not support frames) from [Note: For how to install the Amaya file once downloaded, see below. ]

You can use a text browser such as lynx (see below Using the Lynx Browser), or install Xemacs and the w3 packages (if not already installed) and then use Xemacs for browsing (see below Using Xemacs). Lynx is a very good and much underestimated browser, although it does not show images and does not work with those badly designed image-rich sites whose GNU/Linux unaware designers wrongly and somewhat ignorantly assume everyone uses a MS Internet Explorer type, frames-aware, Java-enhanced browser. Xemacs/W3 is also a good browser and will work with some of these badly designed sites.

Before you start your Internet configuration you will need to have connected a modem to a serial port (or installed an internal modem) and know: (1) the telephone number of your ISP (2) your login name and password (3) details of the DNS servers - domain name (e.g. and the primary and secondary DNS (e.g. (4) the port your modem is set on (e.g. ttyS1) (5) the type of authentication - either CHAP or PAP.

The configuration is divided into two stages, as follows, and is for a 'stand-alone' system with a modem connected to a serial port. It assumes you have set your system, during install, in loopback mode - i.e. you are not on a network and intend to use a modem to connect to your ISP.

I - Configuring Apache:

If you intend using your system/box/machine as a local (LAN) server or as a web-server, you need to install the Apache webserver (using dselect) and then configure it.

If you simply wish to use/browse the Internet, you do not need to install Apache, and so go straight to II - Editing Internet Configuration Files.

Apache configuration is very simple. Once Apache is installed enter, in an xterminal,


and then set the options to those of your system (usually you can accept the defaults).

If Apache still does not work after this, then check the /etc/apache/httpd.conf file. This must have an uncommented line which says:

Server Name localhost

If necessary, remove the # before ServerName and add 'localhost', deleting anything else on that line.

Check also that the file contains:

ServerType standalone

Port 80

Hostnamelookups off

ServerRoot /etc/apache

Then re-run apacheconfig if you have edited the file.

II - Editing Internet Configuration Files:

The important configuration files for internet connection on Debian are: (1) /etc/ppp/peers/provider; (2) /etc/ppp/chap-secrets [or pap-secrets]; (3) /etc/resolv.conf; (4) /etc/chatscripts/provider. These are the files you must check and if necessary edit. You should also check the /etc/ppp/options file and make sure that 'lock' (some way down the file) is commented out - place a # in front of it if one is not there.

(Note: You can also use pppconfig - simply enter, as root, pppconfig. This presents a series of dialogue boxes. But to really understand your system it is much better to view and alter the config scripts themselves.)

(1) .../provider

Under 'debug' you will find the lines you may have to edit. Note: the text in square brackets is not in these files, but notes to inform you what the line means, or what to add/change. For clarity the actual content of the files is given in bold.

/dev/ttySx [Note- change this to the port your modem is on: for example to /dev/ttyS1

115200 [Note:- modem speed. Usually set to this.]

defaultroute [Note:- if this is not present, add]

noipdefault [Note:- if this is not present, add

user <your ISP login name> [Note:- if not present, add followed by a space and then your login name. If your login name has characters e.gUk/zza29 - enclose in ' ' ( e.g. 'UK/zza29' )]

(2) .../chap-secrets [or pap-secrets if PAP is used]

Make sure this contains your ISP login name followed on the same line (after some spaces) by * and then your ISP password, e.g.:

'UK/zza29' * mypassword

[Note: you should add another line below this, exactly the same, if you enclosed your login name as above, but this time leaving out the ' ' .]

(3) .../etc/resolv.conf

This should be empty (or anything else commented out with #) except for

Nameserver <> Nameserver <>

'Nameserver' should be followed - after some spaces - by first the primary and then the secondary numbers given to you by your ISP (e.g. Thus the line would read: Nameserver

(4) /etc/chatscrips/provider


" " ATZ

there should be

OK ATDT<number to be dialled> Connect \d\c

Note: you might also want to check that the /etc/ppp/peers/provider file has the line:

connect "/usr/sbin/chat -v -f /etc/chatscripts/provider"

Once these files are configured, you can connect to the Internet by opening an Xterminal, entering the su command, and typing


To disconnect, enter


(Note: watch, or open, the Xconsole window, for it will tell you a lot.)

If you have all these scripts configured correctly, and still cannot connect, check the following:

(a) /etc/hosts

This should contain only one line such as: spacetime localhost

(replace spacetime with the name you have given to your system)

(b) /etc/hosts.conf

This should contain only:

order hosts,bind multi on

(c) /etc/networks

This should have only:



Also installed on the system is an Internet dial-up utility called WVDial. This is very good, and easy to configure. If not already configured, enter wvdialconf in an xterm. The configuration script is in /etc/wvdial.conf and should be along the following lines, depending on your modem:

Phone = < your ISP telephone number, with no space> Username = <your ISP username> Password = <your ISP password> New PPPD = yes Modem = /dev/ttySx <replace x with correct number, as above> Baud = 115200 Init1 = ATZ Init2 = ATQO V1 E1 SO=O &C1 &D2 S11=55 +FClass=0

You should also have a /etc/ppp/peers/wvdial file which contains only:

noauth name wvdial

To start wvdial - open xterminal, su, and enter


To stop wvdial, the best way is to click on the xterminal where you entered the wvdial command, then press the Control key and the c key together.

Using the Lynx Browser:

The lynx browser is very fast, and ideal for viewing and retrieving information from the Internet. To start lynx, simply enter lynx in an xterm. Note that if you try to start lynx without being connected to the Internet and it fails to start, returning a message like 'cannot connect' than you have probably specified a URL during install and need to edit the /etc/lynx.cfg file if you want to use lynx off-line. You need to change the Startfile line to read exactly as the Helpfile line below (after the initial Helpfile word), and then restart lynx.

To set your options, enter the single letter o (small letter o ). This allows you to reject/accept cookies, set an editor for html files (such as emacs) and turn the colour setting off (this can make text easier to read). The user mode enables you to disable the bottom two lines of help text.

To fetch a URL, press the g key, then type in the full URL (i.e. with http:// ) then press the Return key. Links are highlighted (if colour mode is off) or in a different colour (if colour mode is on) - to follow a highlighted link, press the right arrow key. To move to another link and highlight it, use the up or down arrow keys. To go back, use the left arrow keys.

To bookmark a URl, press the a key, then choose from the list. To view browsing history, press the backspace key (on most UK keyboards; if this does not work, use the delete key). To download a page, press the d key, then choose from the options.

You can view the html of the viewed page by pressing the \ (forward slash) key - and edit this by pressing the e key (if you have entered an editor in the Options file). You can also view files on the local disk - press g key then enter the local path to the file after entering

file://localhost/<file path>

You can use lynx for ftp sessions as well. Press the g key then enter

ftp://<ftp server>

where <ftp server> is the name of the ftp site you wish to connect to - e.g. ftp.debian. org (for help on using ftp - see Using FTP below).

If you want to view pages in a slightly larger format than the default xterm size, then before you start lynx, re-size the xterm window you are going to use, then start lynx.

The Top and Kill Commands:

Sometimes, you may find that you cannot stop a process (or 'program') that you have been running when clicking the 'close/exit' button. To stop the process, you need to know what is called its PID (Process ID).

There are two ways of finding this. First, enter

ps f

in an xterminal. The second way is to enter


then the single letter


(for user) followed by your user name. This will show the processess you are running and the PID's. To quit top, simply enter the single letter


To stop - kill - the process enter

kill <PID>

If this does not work (and it usually does) enter

kill -9 <PID>

which will certainly terminate the process.

Unless you know what you are doing do not use the kill command when logged in as root, either directly or via the su command

Configuring X:

There are two ways to configure the X window system which enables a GUI (Graphical User Interface) to be used. Both require you to be root and use a shell (command line). Before you start you need to know the vertical and horizontal deflection rates of your monitor (see the monitor manual), plus the make of and chipset used in your video card.

1) Enter xf86config This is text based, but almost always works.

2) Enter XF86Setup This is graphics based, but only works if you have installed a default X server (such as xserver-vga16) and the xf86setup package. Also, if your mouse is not correctly configured using gpm there may be problems - when xf86setup loads, you will get three screens, instead of one, and will have to either configure the mouse using gpmconfig or use xf86config instead.

Installing Amaya:

You should download the tar.gz file into /usr/local (or your home directory - e.g. /home/user1). Make sure you download the Linux Elf 2.1 file.

Then change to that directory by entering:

cd /usr/local

Then enter the following command to uncompress the file <filename>:

tar -xvzf <filename>.tar.gz

This creates a new Amaya directory within the local directory and unpacks the Amaya files into that directory.

[Note: A tar.gz file is a compressed tarball, and a tarball is basically a collection of files which are bundled together. Here, the command is tar - the option x means uncompress; the option v means verbose - show list of files; the option z extract, and the option f creates and names the folder that the files are extracted into. ]

Change to this new directory (if you wish you can look for it using a File Manager).

To run Amaya, open an Xterminal and simply enter the path:


Currently the full path is:


It is best to create a link to this file from the /usr/local/bin directory which will enable you to just type in 'amaya' in an xterminal. You could also remove the old 1.3 version which is installed by default. To remove the old version, use either the Remove option in dselect or the dpkg purge command (see below under dpkg ).

To create a symlink the easy way, start Tkdesk (enter tkdesk in an xterm) then using the browser, select the file you wish to make the link from, then right click, select the Copy option and enter the directory for the link (usually /usr/local/bin) then click on Link (symbolic) option.

Default Window Manager: NA 2.2

Edit the /etc/X11/window-managers file and place the WM you want as default at the top of the list.

Window Manager Configuration:

The file for configuration of a particular WM (~/preferences) is in /etc/X11. Thus, for Icewm, the file is /etc/X11/icewm/preferences.

If you wish to configure Icewm then edit the /etc/X11/icewm/preferences file. Anything that can be configured, can be done here.

For example, to remove the clock, simply change

TaskbarShowClock =1


TaskbarShowClock = 0

To set the default appearence, simply edit the


line. For example, if you want Motif as the default,


Executing Commands:

On Debian, the system searches the pattern given in the /etc/profile file when a command is entered. The default is:


which means /usr/local/bin is searched first for executables (binaries), then /usr/bin and so on. Thus, if you install programmes, you would usually install the binary of the programme in /usr/local/bin

Dselect - Apt:

To use the apt method of dselect in Debian 2.1 to install packages from the CD-ROM drive, start dselect, then go to Apt and add the following entry to the sources list:


Then go to the packages - e.g. 'slink', 'main'.

Busy CD-ROM:

Sometimes you may find the CD-ROM drive busy - you may have mounted it as a different user. To find out, enter

fuser -v /cdrom

Configuring LILO:

The default Debian installation boots straight into GNU/Linux without offering a prompt or much of a delay. If you need a prompt, then when LILO boots, press the Alt key which should bring you to a prompt. If this does not work, try the Shift, Ctrl and Alt keys together. However, some users prefer a permanent prompt followed by a set delay so that if necessary certain boot options can be set. This is useful if you need to boot into single user mode, which is a root shell on a console (no X ) - this is necessary on the rare occasions when you need to recover a crashed system or if you need to change monitors and do not wish to boot straight into an X window session (because xdm is configured by default and you need to re-edit the /etc/X11/XF86config file).

To enable a prompt and a delay, as root, edit the /etc/lilo.conf file and add the single word


after vga=normal and before delay=

Then change the delay to 100 (tenths of a second). Save changes, and then as root run the following command which will re-install LILO:


If you need to boot into single user mode, then at the prompt enter

linux single


Configuring and Using Exim

While Netscape can be used for E-mail it is better to use a proper MTA - Mail Transfer Agent. One of the easiest to use and configure is exim which is installed by default. To configure, you need to know your host name. To check, in an xterm enter


Then, you need to as root enter eximconfig in an xterm. Usually Option 2 should be chosen (smarthost with dial-up connection).

Set the visible name to the domain name (it should come up as the default option). Set the smart host to the smtp server where you have your ISP account - usually something like smtp.<ISP name>. For instance - You should accept the default values for the rest, and choose a user account for admin when prompted.

You may also need to edit the new /etc/exim.conf file to ensure that it reads

local_domains = < short domain name> : localhost

(NA 2.2) Next, you need to uncomment (i.e. remove the # ) two lines toward the end of the exim.conf file under the Rewrite Config. heading. The lines begin:

*@<domain name> ${lookup{$1} ...........

Then you need to create a new file in /etc called email-addresses which should be owned by root, be group root and have

rw- r-- r--

permissions. Then you enter in this new file the local user names followed by the ISP E-mail address. Thus, for local user orion with ISP E-mail address is


This re-writes the headers on outgoing E-mail so that the correct ISP E-mail address is given. The file can contain the addresses for all local users: start each one on a new line.

Note: There is also another way to do this (as so often in GNU/Linux). Instead of the above, you can also add the ISP details at the end of the exim.conf file - again at the very end of the #Rewrite Config .... section. You need the following entry:

<local user name>
<ISPusername>@<ISP domain> Ffs

Thus, for orion, this would be:

orion Ffs

Note the three letters - Ffs - at the end. F means From-address; f means from-header; s means sender-header. The entry you make should be just before the #End of Exim conf.... You can also add r to the Ffs options to re-write the Reply-to header.

You can check that all is well with Exim by entering the following in an xterm:

telnet localhost 25

This should return something like

220 <hostname> ESMTP Exim 2.05

To quit, enter quit.

To send mail, you need to use a Mail User Agent (MUA) - either elm which is installed by default, or another MUA such as Mutt, also installed by default. elm is easy to use - just enter elm in an xterm and it will create the folders required. Note that when you are composing a mail, elm drops you into Command mode (see Editing Files as Root above) - press i to enter text, and Esc when finished, etc.

Mutt is very good, and can easily be configured. Like elm, when composing mail, you are dropped into vi command mode. System wide configuration for Mutt is in the /etc/Muttrc file. For instance, to save a copy of outgoing messages, uncomment the

set copy=yes

line, and uncomment then change the set record =" " line to read

set record="+outbox"

which will create the Outbox in the user's Mail folder in their /home directory. To see the headers of a message in Mutt, press the h key when reading the message.

Another good mailer, VM, is included with Xemacs - enter xemacs in an xterm, then from the top menu bar choose Apps, then Read Mail (VM). To compose, click once on the Compose icon. To send, click on the Mail option from the top menu bar, then Send. You can also use mail which is the Unix default - just enter mail in an xterm.


To retrieve mail from your ISP, you can use Fetchmail, which is installed by default. All that needs to be done is create a file, in the home directory of the user, called .fetchmailrc (note the dot - . - before the filename). Thus if the user is orion, this would be in /home/orion. This must be owned by the user, and have the following permissions:

rw- -- ---

(Note: You can use Tkdesk to create the file, and change/set the permissions - click on the Info icon to change/set permissions.)

The .fetchmailrc file should be along the following lines:

set postmaster "<username>"
poll <POP mail server> with proto POP3
user "<POP username>" there with password "<POPpassword>" is<username> here

This assumes POP3 protocol is being used. The username is the username on the localhost, the POP mail server the ISP mail server domain name (e.g.; and the POP username your ISP/mail username. Postmaster, POP username, and POP password should be enclosed in quotes (".......").

To run fetchmail, connect to the ISP, enter fetchmail in an xterm and it will collect and deliver your mail to /var/spool/mail/<username> where it can be read by elm or any other MUA.

Many options can be entered in the .fetchmailrc file - see the documentation in /usr/doc/fetchmail. For instance, you can set a logfile (e.g. /var/log/fetchmail.log), set a daemon to poll for mail at regular intervals, and poll several mail accounts.

Also, if you have multiple accounts on one POP server, and another account on another POP server, you should create a root .fetchmailrc (in /root) which is like this:

set postmaster "postmaster"
poll pop <POP mail server> with proto POP3
user <POP username1> there with password <POPpasswd1> is <username> here
user <POP username2> there with password <POPpasswd2> is <username> here
poll pop <POP mail server2> with proto POP3
user <POP username3> there with password <POPpasswd3> is <username> here

You can then su, and run fetchmail which will poll the different accounts and deliver the mail to the correct users. When fetchmail exits it issues an exit code - the normal (error free) ones are 0 (mail retrieved) and 1 (no mail on server). If you want to see what fetchmail is doing, start fetchmail with the flag -v thus:

fetchmail -v

You can also adapt the sample fetchmail-up and fetchmail-down scripts given in /usr/doc/fetchmail, adding them to /etc/ppp/ip-up.d and /etc/ppp/ip-down.d to run and quit fetchmail when you connect/disconnect to your ISP.

Using Xemacs:

Xemacs (a variant of the original GNU emacs) is a fully-featured environment which enables you, among many other things, to create, edit and spell-check text and html files; read, compose and send E-mail and, via W3, browse the Internet.

When you start Xemacs (and emacs) you will see two buffers - the main, larger, one ('scratch') and a mini-buffer at the bottom where commands appear and where commands can be entered. The basis of both emacs (and thus Xemacs) is the buffer - which is basically a 'container' which contains whatever you are working on, such as a file. It is possible to have many buffers open at the same time, and also have buffers open which are doing different things so that, for example, you can edit a file in one buffer, read and compose E-mail in another buffer, and browse the Internet in another one. As an editor, emacs/Xemacs has a very useful multiple undelete.

To open a file, click on the Open icon, then place the cursor over the directory or file that you want, left click once, then press the Return key. This will load the file - if it is a html file, it will open in html (code mode) and you will find a HTML icon on the menu which will allow you to view it in a browser.

To close the file, go to File menu, then Delete Buffer <file-name>. To create a new file, press the Control and x keys at the same time, then the Control and f keys and enter the path and file name in the mini-buffer at the bottom (where it will say find file). If you specify a htm or html extensio, a new html file will be created, with the html doc tags already inserted.

If you ever find that you seem to be 'hung' in a buffer and that whatever you do you just get an error beep, press Control and the g key together which will cancel whatever operation you may have started.

It is possible to set security levels when using W3 to browse the Internet. To start W3, from the Apps menu, go Browse the Web. To set your level, choose Preferences from the Edit menu, then Url, then Privacy level. Once there, place the cursor over the Value in [ ] brackets and right click. This will open a menu, and choose the level you require. Then click Save, then Done.

To set the default option (blank page/home page etc.) go Edit Preferences from the Options menus. Change, then save and exit. To fetch a URL, either press the Control and o keys at the same time, or from the File menu choose Open location. Then enter the URL you want in the mini-buffer at the bottom and press Return. If you have set the blank page option then when you start a new Browse session from xemacs you will find the main scratch buffer still open while the mini-buffer inserts the beginning of a URL - just enter the URL required and press Return.

Note than when using W3 to follow a link, place the cursor over the link, then press the return key.

Using FTP:

To start a ftp session, connect to your ISP, then enter, in an xterm (or switch to a text console)


followed by the ftp server you wish to connect to. For instance, for it would be


When connected, you will be asked to login and provide a password. For anonymous ftp, the login name is anonymous, and the password your E-mail address. You will then get the ftp prompt:

ftp >

To view files in directories, use the cd (change directory) command, then ls (list files). To return to a directory use the cdup command.

When downloading files, make sure that if you are downloading binary (programme) files you are in binary mode - to make sure, at the ftp prompt enter


To retrieve text files, enter


It is very useful to change your local directory before you download or upload files so that you only have to enter to local name of the file you want to get or upload. The command is

lcd <path to local directory>

where the local directory is where you want to download files to or upload files from.

To download, enter

get <remote file-name>

If you wish to upload a file:

put <localfile name>

If you want to upload a file and change its name:

send <local file name> <new remote file name>

It is useful to see download/upload progress - to do this, before you download/upload, enter the command


which prints to screen a # character for every 1024 bytes which are downloaded/uploaded.

To get several files use the mget command followed by a list of the files. To upload several files, the command is mput.

To quit, enter quit.

Multiple ISP Dial-Up

If you have several ISP accounts it is possible to configure Debian so that you can connect using

pon <ISP name>

1) You need to create a new file in /etc/ppp/peers and name it something like the name of your ISP - e.g. pipex. Then change the permissions (using Tkdesk is the easy way) to be

rw- r-- ---

The owner should be root and the group dip.

Copy over the the contents of the etc/ppp/provider file and then change only the user and the last part of the connect line. Change this last part from provider to the name you have given to the new file - e.g.. pipex.

2) Add the numbers of the ISP nameserver to the /etc/resolv.conf file, under the ones already there and in the same format.

3) Add your ISP name and password to the /etc/ppp/chap-secrets (or pap-secrets) file in the same format as those already there.

4) Create a new file in /etc/chatscripts/ and name it as in (1) - e.g. pipex. Copy over the contents of the /etc/chatscripts/provider file and change the telephone number to that of your ISP. Change the permissions etc. as you did for (1).

To connect to this ISP simply enter pon <name> - for example,

pon pipex

Disconnect in the usual way with poff.

Exim Administration

Install eximon from the Slink CD's to graphically monitor exim.

To delete a message in the queue, and log this, enter

exim -Mg <message ID>

An ID will be similar to - 11iM3D-000cR-00. (Note: the g in the command stands for "give-up".)

To delete a message without any log entry:

exim -Mrm <message ID>

Using Dselect and dpkg

When using dselect the following points might be helpful: 1) After placing a disc in the CD-ROM drive, wait until the drive light goes out/disc stops spinning before pressing the 'Enter'/Return key; 2) After selecting the install method from Access always run Update before selecting any packages.

To remove a package:

dpkg -r <package name>

To purge a package (the best way to remove as it removes the config files)

dpkg --purge <package name>

To report the status of a package

dpkg -s <package name>

Installing Netscape

If you wish to install Netscape the best way is to install the Debian Netscape installation package from the Slink CD's, then either fetch the Netscape tar.gz file via ftp, or copy it from a CD. Note: You can quit dselect, and ignore the error message about Netscape

The binary should copied to /tmp and it should be the x86 glibc2* version. After having copied the tar.gz file to /tmp you can then run Configure in dselect which will install Netscape.

The following should be noted when using Netscape:

(1) There are many bugs in Netscape - some to do with Java - so you may find that Netscape sometimes crashes, does odd things, or not work at all. (2) If you have problems with Netscape, try disabling Java (Go 'Preferences' from the Edit menu). (3) Netscape is not free software, and so therefore cannot be copied as the rest of the Debian packages can. (4) There are GNU Copyleft browsers available such as Lynx, Xemacs-W3 and Amaya.

Securing the System

If others have access to the system it is important to enter a password in the /etc/lilo.conf file to prevent them gaining access to the root shell by entering commands at the LILO boot prompt. This facility is useful if you wish to debug/restore a crashed system or you have lost the root password (see below) but it is good security to set a password so only you can use this facility.

Password settings can be either general, to apply to the images booted, or restricted, to apply when a boot prompt is requested through key presses (usually the Alt key - see Part I). This is usually what is needed. Passwords are case-sensitive. The following example /etc/lilo.conf file has a restricted password setting:

boot=/dev/hda1 root=/dev/hda1 install=/boot/boot.b map=/boot/map vga=normal restricted password=<password> delay=20 image=/vmlinuz label=linux read-only

The file should already be owned by root, and belong to group root, but you must change the permissions to

rw- -- ---

(Note: If you wish to make your system even more secure you should enter a BIOS password, enable booting from hard disk only in BIOS, and disable user access for both floppy and CD-ROM drives by removing them from the /etc/fstab file.)

Lost Root Password

If you have lost the root password, reboot and get the boot prompt (press Alt as soon as Lilo appears on screen). Then enter

linux init=/bin/sh

which will bring you to a shell (console - no X). Then enter:

mount -n -o remount, rw /dev/hda(x)

[ Note: hda(x) is usually hda1 - where the root partition is. ] This re-mounts the filesystem read-write. Then enter

vi /etc/shadow

This starts the vi editor and loads the /etc/shadow file.

Then remove the password string for root (which is between the first and second colons - that is, between : ). Then save and quit (that is, :wq) then enter


Then wait a few moments and enter


You can then login as root without a password and set a new root password. Note: sync writes the data in a buffer to disc - if you omit this, you will find that your changes were not written to disc and you are back where you started.

Set Default Colour Depth

If you wish to alter the default colour depth, edit the /etc/X11/XF86Config file. Find the "Screen" section under the default X server. The default X server is listed in /etc/X11/Xserver. For example, if the default X server is Accelerated XF86_Mach 64:

# Accelerated Servers Section "Screen"

Driver <name> Device <name> Monitor <name> DefaultColorDepth <8, 16, 32>

Subsection "Display"

Depth < > Modes <"800x600">

You need to enter the depth you want after DefaultColorDepth. Note - there may be just a value here, such as 8. If so, enter DefaultColorDepth followed by the value.

Updating Packages

The best way is to use the excellent apt-get method. It is necessary to add the source of the updated .deb packages you wish to install to the /etc/apt/sources.list file. Note: you need the http or ftp source of the updated .deb packages and make sure you copy the source address exactly or apt-get will return an error mesasage. For the sources of .debs try the Debian web-site (

You then need to connect to the Net, and run

apt-get update


apt-get dist-upgrade

After downloading, apt-get automatically unpacks the packages and installs them. To install an individual package, add the source to the apt sources file then enter

apt-get install <package name>

After running apt-get it is recommended that you run

apt-get clean

which removes the downloaded debs stored in /var/cache/apt/archives

Part Two

Dual Boot

What follows is one way to set up a dual system - there are several other ways. First, install the other OS, using the whole drive for the install. Then use the fips utility (which is on the Debian CD in the tools section) to re-size the partition used by the other OS, and make a new partition to accommodate Debian. Boot the Debian install programme, delete the new partition created by fips, and create new GNU/Linux partitions using the Debian install programme. Then install Debian and set Lilo to boot from the MBR (master boot record) using the default boot from hard disc option.

After the Debian install, all you need to do is change the /etc/lilo.conf to include the other OS:

boot=/dev/hda2 root=/dev/hda2 install=/boot/boot.b map=/boot/map vga=normal delay=20 image=/vmlinuz label=linux read-only

#other OS

other=/dev/hda1 label=win table=/dev/hda

(Note: This example assumes the root partition is hda2. You should run /sbin/lilo after altering the file to re-load lilo.)

Then, when the system next boots, press Alt for a boot prompt, then enter either linux to boot Debian or win to boot the other OS.

Security and other Updates

It is a good idea to frequently update the system using apt-get. This applies particuarly to security patches. To retrive and install the security patches add the following line to /etc/apt/sources.list then enter apt-get update followed by apt-get dist-upgrade.

deb stable updates

General updates can be obtained by entering

deb stable updates

XDM Crash

In the event of xdm crashing (it has been known) and you find you cannot kill the X server with Control-Alt-Backspace, then find the xdm PID's using top and kill both of them.

When xdm starts, it forks and two xdm processess are run.

Mutt Configuration

The file to edit is /etc/Muttrc

To save a copy of outgoing mail, unset (by removing the #)

#set copy=yes

and then change #set record= " " to

set record="+outbox"

This creates an Outbox for users in ~/Mail

Updating X Server

You will need to enter the source of the latest X .deb packages in the /etc/apt/sources.list file. For example, enter

vi /etc/apt/sources.list

which will open the file using the vi editor. [ Note that vi starts in command mode - to enter text, press the i key. To delete text, press the Esc key, pressing the x key deletes what is under the cursor. To return to edit mode, press the i key. To quit and save, press :wq (that is, colon followed by wq). Another way is to use fte.

(NA 2.2) At the time of writing (November 1999) the latest Slink deb for X is version 3.3.4 and is available at: xfree86-334-slink

This (with deb before the http) is what you should enter as the source in the /etc/apt/sources.list file.

Then connect to the Net, and enter

apt-get update

Then enter

apt-get dist-upgrade

After the download is complete, the packages will be automatically unpacked and installed. You should then run

apt-get clean

Silent Modem

If you want to disable the speaker on your modem, you need to alter the modem initialization string. For wvdial this is in /etc/wvdial.conf and simply add M0 (that is, Mzero) to the Init 2 string after ATQ0 V1.

For the chatscript used when pon is entered, edit the /etc/chatscripts/provider file and add ATM0 followed by OK after ATZ OK so that it reads

" " ATZ OK ATMO OK ATDT<number>

Here, M is the AT command for speaker; followed by 0 means off; by 1 speaker off until carrier detected; by 2 speaker always on; by 3 off while dialing and on until carrier detected.

You can also use the AT command L to adjust the volume; L0 is low; L1 not so low; L2 medium; L3 high volume.

Tuning X Server

To fine tune or adjust the X server defaults, use (or install the package if not installed) xvidtune which provides a config tool to change options. Enter xvidtune in an xterm.

Format Floppy

To format a floppy in drive 0 - i.e. dev/fd0 - enter, in an xterm,

superformat /dev/fd0 hd

For details about this, enter

info fdutils

Note: The fdutils package is usually installed by default.


The easiest way to set file and directory permissions is to remember the following:

4 = read r 2 = write w 1 = execute x

Thus 7 (4+2+1) means rwx and 5 means r-x.

Hence 755 would mean rwx r-x r-x

To change permissions, enter:

chmod <permissions> <path>


chmod 755 /usr/bin/cal

would change the permissions of cal in /usr/bin/ to rwx r-x r-x

More on Security

To make the system more secure, check the /etc/inetd.conf file and comment out those services not used or required (e.g. finger). Two services which should usually be left enabled are

smtp stream

ident stream

Also, edit /etc/hosts.deny and deny access to all:


Then place in /etc/hosts.allow those allowed.

Adding Users to Group DIP

To save using su every time a user connects to an ISP using pon, you can add the user to the dip group. Enter

gpasswd -a <username> dip

To remove a user from a group:

gpasswd -d <username> <group name>

Scroll X Terminals

It is sometimes useful to scroll up and down an xterm if the information fills more than the visible screen (for example, if you enter something like ps aux, most of which cannot be read).


Shift+PageUp (or Page Down)

MC in Colour

If you have not got the Midnight Commander file manager in colour mode as default and want to use colour for a session, enter

mc -c

If you want to make this the default for the current session:

alias mc="mc -c"

Note: For best results, use mc in console mode - i.e. without running X.

Proxy ARP Error Message

If you get an error message about not finding Proxy ARP and you do not have a network card installed, edit /etc/ppp/options and change the proxyarp line to:


Using PGP with Mutt

Note: 2.2 Installs gpg

First, you need to download and install the Debian pgp package (which for Slink is pgp-i_2.6.3a-4.deb). Then create a directory called .pgp in your home directory and

chmod 700 /home/<user>/.pgp

Next, run

pgp -kg

to generate the keys.

Find your new key ID by

pgp -kc

Create a public key file which you can send to others:

pgp -kxa <username>

It is a good idea, when prompted, to give your username for this file. The resulting file is then <username>.asc and this (which contains your key ID) is what you send to others to enable them to decrypt your messages.

They need to send you their public key as a <name>.asc file, and their key ID, and you add this to your keyring by:

pgp <name>.asc

then validate this with

pgp -ks <name>.

To use mutt with pgp, compose the message in the usual way, then - after the :wq operation - when the message appears ready to be sent you press the p key (for pgp options). Choose e for encrypt and it should show you the key ID's for you and the person to whom you are sending the message (you may have to enter their key ID first time). Then press Return, then y and the mail will be sent.

When receiving an encrypted message, you will be prompted to enter your pass phrase after which mutt will automatically decrypt and display the message.

Using Mutt with GPG

gpg is the GNU Privacy Guard - the GNU alternative to PGP. It is available as a .deb package and in source form (a tar.gz file). The .deb package for Slink is version 0.4 - the latest source available is version 1.0.1.

If using the source, the tar.gz file should be placed in /usr/local and extracted using

tar -xzvf /usr/local/gnupg-1.0.1.tar.gz

Then cd to the new gnupg directory and run:




followed by

make install

This will install the binary in /usr/local/bin

Note: if you install as suid root you can avoid the "using insecure memory" messages (this assumes you have installed the suid package). If not, to disable the messages place the following in your /home/<user>/.gnupg/options file:


To generate keys, as a user enter

gpg --gen-key

To use gpg with Mutt, as root edit the /etc/Muttrc file and set:

set pgp_gpg="/usr/local/bin/gpg"

and then:

set pgp_default_version="gpg"

Note: if you are using the .deb package set:

set pgp_gpg="/usr/bin/gpg"

You should also:

set pgp_sign_micalg="pgp_sha1"

and then, if using the default Mutt (version 0.95.3-0.2) on Slink with a newer gpg (version 1.0 or > ) make a symlink in /usr/local/bin from gpg to gpgm.

This link is not necessary if you are using the older .deb version (0.4) of gpg which works with Mutt 0.95.3-0.2

Using gnupg

To create a Public key file:

gpg --export -a -o <filename>

-a sets ascii mode; and -o outputs to a file.

Usually, this output file should be <username>.gpg

To view your fingerprint (useful for reading out over the telephone etc.)

gpg --fingerprint

To import then sign someone's key:

gpg --import <filename>


gpg --edit-key <UID>

where UID is user's ID. Find it with:

gpg --list-keys

which will print a list of keys in ~/.gnupg

When you use the --edit-key option you will get a prompt. The options you need to enter are:

1) trust 2) sign 3) save

To send your public key to a public keyserver, add a line in the ~/.gnupg/options file. For example, if the keyserver is add:


Then connect to the Net and enter

gpg --send-keys

which will upload your public key.

To sign and compress a file/document:

gpg --sign <file>

where <file> is the path to the file. This outpurs a <file>.gpg

To sign a document which is then readable:

gpg --clearsign <file>

which outputs <file>.asc

To encrypt a document:

gpg --encrypt <file>

To decrypt:

gpg --decrypt <file>

To secure your private key you could copy your ~/.gnupg directory onto for example a floppy disc and then delete the directory from the hard disc. To then use gpg you need to add the following option to gpg commands:

--homedir </path-to-directory>

Thus, if the directory is on a floppy disc, mount the floppy disc, then to for example sign a document:

gpg --homedir /floppy --sign <file>

To use gpg with Mutt, after writing the file by using :wq and pressing return, press the p key, which brings up pgp encryption options. Choose from the menu (e.g. b for both sign and encrypt). When prompted enter the gpg pass-phrase, press return, then return again, and the mail will be encrypted and sent.

Encrypted mail is decrypted automatically provided you have imported and signed the senders gpg key (see above re importing gpg keys).

Locking A Configuration File

Sometimes you might want to lock a particular system file to prevent it being accidentally changed (for example your /etc/lilo.conf file). Also, no links can then be made to this file. To do this:

chattr +i <absolute path to file>

If you want to remove this lock:

chattr -i <absolute path to file>

For details about this see man chattr

Viewing Exim Daily Logs

To receive Exim statistics regarding incoming and outgoing mail, edit the /etc/cron.daily/exim file which gives instructions as to which lines to uncomment.


You will need to configure the package magicfilter, which is usually installed during a default installation. To do this, as root, run:

/usr/sbin/magicfilterconfig --force

Then choose your printer from the options. If necessary, you can tweak the configuration file /etc/printcap

If this does not work, install the package apsfilter (which will automatically remove magicfilter).


To get a sound card working, you need to recompile the kernel and compile in support for sound. For instabce, if you have a SoundBlaster card, when choosing module options, you need to choose the option for the SB card.

Compiling a New Kernel

Make sure that you have the source tar.gz file for the kernel you wish to use installed in /usr/src. These will be named kernel-source-<kernel-version>.tar.gz. Then cd to /usr/src and untar the source:

tar xzf /usr/src/kernel-source-<version>.tar.gz

Then cd to the new directory in /usr/src/ named after the version number. Next, choose whether to compile using console mode (command line) or using a menu under X. For command line enter

make config


make menuconfig

or, for menu when using X

make xconfig

In console mode, you will have three options: y (yes), n (no) or m (compile as module). After selecting all the options you require (still in /usr/src/<source-version> directory) enter the following

make dep


make clean


make bzImage


make modules

Next, if you are using the source of your current kernel version, you should move your old modules directory:

mv /lib/modules/<version> /lib/modules/<version>-old

This step is not necessary if you are using a source with a different number to the one you are currently using.

Then enter

make modules_install

The new kernel will be in /usr/src/linux/arch/i386/boot named bzImage

Move this new kernel to /boot/ and rename it:

cp /usr/src/kernel-source-<version number>/arch/i386/boot/bzImage /boot/vmlinuz-<version-new>

Next, make sure that the symlink /vmlinuz points to the new kernel - you will need to modify the link. Then edit /etc/lilo.conf by adding a new section:

image=/vmlinuz-<version> root=/dev/hda1 label=Old read-only

This enables you to boot the old image - vmlinuz-<version> - by entering old at the lilo boot prompt. (Note: change /dev/hda1 if necessary to that of your own system.)

Then re-run lilo:


Then copy the new kernel image to a new floppy. cd to the directory containing the image, then:

dd if=vmlinuz-<version-new> of=/dev/fd0 bs=512

Note: the bs=512 option simply means read and write 512 bytes at a time. (Enter info dd for information about dd.)

If you have modified your /lib/modules as above then you need to move the modules directories around

mv /lib/modules/<version> /lib/modules/<version>-new

mv /lib/modules/<version>-old /lib/modules/<version>

Configuring GPM

gpm is a console mouse utility. To change the configuration, enter


This writes /etc/gpm.conf

For a ps2 mouse a sample config is:

device=/dev/psaux responsiveness= type=ps2 append=""

For a serial mouse:

device=/dev/ttyS(x) responsiveness= type=ms append="" [ or a string set by the config programme]

Console Messages

If you want system messages displayed on a console (as well in the xconsole which is enabled by default) uncomment the relevant lines in the /etc/syslog.conf file - "#I like to have messages displayed..." - and change tty8 to the console you want the messages to display on (e.g. tty6). [ See also below : Making New Virtual Consoles.]

To access the messages when using a virtual console, simply press the Alt and Fx keys where x is the number of the virtual console you chose (e.g. 6) to send the messages to.

Making New Virtual Consoles

You can create up to 63 virtual consoles. To create a new console, edit the /etc/inittab file. For example to create tty8, add the following after the entry for tty6:

8:23:respawn:/sbin/getty 38400 tty8

then, as root, run

/sbin/init q

to re-read the inittab file. The new console will then be available.

Note that you should not create tty7 by entering tty7 as this is reserved for X.

Creating tar.gz archives

To make an archive which extracts to a directory with the archive file name, cd to the parent directory, then

tar cvfz <directory name>.tar.gz <directory name>

For example, if the files you want to archive are in a directory named dir2 and the path to this directory is /home/user/dir1 (so the full path is /home/user/dir1/dir2) then the parent directory is /home/user/dir1

To make an archive which unpacks into the current install directory - where you place the tar.gz file - without creating a new directory, cd to the actual directory containg the files, then:

tar cvfz ../<directory name>.tar.gz *

Note the two dots (..) before the / and the * after tar.gz

Configuring Ethernet Card



The main file is:


The (first) card is eth0 and a sample configuration is:

inet addr bcast mask

Note that is reserved for the device lo - the loopback device.

To assign an address:

ifconfig eth0 <address>

You should also check that the entries in /etc/hosts are the same as for ppp config. After adding the ethernet card, when you run /sbin/ifconfig it should now have two sections, the first for lo and a second for eth0.

You can assign the route using the route add address command (see man route for more details).

To check what is happening, you can run the netstat command (see man netstat).

For more details see Basic Ethernet Configuration

Secure Boot

NA 2.2

Those concerned about the security of their Debian system - if it is used by others - should be aware that, by default, the Slink system can be booted from a floppy even when booting is disabled in the BIOS and a password is given in /etc/lilo.conf.

To so boot, press the Shift key when the system is booted (and before the default boot/lilo prompt appears) and you get a prompt similar to 3FA which indicates partition 3 can be booted (3), a floppy can be booted from (by pressing the F key) and Advanced mode is available (which enables booting from any partition).

To boot the default partition, at this 3FA type prompt simply press the Return key. (See /usr/doc/mbr/README for more details.) To boot from, say, partition 2 - press a key followed by number of partition, here 2.

To disable this facility, you can edit the boot= line in /etc/lilo.conf - for example

boot=/dev/hda root=/dev/hda1

or probably best of all physically disable or remove the floppy drive.

This mbr facility can be very useful - for example, if there is another OS on hda1, with GNU/Linux root partition on hda2, then simply pressing Shift+A+1 will boot this other OS, and Shift+A+2 will boot GNU/Linux.


wget is a useful utility for retrieving files via both ftp and http and by default it retrieves in binary mode. To retrieve a file, connect to the Net, then

wget <url>

wget can retrieve a list of files, and, being non-interactive, can do this in the background while other processes are active. See man wget and /usr/doc/wget for more details.

Activating Swap

You can initialize already existing swap space by

mkswap /dev/hda(x)

where x is the swap partition (e.g. hda4). To activate this:

swapon -a

If the swap file exists in /etc/fstab it will then be automatically initialized at next reboot. (See man mkswap and man swapon.)

Changing Time and Timezones

To change the system time (for example to add one hour):

date --set=+1hour

The same for minutes:

date --set=-2minutes

To change the timezone:


To Start/Stop Daemons in /etc/init.d

/etc/init.d <name> start

/etc/init.d <name> stop

Manual Fsck

To manually check a file-system:

a) Reboot into single user-mode (enter linux single at lilo prompt)

b) mount fs read-only if necessary (Debian does this automatically for / fs):

mount -n /dev/hda<x> -o remount,ro

where <x> is the partition containing the fs to be checked

c) run:

/sbin/e2fsck /dev/hda<x>

Slay and Zombies

Sometimes, using kill -9 pid does not kill a misbehaving process. You can slay it by

slay <user>

where <user> is the name of the user using the process. Note that this will kill all the processess of that user.

Also, sometimes a zombie will result when one process is killed. To remove a zombie:

kill -1 1

which will restart init but without rebooting the system.


Sudo allows a user to execute root commands without knowing the root password. This can be very useful on shared systems - for instance it is possible to allow certain users access to certain programmes, or to reboot or shutdown the system after they have finished using it.

To set up sudo, as root, edit the /etc/sudoers file by using the visudo command. Thus, to allow user1 to halt and reboot the system:

#Cmnd_Alias spec

Cmnd_Alias REBOOT=/usr/etc/reboot Cmnd_Alias SHUTDOWN=/usr/etc/shutdown

#User privelege


Then link /sbin/reboot to /usr/etc/reboot and /sbin/shutdown to /usr/etc/shutdown

The user can then run the commands

sudo reboot


sudo shutdown


Emacs can be used for creating and editing text, for sending and receiving mail, for reading and posting Usenet articles, and for writing and editing computer programmes using a variety of languages. It has the advantage that it can be do all these things from the command line - that is, X does not need to be running.

When started, emacs "loads" the ~/.emacs file which contains/can contain customs settings. This file is written in lisp - for example, to disable the menu bar at the top:

(menu-bar-mode nil)

Many custom .el files are available for emacs on the Net. To load these files, place them in a special directory (e.g. ~/emacs) and add the following to the ~/.emacs file:

(load "~/emacs/file")

where file is the name of the .el file. Note that it is not necessary to write file.el

All .el files (which can be read in a text viewer) can be byte-compiled to run faster. Th easiest way to do this is start xemacs, open the file in the main (scratch) buffer, then choose byte-compile buffer from the Lisp-Interaction menu. The result will be a .elc file.

The text version created using Debian 2.1 and emacs 19; and converted to html using texi2html. Final edit using emacs 19.

Copyleft 1999 by Space-Time Systems. This document is free; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the license, or (at your option) any later version. This document is distributed in the hope that it will be useful, but without any warranty; without even the implied warranty of merchantability or fitness for a particular purpose. See the GNU General Public License for more details.

Should you be lacking a copy of this, look at

This document was generated using the texi2html translator version 1.54.