Open theuser18 opened 3 weeks ago
That's really weird, it should have some entries. What's the output of sysremctl status power-options
?
Do you mean systemctl status power-options
?
○ power-options.service - power-options daemon
Loaded: loaded (/usr/lib/systemd/system/power-options.service; disabled; p>
Drop-In: /usr/lib/systemd/system/service.d
└─10-timeout-abort.conf
Active: inactive (dead)
Yeah sorry for the typo.
It seems like the service was not started. Could you start it/enable it manually with systemctl? Does it output anything then?
$ systemctl start power-options
$ systemctl status power-options
× power-options.service - power-options daemon
Loaded: loaded (/usr/lib/systemd/system/power-options.service; disabled; p>
Drop-In: /usr/lib/systemd/system/service.d
└─10-timeout-abort.conf
Active: failed (Result: exit-code) since Wed 2024-10-02 11:47:17 EDT; 8s a>
Duration: 9ms
Process: 9664 ExecStart=/usr/bin/power-daemon-mgr daemon (code=exited, stat>
Main PID: 9664 (code=exited, status=101)
CPU: 8ms
Oct 02 11:47:17 fedora systemd[1]: Started power-options.service - power-option>
Oct 02 11:47:17 fedora power-daemon-mgr[9664]: thread 'main' panicked at crates>
Oct 02 11:47:17 fedora power-daemon-mgr[9664]: Could not read config: Os { code>
Oct 02 11:47:17 fedora power-daemon-mgr[9664]: note: run with `RUST_BACKTRACE=1>
Oct 02 11:47:17 fedora systemd[1]: power-options.service: Main process exited, >
Oct 02 11:47:17 fedora systemd[1]: power-options.service: Failed with result 'e>
lines 1-16/16 (END)...skipping...
× power-options.service - power-options daemon
Loaded: loaded (/usr/lib/systemd/system/power-options.service; disabled; preset: disabled)
Drop-In: /usr/lib/systemd/system/service.d
└─10-timeout-abort.conf
Active: failed (Result: exit-code) since Wed 2024-10-02 11:47:17 EDT; 8s ago
Duration: 9ms
Process: 9664 ExecStart=/usr/bin/power-daemon-mgr daemon (code=exited, status=101)
Main PID: 9664 (code=exited, status=101)
CPU: 8ms
Oct 02 11:47:17 fedora systemd[1]: Started power-options.service - power-options daemon.
Oct 02 11:47:17 fedora power-daemon-mgr[9664]: thread 'main' panicked at crates/power-daemon/src/lib.rs:366:44:
Oct 02 11:47:17 fedora power-daemon-mgr[9664]: Could not read config: Os { code: 2, kind: NotFound, message: "No such file or directory" }
Oct 02 11:47:17 fedora power-daemon-mgr[9664]: note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
Oct 02 11:47:17 fedora systemd[1]: power-options.service: Main process exited, code=exited, status=101/n/a
Oct 02 11:47:17 fedora systemd[1]: power-options.service: Failed with result 'exit-code'.
Oh yeah, this happens when power options has not been initialized. The copr package was probably made before the migration to the setup system, and given that it is community made, I do not have control over it so I couldn't change the install instructions. It should have ran the following after installing the package sudo power-daemon-mgr setup
and then restart power-options. Basically what this script does
Temporarily of course, you can still run the commands within setup.sh until the package gets fixed.
Temporarily of course, you can still run the commands within setup.sh until the package gets fixed.
Would you mind sharing how to do that?
Just copy paste the commands in setup.sh into a terminal and you should be good. Especially given that this has to only be run once for the first time power-options is installed any further updates will not require this.
Just copy paste the commands in setup.sh into a terminal and you should be good. Especially given that this has to only be run once for the first time power-options is installed any further updates will not require this.
This worked. Thanks!
@theuser18 Apologies, this completely flew under the radar. Will get to it
@TheAlexDev23 Unfortunately according to Fedora's policies the package is not allowed to enable itself. I can still package it to do that, but then it would not go into official repos ever. The recommended way would be to simply add sudo systemctl enable --now power-options
to the installation instructions after installing the RPM. Additionally, the setup command will not work, it needs to be added to the install instructions.
sudo dnf copr enable leo/power-options
sudo dnf install power-options
sudo power-daemon-mgr setup
sudo systemctl enable --now power-options
Let me know what you think!
@lpuv, how much does Fedora restrict the execution of setup commands? power-daemon-mgr setup
only generates config files. The settings are only applied by the daemon which obviously only runs if started by the user. Altough it does gather system info, which might have restrictions? I've added the custom sysroot parameter, tell me if other parameters are required, but I assume /etc (which is the only folder the setup command writes to) does not have the ambiguity problem that /bin, /usr/bin or /usr/local/bin does.
After thinking about it, the issue is that some of the setup (generating config) would need to be run by the user anyway as it could not be run on Fedora's build servers. The biggest thing is that since none of the packaging is done on the target machine of the user it can't do any real setup.
Yeah, its meant to be ran on the installed system. Does fedora or the RPM package not allow post install scriplets?
I am using the Framework laptop 11th gen Intel i5 running a fully updated Fedora 40.
I get the following error when trying to launch the program, even after multiple reboots.
The output of
journalctl -u power-options
is-- No entries --