LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Desktop (http://www.linuxquestions.org/questions/linux-desktop-74/)
-   -   xscreensaver won't run automatically (http://www.linuxquestions.org/questions/linux-desktop-74/xscreensaver-wont-run-automatically-4175460546/)

tensigh 05-03-2013 04:46 AM

xscreensaver won't run automatically
 
Hello all,

I'm running Debian on a VM and xscreensaver won't run unless I manually start it. I have it set to run under System -> Preferences -> Startup Applications and I added it to /etc/rc.local, but no dice. /var/log/messages and /var/log/syslog don't show any errors.

Any suggestions? Not a major issue, but I just want to know why it won't start.

jmccue 05-03-2013 08:50 PM

Adding it to /etc/rc.local will not work, xscreensaver needs a X server to connect to. Depending upon how you get into X, you should add:
Quote:

xscreensaver &
to your ~/.xinitrc or ~/.xsession

HTH
John

tensigh 05-04-2013 07:25 AM

Thanks for the tip, but still having a problem
 
Thanks for the tip. You're right, it makes sense I would need an X server running for it to work.

I don't have an .xinitrc or .xsessions file in my ~/ directory. I suppose I can create one.

Why would it not work being in Startup Applications?

jmccue 05-04-2013 10:44 AM

Quote:

Originally Posted by tensigh (Post 4944711)
Why would it not work being in Startup Applications?

What is your desktop/Window Manager ? I suspect some desktops ignore .xsession/.xinitrc. I rarely use desktops, I have very little experience with gnome2/gnome3 so I cannot comment, but KDE has a method of starting apps when invoked, but I do not remember how to set it.

If using a window manager best to add it to .xsession/.xinitrc. But, if using fluxbox, you can add it to ~/.fluxbox/startup instead.

John

frankbell 05-04-2013 09:29 PM

If you are using a desktop environment, such as KDE or Gnome, look for an item called "Startup Applications" in the "control center" or "system settings" area. You should be able to add it there.

tensigh 06-01-2013 09:58 AM

Original post
 
Quote:

Originally Posted by frankbell (Post 4945082)
If you are using a desktop environment, such as KDE or Gnome, look for an item called "Startup Applications" in the "control center" or "system settings" area. You should be able to add it there.

Hey Frankbell,

Not sure if you saw it, but I put in my original post that I did put it in Startup Applications, but it still doesn't start. Thanks anyway.

frankbell 06-01-2013 08:04 PM

Sorry, I did miss that.

Here's a possible work-around.

Instead of putting xscreensaver in the startup applications item, put xscreensaver-demo (that's the configuration dialog) in there. When xscreensaver-demo starts, it should pop a dialog to the effect that "The xscreensaver daemon is not running. Do you want to start it now?" Click "Yes" and close the windows.

Try that and report back on what happens.

tensigh 06-02-2013 07:41 AM

Quote:

Originally Posted by frankbell (Post 4963762)
Sorry, I did miss that.

Here's a possible work-around.

Instead of putting xscreensaver in the startup applications item, put xscreensaver-demo (that's the configuration dialog) in there. When xscreensaver-demo starts, it should pop a dialog to the effect that "The xscreensaver daemon is not running. Do you want to start it now?" Click "Yes" and close the windows.

Try that and report back on what happens.

Frankbell,

Thank you. That would work but it still requires manually starting Xscreensaver. I can always drop to a terminal window and run /usr/bin/xscreensaver &. I'm trying to avoid having to manually start it. I also don't get why it requires me to do this; it's already in startup applications - shouldn't that be enough?

frankbell 06-02-2013 08:17 PM

Quote:

I also don't get why it requires me to do this; it's already in startup applications - shouldn't that be enough?
Yes.

If you want to dig deeper, here's a thought: make sure that xsceensaver is in startup applications, exit and restart the GUI. Then check the logs in /var/log.

I'd suggest particularly checking /var/log/messages and /var/log/Xorg.0.log. You might want to do that using the less command (for example, less /var/log/messages) so you can navigate back and forth through them.

I can't promise you'll turn up something, but you might. Also, there might be other suspects to interrogate, but those are the ones I'd start with.

tensigh 06-02-2013 09:29 PM

Thanks for the tip.
 
Quote:

Originally Posted by frankbell (Post 4964303)
Yes.

If you want to dig deeper, here's a thought: make sure that xsceensaver is in startup applications, exit and restart the GUI. Then check the logs in /var/log.

I'd suggest particularly checking /var/log/messages and /var/log/Xorg.0.log. You might want to do that using the less command (for example, less /var/log/messages) so you can navigate back and forth through them.

I can't promise you'll turn up something, but you might. Also, there might be other suspects to interrogate, but those are the ones I'd start with.

Thanks, Frankbell.

Actually, I already looked in /var/log recursively but didn't come up with anything. I love less, by the way, it rocks over more (less really is more!)
I do have it working on another system so I can comb through the config files on that system and see if I can figure out what I tweaked to get it to work. Since I installed that system about a year ago I couldn't find it in the history files.

Still can't figure out why it doesn't work with just startup applications, but I'll manage. Thanks for the tip.

Part of the problem is that these systems originally had the (lame) Gnome-screensaver installed, and these problems happened after replacing it with (the much better) Xscreensaver. Not a huge problem, but it's frustrating that something so seemingly simple takes up this much time.

frankbell 06-03-2013 06:41 PM

You may be on to something.

I have the same problem on my Mint machine and am using the workaround described. It also used to have Gnome-screensaver (I share your opinion of it).

I have similar removed and replaced Gnome-screensaver on Debian and Ubuntu, but not encountered this glich before.

Habitual 06-03-2013 07:05 PM

http://www.jwz.org/xscreensaver/man1.html is pretty explicit about setting this up.

Just an idea.

frankbell 06-03-2013 07:39 PM

Thanks. It's been a long time since I read that.

Perhaps the sections on enabling it from the display manager will help.

That still doesn't really speak to why it is not starting when added to Startup Applications.


All times are GMT -5. The time now is 09:22 AM.