CloudInit logs #1164
-
Hi, For example, if a something in cloud-init file (for example a command) fails, how can we get logs about this? Thank you |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
Hi! on version lower than 2.0.0, the "cloud-init" stages execution is done via systemd services so you should be able to gather their logs with a simple journalctl -u cos-setup-STAGE The service names are as follows: cos-setup-rootfs For versions higher or equal to 2.0.0, the rootfs and initramfs stages are now run via immucore and that stores the rootfs and initramfs logs to the /run/immucore dir. It also allows you to enable debug mode for the runs by settings |
Beta Was this translation helpful? Give feedback.
Hi!
on version lower than 2.0.0, the "cloud-init" stages execution is done via systemd services so you should be able to gather their logs with a simple journalctl -u cos-setup-STAGE
The service names are as follows:
cos-setup-rootfs
cos-setup-initramfs
cos-setup-network
cos-setup-boot
cos-setup-fs
cos-setup-reconcile
For versions higher or equal to 2.0.0, the rootfs and initramfs stages are now run via immucore and that stores the rootfs and initramfs logs to the /run/immucore dir.
It also allows you to enable debug mode for the runs by settings
rd.immucore.debug
in the cmdline