fstab mount inconsistent

Bug #534532 reported by Barry Rutter
10
This bug affects 2 people
Affects Status Importance Assigned to Milestone
usbmount (Ubuntu)
New
Undecided
Unassigned

Bug Description

Binary package hint: usbmount

Package 0.0.19.1
I have a /dev/sdc1 definition for one usb device and a UUID= definition for another usb device (which resolves to /dev/sdd1) in the fstab.

After a system move I plugged the UUID= device into a different port and also changed its label. The system allocated the UUID device to /dev/sdc1 and moved the original /dev/sdc1 to /dev/sdd1.

Ok the fix was to make both reference UUID= in fstab. BUT, in looking at the package code I noticed that the check order seems wrong.
    if egrep -q "^[[:blank:]]*$DEVNAME" /etc/fstab; then
 log info "executing command: mount $DEVNAME"
 mount $DEVNAME

    elif grep -q $UUID /etc/fstab; then
        log info "executing command: mount -U $UUID"
 mount -U $UUID

If the 1st two checks had been swapped the UUID= device would not have been mounted by the reference to /dev/sdc1 in the 1st part of the IF statement.

Please swap the order to give priority to reference to UUID.

tags: added: kernel-series-unknown
tags: removed: kernel-series-unknown
Revision history for this message
J.L. (jl2001) wrote :

it's fixed now

Revision history for this message
J.L. (jl2001) wrote :

oh, i'm sorry, I was wrong

Revision history for this message
Rogério Theodoro de Brito (rbrito) wrote :

Can we close this now? Version 0.0.19.1 is ancient.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.