You are not logged in.

#1 2017-02-05 14:30:15

FlowIt
Member
Registered: 2014-10-25
Posts: 239

running X without session manager

Just out of curiosity I wrote a little script to bypass xinit/startx and my session manager. It looks like this:

X -keeptty -nolisten tcp -br +bs vt1 &
export DISPLAY=":0.0"
sleep 8
xfsettingsd --sm-client-disable
xfwm4 --sm-client-disable --daemon
xfce4-panel --sm-client-disable &
xfdesktop --sm-client-disable &

Certainly, this is not the nicest script but for me it's just an experiment where I can improve it later on. My question is (not specifically tied to Xfce): What do I lose when I start up my graphical session like this? Quoting Wikipedia, "an X session manager is a session management program, a program that can save and restore the current state of a set of running applications". This I don't do. But is this everything? Do I lose something in security (session managers usually pull in some authentication mechanisms)?

Offline

#2 2017-02-05 14:53:07

Lone_Wolf
Member
From: Netherlands, Europe
Registered: 2005-10-04
Posts: 11,911

Re: running X without session manager

you probably don't have  a valid polkit/logind session  now, this can break automounting & power management options for normal users.

$ loginctl show-session $XDG_SESSION_ID

Disliking systemd intensely, but not satisfied with alternatives so focusing on taming systemd.


(A works at time B)  && (time C > time B ) ≠  (A works at time C)

Offline

#3 2017-02-05 17:29:46

FlowIt
Member
Registered: 2014-10-25
Posts: 239

Re: running X without session manager

Id=c1
User=1000
Name=username
Timestamp=Sun 2017-02-05 15:13:36 EST
TimestampMonotonic=20740090
VTNr=1
Seat=seat0
TTY=tty1
Remote=no
Service=login
Scope=session-c1.scope
Leader=291
Audit=0
Type=tty
Class=user
Active=yes
State=active
IdleHint=yes
IdleSinceHint=1486312415282637
IdleSinceHintMonotonic=8419387082
LockedHint=no

It looks like logind works fine and I don't use polkit.

Offline

#4 2017-02-05 17:33:06

Trilby
Inspector Parrot
Registered: 2011-11-29
Posts: 29,523
Website

Re: running X without session manager

This seems to be a very very odd approach.  Why not use xinit/startx?  There is no need to run a session manager with xinit/startx, jut start your WM in your xinitrc instead of after an odd "sleep 8" in that script.


"UNIX is simple and coherent..." - Dennis Ritchie, "GNU's Not UNIX" -  Richard Stallman

Offline

Board footer

Powered by FluxBB