Parkverbot how to use

Hey there
I’m using Leap and enjoying the slower pace of things I’m having one thing that I cannot figure out _ ATM , could be old age brain fog, seems there is not much info about parkverbot I’ve installed it and need assist to get the fine details sorted out for it to work, I always thought it was Dolphin, yes on KDE desktop dolphin was slow to read the external hard-drives, two for data (one = music the other = paperwork) plus one for backup, looks as if the (3) three ext HDs go into a heads off rest mode, might be fine for the Ext HDs me I forget what I’m waiting for to open, is anyone using Parkverbot and if so what steps were use to getting it working. Any help would be very welcome.
Thanks Noel

As far as I know it should “just work”…

What makes you think it’s not, have you monitored the SMART attribute “Load_Cycle_Count” to see if the rate of increment decreases when parkverbot is active?

However… it seems there is indeed a problem. I was only able to try on one machine as it’s the only one which still has an HDD

It’s failing to start at boot.

paul@Orion-15:~$ sudo systemctl status parkverbot
× parkverbot.service - Hard disk head parking inhibitor
     Loaded: loaded (/usr/lib/systemd/system/parkverbot.service; enabled; vendor preset: disabled)
     Active: failed (Result: resources)
        CPU: 0

Nov 13 14:26:45 Orion-15 systemd[1]: parkverbot.service: Failed to load environment files: No such file or directory
Nov 13 14:26:45 Orion-15 systemd[1]: parkverbot.service: Failed to run 'start' task: No such file or directory
Nov 13 14:26:45 Orion-15 systemd[1]: parkverbot.service: Failed with result 'resources'.
Nov 13 14:26:45 Orion-15 systemd[1]: Failed to start Hard disk head parking inhibitor.
paul@Orion-15:~$

I would suggest you create a bug report: https://bugzilla.opensuse.org (same login credentials as the forum).

Thanks for the reply Paul
When I look into the Yaste Control Center > Services manager > parkverbot - on boot - Failed (Failed)
Is there cli routine to start the service
Thanks
Noel

edit
this could be wrong But it looks like nobody is doing any work on parkverbot since 2017 that can’t be correct ?
looking bit deeper does parkverbot need a location somewhere in config from my system (that’s where I think the problem is) to get the Ext HD connected and functioning correctly ?
Yeah I know two questions at once, are all yours SSDs,

sudo systemctl start parkverbot

… but when I tried manually starting, it still failed. As I said, I think a bug report is probably in order.

OK looks that 's the road to take, Thanks for the advice.

I replied before I saw your edit…

Looks like it’s still maintained at the moment, but perhaps only to the extent that it still builds.

I don’t think it’s your configuration as if that was the case it would (should) have worked on my system. I’m leaning towards it being a bug, but could be wrong.

Yes, all but one of my systems use SSDs, I tested on my only HDD system, which runs Tumbleweed, I’m unable to test on a 15.3 system.

Thanks for your time, appreciated.

If you start it with

sudo systemctl start parkverbot

you must set the variable PARKVERBOT_DISKS in file /etc/sysconfig/parkverbot. This file is not included in the leap 15.3 rpm.
As an alternative you could start/enable it e.g for disk /dev/sda


sudo systemctl enable parkverbot@dev-sda 
sudo systemctl start parkverbot@dev-sda
sudo systemctl status parkverbot@dev-sda 
 
parkverbot@dev-sda.service - Run parkverbot daemon on dev/sda 
     Loaded: loaded (/usr/lib/systemd/system/parkverbot@.service; enabled; vendor preset: disabled) 
     Active: **active (running)** since Sat 2021-11-13 16:49:50 CET; 17min ago 
   Main PID: 24622 (parkverbot) 
      Tasks: 1 (limit: 4915) 
     CGroup: /system.slice/system-parkverbot.slice/parkverbot@dev-sda.service 
             └─24622 /usr/sbin/parkverbot /dev/sda

 

My mindset is not 100% so after a nap much later on and I will seriously look at and do what you said to do and do that for my sdb, sdc, and sdd , I will do that just got to get focused on this parkverbot issue, after a break I should be able to follow your suggestion , I’m just edging into this never gone this deep so gimme a day to digest and apply, even if I get it stuffed up I’ll mention what I did and maybe that can help someone else also, maybe in hindsight I should have posted this not tonight, please don’t let this (me) put your nose out of joint, just chill and gimme a day please, Thanks…

sudo systemctl enable parkverbot@dev-sda
sudo systemctl start parkverbot@dev-sda
sudo systemctl status parkverbot@dev-sda

got similar to yours and did give a positive result then did sdb,sdc and sdd each time loaded active etc same as you, and then

parkverbot@dev-sda.service - Run parkverbot daemon on dev/sda
Loaded: loaded (/usr/lib/systemd/system/parkverbot@.service; enabled; vendor preset: disabled)
Active: active (running) since Sat 2021-11-13 16:49:50 CET; 17min ago
Main PID: 24622 (parkverbot)
Tasks: 1 (limit: 4915)
CGroup: /system.slice/system-parkverbot.slice/parkverbot@dev-sda.service
└─24622 /usr/sbin/parkverbot /dev/sda

this
checked Yast Services Manager seems it’s fail to start on bootup tried again three times still a fail

Looks like it’s still maintained at the moment, but perhaps only to the extent that it still builds.
I did/was going to put the links in but something went wrong on reboot and lost all my connect to web access had to use this morning snapshot ‘PHEW’
I don’t think it’s your configuration as if that was the case it would (should) have worked on my system. I’m leaning towards it being a bug, but could be wrong.

I looked at the Parkverbot site seems quiet maybe I tend to agree with @tannington thoughts that it still builds and not much more, it’s a good concept in theory, not bothered by this mostly because the harddrives are getting old and the prospect of an all ssd system for the new year might well be the gift I give to me, yeah.
For the

As an alternative you could start/enable it e.g for disk /dev/sda
Code:

Thanks rawar and tannington for your help

I suspect you forgot to create the file specifying which hard drive parkverbot should act on.

First list the drives:

sudo fdisk -l
paul@Orion-15:~$ sudo fdisk -l
[sudo] password for root: 

snip

Disk /dev/sdc: 232.88 GiB, 250058268160 bytes, 488395055 sectors
Disk model: WDC WD2500AAKS-2
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: dos
Disk identifier: 0x000b10c8

Device     Boot     Start       End   Sectors  Size Id Type
/dev/sdc1  *         2048  67102719  67100672   32G 83 Linux
/dev/sdc2        67102720 469755903 402653184  192G 83 Linux
/dev/sdc3       469755904 488394751  18638848  8.9G 82 Linux swap / Solaris

snip 

paul@Orion-15:~$

On my own machine the drive is dev/sdc and this will be used in the following instructions - replace sdc with your own drive identifier.

Now create a file named parkverbot in /etc/sysconfig with the following content:

PARKVERBOT_DISKS=“dev/sdc”

and save the file.

Now enable the service:

sudo systemctl enable parkverbot

you should then see:

Created symlink /etc/systemd/system/basic.target.wants/parkverbot.service → /usr/lib/systemd/system/parkverbot.service.
paul@Orion-15:~$

Now start the service to ensure it starts OK.

sudo systemctl start parkverbot

Check with:

sudo systemctl status parkverbot
paul@Orion-15:~$ sudo systemctl status parkverbot
● parkverbot.service - Hard disk head parking inhibitor
     Loaded: loaded (/usr/lib/systemd/system/parkverbot.service; enabled; vendor preset: disabled)
     Active: active (running) since Mon 2021-11-15 10:05:36 GMT; 9s ago
   Main PID: 3165 (parkverbot)
      Tasks: 1 (limit: 4596)
        CPU: 100ms
     CGroup: /system.slice/parkverbot.service
             └─3165 /usr/sbin/parkverbot dev/sdc

Nov 15 10:05:36 Orion-15.openSUSE systemd[1]: Started Hard disk head parking inhibitor.
paul@Orion-15:~$

If all is OK reboot and parkverbot should be started on boot:

paul@Orion-15:~$ sudo systemctl status parkverbot
[sudo] password for root: 
● parkverbot.service - Hard disk head parking inhibitor
     Loaded: loaded (/usr/lib/systemd/system/parkverbot.service; enabled; vendor preset: disabled)
     Active: active (running) since Mon 2021-11-15 10:08:17 GMT; 1min 4s ago
   Main PID: 628 (parkverbot)
      Tasks: 1 (limit: 4596)
        CPU: 61ms
     CGroup: /system.slice/parkverbot.service
             └─628 /usr/sbin/parkverbot dev/sdc

Nov 15 10:08:17 Orion-15 systemd[1]: Started Hard disk head parking inhibitor.
paul@Orion-15:~$

Or… you could treat yourself to a nice new SSD :slight_smile:

Thanks for the updated info, ATM trying very hard to catch up with some other projects if I could squeeze 30 Hrs out of a day that might help a little just enough, now back on topic and should good to go and try your instructions in a few days ( happens to everyone at times running out of time,:confused: ), very thankful for your help, I will give this Parkverbot another try with your guide, Be good if it works then others can share the fun.

or

Buy some nice super fast SSDs, umm end of year sales.
Oh yeah slightly off topic but what would you use on an external SSD to clean them up – is sudo fstrim / -v correct, personally I’ve only ever had SSD on/in the tower used for the operating system so more new territory.

Thanks
Noel

Edit_ I re read your guide and there is a couple of steps I omitted so I’m looking forward to try this asap :disapointed: In a few days :good: …

On Leap 15.3 fstrim is triggered by a systemd timer, rather than being ran manually or via a cron job.

It should already be enabled, to check list the timers:

sudo systemctl list-timers

For example: (here it’s the last timer listed)

paul@Orion-17:~> sudo systemctl list-timers
[sudo] password for root:
NEXT                        LEFT        LAST                        PASSED       UNIT                         ACTIVATES                    
Wed 2021-11-17 00:00:00 GMT 14h left    Tue 2021-11-16 07:50:23 GMT 1h 47min ago logrotate.timer              logrotate.service            
Wed 2021-11-17 00:00:00 GMT 14h left    Tue 2021-11-16 07:50:23 GMT 1h 47min ago mandb.timer                  mandb.service                
Wed 2021-11-17 00:43:25 GMT 15h left    Tue 2021-11-16 09:05:19 GMT 32min ago    check-battery.timer          check-battery.service        
Wed 2021-11-17 01:28:24 GMT 15h left    Tue 2021-11-16 09:33:19 GMT 4min 28s ago backup-sysconfig.timer       backup-sysconfig.service      
Wed 2021-11-17 01:58:37 GMT 16h left    Tue 2021-11-16 09:20:33 GMT 17min ago    backup-rpmdb.timer           backup-rpmdb.service          
Wed 2021-11-17 09:00:19 GMT 23h left    Tue 2021-11-16 09:00:19 GMT 37min ago    systemd-tmpfiles-clean.timer systemd-tmpfiles-clean.service
Mon 2021-11-22 00:48:18 GMT 5 days left Mon 2021-11-15 09:12:45 GMT 24h ago      fstrim.timer                 fstrim.service                

7 timers listed.
Pass --all to see loaded but inactive timers, too.
paul@Orion-17:~>

If for some reason it’s not listed you can enable it with:

sudo systemctl enable fstrim.timer

By default when the service runs it will trim all drives that are listed in fstab.

If you want it to trim all mounted drives, not just those in fstab, then you’ll need to edit the ExecStart line of it’s service file from the default:

ExecStart=/usr/sbin/fstrim --listed-in /etc/fstab:/proc/self/mountinfo --verbose --quiet-unsupported

to

ExecStart=/usr/sbin/fstrim --all --verbose --quiet-unsupported

You shouldn’t directly edit the unit files, use the command:

sudo systemctl edit fstrim.service

After the service has been triggered by the timer you can see it’s status with:

sudo systemctl status fstrim.service

https://inai.de/projects/parkverbot/

https://www.gravatar.com/avatar/5b748275c3dbb1ceee18ed554486547d?s=20&d=robohash Jan Engelhardt (jengelh)committed about 1 month ago (revision 23) - Drop harden_parkverbot.service.patch (merged upstream)

Version 1.4 is available for TW, for Leap - 1.3 with Experimental repos: openSUSE Software
AFAIU supplied and maintained by developer.

So what ya talking bout…

Or… you could treat yourself to a nice new SSD

It seems time does fly either too busy or too old to notice and December nearly here, mid next week (so soon) new SSD ordering up later after posting this, @tannington appreciate your time and the guides, help in these pages, pages bookmarked future references for HDD and SSD in case someone I know of needs help.

Thanks Heaps Paul
:slight_smile:
Noel