[Solved]enable autologin

Configuring and tweaking your GhostBSD System.

[Solved]enable autologin

Postby christophe60_fr » Thu Oct 20, 2016 8:51 am

Hi,

GhostBSD 10.3 XFCE 64-bit.

Is there a special way to enable autologin with Slim ?
It doesn't seem to work.

Thanks.
Last edited by christophe60_fr on Thu Oct 20, 2016 4:44 pm, edited 1 time in total.
christophe60_fr
 
Posts: 26
Joined: Thu Oct 29, 2015 6:05 pm
Has thanked: 0 time
Been thanked: 0 time

[Solved]enable autologin


Re: enable autologin

Postby ASX » Thu Oct 20, 2016 10:00 am

Yes, there is a way, a require two changes:
- edit /usr/local/etc/slim.conf: set default_user and autologin
- edit ~/.xinitrc:

the problem is .xinitrc actually contain "exec $1", where $1 is feed from slim depending on the desktop choosen using F1,
when autologin is anabled, slim doesn't feed that variable, and you need to set it explicitly, in example:
exec /usr/local/bin/startxfce4
or
exec /usr/local/bin/mate-session
depending on your desktop of choice.
ASX
Developer
 
Posts: 802
Joined: Wed May 06, 2015 3:46 pm
Location: ITALY
Has thanked: 37 times
Been thanked: 101 times

Re: enable autologin

Postby christophe60_fr » Thu Oct 20, 2016 4:41 pm

Great !
Thank you very much.
christophe60_fr
 
Posts: 26
Joined: Thu Oct 29, 2015 6:05 pm
Has thanked: 0 time
Been thanked: 0 time

Re: [Solved]enable autologin

Postby purebsd » Sun Dec 11, 2016 3:47 am

I had the same question. Thanks!
purebsd
 
Posts: 1
Joined: Sun Dec 11, 2016 3:04 am
Has thanked: 0 time
Been thanked: 0 time

Re: [Solved]enable autologin

Postby ASX » Sun Dec 11, 2016 12:57 pm

purebsd wrote:I had the same question. Thanks!


Glad it worked for you too!

For completeness, the code below (~/.xinitrc) will work with and without autologin enabled:

Code: Select all
DEFAULT=startxfce4

[ -n "$1" ] && exec $1

exec ${DEFAULT}
ASX
Developer
 
Posts: 802
Joined: Wed May 06, 2015 3:46 pm
Location: ITALY
Has thanked: 37 times
Been thanked: 101 times


Return to Tips and Tricks

Who is online

Users browsing this forum: No registered users and 1 guest