From owner-freebsd-questions@FreeBSD.ORG Mon Sep 26 15:28:13 2011 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 971DD106566C for ; Mon, 26 Sep 2011 15:28:13 +0000 (UTC) (envelope-from olivares14031@gmail.com) Received: from mail-iy0-f182.google.com (mail-iy0-f182.google.com [209.85.210.182]) by mx1.freebsd.org (Postfix) with ESMTP id 6454B8FC08 for ; Mon, 26 Sep 2011 15:28:13 +0000 (UTC) Received: by iadk27 with SMTP id k27so7433442iad.13 for ; Mon, 26 Sep 2011 08:28:12 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type:content-transfer-encoding; bh=phN2KeqR1xSUzGvdQQEeWeDlDDFxOtp94fC7Osr1F+o=; b=e5kf/sIzyjNYyBfx71AgDaeRX5w6tOicDETthfQzNfT8UK3Vl7EsfzkPqz51cxNxHp uL40OUuswaRs3HlAM0EryqqSzFB4pGl0Hax6GY5qkwBztesUHAVw4NbmQhW75rfW3asf 8aQTDbT+FroAxdi14VKjuWZH4inhEzLDhZorw= MIME-Version: 1.0 Received: by 10.42.137.1 with SMTP id w1mr7789814ict.29.1317050892857; Mon, 26 Sep 2011 08:28:12 -0700 (PDT) Received: by 10.42.177.199 with HTTP; Mon, 26 Sep 2011 08:28:12 -0700 (PDT) In-Reply-To: <4E7F4F14.7000408@infracaninophile.co.uk> References: <4E7F4F14.7000408@infracaninophile.co.uk> Date: Mon, 26 Sep 2011 10:28:12 -0500 Message-ID: From: Antonio Olivares To: Matthew Seaman Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Cc: freebsd-questions@freebsd.org Subject: Re: autologin on default shell /bin/sh X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 26 Sep 2011 15:28:13 -0000 On Sun, Sep 25, 2011 at 10:56 AM, Matthew Seaman 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