You are not logged in.

#1 2013-03-12 23:23:10

Kopkins
Member
Registered: 2012-07-01
Posts: 189

xscreensaver won't suspend LXDE

Hello,

I'm running Arch with LXDE and I'm trying to get gnome screensaver to work, but the gnome session fails to start. I followed the wiki here. But when I login, a little window say `Failed to load session "Gnome"'. Can anyone help me get it running?

Thanks,

Kopkins

Last edited by Kopkins (2013-03-17 16:46:54)

Offline

#2 2013-03-13 01:09:03

hadrons123
Member
From: chennai
Registered: 2011-10-07
Posts: 1,249

Re: xscreensaver won't suspend LXDE

Lot of things have changed in gnome 3.6 especially in screensaver. I doubt gnome-screensasver 3.6 will work in lxde. Try xscreensaver, if you are interested.


LENOVO Y 580 IVYBRIDGE 660M NVIDIA
Unix is user-friendly. It just isn't promiscuous about which users it's friendly with. - Steven King

Offline

#3 2013-03-13 01:13:53

Kopkins
Member
Registered: 2012-07-01
Posts: 189

Re: xscreensaver won't suspend LXDE

Okay, so I have the arch-logo-xscreensaver from the aur. But I want my computer to suspend when the screensaver turns on and it doesn't, I can't figure out how to do it. It doesn't even turn off the backlight on the screen.

Offline

#4 2013-03-13 01:27:10

hadrons123
Member
From: chennai
Registered: 2011-10-07
Posts: 1,249

Re: xscreensaver won't suspend LXDE

Well there is a power management option in the tabs. Try tweaking those options.


LENOVO Y 580 IVYBRIDGE 660M NVIDIA
Unix is user-friendly. It just isn't promiscuous about which users it's friendly with. - Steven King

Offline

#5 2013-03-13 01:39:57

Kopkins
Member
Registered: 2012-07-01
Posts: 189

Re: xscreensaver won't suspend LXDE

Okay I changed everything and it seems to be turning off the screen okay, but it doesn't suspend. I'm still having issues with power management, the system doesn't estimate time until battery is empty so it never warns me about low battery and I consistently either run it until it just shuts off or I go to use it and it has no power. And I can't seem to configure anything to automatically suspend at say 10%. I think I gave up trying acpid.

Kopkins

Edit: I just realized the power management settings in xscreensaver are only for the monitor. How can I have it suspend the computer?

Last edited by Kopkins (2013-03-13 01:42:46)

Offline

#6 2013-03-13 01:44:55

hadrons123
Member
From: chennai
Registered: 2011-10-07
Posts: 1,249

Re: xscreensaver won't suspend LXDE

I have xscreensaver from arch repos and it does suspend without any issues.

The issues you mentioned happens when the battery is broken. Check it out first.


LENOVO Y 580 IVYBRIDGE 660M NVIDIA
Unix is user-friendly. It just isn't promiscuous about which users it's friendly with. - Steven King

Offline

#7 2013-03-13 01:57:06

Kopkins
Member
Registered: 2012-07-01
Posts: 189

Re: xscreensaver won't suspend LXDE

Trying xscreensaver in the repos doesn't suspend for me either. Maybe it's another issue with the battery? Seems somewhat unrelated to me. This laptop is so old. I can hardly justify putting anything into it. It's got a broken battery and only ~500 MB RAM with a slow processor.

Offline

#8 2013-03-13 06:34:07

fallen00sniper
Member
Registered: 2013-03-07
Posts: 27

Re: xscreensaver won't suspend LXDE

try configuring it with xscreensaver-demo, advanced tab.

Offline

#9 2013-03-14 19:06:25

Kopkins
Member
Registered: 2012-07-01
Posts: 189

Re: xscreensaver won't suspend LXDE

fallen00sniper wrote:

try configuring it with xscreensaver-demo, advanced tab.

That's what I've been doing. I can't get xscreensaver to suspend no matter what combination of settings I use.

Does xscreensaver's user need to be in a certain group?

Offline

#10 2013-03-15 19:38:50

fallen00sniper
Member
Registered: 2013-03-07
Posts: 27

Re: xscreensaver won't suspend LXDE

no it just needs to run at login, not sure about lxde, but i am sure there is a way to start xscreensaver at login with this.

xscreensaver -nosplash

in something like gnome-session-properties
or

xscreensaver -no-splash &

in a script that is part of init.

Offline

#11 2013-03-17 16:34:08

Kopkins
Member
Registered: 2012-07-01
Posts: 189

Re: xscreensaver won't suspend LXDE

my .xinitrc

#!/bin/sh
#
# ~/.xinitrc
#
# Executed by startx (run your window manager from here)

if [ -d /etc/X11/xinit/xinitrc.d ]; then
  for f in /etc/X11/xinit/xinitrc.d/*; do
    [ -x "$f" ] && . "$f"
  done
  unset f
fi

# exec gnome-session
# exec startkde
# exec startxfce4
exec startlxde
xscreensaver -no-splash &

So far its still not working,

I've also tried /usr/bin/xscreensaver -no-splash &
exec /usr/bin/xscreensaver -no-splash &

And also putting it .config/lxsession/LXDE/autostart

Last edited by Kopkins (2013-03-17 16:37:16)

Offline

#12 2013-03-22 18:05:41

fallen00sniper
Member
Registered: 2013-03-07
Posts: 27

Re: xscreensaver won't suspend LXDE

just a idea, try putting a & after the lxde entry.

or follow what the wiki says, i would follow the line containing ~/.config/lxsession/LXDE/autostart.

for future reference the wiki entry is located here.

Autostart Programs

.desktop files

First you can link a program's .desktop in /usr/share/applications/ file to ~/.config/autostart/. For example, to execute lxterminal automatically at startup:

$ ln -s /usr/share/applications/lxterminal.desktop ~/.config/autostart/

Once .desktop files have been added you can manipulate them with the GUI configuration tool lxsession-edit.

autostart file

The second method is to use a ~/.config/lxsession/LXDE/autostart file. This file is not a shell script, but each line represents a command to be executed, if a line begins with a @ symbol, the command following the @ will be automatically re-executed if it crashes. For example, to execute lxterminal and leafpad automatically at startup:

~/.config/lxsession/LXDE/autostart

@lxterminal
@leafpad

Note: The commands do not end with a & symbol.

There is also a global autostart file at /etc/xdg/lxsession/LXDE/autostart. If both files are present, all entries in both files will be executed.

Last edited by fallen00sniper (2013-03-22 18:10:48)

Offline

#13 2013-03-24 02:30:31

Kopkins
Member
Registered: 2012-07-01
Posts: 189

Re: xscreensaver won't suspend LXDE

fallen00sniper wrote:

just a idea, try putting a & after the lxde entry.

or follow what the wiki says, i would follow the line containing ~/.config/lxsession/LXDE/autostart.

for future reference the wiki entry is located here.

Autostart Programs

.desktop files

First you can link a program's .desktop in /usr/share/applications/ file to ~/.config/autostart/. For example, to execute lxterminal automatically at startup:

$ ln -s /usr/share/applications/lxterminal.desktop ~/.config/autostart/

Once .desktop files have been added you can manipulate them with the GUI configuration tool lxsession-edit.

autostart file

The second method is to use a ~/.config/lxsession/LXDE/autostart file. This file is not a shell script, but each line represents a command to be executed, if a line begins with a @ symbol, the command following the @ will be automatically re-executed if it crashes. For example, to execute lxterminal and leafpad automatically at startup:

~/.config/lxsession/LXDE/autostart

@lxterminal
@leafpad

Note: The commands do not end with a & symbol.

There is also a global autostart file at /etc/xdg/lxsession/LXDE/autostart. If both files are present, all entries in both files will be executed.

I don't have a problem starting it. It runs perfect, except it doesn't suspend.

Offline

#14 2013-03-25 23:54:12

fallen00sniper
Member
Registered: 2013-03-07
Posts: 27

Re: xscreensaver won't suspend LXDE

try running it from a terminal and pipe it to a log file.

something like:

xscreensaver | tee log.txt

maybe it will give some clues.

Offline

#15 2013-03-26 02:05:27

Kopkins
Member
Registered: 2012-07-01
Posts: 189

Re: xscreensaver won't suspend LXDE

I used xscreensaver's log option. The logfile contained only the confirmation that it was being used as a logfile. I let xscreensaver blank the screen and allowed enough time for it to suspend. I'm trying this on a different laptop now and it's still not working how I expect. does xscreensaver actually suspend the computer? or just the screen?

Offline

#16 2013-03-26 04:12:38

anonymous_user
Member
Registered: 2009-08-28
Posts: 3,059

Re: xscreensaver won't suspend LXDE

Kopkins wrote:

my .xinitrc

#!/bin/sh
#
# ~/.xinitrc
#
# Executed by startx (run your window manager from here)

if [ -d /etc/X11/xinit/xinitrc.d ]; then
  for f in /etc/X11/xinit/xinitrc.d/*; do
    [ -x "$f" ] && . "$f"
  done
  unset f
fi

# exec gnome-session
# exec startkde
# exec startxfce4
exec startlxde
xscreensaver -no-splash &

So far its still not working,

I've also tried /usr/bin/xscreensaver -no-splash &
exec /usr/bin/xscreensaver -no-splash &

And also putting it .config/lxsession/LXDE/autostart

FYI for your ~/.xinitrc file, all commands should be listed before the exec [windowmanager/DE] line.

Offline

#17 2013-03-26 04:28:10

Kopkins
Member
Registered: 2012-07-01
Posts: 189

Re: xscreensaver won't suspend LXDE

anonymous_user wrote:
Kopkins wrote:

my .xinitrc

#!/bin/sh
#
# ~/.xinitrc
#
# Executed by startx (run your window manager from here)

if [ -d /etc/X11/xinit/xinitrc.d ]; then
  for f in /etc/X11/xinit/xinitrc.d/*; do
    [ -x "$f" ] && . "$f"
  done
  unset f
fi

# exec gnome-session
# exec startkde
# exec startxfce4
exec startlxde
xscreensaver -no-splash &

So far its still not working,

I've also tried /usr/bin/xscreensaver -no-splash &
exec /usr/bin/xscreensaver -no-splash &

And also putting it .config/lxsession/LXDE/autostart

FYI for your ~/.xinitrc file, all commands should be listed before the exec [windowmanager/DE] line.

I realized that, thank you. I installed arch on my macbook and this is what I'm running right now.

sh ~/.fehbg &			#desktop background
sudo backlight night &		#set screen and keyboard brightness
conky -c .conky/conkyMain &	#conky
sleep 2 && pypanel & 		#panel
wicd-client --tray &		#wicd panel applet
volwheel &
xscreensaver --nosplash -log ~/xscreensaver.log &	#lock screen
openbox				#openbox as window manager

I still can't get it to do anything besides turn off the screen and lock it.

Is there something else I have to do to suspend all hardware?

Offline

#18 2013-03-26 05:17:02

progandy
Member
Registered: 2012-05-17
Posts: 5,180

Re: xscreensaver won't suspend LXDE

You could run a second script that waits for xscreensaver to lock the screen and then suspends:

while read action data; do
    echo $action
    if [ "$action" = "LOCK" ]; then
        echo "Standby command should be here"
    fi
done < <(xscreensaver-command -watch)

| alias CUTF='LANG=en_XX.UTF-8@POSIX ' |

Offline

#19 2013-03-26 05:33:27

root
Member
From: 127.0.0.1
Registered: 2012-04-13
Posts: 297

Re: xscreensaver won't suspend LXDE

I might be wrong but I do not recall xscreensaver dealing with system suspension but just, as the OP has been experiencing, with monitor power management and/or screen locking.

If you haven't installed any power manager (besides the management that systemd includes) you can try installing xfce4's power manager and use it as your system power manager and, ultimately, see if it serves your suspension purpose.


\(o_X)/
                        'Cause I wanna be an Archy - An Archy in the UK // Sex Pistols

Offline

#20 2013-03-26 07:39:06

renegat
Member
From: Europe
Registered: 2012-12-28
Posts: 88

Re: xscreensaver won't suspend LXDE

As root above-mentioned: xscreensaver is not dealing with system suspension.

Install the xfce4-power-manager package
edit /etc/xdg/lxsession/LXDE/autostart
after the "@xscreensaver -no-splash" add @xfce4-power-manager

Edit (if you want to have a starter shown in LXMenu):
# vi /usr/share/applications/xfce4-power-manager-settings.desktop
Add LXDE to
OnlyShowIn=LXDE;XFCE;

Best regards

Offline

#21 2013-03-26 14:23:41

Kopkins
Member
Registered: 2012-07-01
Posts: 189

Re: xscreensaver won't suspend LXDE

Thanks root and renegat,

At first (after a few posts in the thread) I didn't think my question was valid because xscreensaver doesn't have any suspend functionality. But it seemed that the other users were telling me that it did. As I got further in my digging I realized that I was misunderstanding something. But I couldn't find anywhere something that worked with xscreensaver to do power management.

Thanks ,
Kopkins

Offline

Board footer

Powered by FluxBB