cloud-init.log inconsistent date format
Bug #1351960 reported by
Darik Horn
This bug affects 1 person
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
cloud-init |
Fix Released
|
Medium
|
Joshua Harlow |
Bug Description
The first field of the /var/log/
2014-08-03 01:45:53,472 - util.py[DEBUG]: Read 12 bytes from /proc/uptime
2014-08-03 01:45:53,472 - util.py[DEBUG]: cloud-init mode 'init' took 12.704 seconds (12.71)
Aug 3 01:45:56 test209 [CLOUDINIT] util.py[DEBUG]: Cloud-init v. 0.7.5 running 'modules:config' at Sun, 03 Aug 2014 01:45:56 +0000. Up 94.33 seconds.
Aug 3 01:45:56 test209 [CLOUDINIT] importer.py[DEBUG]: Looking for modules ['cc_emit_upstart', 'cloudinit.
Expected behavior is consistency in the date format.
Changed in cloud-init: | |
assignee: | nobody → Joshua Harlow (harlowja) |
milestone: | none → 0.7.7 |
Changed in cloud-init: | |
milestone: | 0.7.7 → 0.7.8 |
Changed in cloud-init: | |
milestone: | 0.7.8 → 0.7.9 |
Changed in cloud-init: | |
milestone: | 0.7.9 → none |
status: | Confirmed → Fix Released |
To post a comment you must log in.
Well, i can give an explanation as to why this is the way it is, and how you could change it. cloud-init. log "directly" as it runs before syslog is up.
It is how it is because cloud-init first goes to /var/log/
Then, it transfers over to writing its logs to rsyslog, which in turn re-directs them there.
I agree that is annoying. maybe we could disable rsyslog logging by default (which might fix another isue).
Anyway, if you want consistentsy, you can set the format string in cloud.cfg. d/05_logging. cfg
or you could disable the attempt to use log_syslog.
To disable log_syslog, you could just do:
#cloud-config:
log_cfgs:
- [ *log_base, *log_file ]
If you want to pass that in via user-data, you'd have to copy the content of those yaml references (see the file, you'll probably understand).