mount doesn't mount on boot-up

David G. Miller dave at davenjudy.org
Wed Nov 1 15:10:30 UTC 2006


Claude Jones <claude_jones at levitjames.com> wrote:

> >
> > As a guess, the partition label is screwed up.  The OS uses this
> > statement in fstab to attempt the mount at boot:
> >
> > LABEL=/home/cj/archive  /home/cj/archive  ext3    defaults     1 2
> >
>   
>
> This is supposedly what should work, if I'm reading all the man pages 
> correctly - that's the entry that had been created automatically by whatever 
> process does that
>
>   
>> >
>> > and, somehow, the label gets mapped to /dev/sdb1.  But this is what works:
>> >
>> > mount -t ext2 -w /dev/sdc1 /home/cj/archive
>> >
>>     
>
> Here's where the mystery begins - that command *does* work, but, it's 
> incorrect! The file system is ext3 not ext2 - I know they're related, but, I 
> just experimented, and I can mount manually using that command with either 
> ext2 OR ext3???
>   
You can mount an ext3 file system as either ext2 or ext3.  If mounted as 
ext2, you just don't get journaling.  So, just change your mount command 
to "-t ext3" and you *should* get journaling.
>> >
>> > Definitely not the same.  A quick fix is to just change fstab to use the
>> > device definition that works:
>> >
>> > /dev/sdc1	/home/cj/archive  ext3    defaults     1 2
>> >
>>     
>
> I've tried this, but, it still doesn't work - 
>   
Hmmmm.  Doesn't make sense.  The system uses the information in fstab to 
construct a mount instruction that should be identical to what you're 
providing on the command line.
>> >
>> > I'm guessing there is a user program such as diskdruid to change the
>> > partition label.  Unfortunately, I don't know what it is.  Perhaps
>> > someone else on the list can enlighten both of us.
>> >
>>     
>
> tune2fs is supposed to be able to do this, but I couldn't grasp the 
> explanation of how it works well enough to attempt it when I tried in 
> somewhat of a hurry a couple of weeks ago.
>   
Thanks.  I always wondered how to set a partition label.  The pertinent 
part of the man page for tune2fs says:

       -L volume-label
              Set  the volume label of the file system.  Ext2 file 
system labels
              can be at most 16 characters long;  if  volume-label  is  
longer
              than  16  characters, tune2fs will truncate it and print a 
warn-
              ing.  The volume label can be used  by  mount(8),  
fsck(8),  and
              /etc/fstab(5)  (and  possibly  others)  by specifying 
LABEL=vol-
              ume_label instead of a block special device name like 
/dev/hda5.

You should (there's that magic word again) be able to do something like:

tune2fs -L /home/cj/archive /dev/sdc1

 From what you said earlier, the system seems to think that 
/home/cj/archive is the volume label for /dev/sdb1.  I'm guessing the 
above will fail with an error saying this.  I didn't see anything about 
how to remove an existing label although you could probably just use 
tune2fs to apply a different label to /dev/sdb1. 

One other thing.  /home/cj/archive is exactly 16 characters long which 
is the limit for labels.  I'm always suspicious when something fails 
right at a boundary like this.  You may want to try a shorter label like 
just "archive" since the label is just a name (the system defaults to 
using the mount point as the name).  Make sure that the fstab entry and 
the label match.

Cheers,
Dave

-- 
Politics, n. Strife of interests masquerading as a contest of principles.
-- Ambrose Bierce




More information about the users mailing list