Skip to content

tuned-ppd.service fails to start with KeyError and TunedException #849

Description

@0x70369

Hello. I'm on Arch Linux with tuned version 2.27.0 and some custom profiles. They can be viewed in my repository.

With the configuration stored there, tuned-ppd fails to start every time:

$ systemctl status tuned-ppd.service
× tuned-ppd.service - PPD-to-TuneD API Translation Daemon
     Loaded: loaded (/usr/lib/systemd/system/tuned-ppd.service; enabled; preset: disabled)
     Active: failed (Result: exit-code) since Wed 2026-04-15 19:57:51 -03; 4min 39s ago
 Invocation: bad41ee0b1664ed0a9998c0e184eeedb
    Process: 568680 ExecStart=/usr/bin/tuned-ppd -l (code=exited, status=1/FAILURE)
   Main PID: 568680 (code=exited, status=1/FAILURE)
   Mem peak: 18.5M
        CPU: 108ms

abr 15 19:57:51 Alienware tuned-ppd[568680]:   File "/usr/lib/python3.14/site-packages/tuned/ppd/controller.py", line 436, in switch_profile
abr 15 19:57:51 Alienware tuned-ppd[568680]:     if not self._set_tuned_profile(self._config.ppd_to_tuned.get(profile, self._on_battery)):
abr 15 19:57:51 Alienware tuned-ppd[568680]:                                    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^
abr 15 19:57:51 Alienware tuned-ppd[568680]:   File "/usr/lib/python3.14/site-packages/tuned/ppd/config.py", line 31, in get
abr 15 19:57:51 Alienware tuned-ppd[568680]:     return profile_map[profile]
abr 15 19:57:51 Alienware tuned-ppd[568680]:            ~~~~~~~~~~~^^^^^^^^^
abr 15 19:57:51 Alienware tuned-ppd[568680]: KeyError: 'alienware-balanced'
abr 15 19:57:51 Alienware systemd[1]: tuned-ppd.service: Main process exited, code=exited, status=1/FAILURE
abr 15 19:57:51 Alienware systemd[1]: tuned-ppd.service: Failed with result 'exit-code'.
abr 15 19:57:51 Alienware systemd[1]: Failed to start PPD-to-TuneD API Translation Daemon.

If inside the ppd.conf file I change default=balanced to, say, default=alienware-balanced, this other error shows up instead:

$ systemctl status tuned-ppd.service
× tuned-ppd.service - PPD-to-TuneD API Translation Daemon
     Loaded: loaded (/usr/lib/systemd/system/tuned-ppd.service; enabled; preset: disabled)
     Active: failed (Result: exit-code) since Wed 2026-04-15 20:04:58 -03; 1s ago
 Invocation: 86a007319b124847a21f8d387d42350b
    Process: 621244 ExecStart=/usr/bin/tuned-ppd -l (code=exited, status=1/FAILURE)
   Main PID: 621244 (code=exited, status=1/FAILURE)
   Mem peak: 18.5M
        CPU: 124ms

abr 15 20:04:58 Alienware tuned-ppd[621244]:                    ~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
abr 15 20:04:58 Alienware tuned-ppd[621244]:   File "/usr/lib/python3.14/site-packages/tuned/ppd/config.py", line 47, in __init__
abr 15 20:04:58 Alienware tuned-ppd[621244]:     self.load_from_file(config_file)
abr 15 20:04:58 Alienware tuned-ppd[621244]:     ~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^
abr 15 20:04:58 Alienware tuned-ppd[621244]:   File "/usr/lib/python3.14/site-packages/tuned/ppd/config.py", line 118, in load_from_file
abr 15 20:04:58 Alienware tuned-ppd[621244]:     raise TunedException("Default profile '%s' missing in the profile mapping" % self._default_profile)
abr 15 20:04:58 Alienware tuned-ppd[621244]: tuned.exceptions.TunedException: Default profile 'alienware-balanced' missing in the profile mapping
abr 15 20:04:58 Alienware systemd[1]: tuned-ppd.service: Main process exited, code=exited, status=1/FAILURE
abr 15 20:04:58 Alienware systemd[1]: tuned-ppd.service: Failed with result 'exit-code'.
abr 15 20:04:58 Alienware systemd[1]: Failed to start PPD-to-TuneD API Translation Daemon.

How can I fix this?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions