[lxc-devel] my fedora container and the host time/date are different.

Michael H. Warfield mhw at WittsEnd.com
Mon Jun 9 22:32:12 UTC 2014


On Mon, 2014-06-09 at 14:55 -0700, Steven Howe wrote:
> The container is at 
> Mon Jun  9 21:51:44 UTC 2014

> while the host is at
> Mon Jun  9 14:52:14 PDT 2014

Date and time look about the same to me, just the TZ is off.

> I have set the /etc/localtime to the same value as the host, then
> restarted, but nothing changed.

Make sure it's set as a symlink to the appropriate file
in /usr/share/zoneinfo/ and don't just copy it.

-- 
[root at hydra ~]# ls -l /etc/localtime 
lrwxrwxrwx. 1 root root 36 Oct 13  2013 /etc/localtime -> /usr/share/zoneinfo/America/New_York
-- 

> Any suggestions?

What version LXC are you running?  The old (0.9.0) Fedora template use
to not set this.  The newer template does, upon container creation.  It
does work.  I've done this and you do not need to restart the container
(just any affected applications).
> 
If it didn't work, then you must have done something wrong in
setting /etc/localtime because it does work.

> Steven
> 
Regards,
Mike
-- 
Michael H. Warfield (AI4NB) | (770) 978-7061 |  mhw at WittsEnd.com
   /\/\|=mhw=|\/\/          | (678) 463-0932 |  http://www.wittsend.com/mhw/
   NIC whois: MHW9          | An optimist believes we live in the best of all
 PGP Key: 0x674627FF        | possible worlds.  A pessimist is sure of it!

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 482 bytes
Desc: This is a digitally signed message part
URL: <http://lists.linuxcontainers.org/pipermail/lxc-devel/attachments/20140609/47a1fb70/attachment.sig>


More information about the lxc-devel mailing list