No idea how this occurred, I don’t personally work with “/usr/local”. All I did was a update like I always have done and this time I noticed the error message.
Thanks for that explanation. Next time you want to ask something about this (or any other commands) output, please show those commands and their complete output by copy/paste in the post (using preformatted text: Posting code or preformatted text - Using Discourse - Discourse Meta ). Thus people here can see what you did and what you got. Never assume they can look over your shoulder or can read your mind. And yes, because we can not know what your alas does, you have to revert back to the real commands in such a case.
But again, back to your problem. My advice, do such a test, because it is very strange that /usr/local changed owner.
I still wonder how this error is triggered. The error message is from systemd (it is very deep in the common systemd library), but for the life of me I do not see why systemd would be interested in /usr/local/man path.
I tried changing /usr/local ownership and installing kvm_stat, but no errors. There must be some additional conditions.
I do not know why this product, apparently going to be installed in a “system place” (/usr/local/...) does set ownership to “some” user (isn’t it installed by root ?).
Ollama is Meta’s AI agent service, it allows you to download and run an AI model locally in the terminal.
Their install script is run like: (I can’t remember if it ask me for root permission?). Guess is yes since /usr/local is owned by root.
curl -fsSL https://ollama.com/install.sh | sh
ollama service
$ systemctl status ollama.service
â—Ź ollama.service - Ollama Service
Loaded: loaded (/etc/systemd/system/ollama.service; enabled; preset: disabled)
Active: active (running) since Thu 2024-09-12 19:24:43 EDT; 9h ago
Invocation: bd098307122d403695761c4970aa5c5f
Main PID: 3563 (ollama)
Tasks: 27 (limit: 76904)
CPU: 13.973s
CGroup: /system.slice/ollama.service
└─3563 /usr/local/bin/ollama serve
Warning: some journal files were not opened due to insufficient permissions.
So I did change owner of /usr/local to “root root” and then tried to force install kvm_stat and didn’t see the script error.
$ sudo zypper in -f kvm_stat
Refreshing service 'NVIDIA'.
Refreshing service 'openSUSE'.
Loading repository data...
Reading installed packages...
Forcing installation of 'kvm_stat-6.10.9-23.28.noarch' from repository 'repo-oss'.
Resolving package dependencies...
The following package is going to be reinstalled:
kvm_stat
1 package to reinstall.
Package download size: 29.2 KiB
Package install size change:
| 65.7 KiB required by packages that will be installed
0 B | - 65.7 KiB released by packages that will be removed
Backend: classic_rpmtrans
Continue? [y/n/v/...? shows all options] (y): y
Retrieving: kvm_stat-6.10.9-23.28.noarch (repo-oss) (1/1), 29.2 KiB
Retrieving: kvm_stat-6.10.9-23.28.noarch.rpm ........................................................................................................[done]
Checking for file conflicts: ........................................................................................................................[done]
(1/1) Installing: kvm_stat-6.10.9-23.28.noarch ......................................................................................................[done]
Running post-transaction scripts ....................................................................................................................[done]
I’m going to assume/hope my system is not messed up?
In any case, it is you, as system manager, that is responsible for installing this. I have no idea what happens if you make all in /usr owned by root:root. I also do not know if the product has more surprises for you.
Hopefully its isolated to that location, and it’s pretty easy to check. If the AI stops working I’ll know it’s due to access permission and I can open a bug and tell them to fix the install/update scripts.
It seems to be working fine with “root” as the owner of /usr/local.
Thank you @hcvv and @arvidjaar for helping me investigate the error.