[Solved] HDD high pitch noise on shutdown

Forum rules
Before you post read how to get help. Topics in this forum are automatically closed 6 months after creation.
Post Reply
DamianS555
Level 1
Level 1
Posts: 3
Joined: Mon Feb 19, 2024 4:41 am

[Solved] HDD high pitch noise on shutdown

Post by DamianS555 »

Hi,
My Toshiba HDD spins up just before the shutdown and during the power-off I hear a high pitch noise that I don't like very much.
I think this means my HDD will wear down much quicker than usually.
If I remember correctly, then that wasn't the case in previous versions of Linux Mint

I tried to create a systemd service, so it spins down my HDD (either with "hdparm -Y /dev/sdb" or "echo offline> /sys/block/sdb/device/state"), but that is not helping. Service is triggered, disk spins down, but then it spins up again just to produce the high pitch noise.

Is there anything that can be done to solve it ?

Here is the the output of Inxi:

Code: Select all

System:
  Host: damian-mint Kernel: 6.5.0-18-generic x86_64 bits: 64 compiler: N/A
    Desktop: Cinnamon 6.0.4 Distro: Linux Mint 21.3 Virginia
    base: Ubuntu 22.04 jammy
Machine:
  Type: Desktop Mobo: ASRock model: B450 Gaming-ITX/ac
    serial: <superuser required> UEFI: American Megatrends v: P4.50
    date: 05/11/2021
Battery:
  Device-1: hidpp_battery_0 model: Logitech M720 Triathlon Multi-Device Mouse
    charge: 55% (should be ignored) status: Discharging
CPU:
  Info: quad core model: AMD Ryzen 3 4300GE with Radeon Graphics bits: 64
    type: MT MCP arch: Zen 2 rev: 1 cache: L1: 256 KiB L2: 2 MiB L3: 4 MiB
  Speed (MHz): avg: 1443 high: 3536 min/max: 400/4112 cores: 1: 400 2: 400
    3: 2998 4: 400 5: 400 6: 3014 7: 400 8: 3536 bogomips: 56003
  Flags: avx avx2 ht lm nx pae sse sse2 sse3 sse4_1 sse4_2 sse4a ssse3 svm
Graphics:
  Device-1: AMD Renoir driver: amdgpu v: kernel bus-ID: 09:00.0
  Device-2: Sunplus Innovation Sandberg USB Webcam Pro type: USB
    driver: snd-usb-audio,uvcvideo bus-ID: 1-10.3:6
  Display: x11 server: X.Org v: 1.21.1.4 driver: X: loaded: amdgpu,ati
    unloaded: fbdev,modesetting,vesa gpu: amdgpu resolution: 1: 1920x1080~60Hz
    2: 1920x1080~60Hz
  OpenGL: renderer: RENOIR (renoir LLVM 15.0.7 DRM 3.54 6.5.0-18-generic)
    v: 4.6 Mesa 23.2.1-1ubuntu3.1~22.04.2 direct render: Yes
Network:
  Device-1: Intel Dual Band Wireless-AC 3168NGW [Stone Peak] driver: iwlwifi
    v: kernel bus-ID: 07:00.0
  IF: wlp7s0 state: down mac: 80:32:53:d7:72:06
  Device-2: Intel I211 Gigabit Network vendor: ASRock driver: igb v: kernel
    port: f000 bus-ID: 08:00.0
  IF: enp8s0 state: up speed: 1000 Mbps duplex: full mac: a8:a1:59:1d:ca:60
Drives:
  Local Storage: total: 1.04 TiB used: 828.73 GiB (78.0%)
  ID-1: /dev/sda vendor: Crucial model: CT500MX500SSD1 size: 465.76 GiB
  ID-2: /dev/sdb vendor: Toshiba model: MK6461GSY size: 596.17 GiB
Partition:
  ID-1: / size: 425.39 GiB used: 343.07 GiB (80.6%) fs: ext4 dev: /dev/sda2
  ID-2: /boot/efi size: 511 MiB used: 6.1 MiB (1.2%) fs: vfat
    dev: /dev/sda1
Info:
  Processes: 317 Uptime: 12m Memory: 14.99 GiB used: 2.46 GiB (16.4%)
  Init: systemd runlevel: 5 Compilers: gcc: 11.4.0 Packages: 3470 Shell: Bash
  v: 5.1.16 inxi: 3.3.13
  
=======================

Workaround
I think I found the workaround to the problem. Apparently kernel 6.5.0 has some buggy behavior according to https://bbs.archlinux.org/viewtopic.php?id=289848 and https://bugzilla.kernel.org/show_bug.cgi?id=218038
I have switched to 6.2 branch and the disk properly spins down before shutdown
Last edited by DamianS555 on Wed Feb 28, 2024 5:33 am, edited 1 time in total.
User avatar
Koentje
Level 7
Level 7
Posts: 1581
Joined: Tue Jan 04, 2022 6:23 pm
Location: Netherlands

Re: HDD high pitch noise on shutdown

Post by Koentje »

Have you tried to set the sleep timer in Disks?
Click on the disk, then on the hamburger menu and then Disk Settings. On the first tab you can set the sleep timer. Enabled it and set the time.
Schermafdruk van 2024-02-23 02-38-54.jpg
Image
DamianS555
Level 1
Level 1
Posts: 3
Joined: Mon Feb 19, 2024 4:41 am

Re: HDD high pitch noise on shutdown

Post by DamianS555 »

I did some testing, and found something very strange.
I am spinning down the disk with "sudo hdparm -Y /dev/sdb", however that makes the disk spin down, then usually almost immediately spin up, only the second "sudo hdparm -Y /dev/sdb" spins down the disk for good.
This makes me think that the "hdparm -Y" command does not spin down the disk properly, but in fact sends a "switch between active/standby" command.

See the output of 2 consecutive commands:

Code: Select all

damian@damian-mint:~$ sudo hdparm -Y /dev/sdb

/dev/sdb:
 issuing sleep command
damian@damian-mint:~$ sudo hdparm -C /dev/sdb

/dev/sdb:
 drive state is:  active/idle
I bet something similar happens during shutdown, so even if the system executes "hdparm -Y" the disk will most likely spin up :(
User avatar
Koentje
Level 7
Level 7
Posts: 1581
Joined: Tue Jan 04, 2022 6:23 pm
Location: Netherlands

Re: [Solved] HDD high pitch noise on shutdown

Post by Koentje »

I had the same problem with one of the drives in my NAS. Did not properly spin down, only after second time.

Solved it by replacing all with SSD's! 8)
Image
Post Reply

Return to “Storage”