Tag Info

Hot answers tagged

14

Add the kernel options acpi=off apm=off to the contents of GRUB_CMDLINE_LINUX_DEFAULT in file /etc/default/grub Then run sudo update-grub Finally reboot your computer.


13

On my system I can obtain the power drawn from the battery from cat /sys/class/power_supply/BAT0/power_now 9616000 On Thinkpads if the tp_smapi module is loaded, the file is cat /sys/devices/platform/smapi/BAT0/power_now The value seems to be in µW, though. You can convert it with any tool you're comfortable with, e.g. awk: awk '{print $1*10^-6 " W"}' ...


13

Assuming your governor is the intel_pstate (default for Intel Sandy Bridge and Ivy Bridge CPUs as of kernel 3.9). This issue is not specific to Arch, but all distros using the new Intel pstate driver for managing CPU frequency/power management. Arch linux CPU frequency scaling. Theodore Ts'o wrote his explanation on Google+: intel_pstate can be ...


10

Take a look at this SuperUser Q&A titled: How do you check how much power a USB port can deliver?, specifically my answer. lsusb -v You can get the maximum power using lsusb -v, for example: $ lsusb -v|egrep "^Bus|MaxPower" Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub MaxPower 0mA Bus 002 Device 001: ID 1d6b:0002 ...


9

Here's a small script that checks for the battery level and calls a custom command, here pm-hibernate, in case the battery level is below a certain threshold. #!/bin/sh ########################################################################### # # Usage: system-low-battery # # Checks if the battery level is low. If “low_threshold” is exceeded # a system ...


9

According to the kernel tree documentation, the autosuspend idle-delay time is controlled by the autosuspend module parameter in usbcore. Setting the initial default idle-delay to -1 will prevent the autosuspend of any USB device. You should still be able to to enable autosuspend for selected devices. The usbcore.autosuspend kernel parameter can be set when ...


9

For Ubuntu and Debian, usbcore is compiled in the kernel, so create entries on /etc/modprobe.d will NOT work: we need to change the kernel boot parameters. Edit the /etc/default/grub file and change the GRUB_CMDLINE_LINUX_DEFAULT line to add the usbcore.autosuspend=-1 option: GRUB_CMDLINE_LINUX_DEFAULT="quiet splash usbcore.autosuspend=-1" Note that quit ...


8

Computers generally don't track the current they are drawing. It is common that there are voltage sensors that are readable. Power consumption can vary widely over time depending on workload. CPUs now throttle back when load is low. Disks will shutdown when idle. Tools like powertop will track processes which trigger increases in power consumption. ...


8

This seems to be a known bug and you can read more detail on launchpad as well as on ubuntuforums. The issue is that somehow gnome-power-manager and the xset commands conflict with each other. The solution is to run xset dpms force off in a loop, a python script pretty much works for most of us. Give it a try, and see how it goes.


8

I had the same problem none of the solutions here suited my needs. Using cron is really a workaround, not a solution, udev rules are run when power is connected/disconnected but not after suspending/resuming and pm-utils are no longer used by default in Fedora 19 when you for example close lid of your laptop. Since systemd is now responsible for ...


7

This is not a out-of-the-box solution but it will possibly work if no one other comes up with a solution :-) You can manipulate the power management settings with the command pmset. See the manpage for more information about it. The interesting setting we want to manipulate is sleep: sleep - system sleep timer (value in minutes, or 0 to disable) ...


7

xset dpms force off works for most X setups.


7

Sounds like you want suspend-to-both/hybrid suspend which should do all the steps of hibernating, including writing RAM to disk, but not actually turn the machine off; instead, it'll go into S3 (standby). If you wake the machine up before the battery dies, it'll be fairly quick; if the battery dies, it'll be just as if you'd hibernated it.


7

write a script! battery_level=`acpi -b | grep -P -o '[0-9]+(?=%)'` if [ $battery_level -le 10 ] then notify-send "Battery low" "Battery level is ${battery_level}%!" fi then cron it to run every few minutes or so. But yeah, if you can do it through the GUI, that's probably a much better way of doing it.


7

The kondemand process helps conserve power by reducing the CPU-Speed if the CPU isn't needed to run at maximum speed. Reduced Clock Speed == Reduced power requirements. Personally, I find that very useful on portable devices (smartphones, netbooks) but I'm not sure about that feature when it comes to Servers.


7

Powertop is not a permanent tool, as you know, so you will have to setup your system to run the commands through sysctl, udev, systemd units, scripts, whatever... In order to see what commands are used by powertop you will have to run powertop --html BEFORE MAKING ANY CHANGES, that is, BEFORE toggling the settings from Bad to Good. If you already tuned for ...


7

Potential Method #1 I think you can do it with these commands: disable echo 0 > /sys/bus/pci/slots/$N/power enable echo 1 > /sys/bus/pci/slots/$N/power Where $N is the number of the PCI slot. lspci -vv may help to identify the device. This is not very well documented... Potential Method #2 I came across this thread on U&L, similar ...


6

The fade out is probably the screensaver kicking in. Try to disable it by going to System->Preferences->Look and Feel->Screensaver and disabling "Activate screensaver when computer is idle" if indeed the active screen saver is "Blank screen". The fact that the fading out can't be interrupted is a bug it seems. E.g. Fedora has a bugreport stating it is a ...


6

At that point, I would think about using a power monitor to measure the load on the computer at any time. You could hook up your computer or surge protector to something like Tweet-a-Watt and then keep track of the metrics from there on a per day/week/month basis. I imagine you could use ACPI/APM to monitor some aspects (and mayhaps power, as well) of the ...


6

I doubt that LXDE vs GNOME will make a significant difference, but I don't have hard figures. I doubt less that the default configuration of LXDE and the default configuration of GNOME will make some difference. To keep power consumption down, turn off desktop effects (animations, anything 3D). Make sure you're not running any kind of “screen saver”. Most ...


6

I haven't got the time for all details now, but see the GNOME Power Manager's FAQ "How do I make my application stop the computer auto-suspending" which points to the Inhibit() and UnInhibit() DBus-calls. A caveat: if the process calling Inhibit() exits, the inhibition is ended - dbus-send in a Shell script thus won't do, but some wrapper script (e.g. in ...


6

systemd can handle this. I think this is what you need: Open the /etc/systemd/logind.conf (manual): HandlePowerKey: action on power key is pressed; HandleSuspendKey: action on suspend key is pressed. HandleHibernateKey: action on hibernate key is pressed. HandleLidSwitch: action when the lid is closed. The action can be one of ignore, poweroff, reboot, ...


6

See Controlling a USB power supply (on/off) with linux, short version, for newer kernels "suspend" does not work anymore: echo "0" > "/sys/bus/usb/devices/usbX/power/autosuspend_delay_ms" echo "auto" > "/sys/bus/usb/devices/usbX/power/control" But it doesn't literally cut the power, it signals the device to poweroff, it's up to the device to ...


6

If you are using systemd then use udisksctl utility with power-off option: power-off Arranges for the drive to be safely removed and powered off. On the OS side this includes ensuring that no process is using the drive, then requesting that in-flight buffers and caches are committed to stable storage. I would recommend first to ...


5

The very important thing is to lower down the cpu clock first. The second important part is to verify there is no physical cooling problem (like dust on the fans, cat or dog hairs in the heatsink ect) On most computers, the fan speed is directly operated by the bios or the os automatically. The cleaning/lowering cpu speed process should let the cooling ...


5

If your computer actually keeps track of power (e.g. notebook), than on kernel 3.8.11 you can use the command below. It returns power measured in miliwatts. cat /sys/class/power_supply/BAT0/power_now This works on kernel 3.8.11 (Ubuntu Quantal mainline generic).


5

Does the power strip do anything beyond read the +5V a connected USB port provides? (Do you see anything in dmesg when you attach it? Does the output of lsusb change after you plug it in?) If not, the kernel may not even recognize that anything is attached. You can't tell a device to suspend if it never enumerates itself: it would never show up under ...


5

You need to change the DPMS settings, which are controllable with xset. You can disable all DPMS with: $ xset -dpms And re-enable them with: $ xset +dpms You can also control how long before the monitor switches into each state (standby, suspend, and off; they're explained in this Wikipedia article) by passing 3 integers for the number of seconds ...


5

some UPS devices have displays that track power consumption, too, and there may be ways with the USB connectivity and a program like apcupsd to poll that kind of information for graphing with something like Cacti. otherwise you're looking at a wall outlet with a display, like a Belkin Conserve Insight F7C005q Energy Use Monitor. Btw, powertop will work ...


5

Regular solution In principle, the solutions above : setting desktop-provided power management -- or xset -dpms ; xset s off for a one-time test disabling/uninstalling desktop-provided screensaver and checking/killing existing one to be sure (like pgrep screensaver etc.) ...should be enough. Don't add acpi=off to grub for this, it is off-topic here. ...



Only top voted, non community-wiki answers of a minimum length are eligible