Linux unmount automatically external drive / array after time

ProXXXX

New Member
Nov 18, 2022
5
15
3
Hello everyone,

I have an external hard drive array that is permanently attached to the computer. I specified the array in /etc/fstab. When I start the computer, it is also mounted correctly. Only after a while it is automatically unmount. I don't want this.

If i use mount -a, it is mounted correctly again and works fine until the next unmount.

[fstab]

>UUID=46c61289-7e60-4059-80c4-9322cdccbd5f /mnt/backup-raid ext4 defaults 0 0

Until about 4 weeks ago I had no problems with it.
logfile
Rich (BB code):
Nov 27 21:17:01 - CRON[132829]: pam_unix(cron:session): session opened for user root(uid=0) by (uid=0)
Nov 27 21:17:01 - CRON[132830]: (root) CMD (   cd / && run-parts --report /etc/cron.hourly)
Nov 27 21:17:01 - CRON[132829]: pam_unix(cron:session): session closed for user root
Nov 27 21:19:59 - kernel: usb 2-1: USB disconnect, device number 5
Nov 27 21:19:59 - kernel: blk_update_request: I/O error, dev sde, sector 0 op 0x1:(WRITE) flags 0x800 phys_seg 0 prio class 0
Nov 27 21:19:59 - kernel: sd 9:0:0:0: [sde] Synchronizing SCSI cache
Nov 27 21:19:59 - systemd[1]: Unmounting /mnt/backup-raid...
Nov 27 21:19:59 - systemd[99933]: mnt-backup\x2draid.mount: Succeeded.
Nov 27 21:19:59 - kernel: blk_update_request: I/O error, dev sde, sector 0 op 0x1:(WRITE) flags 0x800 phys_seg 0 prio class 0
Nov 27 21:19:59 - kernel: blk_update_request: I/O error, dev sde, sector 0 op 0x1:(WRITE) flags 0x800 phys_seg 0 prio class 0
Nov 27 21:19:59 - kernel: blk_update_request: I/O error, dev sde, sector 0 op 0x1:(WRITE) flags 0x800 phys_seg 0 prio class 0
Nov 27 21:19:59 - kernel: blk_update_request: I/O error, dev sde, sector 0 op 0x1:(WRITE) flags 0x800 phys_seg 0 prio class 0
Nov 27 21:19:59 - kernel: blk_update_request: I/O error, dev sde, sector 0 op 0x1:(WRITE) flags 0x800 phys_seg 0 prio class 0
Nov 27 21:19:59 - kernel: blk_update_request: I/O error, dev sde, sector 3905161216 op 0x1:(WRITE) flags 0x800 phys_seg 1 prio class 0
Nov 27 21:19:59 - kernel: blk_update_request: I/O error, dev sde, sector 3905161216 op 0x1:(WRITE) flags 0x800 phys_seg 1 prio class 0
Nov 27 21:19:59 - kernel: Buffer I/O error on dev sde1, logical block 488144896, lost sync page write
Nov 27 21:19:59 - kernel: JBD2: Error -5 detected when updating journal superblock for sde1-8.
Nov 27 21:19:59 - kernel: Aborting journal on device sde1-8.
Nov 27 21:19:59 - kernel: blk_update_request: I/O error, dev sde, sector 3905161216 op 0x1:(WRITE) flags 0x800 phys_seg 1 prio class 0
Nov 27 21:19:59 - kernel: blk_update_request: I/O error, dev sde, sector 3905161216 op 0x1:(WRITE) flags 0x800 phys_seg 1 prio class 0
Nov 27 21:19:59 - kernel: Buffer I/O error on dev sde1, logical block 488144896, lost sync page write
Nov 27 21:19:59 - kernel: JBD2: Error -5 detected when updating journal superblock for sde1-8.
Nov 27 21:19:59 - kernel: EXT4-fs error (device sde1): ext4_put_super:1194: comm umount: Couldn't clean up the journal
Nov 27 21:19:59 - kernel: EXT4-fs (sde1): Remounting filesystem read-only
Nov 27 21:19:59 - systemd[1]: mnt-backup\x2draid.mount: Succeeded.
Nov 27 21:19:59 - systemd[1]: Unmounted /mnt/backup-raid.
Nov 27 21:19:59 - kernel: sd 9:0:0:0: [sde] Synchronize Cache(10) failed: Result: hostbyte=DID_ERROR driverbyte=DRIVER_OK
Nov 27 21:20:00 - kernel: usb 2-1: new SuperSpeed Plus Gen 2x1 USB device number 6 using xhci_hcd
Nov 27 21:20:00 - kernel: usb 2-1: New USB device found, idVendor=174c, idProduct=55aa, bcdDevice= 1.00
Nov 27 21:20:00 - kernel: usb 2-1: New USB device strings: Mfr=2, Product=3, SerialNumber=1
Nov 27 21:20:00 - kernel: usb 2-1: Product: IB-RD3802-C31
Nov 27 21:20:00 - kernel: usb 2-1: Manufacturer: ICY BOX
Nov 27 21:20:00 - kernel: usb 2-1: SerialNumber:
Nov 27 21:20:00 - kernel: scsi host9: uas
Nov 27 21:20:00 - kernel: scsi 9:0:0:0: Direct-Access     IB-      RD3802-C31 RAID1 0    PQ: 0 ANSI: 6
Nov 27 21:20:00 - kernel: sd 9:0:0:0: Attached scsi generic sg4 type 0
Nov 27 21:20:00 - kernel: sd 9:0:0:0: [sde] 7813988353 512-byte logical blocks: (4.00 TB/3.64 TiB)
Nov 27 21:20:00 - kernel: sd 9:0:0:0: [sde] 4096-byte physical blocks
Nov 27 21:20:00 - kernel: sd 9:0:0:0: [sde] Write Protect is off
Nov 27 21:20:00 - kernel: sd 9:0:0:0: [sde] Mode Sense: 43 00 00 00
Nov 27 21:20:00 - kernel: sd 9:0:0:0: [sde] Write cache: enabled, read cache: enabled, doesn't support DPO or FUA
Nov 27 21:20:00 - kernel: sd 9:0:0:0: [sde] Optimal transfer size 33553920 bytes not a multiple of physical block size (4096 bytes)
Nov 27 21:20:00 - kernel:  sde: sde1


Output of

udevadm monitor
monitor will print the received events for:
UDEV - the event which udev sends out after rule processing
KERNEL - the kernel uevent

KERNEL[10794.016468] remove /devices/pci0000:00/0000:00:01.2/0000:15:00.0/usb2/2-1/2-1:1.0/host9/target9:0:0/9:0:0:0/bsg/9:0:0:0 (bsg)
KERNEL[10794.016530] remove /devices/pci0000:00/0000:00:01.2/0000:15:00.0/usb2/2-1/2-1:1.0/host9/target9:0:0/9:0:0:0/scsi_generic/sg4 (scsi_generic)
KERNEL[10794.016547] remove /devices/pci0000:00/0000:00:01.2/0000:15:00.0/usb2/2-1/2-1:1.0/host9/target9:0:0/9:0:0:0/scsi_device/9:0:0:0 (scsi_device)
KERNEL[10794.016563] remove /devices/pci0000:00/0000:00:01.2/0000:15:00.0/usb2/2-1/2-1:1.0/host9/target9:0:0/9:0:0:0/scsi_disk/9:0:0:0 (scsi_disk)
UDEV [10794.017253] remove /devices/pci0000:00/0000:00:01.2/0000:15:00.0/usb2/2-1/2-1:1.0/host9/target9:0:0/9:0:0:0/bsg/9:0:0:0 (bsg)
UDEV [10794.017958] remove /devices/pci0000:00/0000:00:01.2/0000:15:00.0/usb2/2-1/2-1:1.0/host9/target9:0:0/9:0:0:0/scsi_device/9:0:0:0 (scsi_device)
UDEV [10794.018593] remove /devices/pci0000:00/0000:00:01.2/0000:15:00.0/usb2/2-1/2-1:1.0/host9/target9:0:0/9:0:0:0/scsi_disk/9:0:0:0 (scsi_disk)
UDEV [10794.019915] remove /devices/pci0000:00/0000:00:01.2/0000:15:00.0/usb2/2-1/2-1:1.0/host9/target9:0:0/9:0:0:0/scsi_generic/sg4 (scsi_generic)
KERNEL[10794.025886] remove /devices/pci0000:00/0000:00:01.2/0000:15:00.0/usb2/2-1/2-1:1.0/host9/target9:0:0/9:0:0:0/block/sde/sde1 (block)
KERNEL[10794.026290] remove /devices/virtual/bdi/8:64 (bdi)
KERNEL[10794.026461] remove /devices/pci0000:00/0000:00:01.2/0000:15:00.0/usb2/2-1/2-1:1.0/host9/target9:0:0/9:0:0:0/block/sde (block)
UDEV [10794.026687] remove /devices/virtual/bdi/8:64 (bdi)
UDEV [10794.028652] remove /devices/pci0000:00/0000:00:01.2/0000:15:00.0/usb2/2-1/2-1:1.0/host9/target9:0:0/9:0:0:0/block/sde/sde1 (block)
UDEV [10794.031073] remove /devices/pci0000:00/0000:00:01.2/0000:15:00.0/usb2/2-1/2-1:1.0/host9/target9:0:0/9:0:0:0/block/sde (block)
KERNEL[10794.260260] unbind /devices/pci0000:00/0000:00:01.2/0000:15:00.0/usb2/2-1/2-1:1.0/host9/target9:0:0/9:0:0:0 (scsi)
KERNEL[10794.260371] remove /devices/pci0000:00/0000:00:01.2/0000:15:00.0/usb2/2-1/2-1:1.0/host9/target9:0:0/9:0:0:0 (scsi)
KERNEL[10794.260441] remove /devices/pci0000:00/0000:00:01.2/0000:15:00.0/usb2/2-1/2-1:1.0/host9/target9:0:0 (scsi)
KERNEL[10794.260482] remove /devices/pci0000:00/0000:00:01.2/0000:15:00.0/usb2/2-1/2-1:1.0/host9/scsi_host/host9 (scsi_host)
KERNEL[10794.260554] remove /devices/pci0000:00/0000:00:01.2/0000:15:00.0/usb2/2-1/2-1:1.0/host9 (scsi)
UDEV [10794.261568] remove /devices/pci0000:00/0000:00:01.2/0000:15:00.0/usb2/2-1/2-1:1.0/host9/scsi_host/host9 (scsi_host)
UDEV [10794.262033] unbind /devices/pci0000:00/0000:00:01.2/0000:15:00.0/usb2/2-1/2-1:1.0/host9/target9:0:0/9:0:0:0 (scsi)
UDEV [10794.262205] remove /devices/pci0000:00/0000:00:01.2/0000:15:00.0/usb2/2-1/2-1:1.0/host9/target9:0:0/9:0:0:0 (scsi)
UDEV [10794.262342] remove /devices/pci0000:00/0000:00:01.2/0000:15:00.0/usb2/2-1/2-1:1.0/host9/target9:0:0 (scsi)
UDEV [10794.262462] remove /devices/pci0000:00/0000:00:01.2/0000:15:00.0/usb2/2-1/2-1:1.0/host9 (scsi)
KERNEL[10794.288576] remove /devices/virtual/workqueue/scsi_tmf_9 (workqueue)
KERNEL[10794.288764] unbind /devices/pci0000:00/0000:00:01.2/0000:15:00.0/usb2/2-1/2-1:1.0 (usb)
KERNEL[10794.288921] remove /devices/pci0000:00/0000:00:01.2/0000:15:00.0/usb2/2-1/2-1:1.0 (usb)
UDEV [10794.289128] remove /devices/virtual/workqueue/scsi_tmf_9 (workqueue)
UDEV [10794.289967] unbind /devices/pci0000:00/0000:00:01.2/0000:15:00.0/usb2/2-1/2-1:1.0 (usb)
UDEV [10794.290166] remove /devices/pci0000:00/0000:00:01.2/0000:15:00.0/usb2/2-1/2-1:1.0 (usb)
KERNEL[10794.290904] unbind /devices/pci0000:00/0000:00:01.2/0000:15:00.0/usb2/2-1 (usb)
KERNEL[10794.291021] remove /devices/pci0000:00/0000:00:01.2/0000:15:00.0/usb2/2-1 (usb)
UDEV [10794.292184] unbind /devices/pci0000:00/0000:00:01.2/0000:15:00.0/usb2/2-1 (usb)
UDEV [10794.292427] remove /devices/pci0000:00/0000:00:01.2/0000:15:00.0/usb2/2-1 (usb)
KERNEL[10794.599053] add /devices/pci0000:00/0000:00:01.2/0000:15:00.0/usb2/2-1 (usb)
KERNEL[10794.607765] add /devices/pci0000:00/0000:00:01.2/0000:15:00.0/usb2/2-1/2-1:1.0 (usb)
KERNEL[10794.624730] add /devices/virtual/workqueue/scsi_tmf_9 (workqueue)
UDEV [10794.625448] add /devices/virtual/workqueue/scsi_tmf_9 (workqueue)
KERNEL[10794.628559] add /devices/pci0000:00/0000:00:01.2/0000:15:00.0/usb2/2-1/2-1:1.0/host9 (scsi)
KERNEL[10794.628600] add /devices/pci0000:00/0000:00:01.2/0000:15:00.0/usb2/2-1/2-1:1.0/host9/scsi_host/host9 (scsi_host)
KERNEL[10794.628717] bind /devices/pci0000:00/0000:00:01.2/0000:15:00.0/usb2/2-1/2-1:1.0 (usb)
KERNEL[10794.628886] bind /devices/pci0000:00/0000:00:01.2/0000:15:00.0/usb2/2-1 (usb)
KERNEL[10794.629785] add /devices/pci0000:00/0000:00:01.2/0000:15:00.0/usb2/2-1/2-1:1.0/host9/target9:0:0 (scsi)
KERNEL[10794.629874] add /devices/pci0000:00/0000:00:01.2/0000:15:00.0/usb2/2-1/2-1:1.0/host9/target9:0:0/9:0:0:0 (scsi)
KERNEL[10794.629897] add /devices/pci0000:00/0000:00:01.2/0000:15:00.0/usb2/2-1/2-1:1.0/host9/target9:0:0/9:0:0:0/scsi_device/9:0:0:0 (scsi_device)
KERNEL[10794.630007] add /devices/pci0000:00/0000:00:01.2/0000:15:00.0/usb2/2-1/2-1:1.0/host9/target9:0:0/9:0:0:0/scsi_generic/sg4 (scsi_generic)
KERNEL[10794.630036] add /devices/pci0000:00/0000:00:01.2/0000:15:00.0/usb2/2-1/2-1:1.0/host9/target9:0:0/9:0:0:0/scsi_disk/9:0:0:0 (scsi_disk)
KERNEL[10794.630104] add /devices/pci0000:00/0000:00:01.2/0000:15:00.0/usb2/2-1/2-1:1.0/host9/target9:0:0/9:0:0:0/bsg/9:0:0:0 (bsg)
UDEV [10794.630303] add /devices/pci0000:00/0000:00:01.2/0000:15:00.0/usb2/2-1 (usb)
UDEV [10794.631372] add /devices/pci0000:00/0000:00:01.2/0000:15:00.0/usb2/2-1/2-1:1.0 (usb)
UDEV [10794.631684] add /devices/pci0000:00/0000:00:01.2/0000:15:00.0/usb2/2-1/2-1:1.0/host9 (scsi)
KERNEL[10794.631931] add /devices/virtual/bdi/8:64 (bdi)
UDEV [10794.632051] add /devices/pci0000:00/0000:00:01.2/0000:15:00.0/usb2/2-1/2-1:1.0/host9/scsi_host/host9 (scsi_host)
UDEV [10794.632364] add /devices/virtual/bdi/8:64 (bdi)
UDEV [10794.632990] bind /devices/pci0000:00/0000:00:01.2/0000:15:00.0/usb2/2-1/2-1:1.0 (usb)
UDEV [10794.634217] bind /devices/pci0000:00/0000:00:01.2/0000:15:00.0/usb2/2-1 (usb)
UDEV [10794.634393] add /devices/pci0000:00/0000:00:01.2/0000:15:00.0/usb2/2-1/2-1:1.0/host9/target9:0:0 (scsi)
UDEV [10794.635025] add /devices/pci0000:00/0000:00:01.2/0000:15:00.0/usb2/2-1/2-1:1.0/host9/target9:0:0/9:0:0:0 (scsi)
UDEV [10794.635505] add /devices/pci0000:00/0000:00:01.2/0000:15:00.0/usb2/2-1/2-1:1.0/host9/target9:0:0/9:0:0:0/scsi_device/9:0:0:0 (scsi_device)
UDEV [10794.635564] add /devices/pci0000:00/0000:00:01.2/0000:15:00.0/usb2/2-1/2-1:1.0/host9/target9:0:0/9:0:0:0/scsi_disk/9:0:0:0 (scsi_disk)
UDEV [10794.636197] add /devices/pci0000:00/0000:00:01.2/0000:15:00.0/usb2/2-1/2-1:1.0/host9/target9:0:0/9:0:0:0/bsg/9:0:0:0 (bsg)
UDEV [10794.638226] add /devices/pci0000:00/0000:00:01.2/0000:15:00.0/usb2/2-1/2-1:1.0/host9/target9:0:0/9:0:0:0/scsi_generic/sg4 (scsi_generic)
KERNEL[10795.214958] add /devices/pci0000:00/0000:00:01.2/0000:15:00.0/usb2/2-1/2-1:1.0/host9/target9:0:0/9:0:0:0/block/sde (block)
KERNEL[10795.215097] add /devices/pci0000:00/0000:00:01.2/0000:15:00.0/usb2/2-1/2-1:1.0/host9/target9:0:0/9:0:0:0/block/sde/sde1 (block)
KERNEL[10795.225318] bind /devices/pci0000:00/0000:00:01.2/0000:15:00.0/usb2/2-1/2-1:1.0/host9/target9:0:0/9:0:0:0 (scsi)
UDEV [10795.297986] add /devices/pci0000:00/0000:00:01.2/0000:15:00.0/usb2/2-1/2-1:1.0/host9/target9:0:0/9:0:0:0/block/sde (block)
UDEV [10795.322713] add /devices/pci0000:00/0000:00:01.2/0000:15:00.0/usb2/2-1/2-1:1.0/host9/target9:0:0/9:0:0:0/block/sde/sde1 (block)
UDEV [10795.323258] bind /devices/pci0000:00/0000:00:01.2/0000:15:00.0/usb2/2-1/2-1:1.0/host9/target9:0:0/9:0:0:0 (scsi)

Thanks for your help.
 
Last edited:
Hi,
since the the errors start happening after
Code:
Nov 27 21:19:59 - kernel: usb 2-1: USB disconnect, device number 5
you might want to check/replace the cable and try a different USB port to see if the issue persists. Did you install kernel or firmware updates when the issue started happening?
 
Hi,
since the the errors start happening after
Code:
Nov 27 21:19:59 - kernel: usb 2-1: USB disconnect, device number 5
you might want to check/replace the cable and try a different USB port to see if the issue persists. Did you install kernel or firmware updates when the issue started happening?
Thx Fiona and excuse for my late reply.

i tried a new usb port, change from usb typ-c to type-a and stop the smartmontools service but i have the same problem.

I find this syslog entry today. Maybe somebody find the Problem in the output. Maybe the hourly cronjob initate the issue

Code:
Jan 06 14:17:01 elicen CRON[3355537]: pam_unix(cron:session): session opened for user root(uid=0) by (uid=0)
Jan 06 14:17:01 elicen CRON[3355538]: (root) CMD (   cd / && run-parts --report /etc/cron.hourly)
Jan 06 14:17:01 elicen CRON[3355537]: pam_unix(cron:session): session closed for user root
Jan 06 15:17:01 elicen CRON[3381743]: pam_unix(cron:session): session opened for user root(uid=0) by (uid=0)
Jan 06 15:17:01 elicen CRON[3381744]: (root) CMD (   cd / && run-parts --report /etc/cron.hourly)
Jan 06 15:17:01 elicen CRON[3381743]: pam_unix(cron:session): session closed for user root
Jan 06 16:07:11 elicen kernel: usb 6-1: USB disconnect, device number 14
Jan 06 16:07:11 elicen kernel: print_req_error: 49 callbacks suppressed
Jan 06 16:07:11 elicen kernel: blk_update_request: I/O error, dev sde, sector 0 op 0x1:(WRITE) flags 0x800 phys_seg 0 prio class 0
Jan 06 16:07:12 elicen systemd[1]: Unmounting /mnt/backup-raid...
Jan 06 16:07:12 elicen kernel: buffer_io_error: 53 callbacks suppressed
Jan 06 16:07:12 elicen kernel: Buffer I/O error on dev sde1, logical block 488144896, lost sync page write
Jan 06 16:07:12 elicen kernel: JBD2: Error -5 detected when updating journal superblock for sde1-8.
Jan 06 16:07:12 elicen kernel: Aborting journal on device sde1-8.
Jan 06 16:07:12 elicen kernel: Buffer I/O error on dev sde1, logical block 488144896, lost sync page write
Jan 06 16:07:12 elicen kernel: JBD2: Error -5 detected when updating journal superblock for sde1-8.
Jan 06 16:07:12 elicen kernel: EXT4-fs error (device sde1): ext4_put_super:1194: comm umount: Couldn't clean up the journal
Jan 06 16:07:12 elicen kernel: EXT4-fs (sde1): Remounting filesystem read-only
Jan 06 16:07:12 elicen kernel: sd 9:0:0:0: [sde] Synchronizing SCSI cache
Jan 06 16:07:12 elicen systemd[1]: mnt-backup\x2draid.mount: Succeeded.
Jan 06 16:07:12 elicen systemd[1]: Unmounted /mnt/backup-raid.
Jan 06 16:07:12 elicen kernel: sd 9:0:0:0: [sde] Synchronize Cache(10) failed: Result: hostbyte=DID_ERROR driverbyte=DRIVER_OK
Jan 06 16:07:12 elicen kernel: usb 6-1: new SuperSpeed USB device number 15 using xhci_hcd
Jan 06 16:07:12 elicen kernel: usb 6-1: New USB device found, idVendor=174c, idProduct=55aa, bcdDevice= 1.00
Jan 06 16:07:12 elicen kernel: usb 6-1: New USB device strings: Mfr=2, Product=3, SerialNumber=1
Jan 06 16:07:12 elicen kernel: usb 6-1: Product: IB-RD3802-C31
Jan 06 16:07:12 elicen kernel: usb 6-1: Manufacturer: ICY BOX
Jan 06 16:07:12 elicen kernel: usb 6-1: SerialNumber: ---
Jan 06 16:07:12 elicen kernel: scsi host9: uas
Jan 06 16:07:12 elicen kernel: scsi 9:0:0:0: Direct-Access     IB-      RD3802-C31 RAID1 0    PQ: 0 ANSI: 6
Jan 06 16:07:12 elicen kernel: sd 9:0:0:0: Attached scsi generic sg4 type 0
Jan 06 16:07:12 elicen kernel: sd 9:0:0:0: [sde] 7813988353 512-byte logical blocks: (4.00 TB/3.64 TiB)
Jan 06 16:07:12 elicen kernel: sd 9:0:0:0: [sde] 4096-byte physical blocks
Jan 06 16:07:12 elicen kernel: sd 9:0:0:0: [sde] Write Protect is off
Jan 06 16:07:12 elicen kernel: sd 9:0:0:0: [sde] Mode Sense: 43 00 00 00
Jan 06 16:07:12 elicen kernel: sd 9:0:0:0: [sde] Write cache: enabled, read cache: enabled, doesn't support DPO or FUA
Jan 06 16:07:12 elicen kernel: sd 9:0:0:0: [sde] Optimal transfer size 33553920 bytes not a multiple of physical block size (4096 bytes)
Jan 06 16:07:13 elicen kernel:  sde: sde1
Jan 06 16:07:13 elicen kernel: sd 9:0:0:0: [sde] Attached SCSI disk

THX
 
Thx Fiona and excuse for my late reply.

i tried a new usb port, change from usb typ-c to type-a and stop the smartmontools service but i have the same problem.
That's unfortunate :(

I find this syslog entry today. Maybe somebody find the Problem in the output. Maybe the hourly cronjob initate the issue

Code:
Jan 06 14:17:01 elicen CRON[3355537]: pam_unix(cron:session): session opened for user root(uid=0) by (uid=0)
Jan 06 14:17:01 elicen CRON[3355538]: (root) CMD (   cd / && run-parts --report /etc/cron.hourly)
Jan 06 14:17:01 elicen CRON[3355537]: pam_unix(cron:session): session closed for user root
Jan 06 15:17:01 elicen CRON[3381743]: pam_unix(cron:session): session opened for user root(uid=0) by (uid=0)
Jan 06 15:17:01 elicen CRON[3381744]: (root) CMD (   cd / && run-parts --report /etc/cron.hourly)
Jan 06 15:17:01 elicen CRON[3381743]: pam_unix(cron:session): session closed for user root
Jan 06 16:07:11 elicen kernel: usb 6-1: USB disconnect, device number 14
The question is why does the disconnect happen? Does the device show the same behavior when connected to another machine? The cron job happens much earlier, so I'd guess it's not likely to be related.
 
That's unfortunate :(


The question is why does the disconnect happen? Does the device show the same behavior when connected to another machine? The cron job happens much earlier, so I'd guess it's not likely to be related.
Hey, thank you. You are right!
I wrote a script to check and remount the USB-Raid. It's not perfect but work fine for me now. Maybe someone else need something like this too. Maybe I have the time to find the problem in the future. ;-)

#!/bin/bash check_mnt() { logger -t BACKUP-RAID-CHECK "START CHECKING" if test -b /dev/sde1 ; then _blkid_sde=$(blkid -s UUID -o value /dev/sde1) _mntpnt_sde=$(findmnt -S /dev/sde1 | awk '{print $1}' | tail +2) if test "$_blkid_sde" == "46c61289-7e60-4059-80c4-9322cdddbd5f"; then if mountpoint -q /mnt/backup-raid ; then _mntpnt_br=$(findmnt -T /mnt/backup-raid | awk '{print $2}' | tail +2) if test "$_mntpnt_br" == "/dev/sde1" ; then logger -t BACKUP-RAID-CHECK "OK -> BACKUP-RAID ALREADY MOUNTED " else logger -t BACKUP-RAID-CHECK "FATAL-ERROR -> THE MOUNTPOINT /mnt/backup-raid HAS A WRONG SOURCE " fi else # CHECK IF SDE IS MOUNTED - IS $_mntpnt_sde A EMPTY STRING if test -z $_mntpnt_sde ;then logger -t BACKUP-RAID-CHECK "ERROR -> BACKUP-RAID NOT MOUNTED -> TRY TO MOUNT" mount /dev/sde1 /mnt/backup-raid check_mnt else logger -t BACKUP-RAID-CHECK "FATAL-ERROR -> BACKUP-RAID MOUNTED AT WRONG MOUNTPOINT" fi fi else logger -t BACKUP-RAID-CHECK "FATAL-ERROR -> THE DEVICE /dev/sde1 HAS WRONG BLKID $_blkid_sde " fi else logger -t BACKUP-RAID-CHECK "FATAL-ERROR -> USB-BACKUP-RAID IS NOT CONNECTED" fi } check_mnt


I know the code doesn't have much to do with clean code. :p
 
Last edited:

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!