Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 26 Sep 2011 10:28:12 -0500
From:      Antonio Olivares <olivares14031@gmail.com>
To:        Matthew Seaman <m.seaman@infracaninophile.co.uk>
Cc:        freebsd-questions@freebsd.org
Subject:   Re: autologin on default shell /bin/sh
Message-ID:  <CAJ5UdcMbWFgDPSJbP-_eR%2BoUL6wy7F2CK5sCCHSvDFP2XbiCSA@mail.gmail.com>
In-Reply-To: <4E7F4F14.7000408@infracaninophile.co.uk>
References:  <CAJ5UdcN7px94fjidvTkdB53Kc7KNO9939kpk%2BAmUohqc_7m%2BMA@mail.gmail.com> <4E7F4F14.7000408@infracaninophile.co.uk>

next in thread | previous in thread | raw e-mail | index | archive | help
On Sun, Sep 25, 2011 at 10:56 AM, Matthew Seaman
<m.seaman@infracaninophile.co.uk> wrote:
> On 25/09/2011 16:16, Antonio Olivares wrote:
>> I have a 9.0 BETA 2 amd64 machine and I am using /bin/sh shell or
>> default shell when one installs FreeBSD. =A0I want to be able to setup
>> autologin and automatic startx as well like I have on the other
>> machines
>>
>> I tried to edit ~/.cshrc and copied W Block's example, but it did not wo=
rk
>>
>> https://freebsd-forums.liquidneon.com/showthread.php?t=3D22304
>>
>> How can I get it without using bash? =A0Do I need to create a
>> ~/.csh_login file and add the code to startx?
>> I have tried to add to ~/.cshrc the code:
>>
>> if [ `/usr/bin/tty` =3D '/dev/ttyv0' ]; then
>> =A0 =A0 /usr/local/bin/startx
>> fi
>>
>> and it does not work.
>
> If the shell on your auto-login account is /bin/sh, then you should =A0pu=
t
> your X startup in .profile -- syntax is identical to the bash example
> you showed.
>
> If the shell on your auto-login account is /bin/csh or /bin/tcsh (which
> are really exactly the same thing on FreeBSD), then you should put your
> X startup in .login In this case the syntax is different, but you can
> copy wblock's example from the forum thread you referenced.
>
> Either of those shells should work.
>
> =A0 =A0 =A0 =A0Cheers,
>
> =A0 =A0 =A0 =A0Matthew
>
> --
> Dr Matthew J Seaman MA, D.Phil. =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 7 Pri=
ory Courtyard
> =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =
=A0 =A0 =A0 =A0 =A0 =A0 =A0Flat 3
> PGP: http://www.infracaninophile.co.uk/pgpkey =A0 =A0 Ramsgate
> JID: matthew@infracaninophile.co.uk =A0 =A0 =A0 =A0 =A0 =A0 =A0 Kent, CT1=
1 9PW
>
>

Thanks Dr Matthew, Warren & others who have made suggestions.

It works [FreeBSD 9.0 BETA 2] partially.

$ uname -a
FreeBSD e213-amd64-1.grullahighschool.org 9.0-BETA2 FreeBSD 9.0-BETA2
#0: Tue Sep 20 10:02:05 CDT 2011
root@e213-amd64-1:/usr/obj/usr/src/sys/GENERIC  amd64
$

They have changed /etc/gettytab from cons25 to xterm, and even
changing it to cons25 back has no effect.  If I type my username and
login, startx starts automatically, but after I have logged in by
typing my username and password.

This is an excerpt of /etc/ttys on FreeBSD 9.0 BETA 2

ttyv0   "/usr/libexec/getty Pc"         xterm   on  secure
# Virtual terminals
ttyv1   "/usr/libexec/getty Pc"         xterm   on  secure
ttyv2   "/usr/libexec/getty Pc"         xterm   on  secure
ttyv3   "/usr/libexec/getty Pc"         xterm   on  secure
ttyv4   "/usr/libexec/getty Pc"         xterm   on  secure
ttyv5   "/usr/libexec/getty Pc"         xterm   on  secure
ttyv6   "/usr/libexec/getty Pc"         xterm   on  secure

Something is restricting the automatic login, but don't know how to
troubleshoot this.

Regards,

Antonio



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CAJ5UdcMbWFgDPSJbP-_eR%2BoUL6wy7F2CK5sCCHSvDFP2XbiCSA>