Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

tools: add logmonitor on stderr by default #123

Merged
merged 1 commit into from
May 3, 2024

Conversation

mvo5
Copy link
Contributor

@mvo5 mvo5 commented May 2, 2024

If a test fails there is little visiblity right now what exactly went wrong because the osbuild --json will default to a NullMontior.

This commit switches to a LogMontior on stderr so that if the test fails we get the full log of the operation.

This was useful to debug a failure in osbuild/osbuild#1573

If a test fails there is little visiblity right now what exactly
went wrong because the osbuild --json will default to a NullMontior.

This commit switches to a LogMontior on stderr so that if the
test fails we get the full log of the operation.
mvo5 added a commit to mvo5/manifest-db that referenced this pull request May 2, 2024
We get regular failures in the manifest-db run. With the extra
visibility from osbuild#123
it seems the errors we get (sometimes) are related to an xfs mount
```
mount/- (org.osbuild.xfs): mounting /dev/98302bc3-1aa3-4eab-96e9-9f1c6eb539ce/rootlv -> /var/lib/osbuild/store/tmp/buildroot-tmp-3y2wyhos/mounts/
mount/- (org.osbuild.xfs): already unmounted: /var/lib/osbuild/store/tmp/buildroot-tmp-3y2wyhos/mounts/
```
which looks similar the UUID clashes we observed in
osbuild/osbuild#1641

Upon inspecting the manifests it seems we have quite a few UUIDs in
our manifests. Those *might* explain the issues that we sometimes
see because the UUIDs is global to the host so running multiple tests
in parallel can lead to clashes when xfs/btrfs assume that the
mount is already done when in fact it was a different loopdevice
that just happend to clash with the UUID.

This commit creates a new UUID for each file where a duplicated
UUID is found (but keeps that UUID inside the same file stable).

We could make this smaller by limiting this to only xfs/btfs which
(AFAIK) are the only systems affected by UUID clashes but my
script is not smart enough for this.
mvo5 added a commit to mvo5/manifest-db that referenced this pull request May 2, 2024
We get regular failures in the manifest-db run. With the extra
visibility from osbuild#123
it seems the errors we get (sometimes) are related to an xfs mount
```
mount/- (org.osbuild.xfs): mounting /dev/98302bc3-1aa3-4eab-96e9-9f1c6eb539ce/rootlv -> /var/lib/osbuild/store/tmp/buildroot-tmp-3y2wyhos/mounts/
mount/- (org.osbuild.xfs): already unmounted: /var/lib/osbuild/store/tmp/buildroot-tmp-3y2wyhos/mounts/
```
which looks similar the UUID clashes we observed in
osbuild/osbuild#1641

Upon inspecting the manifests it seems we have quite a few UUIDs in
our manifests. Those *might* explain the issues that we sometimes
see because the UUIDs is global to the host so running multiple tests
in parallel can lead to clashes when xfs/btrfs assume that the
mount is already done when in fact it was a different loopdevice
that just happend to clash with the UUID.

This commit creates a new UUID for each file where a duplicated
UUID is found (but keeps that UUID inside the same file stable).

We could make this smaller by limiting this to only xfs/btfs which
(AFAIK) are the only systems affected by UUID clashes but my
script is not smart enough for this.
mvo5 added a commit to mvo5/manifest-db that referenced this pull request May 2, 2024
We get regular failures in the manifest-db run. With the extra
visibility from osbuild#123
it seems the errors we get (sometimes) are related to an xfs mount
```
mount/- (org.osbuild.xfs): mounting /dev/98302bc3-1aa3-4eab-96e9-9f1c6eb539ce/rootlv -> /var/lib/osbuild/store/tmp/buildroot-tmp-3y2wyhos/mounts/
mount/- (org.osbuild.xfs): already unmounted: /var/lib/osbuild/store/tmp/buildroot-tmp-3y2wyhos/mounts/
```
which looks similar the UUID clashes we observed in
osbuild/osbuild#1641

Upon inspecting the manifests it seems we have quite a few UUIDs in
our manifests. Those *might* explain the issues that we sometimes
see because the UUIDs is global to the host so running multiple tests
in parallel can lead to clashes when xfs/btrfs assume that the
mount is already done when in fact it was a different loopdevice
that just happend to clash with the UUID.

This commit creates a new UUID for each file where a duplicated
UUID is found (but keeps that UUID inside the same file stable).

We could make this smaller by limiting this to only xfs/btfs which
(AFAIK) are the only systems affected by UUID clashes but my
script is not smart enough for this.
@achilleas-k achilleas-k merged commit 6bb4a11 into osbuild:main May 3, 2024
4 checks passed
@mvo5 mvo5 deleted the more-debug-on-failure branch May 3, 2024 13:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants