From owner-freebsd-questions@FreeBSD.ORG Sat Jan 18 12:14:51 2014 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 513F25BF for ; Sat, 18 Jan 2014 12:14:51 +0000 (UTC) Received: from bs1.fjl.org.uk (bs1.fjl.org.uk [84.45.41.196]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id A5BB81B3C for ; Sat, 18 Jan 2014 12:14:50 +0000 (UTC) Received: from [192.168.1.35] (host109-156-119-17.range109-156.btcentralplus.com [109.156.119.17]) (authenticated bits=0) by bs1.fjl.org.uk (8.14.4/8.14.4) with ESMTP id s0ICEegU072180 (version=TLSv1/SSLv3 cipher=DHE-DSS-CAMELLIA256-SHA bits=256 verify=NO) for ; Sat, 18 Jan 2014 12:14:42 GMT (envelope-from frank2@fjl.co.uk) Message-ID: <52DA7032.3050109@fjl.co.uk> Date: Sat, 18 Jan 2014 12:14:42 +0000 From: Frank Leonhardt User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:24.0) Gecko/20100101 Thunderbird/24.2.0 MIME-Version: 1.0 To: freebsd-questions@freebsd.org Subject: Re: Removing user from lan. Solved! References: <52D89B2C.3080801@hdk5.net> <20140117205006.768a233e.freebsd@edvax.de> <52D98BA6.5000100@hdk5.net> In-Reply-To: <52D98BA6.5000100@hdk5.net> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Content-Filtered-By: Mailman/MimeDel 2.1.17 X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.17 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 18 Jan 2014 12:14:51 -0000 On 17/01/2014 19:59, Al Plant wrote: > Polytropon wrote: >> On Thu, 16 Jan 2014 16:53:32 -1000, Al Plant wrote: >>> Aloha, >>> >>> Could anyone please send me to a how to on removing an unwanted user >>> from the lan on FreeBSD 9 and 8. >>> I tried to remove the adduser file and name and I still cant use the >>> name that was there before. >> >> Deleting the home directory is not sufficient, as the account >> will still be active in files like /etc/passwd and the user >> database. So while an interactive login might be inhibited >> (due to a non-extisting home directory or login shell), other >> kinds of access, like FTP and maybe even scp, may still be >> possible. That's why the account has to be deleted entirely. >> The "rmuser" and "pw userdel" commands can do this. They also >> make sure the user is removed from the (generated) binary >> databases. >> >> >> >>> I read the man page and cant see from that how to get rid off all >>> the parts of the old account. >> >> You should have a look at "man rmuser" and "man pw". >> >> > ############# > > > Thanks, Olivier and Poly.... > > I finally remembered the command when you mentioned. You are great at > helping fix mind blocks. > > I just used "rmuser" and the problem is gone. > > :) 'cept that won't remove mySQL (etc), Pure-FTP, SAMBA, various email and other accounts commonly found on FreeBSD boxes. It does remove users' files from common locations (e.g. /tmp) but not the entire disk, and it does take care of crontabs. In other words, this only removes accounts assuming you are running the base system only, but if you've installed anything else you need to check them too. As I said earlier, it depends on your configuration. Regards, Frank.