Problem Mounting USB Hard Drive on Boot

classic Classic list List threaded Threaded
16 messages Options
Reply | Threaded
Open this post in threaded view
|

Problem Mounting USB Hard Drive on Boot

Charles Philip Chan-3
Hello all,

I am having problems mounting my USB external hard drive at boot time
for the past few snapshots. The drive have an entry in my fstab and I
have no problem mounting it for years. A manual mount with the "mount"
command (which, IIRC, uses systemd-mount now) doesn't work either and
produce no errors in the systemd log journal. However, I have no
problems mounting it with "udisksctl mount -b <device>". What could be
the problem?

Thanks.

Charles

--
There are no threads in a.b.p.erotica,  so there's no  gain in using a
threaded news reader.
(Unknown source)

signature.asc (233 bytes) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: Problem Mounting USB Hard Drive on Boot

Carlos E. R.-2
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1



On Wednesday, 2017-11-01 at 03:09 -0400, Charles Philip Chan wrote:

> Hello all,
>
> I am having problems mounting my USB external hard drive at boot time
> for the past few snapshots. The drive have an entry in my fstab and I
> have no problem mounting it for years. A manual mount with the "mount"
> command (which, IIRC, uses systemd-mount now) doesn't work either and
> produce no errors in the systemd log journal. However, I have no
> problems mounting it with "udisksctl mount -b <device>". What could be
> the problem?

Did you look at the logs?

- --
Cheers,
        Carlos E. R.
        (from openSUSE 42.2 x86_64 "Malachite" at Telcontar)

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2

iEYEARECAAYFAln5tuIACgkQtTMYHG2NR9WVZwCfUBGZmDhs3kgJWGSpIGq2raox
SwAAoI9VkWvf71R5uQp19KIzqDXt0vWr
=Gnr7
-----END PGP SIGNATURE-----
--
To unsubscribe, e-mail: [hidden email]
To contact the owner, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

Re: Problem Mounting USB Hard Drive on Boot

Charles Philip Chan-3

Hi Carlos,

> Did you look at the logs?

Yes.  Here is a snippet:

,----[ Output of journalctl -xb ]
| Nov 01 04:01:31 karnak systemd[1]:
| dev-disk-by\x2did-scsi\x2d1WD_My_Book_1140_WCAZA8742496\x2dpart1.device:
| Job dev-disk
| -by\x2did-scsi\x2d1WD_My_Book_1140_WCAZA8742496\x2dpart1.device/start timed out.
| Nov 01 04:01:31 karnak systemd[1]: Timed out waiting for device
| dev-disk-by\x2did-scsi\x2d1WD_My_Book_1140_WCAZA8742496\
| x2dpart1.device.
| -- Subject: Unit dev-disk-by\x2did-scsi\x2d1WD_My_Book_1140_WCAZA8742496\x2dpart1.device has failed
| -- Defined-By: systemd
| -- Support: https://lists.freedesktop.org/mailman/listinfo/systemd-devel
| --
| -- Unit dev-disk-by\x2did-scsi\x2d1WD_My_Book_1140_WCAZA8742496\x2dpart1.device has failed.
| --
| -- The result is timeout.
| Nov 01 04:01:31 karnak systemd[1]: Dependency failed for /data3.
| -- Subject: Unit data3.mount has failed
| -- Defined-By: systemd
| -- Support: https://lists.freedesktop.org/mailman/listinfo/systemd-devel
| --
| -- Unit data3.mount has failed.
| --
| -- The result is dependency.
| Nov 01 04:01:31 karnak systemd[1]: data3.mount: Job data3.mount/start failed with result 'dependency'.
| Nov 01 04:01:31 karnak systemd[1]: Dependency failed for File System
| Check on /dev/disk/by-id/scsi-1WD_My_Book_1140_WCAZA8742496-part1.
| -- Subject: Unit
| systemd-fsck@dev-disk-by\x2did-scsi\x2d1WD_My_Book_1140_WCAZA8742496\x2dpart1.service
| has failed
| -- Defined-By: systemd
| -- Support: https://lists.freedesktop.org/mailman/listinfo/systemd-devel
| --
| -- Unit systemd-fsck@dev-disk-by\x2did-scsi\x2d1WD_My_Book_1140_WCAZA8742496\x2dpart1.service has failed.
| --
| -- The result is dependency.
`----

I have:

  1. Verified the system can see the drive with "fdisk -l".

  2. Ran fsck on it with no problems.

However, the drive would not mount at boot nor with the "mount"
command. However, it mounts immediately with "udiskctl mount -b
<device>".

This is all very strange.

Charles

--
Avoid the Gates of Hell.  Use Linux
(Unknown source)

signature.asc (233 bytes) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: Problem Mounting USB Hard Drive on Boot

Oliver Neukum-2

> I have:
>
>   1. Verified the system can see the drive with "fdisk -l".
>
>   2. Ran fsck on it with no problems.
>
> However, the drive would not mount at boot nor with the "mount"
> command. However, it mounts immediately with "udiskctl mount -b
> <device>".
>

Hi,

1. this belongs onto bugzilla
2. Give the errors of the mount command, please

        Regards
                Oliver

--
To unsubscribe, e-mail: [hidden email]
To contact the owner, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

Re: Problem Mounting USB Hard Drive on Boot

Charles Philip Chan-3
Oliver Neukum <[hidden email]> writes:

Hi Oliver,

> 1. this belongs onto bugzilla
> 2. Give the errors of the mount command, please

I don't know what to file here. The "mount" command completes silently
with no error output on the console nor the journal log. It just doesn't
mount the device, where as "udiskctrl mount -b <device>" works.

Charles

--
I did this 'cause Linux gives me a woody.  It doesn't generate revenue.
(Dave '-ddt->` Taylor, announcing DOOM for Linux)

signature.asc (233 bytes) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: Problem Mounting USB Hard Drive on Boot

Charles Philip Chan-2
In reply to this post by Oliver Neukum-2
Oliver Neukum <[hidden email]> writes:

Hi Oliver,

> 1. this belongs onto bugzilla
> 2. Give the errors of the mount command, please

I don't know what to file here. The "mount" command completes silently
with no error output on the console nor the journal log. It just doesn't
mount the device, where as "udiskctrl mount -b <device>" works.

Charles

--
I did this 'cause Linux gives me a woody.  It doesn't generate revenue.
(Dave '-ddt->` Taylor, announcing DOOM for Linux)

signature.asc (199 bytes) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: Problem Mounting USB Hard Drive on Boot

Oliver Neukum-2
Am Montag, den 06.11.2017, 18:30 -0500 schrieb Charles Philip Chan:

> Oliver Neukum <[hidden email]> writes:
>
> Hi Oliver,
>
> >
> > 1. this belongs onto bugzilla
> > 2. Give the errors of the mount command, please
>
> I don't know what to file here. The "mount" command completes silently
> with no error output on the console nor the journal log. It just doesn't
> mount the device, where as "udiskctrl mount -b <device>" works.

Hi,

then this exact information needs to go into bugzilla.

        HTH
                Oliver

--
To unsubscribe, e-mail: [hidden email]
To contact the owner, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

Re: Problem Mounting USB Hard Drive on Boot

Freek de Kruijf
Op dinsdag 7 november 2017 10:37:32 CET schreef Oliver Neukum:

> Am Montag, den 06.11.2017, 18:30 -0500 schrieb Charles Philip Chan:
> > Oliver Neukum <[hidden email]> writes:
> >
> > Hi Oliver,
> >
> > > 1. this belongs onto bugzilla
> > > 2. Give the errors of the mount command, please
> >
> > I don't know what to file here. The "mount" command completes silently
> > with no error output on the console nor the journal log. It just doesn't
> > mount the device, where as "udiskctrl mount -b <device>" works.
>
> Hi,
>
> then this exact information needs to go into bugzilla.
>
> HTH
> Oliver

Did you specify -v to get verbose output?

--
vr.gr.

Freek de Kruijf
member openSUSE
--
To unsubscribe, e-mail: [hidden email]
To contact the owner, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

Re: Problem Mounting USB Hard Drive on Boot

Charles Philip Chan-3
Freek de Kruijf <[hidden email]> writes:

Hi Freek,

> Did you specify -v to get verbose output?

Yes.

Charles

--
A Linux machine! because a 486 is a terrible thing to waste!
(By [hidden email], Joe Sloan)

signature.asc (233 bytes) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: Problem Mounting USB Hard Drive on Boot

Knurpht-openSUSE
Op dinsdag 7 november 2017 14:27:35 CET schreef Charles Philip Chan:
> Freek de Kruijf <[hidden email]> writes:
>
> Hi Freek,
>
> > Did you specify -v to get verbose output?
>
> Yes.
>
> Charles
Can you show us the fstab entry?

--
Gertjan Lettink, a.k.a. Knurpht

openSUSE Board Member
openSUSE Forums Team
--
To unsubscribe, e-mail: [hidden email]
To contact the owner, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

Re: Problem Mounting USB Hard Drive on Boot

Charles Philip Chan-3
Knurpht - Gertjan Lettink <[hidden email]> writes:

> Can you show us the fstab entry?

Sure, I have been using this line:

,----[ Exerpt from /etc/fstab ]
| /dev/disk/by-id/scsi-1WD_My_Book_1140_WCAZA8742496-part1  /data3       ext4       defaults,acl,user_xattr,nofail  0 2
`----

for years with no problems.

Charles

--
"It's God.  No, not Richard Stallman, or Linus Torvalds, but God."
(By Matt Welsh)

signature.asc (233 bytes) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: Problem Mounting USB Hard Drive on Boot

Stefan Seyfried
On 07.11.2017 15:32, Charles Philip Chan wrote:

> Knurpht - Gertjan Lettink <[hidden email]> writes:
>
>> Can you show us the fstab entry?
>
> Sure, I have been using this line:
>
> ,----[ Exerpt from /etc/fstab ]
> | /dev/disk/by-id/scsi-1WD_My_Book_1140_WCAZA8742496-part1  /data3       ext4       defaults,acl,user_xattr,nofail  0 2
> `----
>
> for years with no problems.

Does /dev/disk/by-id/scsi-1WD_My_Book_1140_WCAZA8742496-part1 exist when you try to mount?
maybe due to a bug  in an update, the naming rules changed slightly and now there's a different ID pointing to the
device in /dev/disk/by-id?

Check "ls -l /dev/disk/by-id" with the disk plugged.
--
Stefan Seyfried

"For a successful technology, reality must take precedence over
 public relations, for nature cannot be fooled." -- Richard Feynman
--
To unsubscribe, e-mail: [hidden email]
To contact the owner, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

Re: Problem Mounting USB Hard Drive on Boot

Christian Boltz-5
In reply to this post by Charles Philip Chan-3
Hello,

Am Dienstag, 7. November 2017, 15:32:28 CET schrieb Charles Philip Chan:
> ,----[ Exerpt from /etc/fstab ]
>
> | /dev/disk/by-id/scsi-1WD_My_Book_1140_WCAZA8742496-part1  /data3    
> |   ext4       defaults,acl,user_xattr,nofail  0 2
> `----
>
> for years with no problems.

You are basically doing

# mount -o nofail /dev/no_such_device /data3
# echo $?
0

Remove the "nofail" option and try again ;-)


Regards,

Christian Boltz
--
lets focus the marketing on talking about how good openSUSE is..
that''s irrelevant to this discussion about version numbering though,
unless you think one of the reasons openSUSE is good is because we
used to increment the version numbers by 0.1 every 12 months ;)
[Richard Brown in opensuse-factory]

--
To unsubscribe, e-mail: [hidden email]
To contact the owner, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

Re: Problem Mounting USB Hard Drive on Boot

Carlos E. R.-2
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256

Content-ID: <[hidden email]>


El 2017-11-10 a las 15:12 +0100, Christian Boltz escribió:

> Hello,
>
> Am Dienstag, 7. November 2017, 15:32:28 CET schrieb Charles Philip Chan:
>> ,----[ Exerpt from /etc/fstab ]
>>
>> | /dev/disk/by-id/scsi-1WD_My_Book_1140_WCAZA8742496-part1  /data3
>> |   ext4       defaults,acl,user_xattr,nofail  0 2
>> `----
>>
>> for years with no problems.
>
> You are basically doing
>
> # mount -o nofail /dev/no_such_device /data3
> # echo $?
> 0
>
> Remove the "nofail" option and try again ;-)
Yes, the "nofail" option makes it work or fail silently, no errors
written. However, hs said he tried "-v", and that one should have printed
something in case of errors, and apparently it did not.

- --
Cheers
        Carlos E. R.

        (from openSUSE 42.2 x86_64 "Malachite" (Minas Tirith))
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2

iF4EAREIAAYFAloGXAcACgkQja8UbcUWM1yR0QD9GADqZw8vPKzXwzvGdCVFS7h5
zsJtjxWGSdN+NFuW6AIA/jr5sJaAnfy5zjRF+iYd2jQnB4HvuJUb0JWqN1LRfLwT
=1HLd
-----END PGP SIGNATURE-----
Reply | Threaded
Open this post in threaded view
|

Re: Problem Mounting USB Hard Drive on Boot

Christian Boltz-5
Hello,

Am Samstag, 11. November 2017, 03:10:08 CET schrieb Carlos E. R.:

> El 2017-11-10 a las 15:12 +0100, Christian Boltz escribió:
> > You are basically doing
> >
> > # mount -o nofail /dev/no_such_device /data3
> > # echo $?
> > 0
> >
> > Remove the "nofail" option and try again ;-)
>
> Yes, the "nofail" option makes it work or fail silently, no errors
> written. However, hs said he tried "-v", and that one should have
> printed something in case of errors, and apparently it did not.

As I wrote elsewhere [1] a few days ago: "should"  is a good word to
describe the difference between theory and practise ;-)

# mount -v -o nofail /dev/no_such_device /mnt
# echo $?
0


Regards,

Christian Boltz

[1] https://gitlab.infra.opensuse.org/infra/salt/merge_requests/74
    (sorry, that's only available to the Heroes - but we are always
    happy if someone wants to join and help with the infrastructure ;-)

--
Patches come and go like socks. Nobody really wants a bugzilla entry
for each and every one. [Jan Engelhardt in opensuse-packaging]

--
To unsubscribe, e-mail: [hidden email]
To contact the owner, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

Re: Problem Mounting USB Hard Drive on Boot

Carlos E. R.-2
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1



On Sunday, 2017-11-12 at 14:06 +0100, Christian Boltz wrote:

> Hello,
>
> Am Samstag, 11. November 2017, 03:10:08 CET schrieb Carlos E. R.:
>> El 2017-11-10 a las 15:12 +0100, Christian Boltz escribió:
>>> You are basically doing
>>>
>>> # mount -o nofail /dev/no_such_device /data3
>>> # echo $?
>>> 0
>>>
>>> Remove the "nofail" option and try again ;-)
>>
>> Yes, the "nofail" option makes it work or fail silently, no errors
>> written. However, hs said he tried "-v", and that one should have
>> printed something in case of errors, and apparently it did not.
>
> As I wrote elsewhere [1] a few days ago: "should"  is a good word to
> describe the difference between theory and practise ;-)
>
> # mount -v -o nofail /dev/no_such_device /mnt
> # echo $?
> 0
Ah, yes, it doesn't say anything if the device does not exist:


cer@Telcontar:~> grep photo /etc/fstab
LABEL=bck_photos_1 /data/backup/photos xfs users,lazytime,noauto,nofail 1 4
LABEL=CAMERA_1 /mnt/photostick vfat noauto,shortname=mixed,user,users,uid=cer,gid=users,fmask=0117,dmask=0007 0 0
cer@Telcontar:~> mount -v /data/backup/photos
cer@Telcontar:~>
cer@Telcontar:~> mount -v /mnt/photostick
mount: can't find LABEL=CAMERA_1
cer@Telcontar:~>


I have to test for the mount actually hapening in some of my scripts.



> [1] https://gitlab.infra.opensuse.org/infra/salt/merge_requests/74
>    (sorry, that's only available to the Heroes - but we are always
>    happy if someone wants to join and help with the infrastructure ;-)

Hum. I doubt there would be areas where I could help :-?

- --
Cheers,
        Carlos E. R.
        (from openSUSE 42.2 x86_64 "Malachite" at Telcontar)

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2

iEYEARECAAYFAloIYOIACgkQtTMYHG2NR9Vi8ACgldFEb4J7D0SSZpWxLVP027bo
YNoAn3+f2abobCWo7RIa/xVQs0gz+k5f
=OyKW
-----END PGP SIGNATURE-----