LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Slackware (https://www.linuxquestions.org/questions/slackware-14/)
-   -   fluxbox screen lock won't stay locked (https://www.linuxquestions.org/questions/slackware-14/fluxbox-screen-lock-wont-stay-locked-4175558815/)

Z038 11-13-2015 03:39 PM

fluxbox screen lock won't stay locked
 
I have two normal login accounts on my desktop computer. I run KDE on one and fluxbox on the other. If I lock the KDE desktop, it stays locked. But the fluxbox desktop often unlocks itself after a few hours.

I don't think that anyone could have the password, but just in case, I've changed it a couple of times over the last week or so. I still find it unlocked sometimes hours after locking it. That said, I'm not ruling out some kind of security issue.

I'm running Slackware 14.1. Has anyone else run into a problem like this? Is there any way I can determine how it is coming unlocked?

slacker1337 11-13-2015 08:35 PM

I would check to see if your screen locking program is dying and output its stderr to a log file. For instance, if your using xscreensaver:
Code:

/usr/bin/xscreensaver -nosplash 2> logfile
That should point you to where the failure is.

number22 11-14-2015 01:45 AM

if you using xlock, check its permission, it has g+s, and then your username is in the same group, I choose different password for its .xlockrc file.

orbea 11-14-2015 08:03 AM

As I understand it, xlock is designed so that if any single screensaver crashes, the whole program goes down. Xscreensaver doesn't do this.

https://www.jwz.org/xscreensaver/versus-xlock.html

Could so also try other locking programs like slock.

jmccue 11-14-2015 11:50 AM

I am fairly sure KDE has it's own screen saver.

For fluxbox I suspect you are using either xscreensaver or xlock. Could it be one of them are crashing (see slacker1337)? If using xscreensaver try adjusting settings using xscreensaver-demo. Some of xscreensaver's modes can be graphically intensive.

John

Z038 11-14-2015 06:56 PM

Quote:

Originally Posted by slacker1337 (Post 5449467)
I would check to see if your screen locking program is dying and output its stderr to a log file. For instance, if your using xscreensaver:
Code:

/usr/bin/xscreensaver -nosplash 2> logfile
That should point you to where the failure is.

Thank you. But that just hangs. It doesn't lock the screen or display a screensaver or write anything to the log file. I can terminate it with CTRL+C.

Z038 11-14-2015 07:01 PM

Quote:

Originally Posted by jmccue (Post 5449652)
For fluxbox I suspect you are using either xscreensaver or xlock. Could it be one of them are crashing (see slacker1337)? If using xscreensaver try adjusting settings using xscreensaver-demo. Some of xscreensaver's modes can be graphically intensive.

Thanks, John. I don't think fluxbox is using xscreensaver. I ran the xcreensaver-demo, and it looks quite different from what I normally see when I lock the screen. I'm using whatever fluxbox is set up to use by default in Slackware 14.1.

I also get this when I run the xscreensaver-demo, but I'm not too concerned about it since I'm pretty sure that fluxbox is actually using xlock.

Code:

(xscreensaver-demo:32639): libglade-WARNING **: Could not load support for `gnome': libgnome.so: cannot open shared object file: No such file or
directory


Z038 11-14-2015 07:04 PM

Quote:

Originally Posted by number22 (Post 5449509)
if you using xlock, check its permission, it has g+s, and then your username is in the same group, I choose different password for its .xlockrc file.

OK, this is what I'm using. The lock screen I normally see is the xlock screen.

I don't understand what you are saying about a different password for the .xlockrc file. How do I specify that?

The permissions on xlock appear to be what you said (or what I understood, anyway):

Code:

$ ls -al /usr/bin/xlock
-rwxr-s--x 1 root shadow 3115896 Aug 29  2013 /usr/bin/xlock


Z038 11-14-2015 07:06 PM

Quote:

Originally Posted by orbea (Post 5449596)
As I understand it, xlock is designed so that if any single screensaver crashes, the whole program goes down. Xscreensaver doesn't do this.

https://www.jwz.org/xscreensaver/versus-xlock.html

Could so also try other locking programs like slock.

Thank you for the link. Reading it now.

slacker1337 11-14-2015 07:12 PM

Quote:

Originally Posted by Z038 (Post 5449766)
Thank you. But that just hangs. It doesn't lock the screen or display a screensaver or write anything to the log file. I can terminate it with CTRL+C.

It isn't hanging, it's simply running in the foreground. The lack of output to the log is good as well, since the "2>" redirects only stderr to the log. No output to the log means no errors. Place an ampersand at the end of my recommended command to place it in the background, or use CTRL+Z to suspend the process followed by a "bg" to place it in the background.

If you don't know which screensaver that fluxbox is using, just look in ~/.fluxbox/menu and search for "Lock Screen". For instance, my fluxbox menu has the following at line 196:
Code:

[exec] (Lock screen) {xlock}
Which tells me that my default screen locker was xlock.

Best of luck!

Z038 11-14-2015 07:22 PM

Thanks for telling me how to tell which program fluxbox is using, slacker1337. I have the same line in my fluxbox menu file.

Now I will see if I can change it to use xscreensaver.

Z038 11-14-2015 07:59 PM

Ok, it turns out fluxbox menu system is pretty straightforward. I was able to edit ~/.fluxbox/startup to start xscreensaver when fluxbox starts, then add a menu item to run the {/usr/bin/xscreensaver-command -lock}. I'm leaving the xlock menu item in there until I am satisfied that xscreenserver will do the job for me.

Thank you all for the assistance. I appreciate it.

I'm going to mark this solved now.

jmccue 11-14-2015 08:00 PM

Quote:

Originally Posted by Z038 (Post 5449768)
I also get this when I run the xscreensaver-demo, but I'm not too concerned about it since I'm pretty sure that fluxbox is actually using xlock.
Code:

(xscreensaver-demo:32639): libglade-WARNING **: Could not load support for `gnome': libgnome.so: cannot open shared object file: No such file or
directory


I get that too, I just ignore it. For Fluxbox I have this in file ~/.fluxbox/startup to enable xscreensaver:
Code:

xscreensaver -no-splash &
and in ~/.fluxbox/keys I have this:
Code:

Control Mod1 L :ExecCommand xscreensaver-command -lock
which will enable the screen saver when pressing "<Ctrl><Alt>L".

John

Z038 11-14-2015 08:08 PM

Thanks for the key shortcut, John. I just added that to the ~/.fluxbox/keys file, but it doesn't seem to have any affect. I'm working on it.

Z038 11-14-2015 08:13 PM

Quote:

Originally Posted by Z038 (Post 5449786)
Thanks for the key shortcut, John. I just added that to the ~/.fluxbox/keys file, but it doesn't seem to have any affect. I'm working on it.

Seems to work with lower case l, but not upper case L, even though the keys file has an uppercase L in the key sequence. Whatever. So long as it works...


All times are GMT -5. The time now is 10:49 PM.