From owner-freebsd-questions@freebsd.org Sat Jun 4 03:29:22 2016 Return-Path: Delivered-To: freebsd-questions@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id EDF68B69299 for ; Sat, 4 Jun 2016 03:29:22 +0000 (UTC) (envelope-from joh.hendriks@gmail.com) Received: from mail-wm0-x234.google.com (mail-wm0-x234.google.com [IPv6:2a00:1450:400c:c09::234]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 852B21665 for ; Sat, 4 Jun 2016 03:29:22 +0000 (UTC) (envelope-from joh.hendriks@gmail.com) Received: by mail-wm0-x234.google.com with SMTP id z87so16360087wmh.0 for ; Fri, 03 Jun 2016 20:29:22 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:subject:to:references:message-id:date:user-agent:mime-version :in-reply-to:content-transfer-encoding; bh=tKlFIoyaN2qW5vfsKWWSQe0wAdcj996ln1rLLBRVJ/E=; b=fXaz9Id+IH2SG7r3tCUU06r2gWHwgQ9mFBd0tNqBkQzkllBDTRbvdmh1QNARfyv6Pg hYSl2YdDKUBA4QN9nuLVFGAfZz52fPGO/ZJ9WMjAryuEwD/53Zo72fzdl469nHtXPKIi vuj/4SSjhPUsi7eH+fDHi+Z0nKaap1eeqMZaGoigWTMsbNsxfKIbTTT4KFpNVhu9ASCH AU1ug4ni/iq+e8wUQaK3jNl3FKHHGPygO1lM9Ib0Fq1GeXWt4Z3ttjoiQRU9T8YY44rz uEMJy6PldvyZj/asvTdV9BPL93Bne9Ijt8GX+JMFTYn3DQMfH6f6YoECYGtRVBZP2qL5 5PKA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:subject:to:references:message-id:date :user-agent:mime-version:in-reply-to:content-transfer-encoding; bh=tKlFIoyaN2qW5vfsKWWSQe0wAdcj996ln1rLLBRVJ/E=; b=mBnmBgtkCe0LjMMPbHj8SG3NHM3wPD8JzBs2NzP0k1E7SvfNkzFU/zJ8/gwBmOuaAy FucgGM/eS+rhIY0lN1Mu6oLxk8uP0I9r6f9CW4MDvgVGR5x/uOdxtBqgOBXvUYIdYDpo eDVsFfAITnKSRbPBKkcr+OTaqluzav1MfZq282/uaPyRwIg0Akfg6CmNpMHQiszMD0sL BUyL8ZiKdGeUCgy8d0SkgGGxMnLi2CidTp3RgIvimgj0RksNs4kHMdzvoTc6hcuWM3mO EtUcxdOdQd1LrM2QEKFsjVaidAqfTKDf+tnl8Bm/ze9YN/iHX425rPymBUN82Qa5SMKJ cgiQ== X-Gm-Message-State: ALyK8tKK0K4R+Jcip7bxrKqz0M/ndlHaowkg4wXJKugkCINd6Bkxc9pM+DM6UTPYAAOBMQ== X-Received: by 10.194.147.131 with SMTP id tk3mr6586998wjb.100.1465010959886; Fri, 03 Jun 2016 20:29:19 -0700 (PDT) Received: from Johans-MacBook-Air.local (92-111-79-242.static.chello.nl. [92.111.79.242]) by smtp.googlemail.com with ESMTPSA id m8sm8505472wjd.34.2016.06.03.20.29.19 for (version=TLSv1/SSLv3 cipher=OTHER); Fri, 03 Jun 2016 20:29:19 -0700 (PDT) From: Johan Hendriks Subject: Re: User login information on console To: freebsd-questions@freebsd.org References: <0fe96fb9-b6af-777e-9c40-d2552e05a045@gmail.com> Message-ID: <614f99ac-6367-d2c3-5893-089aea3047fb@gmail.com> Date: Sat, 4 Jun 2016 05:29:21 +0200 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.11; rv:45.0) Gecko/20100101 Thunderbird/45.1.1 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.22 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 04 Jun 2016 03:29:23 -0000 Thank you for your time. I added that line to my /root/.cshrc file, but it does not work if I add set watch = (0 root any). The users use bash, root uses csh. If I add set watch = (any any) it only prints the users already loggen on, no notifications are send when a new user su to root like below. [johan@desk ~]$ su Password: johanh has logged on pts/0 from 123.124.123.2.provider.nl johanh has logged on pts/1 from 123.124.123.2.provider.nl johanh has logged on pts/2 from 123.124.123.2.provider.nl [root@desk ~]# This is FreeBSD 10.2 amd64 btw regards Johan Op 04/06/16 om 00:07 schreef Felix Friedlander: > If you’re using csh/tcsh, then `set watch = (0 root any)’ will notify you when someone logs in or out as root. Assuming root’s shell is still (t)csh, you could put that line in /root/.cshrc to apply it for all root logins. > >> On 3 Jun 2016, at 22:13, Johan Hendriks wrote: >> >> Hello all. >> >> If someone logs in and su to root, then there is a line printed on the >> first console. >> Is it possible to print this to all logged in root users with a ssh session? >> >> regards >> Johan >> >> _______________________________________________ >> freebsd-questions@freebsd.org mailing list >> https://lists.freebsd.org/mailman/listinfo/freebsd-questions >> To unsubscribe, send any mail to "freebsd-questions-unsubscribe@freebsd.org"