| Summary: | wic cp corrupts ext4 journal | ||
|---|---|---|---|
| Product: | [Build System, Metadata & Runtime] OE-Core | Reporter: | Thomas Roos <thomas> |
| Component: | devtools / tool chain | Assignee: | Thomas Roos <thomas> |
| Status: | RESOLVED NOTABUG | QA Contact: | |
| Severity: | normal | ||
| Priority: | Medium | CC: | meta.mr.watcher, meta.watcher, ross.burton |
| Version: | 4.0.20 | ||
| Target Milestone: | 5.1 | ||
| Hardware: | x86 | ||
| OS: | Multiple | ||
| Whiteboard: | |||
| OS type for building Yocto: | --- | Type of Regression: | --- |
| Verified: | Documentation change: | Don't know | |
|
Description
Thomas Roos
2024-06-19 19:49:26 UTC
That workaround feels reasonable enough, can you send a patch? Sorry for the noise - could not reproduce it.
Here is a snipplet of my idea to disable journal - but hence it disappeared I close the bug.
diff --git a/scripts/lib/wic/engine.py b/scripts/lib/wic/engine.py
index 674ccfc244..03cd508386 100644
--- a/scripts/lib/wic/engine.py
+++ b/scripts/lib/wic/engine.py
@@ -280,7 +280,7 @@ class Disk:
def __getattr__(self, name):
"""Get path to the executable in a lazy way."""
if name in ("mdir", "mcopy", "mdel", "mdeltree", "sfdisk", "e2fsck",
- "resize2fs", "mkswap", "mkdosfs", "debugfs","blkid"):
+ "resize2fs", "tune2fs", "mkswap", "mkdosfs", "debugfs","blkid"):
aname = "_%s" % name
if aname not in self.__dict__:
setattr(self, aname, shutil.which(name, path=self.paths))
@@ -332,9 +332,12 @@ class Disk:
if self.partitions[pnum].fstype.startswith('ext'):
if isinstance(src, str):
+ # disable journal, since this is not proper updated
+ exec_cmd("{} -fO ^has_journal {}".format(self.tune2fs, self._get_part_image(pnum)))
+ # creating copy cmd
|