LinuxQuestions.org
Help answer threads with 0 replies.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
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!

Notices


Reply
  Search this Thread
Old 08-05-2008, 11:42 PM   #1
emtstephen
LQ Newbie
 
Registered: Aug 2008
Posts: 2

Rep: Reputation: 0
Question drive IDs change from boot to boot


I have an eSATA drive where i store generic stuff like songs, docs, etc.
I put it in fstab to automatically mount it. sometimes it works and sometimes it doesn't depending if the drive comes up as the sdx that i have specified.



fdisk -l

Disk /dev/sdb: 41.1 GB, 41174138880 bytes
16 heads, 63 sectors/track, 79780 cylinders
Units = cylinders of 1008 * 512 = 516096 bytes
Disk identifier: 0x863fbc90

Device Boot Start End Blocks Id System
/dev/sdb1 * 1 79752 40194976+ 7 HPFS/NTFS

Disk /dev/sdc: 20.0 GB, 20020396032 bytes
255 heads, 63 sectors/track, 2434 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0x2b562b55

Device Boot Start End Blocks Id System
/dev/sdc1 * 1 2327 18691596 83 Linux
/dev/sdc2 2328 2434 859477+ f W95 Ext'd (LBA)
/dev/sdc5 2328 2434 859446 82 Linux swap / Solaris

Disk /dev/sdd: 250.0 GB, 250059350016 bytes
255 heads, 63 sectors/track, 30401 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0x0007084d

Device Boot Start End Blocks Id System
/dev/sdd1 * 1 29164 234259798+ 83 Linux
/dev/sdd2 29165 30401 9936202+ 5 Extended
/dev/sdd5 29165 30401 9936171 82 Linux swap / Solaris

Disk /dev/sde: 500.1 GB, 500107862016 bytes
255 heads, 63 sectors/track, 60801 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0xbce589e4

Device Boot Start End Blocks Id System
/dev/sde1 * 1 60801 488384001 7 HPFS/NTFS


here sde is the drive i am trying to automatically mount.



cat /etc/fstab
# /etc/fstab: static file system information.
#
# <file system> <mount point> <type> <options> <dump> <pass>
proc /proc proc defaults 0 0
# /dev/sda1
UUID=b3dd751c-15c3-48f6-a2e3-623949017965 / ext3 relatime,errors=remount-ro 0 1
# /dev/sda5
UUID=8f16156b-022e-47ac-9cfd-ce1a4d12e4cf none swap sw 0 0
/dev/scd0 /media/cdrom0 udf,iso9660 user,noauto,exec,utf8 0 0
/dev/fd0 /media/floppy0 auto rw,user,noauto,exec,utf8 0 0
/dev/sdd1 /media/Steves_Portable ntfs-3g defaults 0 0



The last entry is the one I am trying to automount. It comes up as sdb, sdc, sdd, or sde but I don't know why it changes.
When it matches it works like a charm.

Anyone have any ideas.

Ubuntu 8.0.4.1
 
Old 08-05-2008, 11:51 PM   #2
farslayer
LQ Guru
 
Registered: Oct 2005
Location: Willoughby, Ohio
Distribution: linuxdebian
Posts: 7,232
Blog Entries: 5

Rep: Reputation: 190Reputation: 190
Create a udev rule for it so it always comes up the same..

http://www.linuxquestions.org/questi...les+hard+drive
 
Old 08-06-2008, 12:36 PM   #3
emtstephen
LQ Newbie
 
Registered: Aug 2008
Posts: 2

Original Poster
Rep: Reputation: 0
Thumbs up

Thanks farslayer, That link did the trick. I actually used a reply to that post from elliott678 where he posted a link to http://wiki.archlinux.org/index.php/..._device_naming .
I ended up using the by-uuid in the etc/fstab.

It worked like a charm.

Thanks for you help
 
Old 08-06-2008, 10:49 PM   #4
farslayer
LQ Guru
 
Registered: Oct 2005
Location: Willoughby, Ohio
Distribution: linuxdebian
Posts: 7,232
Blog Entries: 5

Rep: Reputation: 190Reputation: 190
Glad that worked for you. That's why I just linked you to the other thread since it had more than one option available for you to look at.
 
  


Reply

Tags
fdisk, fstab, ubuntu


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
grub boot option to change init boot level danboland Linux - General 3 10-10-2007 01:39 PM
Have to change boot order in BIOS to boot ubuntu/winxp Minn3h Linux - Software 7 04-01-2006 06:17 PM
DSL Kernel Wont detect Flash drive on boot, cant boot =( Javahulk Linux - General 1 03-24-2005 03:59 PM
Lilo 2 drives - want to change boot drive Neze Slackware 11 12-06-2004 04:53 PM
howto boot Suse 9.1 from external usb drive through bios-accessable boot partition McHenner Linux - Hardware 2 09-30-2004 08:27 AM


All times are GMT -5. The time now is 03:09 PM.

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