LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
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 06-10-2012, 07:06 AM   #1
anon091
Senior Member
 
Registered: Jun 2009
Posts: 1,795

Rep: Reputation: 49
fstab only has labels, not /dev/stuff needed for e2fsck


I need to run an e2fsck on one of my arrays, but looking in fstab it only has labels which I don't think work with e2fsck. How do I find out what the label really is so I can put that in the e2fsck command to check that?
 
Old 06-10-2012, 07:11 AM   #2
syg00
LQ Veteran
 
Registered: Aug 2003
Location: Australia
Distribution: Lots ...
Posts: 21,012

Rep: Reputation: 4102Reputation: 4102Reputation: 4102Reputation: 4102Reputation: 4102Reputation: 4102Reputation: 4102Reputation: 4102Reputation: 4102Reputation: 4102Reputation: 4102
Readlink /dev/disk/by-label/<whatever>
 
Old 06-10-2012, 07:16 AM   #3
anon091
Senior Member
 
Registered: Jun 2009
Posts: 1,795

Original Poster
Rep: Reputation: 49
When I do Readlink /data it says command not found
 
Old 06-10-2012, 07:20 AM   #4
syg00
LQ Veteran
 
Registered: Aug 2003
Location: Australia
Distribution: Lots ...
Posts: 21,012

Rep: Reputation: 4102Reputation: 4102Reputation: 4102Reputation: 4102Reputation: 4102Reputation: 4102Reputation: 4102Reputation: 4102Reputation: 4102Reputation: 4102Reputation: 4102
Huh - readlink is in coreutils ...

Try "ls -al /dev/disk/by-label".
 
Old 06-10-2012, 07:22 AM   #5
anon091
Senior Member
 
Registered: Jun 2009
Posts: 1,795

Original Poster
Rep: Reputation: 49
I'm booted into repair filesystem mode, and all I know is the label of it, not the /dev/whatever I need to e2fsck it
 
Old 06-10-2012, 07:26 AM   #6
syg00
LQ Veteran
 
Registered: Aug 2003
Location: Australia
Distribution: Lots ...
Posts: 21,012

Rep: Reputation: 4102Reputation: 4102Reputation: 4102Reputation: 4102Reputation: 4102Reputation: 4102Reputation: 4102Reputation: 4102Reputation: 4102Reputation: 4102Reputation: 4102
Don't try to interpret what I said, do what I said.
 
Old 06-10-2012, 07:29 AM   #7
anon091
Senior Member
 
Registered: Jun 2009
Posts: 1,795

Original Poster
Rep: Reputation: 49
Are you saying literally dev disk then whatever my label is?
 
Old 06-10-2012, 07:34 AM   #8
TobiSGD
Moderator
 
Registered: Dec 2009
Location: Germany
Distribution: Whatever fits the task best
Posts: 17,148
Blog Entries: 2

Rep: Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886
No, he is saying that you literally type in the command
Code:
ls -al /dev/disk/by-label
 
Old 06-10-2012, 07:50 AM   #9
anon091
Senior Member
 
Registered: Jun 2009
Posts: 1,795

Original Poster
Rep: Reputation: 49
I get ls: /dev/disk/by-label no such file or directory
 
Old 06-10-2012, 11:28 AM   #10
michaelk
Moderator
 
Registered: Aug 2002
Posts: 24,995

Rep: Reputation: 5682Reputation: 5682Reputation: 5682Reputation: 5682Reputation: 5682Reputation: 5682Reputation: 5682Reputation: 5682Reputation: 5682Reputation: 5682Reputation: 5682
Post your fstab. Are you sure you are using labels vs UUIDs? Are you using LVM?
Are there any other directories in /dev/disk?

Maybe the blkid command will provide the necessary information.

Last edited by michaelk; 06-10-2012 at 11:29 AM.
 
1 members found this post helpful.
Old 06-11-2012, 09:16 AM   #11
anon091
Senior Member
 
Registered: Jun 2009
Posts: 1,795

Original Poster
Rep: Reputation: 49
This is the volume i'm trying to e2fsck

LABEL=/data /data ext3 defaults 1 2

only thing under /dev/disk is by-path, which then has like 20 things under it.

looks like blkid does give me the /dev/whatever of each label!
 
  


Reply


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
/etc/fstab labels do not come out consistently VirtualEJ Linux - Software 3 10-26-2009 01:18 PM
If I move hd labels, what changes? fstab, grub.conf... soloist Linux - General 6 03-16-2004 11:31 AM
appropiate fstab entries -- How to use labels jimieee Linux - Hardware 2 10-31-2003 04:29 AM
LABELs in /etc/fstab and grub.conf juggler Red Hat 1 09-28-2003 05:10 PM
Installing new harddisks...Questions about filesystems, labels and fstab needamiracle Linux - Hardware 5 09-23-2002 11:35 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 07:13 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
Open Source Consulting | Domain Registration