[Solved]enable autologin

Configuring and tweaking your GhostBSD System.

[Solved]enable autologin

Postby christophe60_fr » Thu Oct 20, 2016 4: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 12:44 pm, edited 1 time in total.
christophe60_fr
 
Posts: 26
Joined: Thu Oct 29, 2015 2:05 pm
Has thanked: 0 time
Been thanked: 0 time

[Solved]enable autologin


Re: enable autologin

Postby ASX » Thu Oct 20, 2016 6: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: 968
Joined: Wed May 06, 2015 11:46 am
Has thanked: 57 times
Been thanked: 128 times

Re: enable autologin

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

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

Re: [Solved]enable autologin

Postby purebsd » Sat Dec 10, 2016 11:47 pm

I had the same question. Thanks!
purebsd
 
Posts: 1
Joined: Sat Dec 10, 2016 11:04 pm
Has thanked: 0 time
Been thanked: 0 time

Re: [Solved]enable autologin

Postby ASX » Sun Dec 11, 2016 8:57 am

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: 968
Joined: Wed May 06, 2015 11:46 am
Has thanked: 57 times
Been thanked: 128 times


Return to Tips and Tricks

Who is online

Users browsing this forum: No registered users and 2 guests