SATA drives will not automount - New install

General support questions
Post Reply
Lucas_Black
Posts: 1
Joined: 2019/01/07 23:53:43

SATA drives will not automount - New install

Post by Lucas_Black » 2019/01/08 00:11:05

Hello,

This is a Dell R630. New install "CentOS Linux release 7.4.1708"
I am connecting different hard drives to SATA port J in the motherboard.
OS will see them, but not automount.
I have to go to Applications > Utilities > Disks and mount it manually.
I would like Centos to mount it automatically as the drive is inserted.

All drives will automount through USB interface.
Also, if I fresh install Ubuntu 16.04 in the same machine all SATA drives will automount.

Thank you in advance.

User avatar
TrevorH
Site Admin
Posts: 33202
Joined: 2009/09/24 10:40:56
Location: Brighton, UK

Re: SATA drives will not automount - New install

Post by TrevorH » 2019/01/08 09:32:42

Start by trying the most recent CentOS media. 7.4 is 18 months old and there have been two intervening releases since then. Try 7.6 - it is the current and only supported installation media.
The future appears to be RHEL or Debian. I think I'm going Debian.
Info for USB installs on http://wiki.centos.org/HowTos/InstallFromUSBkey
CentOS 5 and 6 are deadest, do not use them.
Use the FAQ Luke

Jestav
Posts: 4
Joined: 2019/01/18 20:16:05

Re: SATA drives will not automount - New install

Post by Jestav » 2019/01/18 22:18:14

Hello,

I'm also having this issue. After installing the latest Centos 7 1810 and running an update, the issue is the same as the initial post problem.

hunter86_bg
Posts: 2019
Joined: 2015/02/17 15:14:33
Location: Bulgaria
Contact:

Re: SATA drives will not automount - New install

Post by hunter86_bg » 2019/01/20 06:25:42

Correct me if I understood it wrong.
You want all SATA drives to be automatically mounted, just like the USB drives , right ?

I guess you can use udev to do that for you.

mashiro2004
Posts: 68
Joined: 2018/12/08 21:46:22
Location: Italy

Re: SATA drives will not automount - New install

Post by mashiro2004 » 2019/01/20 21:10:56

Lucas_Black wrote:
2019/01/08 00:11:05
Hello,

This is a Dell R630. New install "CentOS Linux release 7.4.1708"
I am connecting different hard drives to SATA port J in the motherboard.
OS will see them, but not automount.
I have to go to Applications > Utilities > Disks and mount it manually.
I would like Centos to mount it automatically as the drive is inserted.

All drives will automount through USB interface.
Also, if I fresh install Ubuntu 16.04 in the same machine all SATA drives will automount.

Thank you in advance.
if I understood the question correctly, have you tried to compile fstab manually??

Jestav
Posts: 4
Joined: 2019/01/18 20:16:05

Re: SATA drives will not automount - New install

Post by Jestav » 2019/01/20 23:09:19

hunter86_bg wrote:
2019/01/20 06:25:42
Correct me if I understood it wrong.
You want all SATA drives to be automatically mounted, just like the USB drives , right ?

I guess you can use udev to do that for you.
I'm not very knowledgeable still in Centos to create custom udev rules. I would appreciate any help with that if that's possible.
mashiro2004 wrote:
2019/01/20 21:10:56
Lucas_Black wrote:
2019/01/08 00:11:05
Hello,

This is a Dell R630. New install "CentOS Linux release 7.4.1708"
I am connecting different hard drives to SATA port J in the motherboard.
OS will see them, but not automount.
I have to go to Applications > Utilities > Disks and mount it manually.
I would like Centos to mount it automatically as the drive is inserted.

All drives will automount through USB interface.
Also, if I fresh install Ubuntu 16.04 in the same machine all SATA drives will automount.

Thank you in advance.
if I understood the question correctly, have you tried to compile fstab manually??
fstab is mostly used to mount drives on boot up no?

I get new hard drives almost every week, so while the device is booted, it needs to be able to read, auto mount and auto dismount drives at will.

User avatar
TrevorH
Site Admin
Posts: 33202
Joined: 2009/09/24 10:40:56
Location: Brighton, UK

Re: SATA drives will not automount - New install

Post by TrevorH » 2019/01/20 23:13:09

I get new hard drives almost every week, so while the device is booted, it needs to be able to read, auto mount and auto dismount drives at will.
This sounds like quite a specialised use case. Perhaps you could say more about why you have new hard drives every week (most of us probably get new ones every year or three). How are they attached to your system? Are you using an external enclosure?
The future appears to be RHEL or Debian. I think I'm going Debian.
Info for USB installs on http://wiki.centos.org/HowTos/InstallFromUSBkey
CentOS 5 and 6 are deadest, do not use them.
Use the FAQ Luke

hunter86_bg
Posts: 2019
Joined: 2015/02/17 15:14:33
Location: Bulgaria
Contact:

Re: SATA drives will not automount - New install

Post by hunter86_bg » 2019/01/21 08:47:03

Most probably you have to clarify if you have multipath daemon running.
Also you can check this link and modify that to your needs - as it is for usb devices.

Udev is powerful, so I could recommend you to do your tests on a non-productive system.

Jestav
Posts: 4
Joined: 2019/01/18 20:16:05

Re: SATA drives will not automount - New install

Post by Jestav » 2019/01/21 15:58:13

TrevorH wrote:
2019/01/20 23:13:09
I get new hard drives almost every week, so while the device is booted, it needs to be able to read, auto mount and auto dismount drives at will.
This sounds like quite a specialised use case. Perhaps you could say more about why you have new hard drives every week (most of us probably get new ones every year or three). How are they attached to your system? Are you using an external enclosure?
I received USBs and sas/sata removable drives from others. Hence why always inserting new hard drives and USBs into this test machine.
They are being attached by a USB port (Which I know it works) and by SATA CRU Removable Drive Reader attached to an open SATA slot on the motherboard.
hunter86_bg wrote:
2019/01/21 08:47:03
Most probably you have to clarify if you have multipath daemon running.
Also you can check this link and modify that to your needs - as it is for usb devices.

Udev is powerful, so I could recommend you to do your tests on a non-productive system.
Currently, I have udisks2 setting new drives inserted to go to /media/ but this is only working for drives inserted onto a USB port.

When I Insert a Removable SATA Drive onto a SATA Reader, I get the following from fdisk & dmesg:

DMESG:
[ 1349.459105] ata5: exception Emask 0x10 SAct 0x0 SErr 0x4040002 action 0xe frozen
[ 1349.459112] ata5: irq_stat 0x00000040, connection status changed
[ 1349.459118] ata5: SError: { RecovComm CommWake DevExch }
[ 1349.469952] ata5: hard resetting link
[ 1355.242377] ata5: link is slow to respond, please be patient (ready=0)
[ 1357.333129] ata5: SATA link up 3.0 Gbps (SStatus 123 SControl 300)
[ 1357.349644] ata5.00: ATA-8: WDC WD2502ABYS-18B7A0, 02.03B05, max UDMA/133
[ 1357.349651] ata5.00: 488281250 sectors, multi 0: LBA48 NCQ (depth 31/32), AA
[ 1357.350669] ata5.00: configured for UDMA/133
[ 1357.361128] ata5: EH complete
[ 1357.361315] scsi 5:0:0:0: Direct-Access ATA WDC WD2502ABYS-1 3B05 PQ: 0 ANSI: 5
[ 1357.374451] sd 5:0:0:0: [sdc] 488281250 512-byte logical blocks: (250 GB/232 GiB)
[ 1357.374462] sd 5:0:0:0: Attached scsi generic sg2 type 0
[ 1357.374641] sd 5:0:0:0: [sdc] Write Protect is off
[ 1357.374647] sd 5:0:0:0: [sdc] Mode Sense: 00 3a 00 00
[ 1357.374696] sd 5:0:0:0: [sdc] Write cache: enabled, read cache: enabled, doesn't support DPO or FUA
[ 1357.379569] sdc: sdc1
[ 1357.380178] sd 5:0:0:0: [sdc] Attached SCSI disk

FDISK:
Disk /dev/sdc: 250.0 GB, 250000000000 bytes, 488281250 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk label type: dos
Disk identifier: 0xf2644d69

Device Boot Start End Blocks Id System
/dev/sdc1 * 2048 488278015 244137984 7 HPFS/NTFS/exFAT

Basically, these Removable SATA Drives I insert are being seen by the OS but not automatically mounted to /media/

After going by the link you provided, I used the example they had but it ended up in all the USBs I inserted giving the error: Transport not available. I removed the udev rule and they started working again.

Maybe udev is not the best for this type of scenario? Maybe udisks2 is the problem?

Post Reply