You are not logged in.

#1 2013-08-10 12:49:57

fruktstav
Member
Registered: 2012-10-31
Posts: 6

SLiM opens a second dialogue after login

As the subject states, after I have logged in to my account I am met by a second SLIM dialogue, after which I am logged in as I should be.

So, something must be launching a second instance of SLiM on login to my account, right?

Here's from my slim.conf:

login_cmd           exec /bin/bash -login ~/.xinitrc %session

and here is my .xinitrc file:

exec openbox-session &
exec nitrogen --restore &
exec tint2 &
exec tilda &

What's baffling to me is that even though SLiM is suppose to run the 'openbox-session'-command on login, when I remove the 'exec openbox-session' from my .xinitrc file SLiM logs me in without any WM at all.

I might add that the only things I'm aware of having done to SLiM is to install it using pacman and then activating the service with systemctl.

Please help :<

Another quick question, how do I start wifi-radar as a service? I've tried 'systemctl enable wifi-radar.service' but it only returns a file not found error.. Thanks!

Offline

#2 2013-08-10 15:30:56

Raynman
Member
Registered: 2011-10-22
Posts: 1,539

Re: SLiM opens a second dialogue after login

Why are you combining exec with backgrounding (with &)?

Slim runs a bash instance that executes .xinitrc. Slim does not parse .xinitrc and does not really care whether openbox-session is in there or not. Typically the last line in .xinitrc is

exec $SOME_DE_OR_WM

so that the bash instance is replaced by $SOME_DE_OR_WM. It should work without exec, but then the bash instance lives on. Slim waits for this process (either bash or the exec'ed program) to return and then it shows you another login screen.

You are backgrounding all programs started from your .xinitrc, so the bash process exits almost immediately and you are presented with the slim dialogue. In the meantime, openbox and the other programs are starting in the background.

Backgrounding is useful to start other programs before launching openbox-session, especially daemons (otherwise the rest of the script never gets executed). As an alternative, I think openbox has some kind of autostart script.

Second question: I don't know wifi-radar, but if it doesn't provide a service file, you can create one yourself. Read systemd wiki and man pages (because wiki is good but not perfect).

Last edited by Raynman (2013-08-10 15:32:34)

Offline

Board footer

Powered by FluxBB