1. Home
  2. Computing & Technology
  3. Linux

Linux Newbie Administrator Guide

From Authors, for About.com

5.2 Accessing my drives

5.2.1 Where are my drives?
5.2.2 How can I access my CDROM?
5.2.3 Mounting my other devices
5.2.4 How to mount a remote MS Windows filesystem through Samba?
5.2.5 Any quick way to access a file on a DOS/Windows floppy?
5.2.6 Mounting works when I am root. Can a normal user mount?
5.2.7 Mounting command is too long, how can I simplify it with an alias?
5.2.8 Can I mount automatically?
5.2.9 How do I get my parallel-port (external) Zip drive recognized?
5.2.10 Can I set 32-bit hard drive I/O?
5.2.11 I reached the limit on the number of opened files (error message)
5.2.12 I attached a new hard drive. What do I do to start using it?
5.2.13 Swap space

5.2.1 Where are my drives?

Linux shows all the directories in one directory tree, irrespectively of what drives/hardware they are found on. Generally, this is a much better solution than the traditional DOS/Windows model--it completely abstracts the file system from the underlying hardware. You will appreciate this if you ever have to re-arrange or expand your hardware or add network resources. But for the users who are accustomed to the DOS way of dealing with drives, it adds some extra complexity.

To be brief, don't search for drive letters. There are none under Linux; the content of your disks appears as subdirectories on your single Linux filesystem (directory tree). On default, the content of removable media does not appear automatically in these subdirectories--you have to "mount" your drives. See the next answers for details. You should also unmount a drive before ejecting the media.

You can access (read and write) a variety of drives and file systems from under Linux. This includes native Linux partitions, DOS and MS Windows partitions (on hard drives or floppies), ZIP and Jazz drives, and CDROM disks. Many less common file system types are also supported. This means that you can download your Linux software using Netscape for Windows, save the downloaded file on your MS Windows hard drive partition, and then boot Linux and copy the downloaded software from the Windows partition on your harddrive to the Linux partition, and finally install the software under Linux.

5.2.2 How can I access my CDROM?

Mount it. The mounting adds all the directories and files from your CD to your Linux directory tree so you can easily access them without the drive letter.

As root, you can mount the CDROM with a command like this:

mount -t auto /dev/cdrom /mnt/cdrom

If this works, the contents of your CD appears in the directory /mnt/cdrom

Chances are this command will not work for you right away--you may have to customize it. Here is how it works.

The command tells the operating system to mount a filesystem autodetecting the filesystem type ("-t auto"). The device is /dev/cdrom. The mountpoint (the directory where to which "mounting" takes place) is /mnt/cdrom. This directory must exist and be empty. If it does not exist, create it with:

mkdir /mnt/cdrom

If the mounting command fails, maybe the device /dev/cdrom does not exist on your system? Try

ls -l /dev/cdrom

/dev/cdrom is just a convenient symbolic link to a real "device" that is mapped onto your hardware. On an IDE system, chances are your real cdrom is on /dev/hdb. Therefore, try /dev/hdb instead of /dev/cdrom in the mount command above:

mount -t auto /dev/hdb /mnt/cdrom

If this fails, you can try /dev/hdc or /dev/hdd, if your CD is an IDE CDROM on the second IDE interface. If none of them is your CDROM, maybe you

* License

* Linux Newbie Administrator Guide Index

Explore Linux

More from About.com

  1. Home
  2. Computing & Technology
  3. Linux
  4. Linux Documentation
  5. Newbie Administrator Guide
  6. Linux Newbie Administrator Guide - 5.2 Accessing my drives

©2008 About.com, a part of The New York Times Company.

All rights reserved.