Skip to main content

Directory structure in Red Hat




1. / – Root

  • Every single file and directory starts from the root directory.
  • Only root user has write privilege under this directory.
  • Please note that /root is root user’s home directory, which is not same as /.

2. /bin – User Binaries

  • Contains binary executables.
  • Common linux commands you need to use in single-user modes are located under this directory.
  • Commands used by all the users of the system are located here.
  • For example: ps, ls, ping, grep, cp.

3. /sbin – System Binaries

  • Just like /bin, /sbin also contains binary executables.
  • But, the linux commands located under this directory are used typically by system aministrator, for system maintenance purpose.
  • For example: iptables, reboot, fdisk, ifconfig, swapon

4. /etc – Configuration Files

  • Contains configuration files required by all programs.
  • This also contains startup and shutdown shell scripts used to start/stop individual programs.
  • For example: /etc/resolv.conf, /etc/logrotate.conf

5. /dev – Device Files

  • Contains device files.
  • These include terminal devices, usb, or any device attached to the system.
  • For example: /dev/tty1, /dev/usbmon0

6. /proc – Process Information

  • Contains information about system process.
  • This is a pseudo filesystem contains information about running process. For example: /proc/{pid} directory contains information about the process with that particular pid.
  • This is a virtual filesystem with text information about system resources. For example: /proc/uptime

7. /var – Variable Files

  • var stands for variable files.
  • Content of the files that are expected to grow can be found under this directory.
  • This includes — system log files (/var/log); packages and database files (/var/lib); emails (/var/mail); print queues (/var/spool); lock files (/var/lock); temp files needed across reboots (/var/tmp);

8. /tmp – Temporary Files

  • Directory that contains temporary files created by system and users.
  • Files under this directory are deleted when system is rebooted.

9. /usr – User Programs

  • Contains binaries, libraries, documentation, and source-code for second level programs.
  • /usr/bin contains binary files for user programs. If you can’t find a user binary under /bin, look under /usr/bin. For example: at, awk, cc, less, scp
  • /usr/sbin contains binary files for system administrators. If you can’t find a system binary under /sbin, look under /usr/sbin. For example: atd, cron, sshd, useradd, userdel
  • /usr/lib contains libraries for /usr/bin and /usr/sbin
  • /usr/local contains users programs that you install from source. For example, when you install apache from source, it goes under /usr/local/apache2

10. /home – Home Directories

  • Home directories for all users to store their personal files.
  • For example: /home/john, /home/nikita

11. /boot – Boot Loader Files

  • Contains boot loader related files.
  • Kernel initrd, vmlinux, grub files are located under /boot
  • For example: initrd.img-2.6.32-24-generic, vmlinuz-2.6.32-24-generic

12. /lib – System Libraries

  • Contains library files that supports the binaries located under /bin and /sbin
  • Library filenames are either ld* or lib*.so.*
  • For example: ld-2.11.1.so, libncurses.so.5.7

13. /opt – Optional add-on Applications

  • opt stands for optional.
  • Contains add-on applications from individual vendors.
  • add-on applications should be installed under either /opt/ or /opt/ sub-directory.

14. /mnt – Mount Directory

  • Temporary mount directory where sysadmins can mount filesystems.

15. /media – Removable Media Devices

  • Temporary mount directory for removable devices.
  • For examples, /media/cdrom for CD-ROM; /media/floppy for floppy drives; /media/cdrecorder for CD writer

16. /srv – Service Data

  • srv stands for service.
  • Contains server specific services related data.
  • For example, /srv/cvs contains CVS related data.

Comments

Popular posts from this blog

Red Hat Enterprise version list

Red Hat Enterprise Linux 6 Release/Update General Availability Date redhat-release Errata Date* Kernel Version RHEL 6 Update 4 TBA TBA TBA RHEL 6 Update 3 2012-06-20 2012-06-19 RHSA-2012-0862 2.6.32-279 RHEL 6 Update 2 2011-12-06 2011-12-06 RHEA-2011:1743 2.6.32-220 RHEL 6 Update 1 2011-05-19 2011-05-19 RHEA-2011:0540 2.6.32-131.0.15 RHEL 6 GA 2010-11-09 - 2.6.32-71 Codename: Santiago (based on a mix of Fedora 12, Fedora 13, and several modifications) Red Hat Enterprise Linux 5 Release/Update General Availability Date redhat-release Errata Date* Kernel Version RHEL 5 Update 9 TBA TBA TBA RHEL 5 Update 8 02/20/2012 02/20/2012 RHEA-2012:0315 2.6.18-308 RHEL 5 Update 7 07/21/2011 07/20/2011 RHEA-2011:0977 2.6.18-274 RHEL 5 Update 6 01/13/2011 01/12/2011 RHEA-2011:0020 2.6.18-238 RHEL 5 Update 5 03/30/2010 03/30/2010 RHEA-2010:0207 2.6.18-194 RHEL 5 Update 4 09/02/2009 09/02/2009 ...

Installation Red Hat Enterprise & make standered partition

First of all select DVD and reboot your computer. After Booting from DVD you will get below screen. Select  Install or Upgrade an Existing System and press Enter. If you get the following screen then let Anaconda take another step. Select your preferred  Language and Select  Keyboard Layout . In Following Screen you will be able to see 4 Installation Methods, Let me explain Methods here:- Local CD/DVD – It is obvious that If you use CD/DVD media then Choose this option. Hard Drive – Select this if you have dumped your source into any other Linux partition. NFS Directory – You can select this option if you have configured NFS server. URL – Select this if you want to install using FTP or HTTP Source link. So for step by step installation of RHEL 6 I had  Local CD/DVD Installation Method. If you are not sure about your media then select  OK to verify else select  Skip . If your media is fine till now it will take ...

MBR, Primary, Extended & Logical partition in Red Hat

MBR, Primary, Extended & Logical partition in Red Hat Hard disk and storage device are normally divided up into smaller chunks called partitions. So that different parts of it can be formatted with different file system or used for different purposes. For example, one partition could contain user home directories while another could contain system data and logs; by placing the data in two separate file system on two separate partitions, even if a user fills up the home directories partition with data, the system data partition may have space. Most Red Hat Enterprise Linux system on the x86 and x86-64 processor architectures use the MBR partitioning format for their hard disk. This is the same format that is used by most Microsoft Windows systems, and dates back to the IBM PC.                              Storage device: /dev/sda In this format, the first sector of the disk is reser...