SlackwareThis Forum is for the discussion of Slackware Linux.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
The command '/sbin/init 0' shuts down your machine. Hence the following lines are not executed.
Try changing the order.
Sorry for the mistake. Now I switched the order of the statements, but still not seen the 'battery-log' file as expected. I really concerns, did the event button/power happen? Or the event group/name is not correct?
You say the script is /etc/acpi_handler.sh. Slackware has the default /etc/acpi/acpi_handler.sh.
Also, where did you get the acpitool command? It is not part of standard Slackware.
You say the script is /etc/acpi_handler.sh. Slackware has the default /etc/acpi/acpi_handler.sh.
Also, where did you get the acpitool command? It is not part of standard Slackware.
Yes, it's actually /etc/acpi/acpi_handler.sh. I build acpitool from source tarball because I don't see what utility in slackware can check the battery usage.
... I don't see what utility in slackware can check the battery usage.
From the command line you have 'cat /sys/class/power_supply/BAT*/uevent'
KDE has a Battery Monitor widget.
XFCE has the Xfce 4 Power Manager system tray icon.
Windowmaker has a number of dockapps for monitoring the battery.
gkrellm can be configured to monitor the battery and will run in any X session.
gkrellm is nice! But it is not able to shutdown my computer when battery is low. I see the 'alert commands', but I think I can not depend on it since my gkrellm must run in normal user mode in X where it does not have privilege to shutdown the system.
So, back to the topic: When acpi power events is not triggering?
What desktop environment or window manager are you running?
Automatic shutdown on low power can be configured in:
KDE using System Settings -> Power Management
XFCE by Settings -> Xfce 4 Power Manager.
What desktop environment or window manager are you running?
Automatic shutdown on low power can be configured in:
KDE using System Settings -> Power Management
XFCE by Settings -> Xfce 4 Power Manager.
I am using fluxbox. And for the moment, I like to stick to this lightweight window manager.
Your user will likely need to be a member of the 'power' group.
Hi Allend,
I tried the xfce4-power-manager and found some problems:
1. When run it as non-root user, it's low power action is not configurable and default to do nothing. So how should I start it in fluxbox startup script?
2. 'Hibernate' action does not work. This may not be a fault of xfce4-power-manage. I think I have to enable slackware's hibernate funcationality. But how?
The man page of the program as well as the it's web page don't tell more.
I have just started a fluxbox session with the line I gave without the & in my ~/.fluxbox/startup
Code:
# Applications you want to run with fluxbox.
# MAKE SURE THAT APPS THAT KEEP RUNNING HAVE AN ''&'' AT THE END.
#
# unclutter -idle 2 &
# wmnd &
# wmsmixer -w &
# idesk &
## My testing
/usr/bin/xfce4-power-manager
I have no problems with configuring Xfce Power Manager or getting lid switch actions to occur. I have not tested critical battery power events.
I am using 0.8.5 xfce4-power-manager on slackware 13.37. Was you using the same version? And, you was running as root or a normal user account?
I did the same configuration to a normal user account. The xfce4-power-manager get runs, but
- The lip actions take no effect. Simply nothing happened if lip closed.
- The On Battery actions are not editable. (right click the xfce4-power-manager icon, and select 'preference', then click 'On Battery').
Yes, tested with 0.8.5 xfce4-power-manager on slackware 13.37 running as a normal user.
I am starting to think that there is a problem with ACPI on your computer. The inability to get the script to run as well as being unable to successfully use xfce4-power-manager would be consistent with this.
Please test your setup, as root, using the information in /usr/doc/pm-utils-1.4.1/README.SLACKWARE and report the findings together with the make and model of your computer.
Thanks for pointing me to the document /usr/doc/pm-utils-1.4.1/README.SLACKWARE. After I added the user account to the 'power' groups, I found the xfce4-power-manage works, I do suspend my computer after 'lip close' or 'batter low'. Thanks a lot!
But I still don't understand why the 'power' action defined in acpi_handler.sh had never triggered. What's the definition of the event? I think making it works is important when I in console mode where the xfc4-power-manage cannot run.
Hope I can continuous to get help, though the current situation is much better after got help from here.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.