Eject External Hard Drive option gone

Hello, it used to be that you could command ‘eject’ your external hard drive (usb drive), that option doesn’t appear to be available anymore?

It’s handy because it does the ‘umount’ and then ‘eject’ at the same time and it turns off the device completely, until reboot or physical replug USB device.

Linux 5.4.108-1-MANJARO (x86_64)

Any ideas?

Thanks!

We need some more info…

1 Like

My apologies.

This is my inxi output:

System:
  Kernel: 5.4.108-1-MANJARO x86_64 bits: 64 compiler: gcc v: 10.2.0 
  parameters: BOOT_IMAGE=/boot/vmlinuz-5.4-x86_64 
  root=UUID=fec8603e-392b-4ab6-9e05-1be859d00151 rw quiet apparmor=1 
  security=apparmor udev.log_priority=3 
  Desktop: Xfce 4.16.0 tk: Gtk 3.24.24 info: xfce4-panel wm: Compiz 0.8.18 
  vt: 7 dm: LightDM 1.30.0 Distro: Manjaro Linux base: Arch Linux 
Machine:
  Type: Laptop System: ASUSTeK product: VivoBook S14 X430UA v: 1.0 
  serial: <filter> 
  Mobo: ASUSTeK model: X430UA v: 1.0 serial: <filter> 
  UEFI: American Megatrends v: X430UA.304 date: 05/22/2019 
Battery:
  ID-1: BAT0 charge: 34.1 Wh (96.9%) condition: 35.2/42.0 Wh (83.7%) 
  volts: 11.8 min: 11.8 model: ASUSTeK ASUS Battery type: Li-ion serial: N/A 
  status: Charging cycles: 171 
Memory:
  RAM: total: 7.66 GiB used: 2.55 GiB (33.3%) 
  RAM Report: permissions: Unable to run dmidecode. Root privileges required. 
CPU:
  Info: Quad Core model: Intel Core i5-8250U bits: 64 type: MT MCP 
  arch: Kaby Lake note: check family: 6 model-id: 8E (142) stepping: A (10) 
  microcode: E0 cache: L2: 6 MiB bogomips: 28808 
  Speed: 800 MHz min/max: 400/3400 MHz Core speeds (MHz): 1: 800 2: 800 3: 800 
  4: 800 5: 800 6: 800 7: 800 8: 800 
  Flags: 3dnowprefetch abm acpi adx aes aperfmperf apic arat arch_perfmon art 
  avx avx2 bmi1 bmi2 bts clflush clflushopt cmov constant_tsc cpuid 
  cpuid_fault cx16 cx8 de ds_cpl dtes64 dtherm dts epb ept ept_ad erms est 
  f16c flexpriority flush_l1d fma fpu fsgsbase fxsr ht hwp hwp_act_window 
  hwp_epp hwp_notify ibpb ibrs ida intel_pt invpcid invpcid_single lahf_lm lm 
  mca mce md_clear mmx monitor movbe mpx msr mtrr nonstop_tsc nopl nx pae pat 
  pbe pcid pclmulqdq pdcm pdpe1gb pebs pge pln pni popcnt pse pse36 pti pts 
  rdrand rdseed rdtscp rep_good sdbg sep smap smep ss ssbd sse sse2 sse4_1 
  sse4_2 ssse3 stibp syscall tm tm2 tpr_shadow tsc tsc_adjust 
  tsc_deadline_timer vme vmx vnmi vpid x2apic xgetbv1 xsave xsavec xsaveopt 
  xsaves xtopology xtpr 
  Vulnerabilities: Type: itlb_multihit status: KVM: Split huge pages 
  Type: l1tf 
  mitigation: PTE Inversion; VMX: conditional cache flushes, SMT vulnerable 
  Type: mds mitigation: Clear CPU buffers; SMT vulnerable 
  Type: meltdown mitigation: PTI 
  Type: spec_store_bypass 
  mitigation: Speculative Store Bypass disabled via prctl and seccomp 
  Type: spectre_v1 
  mitigation: usercopy/swapgs barriers and __user pointer sanitization 
  Type: spectre_v2 mitigation: Full generic retpoline, IBPB: conditional, 
  IBRS_FW, STIBP: conditional, RSB filling 
  Type: srbds mitigation: Microcode 
  Type: tsx_async_abort status: Not affected 
Graphics:
  Device-1: Intel UHD Graphics 620 vendor: ASUSTeK driver: i915 v: kernel 
  bus-ID: 00:02.0 chip-ID: 8086:5917 class-ID: 0300 
  Device-2: IMC Networks USB2.0 HD UVC WebCam type: USB driver: uvcvideo 
  bus-ID: 1-6:4 chip-ID: 13d3:56c1 class-ID: 0e02 serial: <filter> 
  Display: x11 server: X.Org 1.20.10 compositor: compiz v: 0.8.18 driver: 
  loaded: modesetting unloaded: intel alternate: fbdev,vesa display-ID: :0.0 
  screens: 1 
  Screen-1: 0 s-res: 1920x1080 s-dpi: 96 s-size: 508x285mm (20.0x11.2") 
  s-diag: 582mm (22.9") 
  Monitor-1: eDP-1 res: 1920x1080 hz: 60 dpi: 158 size: 309x174mm (12.2x6.9") 
  diag: 355mm (14") 
  OpenGL: renderer: Mesa Intel UHD Graphics 620 (KBL GT2) v: 4.6 Mesa 21.0.1 
  direct render: Yes 
Audio:
  Device-1: Intel Sunrise Point-LP HD Audio vendor: ASUSTeK 
  driver: snd_hda_intel v: kernel alternate: snd_soc_skl bus-ID: 00:1f.3 
  chip-ID: 8086:9d71 class-ID: 0403 
  Sound Server-1: ALSA v: k5.4.108-1-MANJARO running: yes 
  Sound Server-2: JACK v: 0.125.0 running: no 
  Sound Server-3: PulseAudio v: 14.2 running: yes 
  Sound Server-4: PipeWire v: 0.3.24 running: no 
Network:
  Device-1: Realtek RTL8822BE 802.11a/b/g/n/ac WiFi adapter vendor: AzureWave 
  driver: rtw_pci v: N/A modules: rtwpci port: e000 bus-ID: 02:00.0 
  chip-ID: 10ec:b822 class-ID: 0280 
  IF: wlp2s0 state: down mac: <filter> 
  Device-2: Realtek RTL8153 Gigabit Ethernet Adapter type: USB driver: r8152 
  bus-ID: 2-2:2 chip-ID: 0bda:8153 class-ID: 0000 serial: <filter> 
  IF: enp0s20f0u2 state: up speed: 100 Mbps duplex: full mac: <filter> 
  IP v4: <filter> type: dynamic noprefixroute scope: global 
  broadcast: <filter> 
  IP v6: <filter> type: noprefixroute scope: link 
  WAN IP: <filter> 
Bluetooth:
  Device-1: IMC Networks Bluetooth Radio type: USB driver: btusb v: 0.8 
  bus-ID: 1-8:5 chip-ID: 13d3:3526 class-ID: e001 serial: <filter> 
  Report: This feature requires one of these tools: hciconfig/bt-adapter 
Logical:
  Message: No LVM data was found. 
RAID:
  Hardware-1: Intel 82801 Mobile SATA Controller [RAID mode] driver: ahci 
  v: 3.0 port: f060 bus-ID: 00:17.0 chip-ID: 8086.282a rev: 21 class-ID: 0104 
Drives:
  Local Storage: total: 5.69 TiB used: 200.24 GiB (3.4%) 
  SMART Message: Required tool smartctl not installed. Check --recommends 
  ID-1: /dev/sda maj-min: 8:0 vendor: Micron model: 1100 MTFDDAV256TBN 
  size: 238.47 GiB block-size: physical: 512 B logical: 512 B speed: 6.0 Gb/s 
  rotation: SSD serial: <filter> rev: A031 scheme: GPT 
  ID-2: /dev/sdb maj-min: 8:16 type: USB vendor: Seagate model: One Touch HDD 
  size: 4.55 TiB block-size: physical: 4096 B logical: 512 B serial: <filter> 
  rev: 1707 scheme: GPT 
  ID-3: /dev/sdc maj-min: 8:32 type: USB vendor: Seagate 
  model: ST1000LM024 HN-M101MBB size: 931.51 GiB block-size: physical: 512 B 
  logical: 512 B rotation: 5400 rpm serial: <filter> rev: 0608 scheme: MBR 
  Message: No Optical or Floppy data was found. 
Partition:
  ID-1: / raw-size: 238.17 GiB size: 233.43 GiB (98.01%) 
  used: 200.24 GiB (85.8%) fs: ext4 dev: /dev/sda2 maj-min: 8:2 label: N/A 
  uuid: fec8603e-392b-4ab6-9e05-1be859d00151 
  ID-2: /boot/efi raw-size: 300 MiB size: 299.4 MiB (99.80%) 
  used: 280 KiB (0.1%) fs: vfat dev: /dev/sda1 maj-min: 8:1 label: N/A 
  uuid: DFF3-807C 
Swap:
  Alert: No Swap data was found. 
Unmounted:
  ID-1: /dev/sdb1 maj-min: 8:17 size: 200 MiB fs: vfat label: EFI 
  uuid: 67E3-17ED 
  ID-2: /dev/sdb2 maj-min: 8:18 size: 4.55 TiB fs: ext4 label: backup1 
  uuid: 3d8a68ce-6c85-447d-9eaa-9f0fdc7f1b18 
  ID-3: /dev/sdc1 maj-min: 8:33 size: 931.51 GiB fs: ntfs 
  label: Seagate Expansion Drive uuid: EC623E11623DE14E 
USB:
  Hub-1: 1-0:1 info: Full speed (or root) Hub ports: 12 rev: 2.0 
  speed: 480 Mb/s chip-ID: 1d6b:0002 class-ID: 0900 
  Device-1: 1-3:2 
  info: Seagate RSS LLC USB 3.0 bridge [Portable Expansion Drive] 
  type: Mass Storage driver: usb-storage interfaces: 1 rev: 2.1 
  speed: 480 Mb/s power: 100mA chip-ID: 0bc2:2320 class-ID: 0806 
  serial: <filter> 
  Device-2: 1-4:3 info: Seagate RSS LLC One Touch HDD type: Mass Storage 
  driver: uas interfaces: 1 rev: 2.1 speed: 480 Mb/s power: 500mA 
  chip-ID: 0bc2:ab65 class-ID: 0806 serial: <filter> 
  Device-3: 1-6:4 info: IMC Networks USB2.0 HD UVC WebCam type: Video 
  driver: uvcvideo interfaces: 2 rev: 2.0 speed: 480 Mb/s power: 500mA 
  chip-ID: 13d3:56c1 class-ID: 0e02 serial: <filter> 
  Device-4: 1-8:5 info: IMC Networks Bluetooth Radio type: Bluetooth 
  driver: btusb interfaces: 2 rev: 1.1 speed: 12 Mb/s power: 500mA 
  chip-ID: 13d3:3526 class-ID: e001 serial: <filter> 
  Hub-2: 2-0:1 info: Full speed (or root) Hub ports: 6 rev: 3.0 speed: 5 Gb/s 
  chip-ID: 1d6b:0003 class-ID: 0900 
  Device-1: 2-2:2 info: Realtek RTL8153 Gigabit Ethernet Adapter type: Network 
  driver: r8152 interfaces: 1 rev: 3.0 speed: 5 Gb/s power: 288mA 
  chip-ID: 0bda:8153 class-ID: 0000 serial: <filter> 
Sensors:
  System Temperatures: cpu: 52.0 C mobo: N/A 
  Fan Speeds (RPM): cpu: 2000 
Info:
  Processes: 275 Uptime: 1m wakeups: 3 Init: systemd v: 247 tool: systemctl 
  Compilers: gcc: 10.2.0 alt: 9 clang: 11.1.0 Packages: 1524 pacman: 1498 
  lib: 446 flatpak: 15 snap: 11 Shell: Bash v: 5.1.0 
  running-in: xfce4-terminal inxi: 3.3.03 

This is my dmesg output:

[    0.283674] usbcore: registered new interface driver usbfs
[    0.283674] usbcore: registered new interface driver hub
[    0.283674] usbcore: registered new device driver usb
[    0.446116] usbcore: registered new interface driver usbserial_generic
[    0.446119] usbserial: USB Serial support registered for generic
[    0.676483] usb usb1: New USB device found, idVendor=1d6b, idProduct=0002, bcdDevice= 5.04
[    0.676485] usb usb1: New USB device strings: Mfr=3, Product=2, SerialNumber=1
[    0.676487] usb usb1: Product: xHCI Host Controller
[    0.676488] usb usb1: Manufacturer: Linux 5.4.108-1-MANJARO xhci-hcd
[    0.676489] usb usb1: SerialNumber: 0000:00:14.0
[    0.677787] usb usb2: New USB device found, idVendor=1d6b, idProduct=0003, bcdDevice= 5.04
[    0.677789] usb usb2: New USB device strings: Mfr=3, Product=2, SerialNumber=1
[    0.677790] usb usb2: Product: xHCI Host Controller
[    0.677791] usb usb2: Manufacturer: Linux 5.4.108-1-MANJARO xhci-hcd
[    0.677792] usb usb2: SerialNumber: 0000:00:14.0
[    0.678169] usb: port power management may be unreliable
[    1.008995] usb 1-3: new high-speed USB device number 2 using xhci_hcd
[    1.150032] usb 1-3: New USB device found, idVendor=0bc2, idProduct=2320, bcdDevice= 1.00
[    1.150034] usb 1-3: New USB device strings: Mfr=2, Product=3, SerialNumber=1
[    1.150035] usb 1-3: Product: Expansion
[    1.150036] usb 1-3: Manufacturer: Seagate
[    1.150037] usb 1-3: SerialNumber: NA45PWPH
[    1.153289] usb-storage 1-3:1.0: USB Mass Storage device detected
[    1.153347] scsi host3: usb-storage 1-3:1.0
[    1.153400] usbcore: registered new interface driver usb-storage
[    1.154371] usbcore: registered new interface driver uas
[    1.268645] usb 2-2: new SuperSpeed Gen 1 USB device number 2 using xhci_hcd
[    1.286725] usb 2-2: New USB device found, idVendor=0bda, idProduct=8153, bcdDevice=30.00
[    1.286730] usb 2-2: New USB device strings: Mfr=1, Product=2, SerialNumber=6
[    1.286733] usb 2-2: Product: USB 10/100/1000 LAN
[    1.286736] usb 2-2: Manufacturer: Realtek
[    1.286739] usb 2-2: SerialNumber: 000001
[    1.408487] usb 1-4: new high-speed USB device number 3 using xhci_hcd
[    1.606454] usb 1-4: New USB device found, idVendor=0bc2, idProduct=ab65, bcdDevice=17.07
[    1.606458] usb 1-4: New USB device strings: Mfr=1, Product=2, SerialNumber=3
[    1.606461] usb 1-4: Product: One Touch HDD
[    1.606463] usb 1-4: Manufacturer: Seagate
[    1.606464] usb 1-4: SerialNumber: 00000000NABN43P0
[    1.731729] usb 1-6: new high-speed USB device number 4 using xhci_hcd
[    1.895708] usb 1-6: New USB device found, idVendor=13d3, idProduct=56c1, bcdDevice=18.52
[    1.895710] usb 1-6: New USB device strings: Mfr=3, Product=1, SerialNumber=2
[    1.895712] usb 1-6: Product: USB2.0 HD UVC WebCam
[    1.895713] usb 1-6: Manufacturer: Azurewave
[    1.895714] usb 1-6: SerialNumber: 0x0001
[    2.018411] usb 1-8: new full-speed USB device number 5 using xhci_hcd
[    2.159171] usb 1-8: New USB device found, idVendor=13d3, idProduct=3526, bcdDevice= 1.10
[    2.159173] usb 1-8: New USB device strings: Mfr=1, Product=2, SerialNumber=3
[    2.159175] usb 1-8: Product: Bluetooth Radio 
[    2.159176] usb 1-8: Manufacturer: Realtek 
[    2.159177] usb 1-8: SerialNumber: 00e04c000001
[    3.005273] input: USB2.0 HD UVC WebCam: USB2.0 HD as /devices/pci0000:00/0000:00:14.0/usb1/1-6/1-6:1.0/input/input19
[    3.005395] usbcore: registered new interface driver uvcvideo
[    4.332597] usbcore: registered new interface driver r8152
[    4.355039] usbcore: registered new interface driver cdc_ether
[    4.402559] usbcore: registered new interface driver btusb
[    4.455476] usb 2-2: reset SuperSpeed Gen 1 USB device number 2 using xhci_hcd

Wanted to add the journalctl, but I was limited by the amount of characters allowed in the post. Is there a way around that?

Thanks!

If I execute the commands below in the terminal, I see that the eject command is in the PATH (echo $PATH) and is provided by the package util-linux. It isn’t clear to me in your text if you are executing the command eject or if you are perhaps selecting “eject” in a GUI, maybe Thunar.

type -a eject
pacman -Fx /bin/eject

I’m a bit newby, so I don’t follow what you are thinking.

This is the thing, from Thunar, the option to eject, shows up sometimes, and sometimes it doesn’t.

When it does show up, from Thunar I click eject, and it will unmount, and then eject.
When it does show up, from Terminal:

[user@user ~]$ sudo eject /run/media/user/Elements
eject: unable to eject

When the option to eject is not available in Thunar, I simply unmount, and then disconnect it physically.

So why does it show the option to eject sometimes? Why can’t I eject from command?

Any thoughts?

Thanks for you help!

In Thunar, the eject icon appears in every mounted drive

If sometimes it doesn’t. kill thunar, and open again. (this happens to me, I just close thunar and reopen)

eject will work, but will not really “finish the job” regarding USB rotating drives.

The best way to unplug a USB external hard-drive, after proper unmounting, is:

udisksctl power-off -b /dev/sdX

or

udisks --detach /dev/sdX

This usually causes the drive to spin down gracefully.

Note: udisksctl might be a more “mainstream” tool, compared to udisks (the former is already installed on my Debian, the latter isn’t).

1 Like

Is there a GUI plugin/app which does this? It would be convenient.

Thunar or gnome-disks

Install with, pacman -S gnome-disk-utility

This would be useful!