From owner-freebsd-questions@FreeBSD.ORG Mon Oct 31 19:12:51 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 BBD6D106566C for ; Mon, 31 Oct 2011 19:12:51 +0000 (UTC) (envelope-from jhs@berklix.com) Received: from tower.berklix.org (tower.berklix.org [83.236.223.114]) by mx1.freebsd.org (Postfix) with ESMTP id 2AF508FC13 for ; Mon, 31 Oct 2011 19:12:50 +0000 (UTC) Received: from mart.js.berklix.net (pD9FBF8E9.dip.t-dialin.net [217.251.248.233]) (authenticated bits=0) by tower.berklix.org (8.14.2/8.14.2) with ESMTP id p9VJCcG3004938; Mon, 31 Oct 2011 19:12:39 GMT (envelope-from jhs@berklix.com) Received: from fire.js.berklix.net (fire.js.berklix.net [192.168.91.41]) by mart.js.berklix.net (8.14.3/8.14.3) with ESMTP id p9VJCRAQ003529; Mon, 31 Oct 2011 20:12:29 +0100 (CET) (envelope-from jhs@berklix.com) Received: from fire.js.berklix.net (localhost [127.0.0.1]) by fire.js.berklix.net (8.14.4/8.14.4) with ESMTP id p9VJBvFL058118; Mon, 31 Oct 2011 19:12:03 GMT (envelope-from jhs@fire.js.berklix.net) Message-Id: <201110311912.p9VJBvFL058118@fire.js.berklix.net> To: Jason Helfman From: "Julian H. Stacey" Organization: http://www.berklix.com BSD Unix Linux Consultancy, Munich Germany User-agent: EXMH on FreeBSD http://www.berklix.com/free/ X-URL: http://www.berklix.com In-reply-to: Your message "Mon, 31 Oct 2011 11:25:32 MST." <20111031182532.GF82316@eggman.experts-exchange.com> Date: Mon, 31 Oct 2011 20:11:57 +0100 Sender: jhs@berklix.com Cc: Damien Fleuriot , Dan Nelson , FreeBSD Questions , Modulok Subject: Re: idletime in login.conf 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, 31 Oct 2011 19:12:51 -0000 Hi, Reference: > From: Jason Helfman > Date: Mon, 31 Oct 2011 11:25:32 -0700 > Message-id: <20111031182532.GF82316@eggman.experts-exchange.com> Jason Helfman wrote: > On Mon, Oct 31, 2011 at 10:09:34AM -0500, Dan Nelson thus spake: > >In the last episode (Oct 31), Damien Fleuriot said: > >> On 30 Oct 2011, at 16:45, Modulok wrote: > >> > List, > >> > > >> > Goal: Automatically logoff users that are idle after 'x' minutes. > >> > > >> > Attempt: I added this to /etc/login.conf to the default login class: > >> > > >> > :idletime=10m: > >> > > >> > I then rebuilt the database: > >> > > >> > cap_mkdb /etc/login.conf > >> > > >> > Problem: It doesn't work. The 'w' command shows users idle for 20 > >> > minutes or more. I'm missing something. Other than an autologout shell > >> > variables, how do I force idle users to logout? > >> > >> Are these users that logged in after or before your change ? > >> > >> Obviously the idle timeout only applies to users who logged in after you > >> adjusted the value and rebuilt the db. > > > >Actually, the idle timeout is not implemented in the base system. It's > >there in case someone writes a 3rd-party module that does idle detection. > >See the login.conf manpage: > > > >RESERVED CAPABILITIES > > The following capabilities are reserved for the purposes indicated and > > may be supported by third-party software. They are not implemented in > > the base system. > >[...] > > idletime time Maximum idle time before logout. > > > > > You may want to look into /usr/ports/sysutils/doinkd for this. I use it on > many systems, and it works remarkable well, and it is highly configurable. > > -jgh > > -- > Jason Helfman > System Administrator That was a useful tip, but people (inc. self) will not remember. Suggestion: use send-pr to submit a diff to add SEE ALSO ports/sysutils/doinkd to man login.conf Cheers, Julian -- Julian Stacey, BSD Unix Linux C Sys Eng Consultants Munich http://berklix.com Reply below, not above; Indent with "> "; Cumulative like a play script. Format: Plain text. Not HTML, multipart/alternative, base64, quoted-printable.