Welcome to the most active Linux Forum on the web.
Go Back > Forums > Linux Forums > Linux - Newbie
User Name
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!


  Search this Thread
Old 04-24-2006, 10:55 PM   #1
LQ Newbie
Registered: Apr 2006
Posts: 1

Rep: Reputation: 0
Need help Reading/Writing to Ext Hard Drive

Hello to everyone. This is my first time posting to a linux forum as I am a newb. Thanks in advance for any assistance.

All I am trying to do is get to where I can access my external hard drive and read and write files to and from it.

Here's some background info:
The external HD is a firelite usb drive
I plug the drive into usb (after booting and having logged into the gnome gui as normal user)
My distro is debian (I'm not sure how to determine the kernal release number, but its an i386 stable)

I click on 'computer icon' and am looking for it to show up there as an icon or something...kinda of the same way I would look for a new drive in my computer in a windows OS.

I honestly am at a loss as to how to find it, mount it, or do whatever I need to do just to see the drive, and be able to read and write from it.

Thanks again for your help.
Old 04-24-2006, 11:10 PM   #2
LQ Guru
Registered: Oct 2005
Location: Northeast Ohio
Distribution: linuxdebian
Posts: 7,243
Blog Entries: 5

Rep: Reputation: 190Reputation: 190
ok uname -a will tell you your kernel version

Boot the system but do not plug in the USB drive yet.. su to root

su -
password *****

mkdir /media/usbdrive - create a directory somewhere to mount the drive - Debian typically mounts devices in the /media directory but you can choose another empty directory if you like..

tail -f /var/log/messages The last 10 lines of the log should appear on the screen

Plug in the USB Drive and watch the Screen for the designation of the drive. it will come up as a sd device so if it is the only USB or SATA drive in the system it will come up as sda you should be able to see this designation in the messages that scroll onto the screen after pluggin in the drive.

Hit CTRL+C to exit the log listing

Is the drive formatted as Fat32 ? I hope so as that will make things easier.. if the drive is fomratted NTFS things get a bit more complex..

mount -t vfat /dev/sda1 /media/usbdrive Mount the drive to the directory you created

you will then be able to acces the drive through the /media/usbdrive directory..

if that works then you can add an entry to your fstab file to simplify mounting and allow any user to mount and have read/write access to the drive.

default@debian:~$ more /etc/fstab
# /etc/fstab: static file system information.
# <file system> <mount point>   <type>  <options>       <dump>  <pass>
proc            /proc           proc    defaults        0       0
/dev/hda1       /               ext3    defaults,errors=remount-ro 0       1
/dev/hda3       /home           ext3    defaults        0       2
/dev/hda2       /usr            ext3    defaults        0       2
/dev/hda4       none            swap    sw              0       0
/dev/hdd        /media/cdrom0   iso9660 ro,user,noauto  0       0
/dev/hdc        /media/cdrom1   iso9660 ro,user,noauto  0       0
/dev/fd0        /media/floppy0  auto    rw,user,noauto  0       0
/dev/sda1       /media/usbdrive auto    rw,users,noauto 0       0
It's always a good idea to backup your fstab before editing it .. just in case..
cp /etc/fstab /etc/fstab.bak
Old 04-24-2006, 11:11 PM   #3
Senior Member
Registered: Feb 2006
Location: Seattle, WA: USA
Distribution: Slackware 11.0
Posts: 1,191

Rep: Reputation: 45
lol, somone must of replied while I was typing all of this out. Oh well, choose your directions of choice

Welcome to linux! Mounting your drive kind of depends on the partition it has on it (mounting =linux speak for adding a storage device to your file system) I'm going to assume that it is fat32 for the sake of these directions.

1) Create a folder to link your drive to. The standard is to put it in the /mnt directory: IE '/mnt/usbdrive'. You will mount your drive to this folder and anything you put in it will actually be saved on your usb drive. You will also need to give the folder r/w access to the user who will be using it. As Root:
#mkdir /mnt/usbdrive
#chown <username> /mnt/usbdrive
2) Find out the linux name to your hardrive:
#fdisk -l
3) Update the /etc/fstab by using a text editor and add a line to mount your drive at boot:
/dev/sda1   /mnt/usbdrive   vfat   users,defaults,umask=000   0   0
This assumes /dev/sda1 is the correct drive name (from fdisk -l) This also assumes that your drive is fat32. note: umask=000 is required to write to any fat32 drive as a non-root user. It will be a bit different if you are mounting a different partition type.

Your drive should now be mounted to the /mnt/usbdrive folder at boot time. You don't have to reboot after you update your fstab to get access right away. Just type 'mount /mnt/usbdrive' when you are done.

Hope this was of some help


Last edited by drkstr; 04-24-2006 at 11:48 PM.


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Problems with reading & writing to USB Flash Drive LordSurvivoR Linux - Hardware 8 01-31-2006 02:45 PM
MDK 9.2 cannot mount Ext USB hard drive dr_skids Linux - Hardware 0 11-06-2005 11:56 AM
Install Suse 9.2 on Ext. Hard Drive sall Linux - Software 1 09-28-2005 09:31 PM
Cannot Mount Ext. USB Hard Drive sall Linux - Hardware 32 07-15-2005 11:19 AM
Mounting Ext. Hard Drive through USB 2+PCMCIA CondorPasa Linux - Hardware 1 03-11-2004 06:49 AM > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 05:11 AM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration