From owner-freebsd-questions Mon Jul 31 9:52:48 2000 Delivered-To: freebsd-questions@freebsd.org Received: from dan.emsphone.com (dan.emsphone.com [199.67.51.101]) by hub.freebsd.org (Postfix) with ESMTP id 6596337BCA6 for ; Mon, 31 Jul 2000 09:52:43 -0700 (PDT) (envelope-from dan@dan.emsphone.com) Received: (from dan@localhost) by dan.emsphone.com (8.9.3/8.9.3) id LAA19424; Mon, 31 Jul 2000 11:52:40 -0500 (CDT) (envelope-from dan) Date: Mon, 31 Jul 2000 11:52:40 -0500 From: Dan Nelson To: Zhihui Zhang Cc: freebsd-questions@FreeBSD.ORG Subject: Re: automatic log in Message-ID: <20000731115239.A18962@dan.emsphone.com> References: <20000730205326.A18493@dan.emsphone.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline User-Agent: Mutt/1.3.6i In-Reply-To: ; from "Zhihui Zhang" on Mon Jul 31 12:40:30 GMT 2000 X-OS: FreeBSD 5.0-CURRENT Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG In the last episode (Jul 31), Zhihui Zhang said: > On Sun, 30 Jul 2000, Dan Nelson wrote: > > > In the last episode (Jul 30), Zhihui Zhang said: > > > > > > A wild thought. If I am the only user of a FreeBSD machine, can I set the > > > machine so that it automatically logs into my account after reboot? > > > Thanks. > > > > You can create a custom getty entry in /etc/gettytab with the "al" > > capability, then assign that getty entry to a vty in /etc/ttys. That > > should do it. > > > Thanks for your reply. I searched the mailing list archive. It > seems to me that I need to hack getty to achieve this. "al" was not > mentioned at all. Maybe newer versions of FreeBSD make this easy. > But at least I should have to specify the username somehow. If this > can be done without hacking any code, please give me more specific > instructions. Thanks. What version of FreeBSD are you running? It was added for version 3.2. Just edit /etc/gettytab, copy the "Pc" entry to something like "Pcautologin", add an "al=root" to it, then edit /etc/ttys and change one of ttys from "Pc" to "pcautologin". revision 1.25 date: 1999/04/04 04:36:50; author: peter; state: Exp; lines: +21 -4 Add an 'al' (autologin username) capability to getty/gettytab. This is a damn useful thing for using with serial consoles in clusters etc or secure console locations. Using a custom gettytab entry for console with an entry like 'al=root' means that there is *always* a root login ready on the console. This should replace hacks like those which go with conserver etc. (This is a loaded gun, watch out for those feet!) Submitted by: "Andrew J. Korty" -- Dan Nelson dnelson@emsphone.com To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message