Computer Science Linux FAQ
coms_linux_faq,v 1.1 04/12/01
This document is maintained by Joe Mesterhazy (jmesterh@cs.iastate.edu)
It is not an official document of the CS Department, and is provided
in the hope that it will be helpful.
Feedback and suggestions are welcome; please send email to ssg@cs.iastate.edu
FREQUENTLY ASKED QUESTIONS:
0.
What does this faq cover?
1.
Which machines are capable of running Linux?
2.
How do I boot a machine into Linux?
3.
How do I boot from Linux back to Windows NT?
4.
Why does the system say 'password incorrect' when I try to login?
5.
The computer accepts my username and password but logs me out right away.
6.
A Linux box appears to be crashed. What should I do?
7.
My customized .xsession file does not appear correctly on the Linux machines.
8.
The display looks like it is shifted to the left or is garbled.
9.
Why do I get "Binary file not executable" why I try to run a program?
10.
Can I use Zephyr on the Linux machines?
11.
How do I setup or use SSH (secure shell)?
12.
How do I use Java?
13.
Who can I talk to about problems or ask for further help?
========================================================================
A: This is an attempt to address frequently asked questions pertaining
to the Linux machines in labs 115 and 116.
This document is available via the Com Sci
Web server as well: http://www.cs.iastate.edu/help/linux-faq.html.
A: Currently the machines that are capable of running Linux are the
HP-Vectra PCs in room 115 labeled PC115-01 through PC115-12,
and the Dell XPS T800r boxes in lab 116.
A: Log off the machine you want to boot into Linux, so you come to the
login prompt. Press Control+Alt+Del and then click on "shutdown", then select
"shutdown and power off" and press OK. After a moment power the computer back on.
Once the machine goes through the boot process, you will get a menu with the
selections Windows NT, Windows NT (VGA mode), and RedHat Linux. Use the
arrow keys to highlight "RedHat Linux" and press enter. The machine should
then begin to boot into Linux.
A: Log off of the Linux machine you wish to restart. Click on the shutdown
button, then select "Restart" and click OK.
After the machine has booted, you should be provided with a menu to choose
which OS you wish to use. Select "Windows NT" with the cursor keys and press enter.
A: If you have recently changed your password on another machine, and
the Linux box you are trying to access will not let you log in, reboot
the machine by following the instructions in the question above. If you
still cannot login, and you have a valid Computer Science UNIX account,
contact SSG.
A: It is most likely you have customized your .xsession file in a way that
Linux cannot understand. Log into a non-Linux machine and rename your .xsession
using "mv ~/.xsession ~/.xsession-old" so you can log in using the default
settings. See Question #7 for information regarding your .xsession script.
A: Do NOT reboot or turn the system off. Contact SSG.
A: Although we have tried to make Linux and HPUX as compatible as possible
there will always be differences in the way your .xsession file is interpreted
by the two systems. If you would like to restore your .xsession back to the original
one provided by the CS department, rename your .xsession with the command
"mv ~/.xsession ~/.xsession-old" and copy the standard .xsession file with the command
"cp /etc/X11/wmconfig/sys.xsession ~/.xsession".
A: Because Linux currently does not fully support the graphics adapters in
the HP-Vectras, a few graphical glitches may appear. This can be solved by
logging out, then at the login screen press and hold Control+Alt+Backspace
to reset the X-server.
A: It is most likely you are trying to execute a HP-UX binary and not a
native Linux binary. Try to recompile your program on a Linux machine.
It is recommended if you plan on switching between the two systems you either
make a different 'Makefile' for each system, or append a .exe.linux or .exe.hpux to
to the end of the executable name to be able to identify the correct program.
A: No. We do not plan on implementing Zephyr or Athena on the Linux boxes
because of stability concerns. If you wish to use Zephyr you can telnet to
another HPUX machine and run Zephyr from there.
A: To setup your account for SSH (create keys), login to a Linux machine,
run "ssh-keygen" and follow the instructions given. See http://support.cs.iastate.edu/faqs.php3?op=unix#19.
After you have your SSH keys created, you can open secure connections to other
machines on the CS network by typing "ssh hostname" where hostname is the name
of the computer you want to connect to. You may be required to enter the pass
phrase you entered when you created your keys. If you want to open a secure
X-Terminal to another machine, use the command "sxterm"
A: The department Linux machines include several versions of Java. The most
recent as of this writing is 1.3.0. These instructions assume you want to
run the most recent version. They also assume that you know how to set
environment variables using your default shell and how to edit the
configuration files for your default shell.
First add the Java binaries to your PATH. Do this by adding
/usr/java/jdk1.3/bin to your PATH variable.
Once you have set the PATH you can test it with the command:
java -version
This should print 'java version "1.3.0"' or something similar.
Next you need to setup your CLASSPATH. This is where Java searches for your
.class files. Java takes the fully qualified name of a class (e.g.
java.util.Vector, the package name + the class name) and converts this to a
path name (e.g. java/util/Vector.class). Then java searches for the class
by appending the previous result to each entry in your CLASSPATH. To search
inside .jar files the fully qualified path to the .jar file, including the
.jar file itself, must appear in your CLASSPATH.
A typical CLASSPATH is: /usr/java/jdk1.3/jre/lib/rt.jar:.:..
This tells java to look inside the rt.jar file, inside the current
directory, and inside the directory above the current directory.
To compile a java program you can use Sun's java compiler by typing the
command:
javac HelloWorldApp.java
If you have /usr/java/jdk1.3/jre/lib/rt.jar in your CLASSPATH and /usr/bin
in your PATH, then you can use IBM's java compiler by typing the command:
jikes HelloWorldApp.java
The jikes compiler is _much_ faster than the javac compiler.
To run a compiled java program use the command:
java HelloWorldApp
Note that the name of the actually class is used. No ".class" or ".java"
file extension is used.
A: The main SSG (System Support Group) offices are located in
108 Atanasoff Hall, and are typically staffed from about 7AM
until 5 PM. Knock on the door, and if it's unlocked, come in.
If the door is locked, it's probably the case that everybody has
stepped out for a moment; try again in a few minutes.
If your question can be answered in email, you may send mail
to ssg@cs.iastate.edu and we'll respond as soon as we can.
The ssg PGP public key follows:
-----BEGIN PGP PUBLIC KEY BLOCK-----
Version: 2.6.2
mQCNAy+jSIcAAAEEANgH6qe8JsBI/lURS5IsMzgXFaK6BtANfFO2IrB6EpOSJ4ST
czChdKhkgPrJa+u6TI15oRRiV7ouUpBFLbOxUH8Cvrw7Xk0BQWnnZMGfp0jVqZV6
G4UPOHxb1+froGzSsK5r4sL+pT0bkW6/6MgF4HnMo/ms2gRaP4+qwWCygOcVAAUR
tEFTeXN0ZW1zIFN1cHBvcnQgR3JvdXAsIENvbXB1dGVyIFNjaWVuY2UsIElTVSA8
c3NnQGNzLmlhc3RhdGUuZWR1Pg==
=u9Dk
-----END PGP PUBLIC KEY BLOCK-----