Comments (10)
Hi @agcmartins
Could you please share the result of the command systemctl status hd-idle
?
Also I'd be great if you could double check that the directory /home/USER
(I guess obfuscated) really exists.
Thank you
from hd-idle.
Hi,
Directory exist, is my home folder, but I've change it to USER to post.
systemctl status hd-idle
β hd-idle.service - hd-idle - spin down idle hard disks
Loaded: loaded (/lib/systemd/system/hd-idle.service; enabled; vendor preset: enabled)
Active: active (running) since Tue 2020-03-31 23:47:30 -03; 11h ago
Docs: man:hd-idle(8)
Main PID: 371 (hd-idle)
Tasks: 10 (limit: 4915)
Memory: 4.2M
CGroup: /system.slice/hd-idle.service
ββ371 /usr/sbin/hd-idle -i 600 -l /home/USER/hd-idle.log
Mar 31 23:47:30 raspberrypi systemd[1]: Started hd-idle - spin down idle hard disks.
Mar 31 23:47:30 raspberrypi hd-idle[371]: symlinkPolicy=0, defaultIdle=600, defaultCommand=sc
Mar 31 23:59:57 raspberrypi hd-idle[371]: sda spindown
Apr 01 11:07:53 raspberrypi hd-idle[371]: sda spinup
from hd-idle.
Sadly the log doesn't show long lines :/
Could you run this command and post the result? grep hd-idle /var/log/syslog
from hd-idle.
Sure, but sorry, before I saw you message I had to reboot it.
I've also installed hd-idle in my desktop to test, but leave the log as default (/var/log/hd-idle.log), than after while I have checked the folder and there is no file there too.
Apr 1 11:07:53 raspberrypi hd-idle[371]: sda spinup
Apr 1 11:18:03 raspberrypi hd-idle[371]: sda spindown
Apr 1 11:57:42 raspberrypi hd-idle[371]: sda spinup
Apr 1 12:01:31 raspberrypi systemd[1]: Started hd-idle - spin down idle hard disks.
Apr 1 12:01:32 raspberrypi hd-idle[391]: symlinkPolicy=0, defaultIdle=600, defaultCommand=scsi, debug=false, logFile=/home/USER/hd-idle.log, devices=
Apr 1 12:23:05 raspberrypi hd-idle[391]: sda spindown
from hd-idle.
I can't tell why your log file is always empty. But not all is lost for you.
You can use grep hd-idle /var/log/syslog
to monitor spinups and spindowns. That will give you the stats you need.
This is a sample of how the log file looks like:
date: 2020-04-01, time: 00:00:34, disk: sda, running: 671, stopped: 42523
date: 2020-04-01, time: 00:00:34, disk: sdb, running: 609, stopped: 9638
date: 2020-04-01, time: 00:00:34, disk: sdc, running: 611, stopped: 9576
date: 2020-04-01, time: 12:00:25, disk: sdb, running: 671, stopped: 42519
date: 2020-04-01, time: 12:01:26, disk: sdc, running: 671, stopped: 42581
hd-idle
creates entries in the log file only on spinups. So I don't think it will be any useful for your use case to use the log file.
Hope this helps.
from hd-idle.
Thank you very much, I'll use that information. Do you have any advice about spin up events and hardware durability for external usb HD?
Regarding the log file, I've notice, that if I create an empty file using log name in directory, the program start to write lines on it. But it seems that if the file doesn't exit the program do not create it.
Best,
from hd-idle.
I had to re-test the scenario that you describe and I can confirm that the log file does get created if it doesn't previously exits.
Sorry that I can't help you further with this topic, but at least you got the data you were looking for.
Thank you
from hd-idle.
Hi all,
I know it's an old thread, but I also cannot see the log file despite the configuration file has been setup properly.
This is the result of: grep hd-idle /var/log/syslog
Jan 18 18:55:07 OPENMEDIAVAULT systemd[1]: Started hd-idle - spin down idle hard disks.
Jan 18 18:55:07 OPENMEDIAVAULT hd-idle[936]: symlinkPolicy=0, defaultIdle=0, defaultCommand=scsi, debug=false, logFile=/var/log/hd-idle.log, devices={name=sdf, givenName=/dev/disk/by-label/media1, idle=3600, commandType=scsi}{name=sdh, givenName=/dev/disk/by-label/media2, idle=3600, commandType=scsi}{name=sde, givenName=/dev/disk/by-label/media3, idle=3600, commandType=scsi}{name=sdb, givenName=/dev/disk/by-label/media4, idle=3600, commandType=scsi}{name=sdg, givenName=/dev/disk/by-label/backup1, idle=3600, commandType=scsi}{name=sdd, givenName=/dev/disk/by-label/downloads, idle=3600, commandType=scsi}{name=sdc, givenName=/dev/disk/by-label/rootdata2, idle=3600, commandType=scsi}
no log file:
user@OPENMEDIAVAULT:~$ cat /var/log/hd-idle.log
cat: /var/log/hd-idle.log: No such file or directory
hd-idle configuration file:
START_HD_IDLE=true
HD_IDLE_OPTS="-i 0 -l /var/log/hd-idle.log -a /dev/disk/by-label/media1 -i 3600 -a /dev/disk/by-label/media2 -i 3600 -a /dev/disk/by-label/media3 -i 3600 -a /dev/disk/by-label/media4 -i 3600 -a /dev/disk/by-label/backup1 -i 3600 -a /dev/disk/by-label/downloads -i 3600 -a /dev/disk/by-label/rootdata2 -i 3600"
Anything I can do to help you track down the issue?
from hd-idle.
Have you seen my reply to #63?
from hd-idle.
All right.
I understand now.
Thanks for your quick reply.
from hd-idle.
Related Issues (20)
- Question. Don't start HDD after suspend and sleep HDD on standby HOT 1
- HDD in external bay not detected anymore HOT 3
- Question / Clarification: How does hd-idle parse options (disks vs. partitions, LUKS, precedence in case of contradictions) HOT 1
- Help understanding how to use the -p power_condition flag for SAS drives HOT 15
- WD Re HDD over USB does not spin down. HOT 23
- Can't spin down my internal WD Blue HDD HOT 5
- HD-Idle command does not seem to get set? HOT 4
- Drive standby instead of sleep. HOT 2
- Logfile won't be generate dataγ HOT 5
- Hook-function to be called after spinning down HOT 2
- Spin up not recognized HOT 2
- Disk spin down not working after scheduled S.M.A.R.T test
- hd-idle task gets out of sync with real disk spindown HOT 5
- logfile hard to read - how can we have spindown/spinup log entries? HOT 1
- Deprecated Key? HOT 2
- Raspberry Pi Install Issues & Running Issues HOT 9
- Feature: Flag for script after spin up HOT 4
- Possible to spin-down based on Schedule? HOT 3
- Logfile won't be created HOT 4
- Nothing after hd-idle command HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
π Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. πππ
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google β€οΈ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from hd-idle.