Page MenuHomePhabricator

disable kde power management in VMs
Closed, ResolvedPublic

Description

TODO:

  • disable powerdevil
  • disable kde battery monitor systray
  • disable KDE -> System Settings --> Power Management

Forum discussion:
https://www.whonix.org/forum/index.php/topic,1217.0.html


Deprecated:

In /usr/share/kde4/services/kded/powerdevil.desktop change from

X-KDE-Kded-phase=1
to
X-KDE-Kded-phase=0

using config-package-dev's displace operation. Conditionally, only if --target virtualbox, qcow2, qubes (T298) [during build script] or when virt-what detects a virtual machine.

Details

Impact
Normal

Event Timeline

Patrick created this task.May 10 2015, 8:20 PM
Patrick updated the task description. (Show Details)
Patrick raised the priority of this task from to Normal.
Patrick set Impact to Normal.
Patrick added a subscriber: Patrick.
Patrick changed the status of subtask T298: add --target qubes from Open to Review.May 11 2015, 12:29 AM
Patrick updated the task description. (Show Details)May 16 2015, 3:01 AM
Patrick added a comment.EditedAug 18 2015, 7:06 PM

Might have found a better solution.

Switching using the kde service manager (https://userbase.kde.org/System_Settings/Startup_and_Shutdown/de#Service_Manager) modifies the following file.

/home/user/.kde/share/config/kdedrc

[Module-powerdevil]
autoload=false

But we won't need to write into user's home folder. Can be implemented similar to the kde-lowfat package.

The Xsession.d script could even check if being run within virtualization.


Produced a branch doing this. Not yet merged into master.

disabled powerdevil service to prevent occasionally message "no valid power management backend plugins are available" - https://phabricator.whonix.org/T297:
https://github.com/adrelanos/power-savings-disable-in-vms/commit/eec0a4283651d61f8f179ca7b05ddb16fe3e8ea5

But that alone is an incomplete solution. The battery monitor still appears in systray by default. And worse, when you click at it, there will be an error message, because power devil has been disabled. I am onto something to get rid of the battery monitor as well. Let's see.

Nice. Do you know if this can be extended to KDE network manager to get rid of the taskbar icon?

My quick and dirty solution in place solution that works, that I am cleaning up and committing to disable the battery monitor systray.

/usr/share/whonix-ws-kde-desktop-conf/share/kde4/services/plasma-applet-batterymonitor.desktop

[Desktop Entry]
Name=battery-monitor-disabled
Type=none
This comment was removed by Patrick.
In T296#6497, @HulaHoop wrote:

Nice. Do you know if this can be extended to KDE network manager to get rid of the taskbar icon?

Will answer here later:
https://www.whonix.org/forum/index.php/topic,532.msg9518.html#msg9518

Patrick renamed this task from disable kde power devil in VMs to disable kde power management in VMs.Aug 18 2015, 10:58 PM
Patrick updated the task description. (Show Details)
Patrick updated the task description. (Show Details)Aug 18 2015, 11:01 PM

disabled kde battery monitor systray in VMs - https://phabricator.whonix.org/T296:
https://github.com/adrelanos/power-savings-disable-in-vms/commit/73c37a29c936a2d4d51e068789ae79d0471081f8

Working quick and dirty in place solution to get rid of the broken power management item in kde systemsettings. (Broken as expected because powerdevil has been disabled.)
/usr/share/whonix-ws-kde-desktop-conf/share/kde4/services/powerdevilglobalconfig.desktop

[Desktop Entry]
Type=none
X-KDE-System-Settings-Parent-Category=
Patrick changed the task status from Open to Review.Aug 19 2015, 9:52 PM

Yes its working :)

Patrick closed this task as Resolved.May 11 2016, 6:00 PM
Patrick claimed this task.