cirruslabs / cirrus-ci-docs

Documentation for Cirrus CI 📚
https://cirrus-ci.org
MIT License
352 stars 109 forks source link

Instance-specific logs #817

Open edigaryev opened 3 years ago

edigaryev commented 3 years ago

Currently, only instructions (e.g. scripts) inside of tasks can produce log output.

However, when running a whole VM instances, most of the time additional context like serial port output can be pulled through an API and provided to the user.

Here's a real use-case for this:

Since it was already my lucky day, I decided to push it and again went poking around my cloud's WebUI. Eventually, I found another incredibly handy little setting: Serial-console output log.

This was basically a direct, low-level communication line straight into the kernel. If something were happening horrible enough for a complete system-hang, surely the kernel would be screaming out of its virtual serial port.

(https://www.redhat.com/sysadmin/linux-troubleshooting-navigating-perfect-storm)

fkorotkov commented 3 years ago

Related to #402

fkorotkov commented 3 years ago

@cevich, thank you for the inspiration!

cevich commented 3 years ago

Oh! This would be handy on occasion. You never know when a kernel panic will happen, and it may not be easily reproducible. Though I would suggest making it optional, in case log storage-space is a concern for people. There are cases where console output can be overwhelmingly huge depending on the OS/Distro/Version. Some are very liberal with their printk() and some syslog/rsyslog configs can send lots of system messages to the console. I can say at least for GCP, the default access permissions DO allow reading from VM serial-ports, just not connecting to them interactively. So nothing should be needed to set this up on the cloud-side.