Up


Yet another Linux FAQ
:

3 How do I...?

3.1 Find out what's going wrong?

First: Don't panic! Cursing, whining, and throwing the computer out the window will not help solve the problem ( It will make you feel better for 5 minutes :-). In most cases you are not the first person who got stuck by this, so chances are that there is already a documented solution to your problem somewhere. For the FAQs for the distribution you are using check out my other FAQs page section 8 of the FAQ. If that doesn't work try looking it up at http://groups.google.com

Second: Find out, what exactly doesn't work. That's what error messages are for. System wide errors are documented in /var/log/messages
( type 'less /var/log/messages' ) as root without the quotes to read this file. Keeping track of new entries in this file is possible by typing 'tail -f /var/log/messages' in a xterm window or a second console. X-server errors are kept in /var/log/xdm-error.log, or generated in files in your home directory, usually called .Xerrors or .Xsession-errors. You can generate the error logs for every program yourself by typing 'name_of_command 2> error.log'. This will write error messages of name_of_command to a file called error.log. This also applies to programs run within X: just start them by typing the command(and full path if needed) in a terminal window(kvt, konsole, rxvt, or xterm). Now you know where the trouble lies. So how do you get rid of it? Read on!


3.2 Use documentation efficiently?

It is by no means an exaggeration to say that Linux is one of the best-documented OS's in existence. Furthermore a large part of the documentation (http://www.tldp.org/) is actually written by the users, and therefore doesn't require a degree in computer science to understand them. ( You are reading one such document now :-)

Man pages: These are are the standard help files provided with most Linux programs. (Apart from KDE apps and GNU software.) 'man name_of_command' will give you the man page for that command( typed in to a terminal window or at the console) 'man -f  name_of_command' will give an one line description of the command. 'man -k [string]' searches for a given string in the synopsis lines of all man pages.(example: man -k X will give you a long list of all man pages related to the X windows system) 'man -K [string]' will search the whole body of every man page for the given string. This may take a while. Navigating within a man page is the same as within less. '/[string]' searches forward for a string. Pressing 'n' will search for the next match. '?[string]' searches backward for a string. 'h' gives more help on man navigation. 'q' quits. There are X programs to handle man pages as well. KDE help 'kdehelp man: name_of_command'. There is also tkman, xman, and the GNOME help browser 'gnome-help-browser man: name_of_command'.

Info files: Info files are usually provided by programs written byGNUlike gcc, Emacs, and a host of system utilities. Their advantage is that they provide a hypertext style help system. 'info name_of_command' gets you the info page of that command(example 'info info' will give you the help page for the info command). Navigation is achieved by typing 'n' next, 'p' previous, 'u' up, and then hitting the enter key. The top of every info page will show you where these commands will take you. There are X programs to handle info files as well. In KDE 'kdehelp info: name_of_command', GNOME help browser 'gnome-help-browser info: name_of_command, There is also tkinfo, and xinfo.

HowTo's: Written by experts and users alike and available in many languages and formats (including HTML, plain text, and PDF), these are an excellent source of information on a certain topic. They come with most distributions and are installed under /usr/doc/HOWTO. If they aren't there or you want to use the latest editions go online to The Linux Documentation Project (http://www.tldp.org/)

Others: These are usually stored within /usr/doc/name_of_program. (Newer distros have moved this to /usr/share/doc) 

Online: Another idea might be to look at the offending program's home page. Often they provide more information like FAQ's, mailing lists, archives, and troubleshooting guides. A quick search on Google will usually turn it up rather quickly.

Well you still haven't got a clue? Read on!

3.3 Get people to answer my questions?

Some hints to help you get help from others:

1. Try to solve the problem yourself first! Remember people in the newsgroups help out for fun. They are in no way obligated to help you. It's no fun answering questions that are already well documented. Do a little research first.

2. Be explicit! Include error messages/logs, program name and version, kernel-version, distribution used and version, full hardware information if related to your problem, and what you have tried so far. If you don't feel it's important enough to provide these things nobody else will think it important enough to answer.

3. Be specific! Choose the right audience for your questions, like comp.os.linux.hardware for hardware related questions, comp.os.linux.x for X windows related questions, comp.windows.x.kde for... you get the idea.

4. Be polite! I can't stress this enough a little thank you every now and then will help keep people motivated. 

Recommended Reading:(dare I say it this should be required reading) How To Ask Questions The Smart Way (http://tuxedo.org/%7Eesr/faqs/smart-questions.html)