On 09/30/2016 03:50 AM, Per Jessen wrote:
Hans de Faber wrote:
Using: Leap 42.1
At the end or somewhere else in the bootproces I want to run the command " cpupower frequency-set -g performance".
What is the right method and place to do this ?
To my knowledge, systemd does not have a concept such as "At the end of the bootprocess", but as your command does not seem dependent on anything, I guess you can put it anywhere after whatever usually is started last. I don't know if there is a sort of "after-boot.local", but adding a local systemd unit is no big deal.
It depends on what you mean by "end or somewhere else in the boot process". With that relaxed a definition, then systemd is what you should be using. Creata unit with that command. it's a system one so it goes under /etc/systemd I would think. I'd put it under /etc/systemd/user sicne I take that to mean 'user defined' rather than 'end user. Well, OK systemd.unit(5( makes me wonder. it does say in Table 1 that Load path when running in system mode (--system). ┌────────────────────────┬─────────────────────────────┐ │Path │ Description │ ├────────────────────────┼─────────────────────────────┤ │/etc/systemd/system │ Local configuration │ ├────────────────────────┼─────────────────────────────┤ but it seems to group /etc/systemd/user with the end user in $HOME/.config I see it as an issue of maintainability under later revisions. Perhaps the important thing is to document it. However you can use the before and after sections of a unit, one of the other, to specify that 'somewhere' in the boot process. You may want to decide if you want it to occur only in multi-user mode or both single and multi user mode. That's where the 'after' and 'before comes in. Run the command systemctl list-units -t target to see some of the milestone units you can use for the before/after HOWEVER ... If you run systemctl list-units -t service you will see an entry for upower.service which is the daemon for power management. perhaps you need to communicate with that. I'd certainly make your custom unit dependent on that! Systemd and the unit model offer a great deal of flexibility about all this. it just requires more forethought, consideration of actions and consequences and planning than the old script based approach. That's often the price you pay for more power. -- A: Yes. > Q: Are you sure? >> A: Because it reverses the logical flow of conversation. >>> Q: Why is top posting frowned upon? -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse+owner@opensuse.org