Generic Navigation
Home
Site Map
What's New?
Who Are We?

Install Plesk On Windows

Newbie Navigation
Distributions
Installation Help
Filesystem Layout
XWindows
Networking & Internet
Security
Reviews and HOW-TOs

Links Of Interest
Linux.com  RVGLUG

Slashdot.org  Themes.org

Apache  Zope

[Manage]

Filesystem Layout

The Linux Filesystem

 

  Well, now you have your brand spanking new linux system installed, and you are probably wondering, just how to I move around in the filesystem, what is a filesystem, and how do I edit files? We hope that this section will make you more at home when dealing with linux from the command line.

The first thing you will want to know is that unlike other operating systems, there are no "drives" exactly. Instead everything is a "file" or "directory". For instance, you noticed in the installation that it asked you where you wanted your root filesystem and where you wanted to mount it. Of course, you must have a "root" partition that is mounted on /

So what does this mean exactly? Well, you now have a "drive" that is mounted on your system as the root of your filesystem. So unlike Windows, if you want to get to the first partition on your first hard disk, instead of typing C: <ENTER> your would type cd / <ENTER> and that would put you in the same place physically on your hard disk.

Let's take a look at the common structure of a linux "C: Drive" shall we? If we issue the command

cd /
and then we issue the command
ls -al
this is what it should look like (or close anyway)
[newbie@virago /]$ ls -al
total 50
drwxr-xr-x  16 root     root         1024 Jun  6 22:18 .
drwxr-xr-x  16 root     root         1024 Jun  6 22:18 ..
drwxr-xr-x   2 root     root         2048 Aug  1 02:20 bin
drwxr-xr-x   2 root     root         1024 Jun 21 13:05 boot
drwxr-xr-x   3 root     root        20480 Oct 16 17:14 dev
drwxr-xr-x  20 root     root         2048 Nov 11 01:08 etc
drwxr-xr-x  21 root     root         1024 Aug 21 17:41 home
drwxr-xr-x   4 root     root         2048 Jun 16 08:55 lib
drwxr-xr-x   2 root     root        12288 Jun  5 12:58 lost+found
drwxr-xr-x   4 root     root         1024 Jun  5 13:17 mnt
dr-xr-xr-x   5 root     root            0 Oct 16 13:14 proc
drwx------  12 root     root         1024 Nov  8 02:03 root
drwxr-xr-x   3 root     root         2048 Jun 21 12:57 sbin
drwxrwxrwt   2 root     root         1024 Nov 11 21:01 tmp
drwxr-xr-x  20 root     root         1024 Aug 15 19:01 usr
drwxr-xr-x  13 root     root         1024 Aug 15 19:04 var
[newbie@virago /]$ 
So just what is all this stuff? It is your newly installed linux filesystem. Let's break each directory down and see just what is contained in each one.
  • bin - Executables go here. You know, programs that keep your system running
  • boot - This is where your kernel lives. The kernel is the file that makes your computer run linux
  • dev - This directory is where all your devices live. More on this later.
  • etc - This directory houses most of your configuration files for the way your linux system behaves. For instance, your IP address, what programs to run on startup, and your X config file.
  • home - This is where your users store their personal data
  • lib - These are where the system libraries live. Libraries can be called used by many programs to do commonly used tasks
  • mnt - This is where you can mount other filesystems/devices. Like for instance your CDROM or floppy drive
  • proc - This directory holds a bunch of files that describe your system and hardware.
  • root - This is root's home directory.
  • sbin - More executables
  • tmp - Just like the name implies, this is temporary storage space.
  • usr - Usually, this houses other "user installed" applications, libraries and source code.
  • var - Where most of the logs and spools are held.

Ok, so what do I mean by everything is a file or directory? Well..literally, everything is a file. Even the devices in your computer are recognized as files in a linux system. So what am I gettin at? Well, you should probably learn what files are associated with the hardware you might have in your machine. And here is a handy table of the most common pieces of hardware in your system.

Windows/DOS namelinux device file
PS/2 Mouse /dev/psaux
Serial Mouse on COM1/dev/ttyS0
Soundblaster/dev/dsp
Modem on COM2/dev/ttyS1
IDE CDROMIf your CDROM is Primary Master: /dev/hda
If it is Primary Slave: /dev/hdb
And if it is Secondary Master: /dev/hdc
And finally, if it is Secondary Slave: /dev/hdd



Copyright © 2000 Roanoke Valley GNU/Linux Users Group
Get Software
CueCat Driver 0.1.5
Linux kernel driver for the :Cue:Cat barcode reader.
Dieresis Colloquius 1.0.0 B PR2
Perl-based bulletin board system.
qVIX 1.0beta1
High quality, full-framerate, low bandwidth, realtime video conferencing.
vtgrab 0.1.2
A utility for monitoring another machine's console.
HappyDoc 0.7.1
A Python source documentation extraction tool.
pitchtune 0.0.2
An instrument tuner.
Partition Image 0.3.2
A harddisk cloning utility.
AutoZen 1.2.1
A tool to alter your state of consciousness.
vHost 1.01
A small Virtual Host administration utility for Apache.
TeXmacs 0.3.0-3
W.Y.S.I.W.Y.G. technical text editor