public inbox for gentoo-user@lists.gentoo.org
 help / color / mirror / Atom feed
From: walt <w41ter@gmail.com>
To: gentoo-user@lists.gentoo.org
Subject: [gentoo-user] Re: [poll] What is your session state?
Date: Mon, 10 Feb 2014 16:03:24 -0800	[thread overview]
Message-ID: <52F968CC.4030003@gmail.com> (raw)
In-Reply-To: <CADPrc80QSZBcmWRuv20fCWg7QCyYFBhD+yL7k98rjYK7eozVLQ@mail.gmail.com>

On 02/09/2014 06:06 PM, Canek Peláez Valdés wrote:
> On Sun, Feb 9, 2014 at 4:43 PM, walt <w41ter@gmail.com> wrote:
>> Recent threads about consolekit vs logind(systemd) have made me curious, so
>> I've been studying...
>>
>> A few of us have had recent problems with things like plugging USB sticks,
>> which once worked transparently but now require root privileges.
>>
>> I've discovered that my own such problems are caused by this:
>>
>> $loginctl show-session 1   (I have only one session, cleverly named '1')
>>
>> Id=1
>> Timestamp=Sun 2014-02-09 07:18:32 PST
>> TimestampMonotonic=389744251
>> VTNr=1
>> TTY=/dev/tty1
>> Remote=no
>> Service=login
>> Scope=session-1.scope
>> Leader=426
>> Audit=1
>> Type=tty
>> Class=user
>> Active=no   <=========================  should be 'yes'
>> State=online  <=======================  should be 'active'
>>
>> Users of consolekit, don't feel neglected.  You should try this instead:
>>
>> $ck-list-sessions
>> Session1:
>>         unix-user = '1001'
>>         realname = '(null)'
>>         seat = 'Seat2'
>>         session-type = ''
>>         active = FALSE    (correct because I'm ssh'd into a remote box)
>>         x11-display = ':0'
>>         x11-display-device = '/dev/tty2'
>>         display-device = '/dev/tty1'
>>         remote-host-name = ''
>>         is-local = FALSE
>>         on-since = '2014-02-09T22:00:10.750312Z'
>>         login-session-id = '1'
>>
>> Canek explained that the reason my session is not 'active' is that I'm
>> not using a Display Manager (gdm kdm lightdm), which talks to logind or
>> consolekit and vouches for my physical presence at the local keyboard.
>>
>> However, when I do the same thing on arch linux (as a virtualbox guest)
>> I see that my session (running gnome) is 'active' and I have no trouble
>> powering off the virtual machine as an unprivileged user.
> 
> Hi Walt; since I already have GNOME 3+systemd, I decided to install
> Xfce. Given that all the plumbing is essentially the same for both
> desktops, it took less than 15 minutes for portage to emerge it (13
> small packages).
> 
> I started it like you, with "exec startxcfe4" in my $HOME/.xinitrc.
> Boy, I had forgotten how desktops looked at the start of the century.

Which century?  :p

> 
> Anyway, I had exactly the same problem as you; I needed my root
> password to mount USB sticks or shutdown the machine. My session was
> Active=no, State=online.
> 
> As I suspected, if I started Xfce through gdm, everything worked
> without any issue; session was Active=yes, State=active, and my root
> password was not required for anything. So one workaround is to
> install gdm,  but that is ugly (and unnecessary, see below).
> 
>> Any ideas how I can fix it?
> 
> Yeah, I found the solution on the net:
> 
> http://blog.falconindy.com/articles/back-to-basics-with-x-and-systemd.html

Thank you!

> 
> Basically, invoke startx passing Xorg the option of which VT you want
> to "transfer" for your X11 session:
> 
> startx -- vt01
> 
> Obviously, that only works if you are in VT 1 (Alt-F1).

What an obvious fix, once you understand the underlying problem.

BTW (thinking seat0) I typed "startx --vt0"  That was interesting.
(But not recommended :)  

> I owe you an apology Walter; I just assumed you had configured
> something wrong. I'm just getting used to the fact that with GNOME
> 3+systemd everything kinda works immediately. Sorry.

No problem Canek.  I'd never have got this far without your suggestions
and hints.

> I really don't understand
> how could I get any work done before using GNOME Shell.

Hmm.  I think by 3.12 I'll be ready to give it another try.  Meanwhile
I'll stick to an earlier century :)
 



  reply	other threads:[~2014-02-11  0:03 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-02-09 22:43 [gentoo-user] [poll] What is your session state? walt
2014-02-10  2:06 ` Canek Peláez Valdés
2014-02-11  0:03   ` walt [this message]
2014-02-10  8:13 ` Stefan G. Weichinger
2014-02-10  8:36   ` J. Roeleveld
2014-02-10 15:13     ` Canek Peláez Valdés
2014-02-10 15:52       ` Stefan G. Weichinger
2014-02-10 15:55         ` Canek Peláez Valdés
2014-02-10 15:58           ` Stefan G. Weichinger
2014-02-10 16:11             ` Canek Peláez Valdés
2014-02-10 20:32               ` Stefan G. Weichinger
2014-02-10 15:12   ` Canek Peláez Valdés
2014-02-10 15:50     ` Stefan G. Weichinger
2014-02-10 15:55       ` Canek Peláez Valdés
2014-02-10 10:52 ` Samuli Suominen
2014-02-10 15:24   ` Canek Peláez Valdés

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=52F968CC.4030003@gmail.com \
    --to=w41ter@gmail.com \
    --cc=gentoo-user@lists.gentoo.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox