||04-03-2010 07:30 AM
Custom pm-utils suspend/resume hook stopped working
some time ago I created my own hook in /etc/pm/sleep.d/ in order to fill a few gaps in my e17
case "$1" in
sudo -u username xscreensaver-command -display :0.0 -lock
sudo -u username /opt/e17/bin/enlightenment_remote -restart
and it used to work as a charm for some time. However, at certain point it started returning this error in /var/log/pm-suspend.log:
/etc/pm/sleep.d/00customhook resume suspend: Failed to open connection to "session" message bus: /usr/bin/dbus-launch terminated abnormally with the following error: Autolaunch error: X11 initialization failed.
and it stopped functioning. The only system changes I've made in the meantime are cleaning up some leftovers from gnome and kde, but I fail to see how would that affect X initialization or dbus's functions. Any help will be appreciated, thanks in advance.
EDIT: I did some experimenting with the hooks and found out that any command that has anything to do with X returns the same error if put in the hooks. Normal execution in terminal/tty works fine.