You are not logged in.

#1 2012-09-21 13:01:10

usagi
Member
Registered: 2011-11-21
Posts: 54

[SOLVED] Systemd asking for authentication to suspend all of a sudden

Hello,

This morning, while experimenting with the Wake-on-lan settigns on my computer, systemd started asking for my credentials in order to suspend the system. This is annoying, becuase i have a script that does this automatically. It is now broken. Also, I'm not aware of any changes I've made to the system, other than waking it up on lan once or twice. I've done several normal reboots since then.

The funny thing is, if i'm just in a TTY, it'll let me suspend the system. Once i start X, it starts asking for credentials. It's almost like it is interpreting the X session as a separate user logon...

Any ideas on how to correct this? I've tried removing ck-launch-session from the .xinitrc shown below, but it had no effect (not that i really expected it to).

Thanks,
Aaron

If it helps, this is how i start X:


#! /bin/sh
[ -f ~/.xprofile ] && . ~/.xprofile

ck-launch-session /usr/bin/i3

EDIT: Aaaand my .xprofile

xrandr --output DVI-I-3 --left-of DVI-I-2
xrandr --output DVI-I-3 --pos 0x312

Last edited by usagi (2012-09-21 14:14:28)

Offline

#2 2012-09-21 13:26:57

nierro
Member
From: Milan, Italy
Registered: 2011-09-02
Posts: 809

Re: [SOLVED] Systemd asking for authentication to suspend all of a sudden

Are you starting your session on the same tty where you login?
Post the output of

loginctl show-session 1

Online

#3 2012-09-21 13:46:07

usagi
Member
Registered: 2011-11-21
Posts: 54

Re: [SOLVED] Systemd asking for authentication to suspend all of a sudden

Yes, I'm starting x using the login TTY.

Output (NAME line redacted)

Id=1
Timestamp=Fri, 21 Sep 2012 08:42:37 -0400
TimestampMonotonic=18356735
DefaultControlGroup=name=systemd:/user/*<<name>>*/1
VTNr=1
TTY=tty1
Remote=no
Service=login
Leader=405
Audit=1
Type=tty
Class=user
Active=no
State=online
KillProcesses=no
IdleHint=yes
IdleSinceHint=1348231814952301
IdleSinceHintMonotonic=475789691

Last edited by usagi (2012-09-21 13:48:41)

Offline

#4 2012-09-21 13:50:31

nierro
Member
From: Milan, Italy
Registered: 2011-09-02
Posts: 809

Re: [SOLVED] Systemd asking for authentication to suspend all of a sudden

Active should be yes.
You're on tty7, or tty2, aren't you? You autologin in tty1, and then startx from there, but x starts on another tty, this is the problem.
Read here: https://wiki.archlinux.org/index.php/Sy … emd-logind .

Online

#5 2012-09-21 13:52:21

65kid
Member
From: Germany
Registered: 2011-01-26
Posts: 663

Re: [SOLVED] Systemd asking for authentication to suspend all of a sudden

your session isn't properly registered (Active=no). Not sure on this, but maybe a missing "exec" is to blame:

exec ck-launch-session /usr/bin/i3

you might also want to take a look at:
https://wiki.archlinux.org/index.php/Sy … emd-logind

@nierro: starting X on the same tty afaik should not be neccessary if he is using ck-launch-session, only if he's using logind directly (as explained in the wiki).

Last edited by 65kid (2012-09-21 13:53:16)

Offline

#6 2012-09-21 13:56:36

nierro
Member
From: Milan, Italy
Registered: 2011-09-02
Posts: 809

Re: [SOLVED] Systemd asking for authentication to suspend all of a sudden

Oh damn, you're right, sorry...i completely forgot about ck...sorry, i'm not using it anymore since 2 weeks...

Online

#7 2012-09-21 14:13:23

usagi
Member
Registered: 2011-11-21
Posts: 54

Re: [SOLVED] Systemd asking for authentication to suspend all of a sudden

Well, i switched to logind and started X in vt01. Works like a charm! i wonder what happened to cause it to suddenly fail if it's been wrong for 4 months?

Offline

#8 2012-09-21 14:23:02

nierro
Member
From: Milan, Italy
Registered: 2011-09-02
Posts: 809

Re: [SOLVED] Systemd asking for authentication to suspend all of a sudden

May be you have testing repo on? Because two days ago polkit has been upgrade, with logind support. May be that is the cause, even if it *shouldn't*.

Online

#9 2012-09-21 14:31:43

usagi
Member
Registered: 2011-11-21
Posts: 54

Re: [SOLVED] Systemd asking for authentication to suspend all of a sudden

THAT makes sense, and would explain my lack of issues on my laptop, which does not have [testing] enabled.

Cheers!!

Offline

#10 2012-10-06 11:04:27

salvojimmy
Member
Registered: 2012-10-06
Posts: 2

Re: [SOLVED] Systemd asking for authentication to suspend all of a sudden

Hello,

I have the same problem, I cannot start X into the same tty. I followed the procedure in the wiki to replace consolekit with systemd following this one https://wiki.archlinux.org/index.php/Sy … md-logind/  but with no luck. The problem is only into X.

loginctl gives the following

Id=1
Timestamp=Sat, 06 Oct 2012 14:48:23 +0200
TimestampMonotonic=13714786
DefaultControlGroup=name=systemd:/user/user/1
VTNr=1
TTY=tty1
Remote=no
Service=login
Leader=223
Audit=1
Type=tty
Class=user
Active=no
State=online
KillProcesses=no
IdleHint=yes
IdleSinceHint=1349527696047839
IdleSinceHintMonotonic=6575930

I know that Active should be yes but I cant figure out how to do it

Thanks

Offline

#11 2012-10-06 12:12:50

nierro
Member
From: Milan, Italy
Registered: 2011-09-02
Posts: 809

Re: [SOLVED] Systemd asking for authentication to suspend all of a sudden

Online

#12 2012-10-06 14:21:09

salvojimmy
Member
Registered: 2012-10-06
Posts: 2

Re: [SOLVED] Systemd asking for authentication to suspend all of a sudden

Thanks, that was the one!! I even removed the auto login bit. I couldn't wait to get rid of console kit..

Grazie tante di nuovo

Offline

Board footer

Powered by FluxBB