Make boot disk in DOS |
CD:\Dosutils\rawrite |
Image file location |
CD:\images\boot.img |
Needed partitions |
Swap (should equal RAM size up to 70MB); /boot (20Mb); / (root shoud be the rest of your available disk space) |
Linux partitions can be made using Disk Druid during the install. As of RH 6.2, the installer will do the partitioning for you, just make there is at least 2Gb of free,unformatted Hard Drive space. If you already have another OS installed that formatted your entire drive, but still have free space available, you can use a utility like "Partition Magic" to resize the partition without loosing any data. Once you have at least 2Gig free space, put in the install CD and boot up with the boot disk. |
General Linux Setup (aka Debian;)
Most modern BIOSes will boot up a CD-ROM. When installing Linux from CD-ROM,
just insert the disk and boot up, you'll get prompted to enter for standard install.
Compiling, Extracting and Generally what to do with program installs
Look for distribution packages first, they are much easier to manage your system with.
Debian packages:
dselect
The main package manager, will show a list of all packages, installed or not, from the CLI.
gnome-apt
The Gnome gui front end for dselect, useful if you find dselect hard to navigate, but it's a little buggy.
There is also a package list at www.debian.org
apt-get install
As root, type apt-get install (packagename)
This will not only install the program in the correct place, but will also install any
needed dependancies for the program.
apt-get remove
apt-get remove (package name) will remove the program and all of it's unused dependancies.
apt-get upgrade
apt-get upgrade (package name) will upgrade your program to the latest verion.
apt-get dist-upgrade
This will upgrade your entire Debian OS!
The config file for apt-get = /etc/apt/sources.list
Edit this file to include any places to look for packages like web sites, CD-ROM etc.
Be sure to include deb http://security.debian.org/ stable/updates main if you have an internet connection.
apt-cdrom add
If your sources.list is corrupt (error on finding CD index), do the following as root:
insert your Debian CD #1 and type 'apt-cdrom add' for each CD (Woody has 7 CDs).
after all cds have been added, type 'apt-get update'.
Now you should be able to issue apt-get install (package name) without errors.
RPM packages are part of any Red Hat or Mandrake based Linux distro.
.RPM files can usually be uncompressed & installed by launching them from an X Windows file manager like GNOME or KDE, as long as they have EXECUTE rights (chmod 777 [filename]). |
To uncompress RPM from CLI (or "shell" in unix lingo): rpm -i filename.rpm i = inflate |
Compression: .tar.gz.bz2.tbz.zip.bin
Most compressed files need to be extracted in a shell window. To get a shell, launch the termnial program.
A shell is a UNIX term for a command line interface, which looks and acts like a DOS window in Windows .
For .tar.gz files (tar & gzip, the most popular) type: tar zxvf filename.tar.gz. It should unZip, eXtract and Verify Filestructure. |
To unzip .gz (gzip) files: gzip -dc filename.gz (-dc = Decompress & Check) |
To extract .tar files: tar -xvf filename.tar (-xvf = eXtract & Verify File) |
.bz2 or .tbz files: bunzip2 filename.bz2, or bunzip2 filename.tbz |
.tar.bz2 combo files: tar jxvf filename.tar.bz2 |
.bin files are executable. Either click on them in a filemanager or launch them from a shell: ./filename |
.RPM or .DEB files are not just compressed, they are part of a package management system. See Deb or Rpm sections above. |
Apache Web Server
Download:Apache to /usr
Extract: tar zxvf filename.tar.gz
Install: cd apache dir
./configure --prefix=/usr/local/apache (you can put apache anywhere, but this location matches the help docs)
make, make install
Start: /usr/local/apache/bin ./httpd (check ps -ef to verify)
You can also cp /usr/local/apache/bin/httpd /bin (binarys in /bin execute anywhere without typing ./ first)
Stop: kill (PID#) (check ps -ef for Process ID#)
Configure Settings: /usr/local/apache/conf/httpd.conf (edit with any text editor)
**note; default user= nobody group=nobody; editing this is not recommended
default users are usually webuser and webgroup group.
Edit HTML docs: /usr/local/apache/htdocs/index.html
Authentication:
edit the httpd.conf file to include:
Close XTerm window | exit or ^D |
Display current path | pwd |
Change to a new directory | cd /(directory name) |
Move up one directory | cd .. |
Move back to home directory | cd ~ |
List contents of current dir | ls (including hidden files = ls -al) |
Put list of directory into a file called foo.txt | ls -al > foo.txt |
Create a directory and call it foo | mkdir foo |
Remove empty diectories | rmdir |
Print a file | lpr filename.txt |
Delete a file | rm foo.txt |
Edit a text file | (name of text editor like pico or vi) filename |
Copy foo.txt and call it foo2.txt | cp foo.txt foo2.txt |
Move a file | mv foo.txt /home/foo.txt |
Rename a file | mv foo.txt foocopy.txt (same as move, but without a new dir) |
Create or combind "concatenate" text files | cat > filename (^D quits) |
Login as root from user prompt | su (then root password) |
Logout as root back to user prompt | exit |
Clear the screen of previous text | clear |
Read a text file | less filename.txt (space for next screen, b for back, q for quit) |
Combind commands together | use the "pipe" key = (shift + \) command1 | command2 |
Print a listing of all files in a directory | ls -al|lpr |
List files in brian's homedir one screen at a time | ls ~brian|less |
Load a flopy disk | mount /mnt/floppy (contents then appear in /mnt/floppy/) |
Load a CD | mount /mnt/cdrom (contents them appear in /mnt/cdrom) |
View help file for a command | man commandname or info commandname |
Print the lpr man page | man lpr|col -b|lpr |
Find the word "bar" (regardless of case) in foo.txt | grep -i bar foo.txt |
Find a file by name |
find [start path] -type [d=dir f=file] -name "filename" |
Check what mounted on the system | mount |
Check disk space | df |
Check TCP/IP settings | ifconfig |
Check for echo response from another system | ping -c 3 host.domain (will ping a system by name 3 times; pings are infinite if -c # is not used) Ctrl+C to stop ping loops. |
Check route path to another system | traceroute host.domain (same as NT/2000; "tracert" in Win95/98/ME) |
Display current environment & system settings | env |
Display system settings only | uname -a (all)(prints: sysname[-s], netname[-n], OS release[-r], OS version[-v], Machine type[-m], processor[-p]). |
Use menus in terminal | mc = midnight commander, the text version of the GNOME file manager. |
Display text file one page at a time | more |
Identify Shell types by prompt | $ = bourne shell, $ = user, # = root |
Logout of Linux | logout |
Shut the system down |
shutdown (-h = off, -r = reboot, +# = minutes to shutdown)
or poweroff, or reboot halt will stop system only. Then use ctrl+alt+del to reboot. |
Switch to another GUI at next XWindow login | switchdesk |
Format floppy disk | mkfs -t ext2 /dev/fd0 (or use gnofloppy/kfloppy when in GUI) |
Change login screens | Ctrl+Alt+F1-F6 (F7 = default XWindow) |
Location of most shared programs | /usr/bin (users, binaries) |
Set access rights | chmod dir or filename permission# (4=read, 2=write, 1=edit; per order= root, owner, allusers) example: 756= root has all, owner has read+edit, allusers have read+write. 'chmod 777 foo.txt' would give all users full rights to foo. |
User creating | useradd (username) ; passwd newuser (password) |
Install or configure X Windows | Xconfigurator (writes config to /etc/X11/XF86Config) |
Start X Windows | startx |
How to boot directly into X Windows | /etc/inittab, change ID line to 5. Example: id:5:initdefault (3=CLI w/net, 2=CLI no net) |
check XWin settings | rpm -qa|grep^X (note last line = video type) |
Change XWin resolution | Ctrl+Alt+"+" key |
Users; adding, deleteing, editing rights. | userconf (User Configurator, must be logged in Gui as root) |
Network settings | netconf (Network Configurator, must be logged in Gui as root) |
Partition and Network access settings | fsconf (File System Configurator, must be logged in Gui as root) |
Main GUI source for all settings | linuxconf (Linux Configurator, must be logged in GUI as root) |
Force Quit | ctrl+alt+shift+tab |
Pico | F1=help, F2=exit & save, F3=Save, F4=Format paragraph, F5=Paste another file, F6=Search for text for no save, F7=Back page, F8=Forward page, F9=Cut text, F10=Paste text, F12=Spell checker, ^X = Exit, N for no save |
Vi | vi (filename) to create or edit a file. See VIM, the GUI version, or VI Commands |
emacs | emacs (filename) to make/edit file. See emacs commands |
View DOS floppy | mmdir a: |
Format floppy for DOS | mformat a: |
Copy DOS file from floppy to Hard Drive | mcopy a: filename |
Copy file from Hard Drive to floppy | mcopy filename a: |
^ | Symbol for the Ctrl key.
Example: ^c = Press the Ctrl+c keys |
| | The pipe key, used to combind commands together.
Example: du | sort -rn | more |
^D | The EOF 'End Of File' key, used to signal the end of an entry.
Example: at 12:00 < enter > /home/user/logscript ^D |