LinuxQuestions.org
Have you listened to LQ Radio?
Go Back   LinuxQuestions.org > Forums > Linux > Linux - Distributions > Fedora
User Name
Password
Fedora This forum is for the discussion of the Fedora Project.

Notices

Reply
 
Thread Tools
Old 07-02-2008, 06:20 PM   #1
sandaili
LQ Newbie
 
Registered: Jun 2007
Posts: 25
Thanked: 0
Can I assign a UUID to a disk added without deleting data? How?


[Log in to get rid of this advertisement]
I have a disk that is not automounted by Fedora 9. I would like it to be, and I'd like preferably for it to have it's own UUID. But, just by adding a unique UUID to the fstab, obviously won't work.

But I am afraid I can't find any information about how to add a UUID to an existing disk that is full of data. Anywhere. I've searched and searched....

L

Nevermind, I'm a moron. I assumed there wasn't a UUID because I was getting an error. However, I needed the right command, and I was using the wrong one. This is the command to find a UUID for a device in Fedora: udevinfo -q env -n /dev/sdb1

Hope that helps someone.

Last edited by sandaili; 07-02-2008 at 06:27 PM.. Reason: found solution
sandaili is offline     Reply With Quote
Old 07-02-2008, 09:00 PM   #2
GlennsPref
Senior Member
 
Registered: Apr 2004
Location: Brisbane, Australia
Distribution: Mandriva x86_64 KDE4
Posts: 2,049
Blog Entries: 10
Thanked: 59
Thank you.
I had a bit of trouble with 2 of my fat32 partitions having the same uuid number,

This might help me sort it out.

Regards, Glenn
GlennsPref is offline     Reply With Quote
Old 07-02-2008, 09:33 PM   #3
Mr. C.
Senior Member
 
Registered: Jun 2008
Posts: 2,511
Thanked: 4
# uuidgen
# tune2fs /dev/hdaX -U numbergeneratedbyuuidgen
# vol_id /dev/hdaX
Mr. C. is offline     Reply With Quote
Old 07-02-2008, 09:57 PM   #4
syg00
Guru
 
Registered: Aug 2003
Location: Australia
Distribution: Lots ...
Posts: 6,908
Thanked: 165
Not all filesystems support UUID - notably VFAT (and NTFS) last I looked. UUIDs can be generated for them, but labels are probably a better option for them.
syg00 is offline     Reply With Quote
Old 07-02-2008, 10:22 PM   #5
GlennsPref
Senior Member
 
Registered: Apr 2004
Location: Brisbane, Australia
Distribution: Mandriva x86_64 KDE4
Posts: 2,049
Blog Entries: 10
Thanked: 59
Hey, Thanks for the info,

Mr.C., Can you give me a short description of what you posted, please?


syg00, fstab has these entries for...sdb8 and sdb9 both had UUID=4807-901A and while it was only one partition would show up, and it was difficult to navigate, let alone read and write files. So I edited it back to the old way... Possibly not supported as you mention.

excerpt from fstab,

# Entry for /dev/sda1 :
UUID=4C54BBD554BBBFCE /mnt/win_c ntfs-3g defaults 0 0
# Entry for /dev/sdb8 :UUID=4807-901A
/dev/sdb8 /mnt/win_c2 vfat defaults,umask=0,quiet 0 0
# Entry for /dev/sda10 :UUID=4807-8FD4
/dev/sda10 /mnt/win_d vfat defaults,umask=0,quiet 0 0
# Entry for /dev/sdb9 /mnt/win_d2:
/dev/sdb9 /mnt/win_d2 vfat defaults,umask=0,quiet 0 0

(wip)
cheers,
Regards, Glenn
GlennsPref is offline     Reply With Quote
Old 07-02-2008, 10:39 PM   #6
Mr. C.
Senior Member
 
Registered: Jun 2008
Posts: 2,511
Thanked: 4
Quote:
Originally Posted by syg00 View Post
Not all filesystems support UUID - notably VFAT (and NTFS) last I looked. UUIDs can be generated for them, but labels are probably a better option for them.
Yes, you are correct.

Quote:
Originally Posted by GlennsPref View Post
Mr.C., Can you give me a short description of what you posted, please?
[/quote]


1) generate a UUID for the device
2) push that UUID onto the meta-data for the ext[23] file system
3) verify the value placed there

$ man uuidgen tune2fs vol_id

for the complete details.
Mr. C. is offline     Reply With Quote

Reply

Bookmarks


Thread Tools

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
/dev/disk/by-uuid on install disk? randomsel Slackware 6 06-29-2008 09:54 AM
initial ram disk image support for UUID query aus9 Linux - Kernel 9 02-03-2008 11:31 PM
How to assign disk quota(disk space limited) to user and group. hocheetiong Linux - Newbie 1 08-24-2007 05:20 AM
added hdb - want to access old data joel b Fedora 1 02-21-2005 03:02 AM
assign new data partition to specific users wycolorado Linux - Newbie 2 01-01-2005 10:53 PM


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

Main Menu
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
RSS2  LQ Podcast
RSS2  LQ Radio
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: @linuxquestions
Open Source Consulting | Domain Registration