Xfce Forum

Sub domains
 

You are not logged in.

#1 2021-01-10 18:40:48

elesouef
Member
Registered: 2021-01-10
Posts: 7

Starting Xscrensaver from "Startup and session" seems not to work

Hello,

I'm currently (and happily) use XFCE 4.16 (Debian testing).

In the past, using 4.14, Xscreensaver use to work normally. Xscreensaver was started at login.

Starring 4.16, I am unable to lock my screen with xflock4 because xscreensaver is not started anymore.

In "Startup and session", I have a line enabled at login the launches "/usr/share/xscreensaver/xscreensaver-wrapper.sh". Seems not to work.

But if I start a terminal, and launches xscreensaver-wrapper.sh by hand, now, I can lock my screen and and see the screensavers configured.

Am I missing something ?

Thanks for your help.

Offline

#2 2021-01-10 18:51:28

elesouef
Member
Registered: 2021-01-10
Posts: 7

Re: Starting Xscrensaver from "Startup and session" seems not to work

More infos : in fact, it seems to launch at login, but, shortly after, it seems to exit :

[~]$ ps afx | grep screen                                                      
   1652 ?        Ss     0:00  \_ xscreensaver
   1692 ?        SN     0:00  |   \_ xscreensaver-systemd
[~]$ ps afx | grep screen          
[~]$                                            

Offline

#3 2021-01-10 20:21:02

ToZ
Administrator
From: Canada
Registered: 2011-06-02
Posts: 11,486

Re: Starting Xscrensaver from "Startup and session" seems not to work

Hello and welcome.

Does debian create an xscreensaver log file (probably in /var/log)? If so, can you post its contents?

Otherwise, to create the log file, first:

sudo touch /var/log/xscreensaver.log

...then edit your ~/.Xresources file (create one if it doesn't exist) and add the following to the end:

xscreensaver.logFile:/var/log/xscreensaver.log
xscreensaver.verbose:true

Then reboot to get some log entries and post back the contents of /var/log/xscreensaver.log.

Also, interesting to see xscreensaver-systemd listed. Is it possibly enabled/running as a systemd service?

systemctl --user list-units | grep xscreensaver

Please remember to mark your thread [SOLVED] to make it easier for others to find
--- How To Ask For Help | FAQ | Developer Wiki  |  Community | Contribute ---

Offline

#4 2021-01-11 08:33:37

elesouef
Member
Registered: 2021-01-10
Posts: 7

Re: Starting Xscrensaver from "Startup and session" seems not to work

Thanks ToZ for your answer.

Configuring Xressrouces to make xscreensaver log to a particular file did not work (or maybe I did something wrong), but, when I grep'ed syslog for something matching xscreensaver :

Jan 11 08:06:26 delport180075 xscreensaver[1711]: xscreensaver: 08:06:26: warning: $DISPLAY is not set: defaulting to ":0.0".
Jan 11 08:07:10 delport180075 xscreensaver[2508]: xscreensaver: 08:07:10: warning: $DISPLAY is not set: defaulting to ":0.0".
Jan 11 08:07:10 delport180075 xscreensaver[2508]: Invalid MIT-MAGIC-COOKIE-1 keyxscreensaver: 08:07:10: Can't open display: :0.0
Jan 11 08:07:10 delport180075 xscreensaver[2508]: xscreensaver: 08:07:10: running as elesouef/elesouef (1000/1000)
Jan 11 08:07:10 delport180075 xscreensaver[2508]: xscreensaver: 08:07:10: Errors at startup are usually authorization problems.
Jan 11 08:07:10 delport180075 xscreensaver[2508]:               But you're not logging in as root (good!) so something
Jan 11 08:07:10 delport180075 xscreensaver[2508]:               else must be wrong.  Did you read the manual and the FAQ?
Jan 11 08:07:10 delport180075 xscreensaver[2508]:               https://www.jwz.org/xscreensaver/faq.html
Jan 11 08:07:10 delport180075 xscreensaver[2508]:               https://www.jwz.org/xscreensaver/man.html
Jan 11 08:07:10 delport180075 systemd[2480]: xscreensaver.service: Main process exited, code=exited, status=1/FAILURE
Jan 11 08:07:10 delport180075 systemd[2480]: xscreensaver.service: Failed with result 'exit-code'.
Jan 11 08:07:20 delport180075 xscreensaver[1711]: xscreensaver-systemd: 08:07:20: failed to process user bus: Connection reset by peer
Jan 11 08:07:20 delport180075 xscreensaver[1711]: xscreensaver:   signal: 0: child pid 1799 (xscreensaver-systemd) exited abnormally (code 1).
Jan 11 08:07:20 delport180075 xscreensaver[1711]: xscreensaver: 08:07:20: SIGTERM
Jan 11 08:07:20 delport180075 systemd[1648]: xscreensaver.service: Succeeded.

It seems to me that something is wrong with permissions with, maybe, DBUS,

Any ideas ?

(sorry, it seems it is not related to an Xfce issue).

Offline

#5 2021-01-11 11:31:07

ToZ
Administrator
From: Canada
Registered: 2011-06-02
Posts: 11,486

Re: Starting Xscrensaver from "Startup and session" seems not to work

It looks like you have both xscreensaver in startup and xscreensaver running as a systemd service. Try unchecking the autostart instance and trying again.

Can you post back the results of:

systemctl --user status xscreensaver

How do you log in? Do you use a display manager (and if so, which one) or are you using startx/xinit (in which case can you post your ~/.xinitrc file)?


Please remember to mark your thread [SOLVED] to make it easier for others to find
--- How To Ask For Help | FAQ | Developer Wiki  |  Community | Contribute ---

Offline

#6 2021-01-11 11:44:55

elesouef
Member
Registered: 2021-01-10
Posts: 7

Re: Starting Xscrensaver from "Startup and session" seems not to work

Here it is :

[~]$ systemctl --user status xscreensaver                                                                                                                                                                                                                                      
● xscreensaver.service - XScreenSaver
     Loaded: loaded (/usr/lib/systemd/user/xscreensaver.service; enabled; vendor preset: enabled)
     Active: failed (Result: exit-code) since Mon 2021-01-11 08:07:10 CET; 4h 35min ago
    Process: 2508 ExecStart=xscreensaver (code=exited, status=1/FAILURE)
   Main PID: 2508 (code=exited, status=1/FAILURE)
        CPU: 5ms

janv. 11 08:07:10 delport180075 xscreensaver[2508]: xscreensaver: 08:07:10: warning: $DISPLAY is not set: defaulting to ":0.0".
janv. 11 08:07:10 delport180075 xscreensaver[2508]: Invalid MIT-MAGIC-COOKIE-1 keyxscreensaver: 08:07:10: Can't open display: :0.0
janv. 11 08:07:10 delport180075 xscreensaver[2508]: xscreensaver: 08:07:10: running as elesouef/elesouef (1000/1000)
janv. 11 08:07:10 delport180075 xscreensaver[2508]: xscreensaver: 08:07:10: Errors at startup are usually authorization problems.
janv. 11 08:07:10 delport180075 xscreensaver[2508]:               But you're not logging in as root (good!) so something
janv. 11 08:07:10 delport180075 xscreensaver[2508]:               else must be wrong.  Did you read the manual and the FAQ?
janv. 11 08:07:10 delport180075 xscreensaver[2508]:               https://www.jwz.org/xscreensaver/faq.html
janv. 11 08:07:10 delport180075 xscreensaver[2508]:               https://www.jwz.org/xscreensaver/man.html
janv. 11 08:07:10 delport180075 systemd[2480]: xscreensaver.service: Main process exited, code=exited, status=1/FAILURE
janv. 11 08:07:10 delport180075 systemd[2480]: xscreensaver.service: Failed with result 'exit-code'.

Currently using Lightdm as a display manager, and not using start/xinit at all.

Should it be as simple as disable xscreensaver systemd service (as user) and check the box in "Startup and session" ?

Offline

#7 2021-01-11 16:20:31

ToZ
Administrator
From: Canada
Registered: 2011-06-02
Posts: 11,486

Re: Starting Xscrensaver from "Startup and session" seems not to work

elesouef wrote:

Should it be as simple as disable xscreensaver systemd service (as user) and check the box in "Startup and session" ?

Can you give a try?

Can also post back the contents of the systemd service file?


Please remember to mark your thread [SOLVED] to make it easier for others to find
--- How To Ask For Help | FAQ | Developer Wiki  |  Community | Contribute ---

Offline

#8 2021-01-11 17:20:31

elesouef
Member
Registered: 2021-01-10
Posts: 7

Re: Starting Xscrensaver from "Startup and session" seems not to work

Not better :

[~]$ systemctl --user status xscreensaver                                                                                                                                             
● xscreensaver.service - XScreenSaver
     Loaded: loaded (/usr/lib/systemd/user/xscreensaver.service; enabled; vendor preset: enabled)
     Active: failed (Result: exit-code) since Mon 2021-01-11 18:15:53 CET; 2min 27s ago
    Process: 2344 ExecStart=xscreensaver (code=exited, status=1/FAILURE)
   Main PID: 2344 (code=exited, status=1/FAILURE)
        CPU: 19ms

janv. 11 18:15:53 delport180075 xscreensaver[2344]: xscreensaver: 18:15:53: warning: $DISPLAY is not set: defaulting to ":0.0".
janv. 11 18:15:53 delport180075 xscreensaver[2344]: Invalid MIT-MAGIC-COOKIE-1 keyxscreensaver: 18:15:53: Can't open display: :0.0
janv. 11 18:15:53 delport180075 xscreensaver[2344]: xscreensaver: 18:15:53: running as elesouef/elesouef (1000/1000)
janv. 11 18:15:53 delport180075 xscreensaver[2344]: xscreensaver: 18:15:53: Errors at startup are usually authorization problems.
janv. 11 18:15:53 delport180075 xscreensaver[2344]:               But you're not logging in as root (good!) so something
janv. 11 18:15:53 delport180075 xscreensaver[2344]:               else must be wrong.  Did you read the manual and the FAQ?
janv. 11 18:15:53 delport180075 xscreensaver[2344]:               https://www.jwz.org/xscreensaver/faq.html
janv. 11 18:15:53 delport180075 xscreensaver[2344]:               https://www.jwz.org/xscreensaver/man.html
janv. 11 18:15:53 delport180075 systemd[2317]: xscreensaver.service: Main process exited, code=exited, status=1/FAILURE
janv. 11 18:15:53 delport180075 systemd[2317]: xscreensaver.service: Failed with result 'exit-code'.

and here is the unit mentioned :

[~]$ cat /usr/lib/systemd/user/xscreensaver.service                                                                                                                                   
[Unit]
Description=XScreenSaver

[Service]
ExecStart=xscreensaver

[Install]
WantedBy=default.target

Thanks for your help.

Offline

#9 2021-01-11 17:55:35

ToZ
Administrator
From: Canada
Registered: 2011-06-02
Posts: 11,486

Re: Starting Xscrensaver from "Startup and session" seems not to work

Did you disable the service via:

systemctl --user disable xscreensaver.service

...and log out and back in again.

It looks like its still loading.


Please remember to mark your thread [SOLVED] to make it easier for others to find
--- How To Ask For Help | FAQ | Developer Wiki  |  Community | Contribute ---

Offline

#10 2021-01-11 18:11:28

elesouef
Member
Registered: 2021-01-10
Posts: 7

Re: Starting Xscrensaver from "Startup and session" seems not to work

I hate systemd...

[~]$ systemctl --user status xscreensaver.service                                                                                                                                         
● xscreensaver.service - XScreenSaver
     Loaded: loaded (/usr/lib/systemd/user/xscreensaver.service; enabled; vendor preset: enabled)
     Active: failed (Result: exit-code) since Mon 2021-01-11 19:08:17 CET; 1min 9s ago
    Process: 2548 ExecStart=xscreensaver (code=exited, status=1/FAILURE)
   Main PID: 2548 (code=exited, status=1/FAILURE)
        CPU: 17ms

janv. 11 19:08:17 delport180075 xscreensaver[2548]: xscreensaver: 19:08:17: warning: $DISPLAY is not set: defaulting to ":0.0".
janv. 11 19:08:17 delport180075 xscreensaver[2548]: Invalid MIT-MAGIC-COOKIE-1 keyxscreensaver: 19:08:17: Can't open display: :0.0
janv. 11 19:08:17 delport180075 xscreensaver[2548]: xscreensaver: 19:08:17: running as elesouef/elesouef (1000/1000)
janv. 11 19:08:17 delport180075 xscreensaver[2548]: xscreensaver: 19:08:17: Errors at startup are usually authorization problems.
janv. 11 19:08:17 delport180075 xscreensaver[2548]:               But you're not logging in as root (good!) so something
janv. 11 19:08:17 delport180075 xscreensaver[2548]:               else must be wrong.  Did you read the manual and the FAQ?
janv. 11 19:08:17 delport180075 xscreensaver[2548]:               https://www.jwz.org/xscreensaver/faq.html
janv. 11 19:08:17 delport180075 xscreensaver[2548]:               https://www.jwz.org/xscreensaver/man.html
janv. 11 19:08:17 delport180075 systemd[2520]: xscreensaver.service: Main process exited, code=exited, status=1/FAILURE
janv. 11 19:08:17 delport180075 systemd[2520]: xscreensaver.service: Failed with result 'exit-code'.
[~]$ systemctl --user disable xscreensaver.service                                                                                                                                        
[~]$ systemctl --user status xscreensaver.service                                                                                                                                         
● xscreensaver.service - XScreenSaver
     Loaded: loaded (/usr/lib/systemd/user/xscreensaver.service; enabled; vendor preset: enabled)
     Active: failed (Result: exit-code) since Mon 2021-01-11 19:08:17 CET; 1min 24s ago
   Main PID: 2548 (code=exited, status=1/FAILURE)
        CPU: 17ms

janv. 11 19:08:17 delport180075 xscreensaver[2548]: xscreensaver: 19:08:17: warning: $DISPLAY is not set: defaulting to ":0.0".
janv. 11 19:08:17 delport180075 xscreensaver[2548]: Invalid MIT-MAGIC-COOKIE-1 keyxscreensaver: 19:08:17: Can't open display: :0.0
janv. 11 19:08:17 delport180075 xscreensaver[2548]: xscreensaver: 19:08:17: running as elesouef/elesouef (1000/1000)
janv. 11 19:08:17 delport180075 xscreensaver[2548]: xscreensaver: 19:08:17: Errors at startup are usually authorization problems.
janv. 11 19:08:17 delport180075 xscreensaver[2548]:               But you're not logging in as root (good!) so something
janv. 11 19:08:17 delport180075 xscreensaver[2548]:               else must be wrong.  Did you read the manual and the FAQ?
janv. 11 19:08:17 delport180075 xscreensaver[2548]:               https://www.jwz.org/xscreensaver/faq.html
janv. 11 19:08:17 delport180075 xscreensaver[2548]:               https://www.jwz.org/xscreensaver/man.html
janv. 11 19:08:17 delport180075 systemd[2520]: xscreensaver.service: Main process exited, code=exited, status=1/FAILURE
janv. 11 19:08:17 delport180075 systemd[2520]: xscreensaver.service: Failed with result 'exit-code'.

I don't know why it is still enabled.

Offline

#11 2021-01-11 18:18:02

elesouef
Member
Registered: 2021-01-10
Posts: 7

Re: Starting Xscrensaver from "Startup and session" seems not to work

By the way, once logged in :

[~]$ systemctl --user start xscreensaver.service
[~]$ systemctl --user status xscreensaver.service                                                                                                                                                                                                                              
● xscreensaver.service - XScreenSaver
     Loaded: loaded (/usr/lib/systemd/user/xscreensaver.service; enabled; vendor preset: enabled)
     Active: active (running) since Mon 2021-01-11 19:13:25 CET; 1min 35s ago
   Main PID: 4789 (xscreensaver)
      Tasks: 2 (limit: 9130)
     Memory: 3.0M
        CPU: 461ms
     CGroup: /user.slice/user-1000.slice/user@1000.service/app.slice/xscreensaver.service
             ├─4789 xscreensaver
             └─4795 xscreensaver-systemd

janv. 11 19:13:25 delport180075 systemd[2520]: Started XScreenSaver.
janv. 11 19:14:03 delport180075 xscreensaver[4789]: pam_unix(xscreensaver:auth): Couldn't open /etc/securetty: No such file or directory
janv. 11 19:14:03 delport180075 xscreensaver[5024]: pam_unix(xscreensaver:auth): Couldn't open /etc/securetty: No such file or directory
janv. 11 19:14:07 delport180075 xscreensaver[5038]: pam_unix(xscreensaver:auth): Couldn't open /etc/securetty: No such file or directory

But, as far as I know, /etc/securetty is not mandatory.

At least, the xscreensaver starts once logged in. But it is not how it should work...

Offline

#12 2021-04-10 14:07:44

jarnos
Member
From: Finland
Registered: 2009-03-22
Posts: 50
Website

Re: Starting Xscrensaver from "Startup and session" seems not to work

How do you think it should work? Does it obey setting "Lock before sleep" in "Session and Startup" dialog? There might be a problem if the locker is called by both Xfce and systemd when it is enabled, and by systemd even if it is not enabled.

Offline

Registered users online in this topic: 0, guests: 1
[Bot] ClaudeBot

Board footer

Powered by FluxBB
Modified by Visman

[ Generated in 0.015 seconds, 8 queries executed - Memory usage: 610.5 KiB (Peak: 627.34 KiB) ]