← Back to team overview

group.of.nepali.translators team mailing list archive

[Bug 1543025] Re: Wrong UTC zoneinfo in cloud-images

 

I think the bug is here in cloudinit/distros/__init__.py:

def set_etc_timezone(tz, tz_file=None, tz_conf="/etc/timezone",
                     tz_local="/etc/localtime"):
    util.write_file(tz_conf, str(tz).rstrip() + "\n")
    # This ensures that the correct tz will be used for the system
    if tz_local and tz_file:
        util.copy(tz_file, tz_local)
    return

/etc/localtime ought to be a symlink to the selected file in
/usr/share/zoneinfo/, not a copy (it used to in the past due to the
possibility of /usr/ being on a separate file system, but that got fixed
by initramfs-tools in a better way now). So with the copy() the symlink
doesn't get updated, and instead it clobbers the file in /usr/.

** Changed in: cloud-init (Ubuntu)
       Status: New => Triaged

** Also affects: cloud-init (Ubuntu Xenial)
   Importance: High
       Status: Triaged

-- 
You received this bug notification because you are a member of नेपाली
भाषा समायोजकहरुको समूह, which is subscribed to Xenial.
Matching subscriptions: Ubuntu 16.04 Bugs
https://bugs.launchpad.net/bugs/1543025

Title:
  Wrong UTC zoneinfo in cloud-images

Status in cloud-init package in Ubuntu:
  Triaged
Status in cloud-init source package in Xenial:
  Triaged

Bug description:
  ADT runs use cloud-images to create test VM environments. For the Xenial cloud-images I observed a weird issue where libvirt suddenly fails its build-time tests on a time offset test on UTC.
  Looking at the prepared image (cloud-init did already run there), I found that indeed a command-line of

  TZ=UTC date

  reports a CET based time. Looking further this seems to drill down
  into

  /usr/share/zoneinfo/UTC -> Zulu

  and that (Zulu another term for UTC) Zulu file looks quite bigger that
  the same on other hosts and contains the CET string as well (normal
  ~128b, wrong size 2335). Forcing a reinstall of tzdata will fix the
  file and also allows the libvirt test to pass.

  So I am not sure this is wrong in the initial image base or gets in
  some way broken during cloud-init. Thats why I start reporting it
  against cloud-init.

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/cloud-init/+bug/1543025/+subscriptions