From owner-freebsd-questions Thu Nov 21 10:25:31 2002 Delivered-To: freebsd-questions@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id F22F437B401 for ; Thu, 21 Nov 2002 10:25:29 -0800 (PST) Received: from smtp.infracaninophile.co.uk (happy-idiot-talk.infracaninophile.co.uk [81.2.69.218]) by mx1.FreeBSD.org (Postfix) with ESMTP id 0B09C43EAA for ; Thu, 21 Nov 2002 10:25:29 -0800 (PST) (envelope-from m.seaman@infracaninophile.co.uk) Received: from happy-idiot-talk.infracaninophile.co.uk (localhost [IPv6:::1]) by smtp.infracaninophile.co.uk (8.12.6/8.12.6) with ESMTP id gALIPPx2077367 for ; Thu, 21 Nov 2002 18:25:25 GMT (envelope-from matthew@happy-idiot-talk.infracaninophile.co.uk) Received: (from matthew@localhost) by happy-idiot-talk.infracaninophile.co.uk (8.12.6/8.12.6/Submit) id gALIPKqt077362 for questions@FreeBSD.ORG; Thu, 21 Nov 2002 18:25:20 GMT Date: Thu, 21 Nov 2002 18:25:20 +0000 From: Matthew Seaman To: questions@FreeBSD.ORG Subject: Re: Setting date with securelevel over 1 Message-ID: <20021121182520.GA77105@happy-idiot-talk.infracaninophi> Mail-Followup-To: Matthew Seaman , questions@FreeBSD.ORG References: <20021121174714.GC76311@happy-idiot-talk.infracaninophi> <5A7F3C98-FD7B-11D6-9948-000393012742@macconnect.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <5A7F3C98-FD7B-11D6-9948-000393012742@macconnect.com> User-Agent: Mutt/1.5.1i X-Spam-Status: No, hits=-2.5 required=5.0 tests=IN_REP_TO,REFERENCES,SPAM_PHRASE_01_02,USER_AGENT, USER_AGENT_MUTT version=2.43 Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Thu, Nov 21, 2002 at 01:02:09PM -0500, Brendan McAlpine wrote: > date -v +1H Ah. That doesn't actually *set* the date. It just displays the date/time one hour ahead. As the man page says: -v Adjust (i.e., take the current date and display the result of the adjustment; not actually set the date) the second, minute, hour, You need the date [[[[[cc]yy]mm]dd]HH]MM[.ss] style to actually set the date. Eg. to set the clock one hour ahead you could do: date `date -v+1H '+%Y%m%d%H%M'` Cheers, Matthew -- Dr Matthew J Seaman MA, D.Phil. 26 The Paddocks Savill Way Marlow Tel: +44 1628 476614 Bucks., SL7 1TH UK To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message