osbuild / osbuild-composer

An HTTP service for building bootable OS images.
https://www.osbuild.org
Apache License 2.0
166 stars 107 forks source link

Can't easily get the reason why a compose failed #4429

Open jbenc opened 1 month ago

jbenc commented 1 month ago

The documentation says to use composer-cli compose status to get the build status. However, when something gets wrong, only FAILED is displayed. That doesn't help to figure out what happened.

You need to go hunting for the logs. However, there's no documentation where to find the logs. In my case, I eventually found the error in journalctl -u osbuild-worker@1. That's far from obvious. Furthermore, the error there is present as a Python backtrace only; at least that's been the case for the errors I've hit so far (https://github.com/osbuild/osbuild-composer/issues/4427 and getting out of disk space).

I'd expect either composer-cli compose status to get me the error, or to have a (documented!) another subcommand that displays the error for the particular failed compose in a useful and preferably actionable way (i.e. not a backtrace).

bcl commented 1 month ago

composer-cli compose logs UUID may get you more detail, but in general yes the logging and debugging of failures is something that needs improvement.

jbenc commented 1 month ago

composer-cli compose logs UUID produces a tarball with a single file which contains a single line The compose result is empty. That's not useful.