From owner-freebsd-questions@freebsd.org Mon Dec 4 10:29:57 2017 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 E86D1DF763F for ; Mon, 4 Dec 2017 10:29:57 +0000 (UTC) (envelope-from erwan@rail.eu.org) Received: from voyageurs.rail.eu.org (voyageurs.rail.eu.org [IPv6:2001:bc8:30d3::1]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id B481E241B for ; Mon, 4 Dec 2017 10:29:57 +0000 (UTC) (envelope-from erwan@rail.eu.org) Received: from [IPv6:2001:bc8:30d3:3040:6267:20ff:fede:1808] (unknown [IPv6:2001:bc8:30d3:3040:6267:20ff:fede:1808]) by voyageurs.rail.eu.org (Postfix) with ESMTPSA id 16F8D2CC064A for ; Mon, 4 Dec 2017 11:29:47 +0100 (CET) Subject: Re: tzsetup without menu? To: freebsd-questions@freebsd.org References: <776CD363-26A1-4628-B21E-2CA266609BAE@luckyhands.nl> From: Erwan David Message-ID: <770818ba-84da-2b72-75fa-46788621986d@rail.eu.org> Date: Mon, 4 Dec 2017 11:29:46 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.5.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit Content-Language: fr DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=rail.eu.org; s=mail; t=1512383387; bh=2b7OnZIs3viP7c6guei50IJ/F4FcHd5/NNvO1OyREA8=; h=Subject:To:References:From:Message-ID:Date:MIME-Version:In-Reply-To:Content-Type:Content-Transfer-Encoding; b=gmAsR4hnEhZUiNe2B4d0T9zWFQpCFUUV0uhZHmUEFN3R8mVkTctqdw6/inihzp6cFROpnXK+9wBKUu+w671LCdj03fQotkBMrCaNIv7BG4Rb615ZJ9CrJM3wSebFZTDv+R5TLfQG2xnSzikHakCnCvK4zRviH9KDHg12r7W+zq4= X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 04 Dec 2017 10:29:58 -0000 Le 12/04/17 à 11:01, Michael Ross a écrit : > Am .12.2017, 10:32 Uhr, schrieb Remy Zandwijk : > >> The tzsetup manual page on 11.1-RELEASE-p4 says: >> >>     It is possible to short-circuit the menu system by specifying the >>     location of a zoneinfo_file or the name of the zoneinfo_name on the >>     command line; this is intended mainly for pre-configured >> installation >>     scripts or people who know which zoneinfo they want to install. >> >> >> However, when I run the command like this, I still get the menu: >> >>     tzsetup -s /usr/share/zoneinfo/Europe/Amsterdam >> >> >> >> Am I doing it wrong or does the tzsetup command not act like documented? >> >> >> -Remy >> > > I think you could just copy the zonefile > > # md5 /usr/share/zoneinfo/Europe/Berlin /etc/localtime > MD5 (/usr/share/zoneinfo/Europe/Berlin) = > 4790e83465681cefbf852aed265354bf > MD5 (/etc/localtime) = 4790e83465681cefbf852aed265354bf > > > thus > > cp /usr/share/zoneinfo/Europe/Amsterdam /etc/localtime > echo "Europe/Amsterdam" > /var/db/zoneinfo > Hi, Is there a reason to prefer cp to ln -s ? With ln -s when timezone definition gets changed in the system, the localtime gets the modification. Ansible timezone module uses a symbolic link.