Uh oh!
There was an error while loading. Please reload this page.
[vminitd]: api for freeze/thaw filesystem operations - #685
Conversation
jglogan
commented
Apr 14, 2026
@dcantah wdyt? |
dcantah
commented
Apr 14, 2026
Looks good! |
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
saehejkang
commented
Apr 22, 2026
jglogan
commented
Apr 23, 2026
@saehejkang Congrats! And it's a good question. I'm wondering if you could make a copy of one of the really simple "run container and exec a command" integration tests and extend it so that it does this instead:
|
4dc49f5 to
9dd12d9Comparedcantah
commented
Apr 30, 2026
You'll need to run |
f01ce95 to
b7fbbe5Comparesaehejkang
commented
Jun 2, 2026
jglogan
left a comment
There was a problem hiding this comment.
@saehejkang looks good, only a couple of nits
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
b82be48 to
4b06bfcCompareUh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
jglogan
left a comment
There was a problem hiding this comment.
@saehejkang I ran into two errors when running make all integration:
- The defer-remove of cloneImageURL was removing the cloned image was removing the cloned image before it could be used in a later scope. Suite.swift removes testDir at the end of the tests, so the removes should be unnecessary.
- The dmesg check was failing; the output I was seeing when running the test was:
[ 0.310796] EXT4-fs (vdc): warning: mounting unchecked fs, running e2fsck is recommended [ 0.310975] EXT4-fs (vdc): mounted filesystem 8a5c73a9-3c81-45b5-909f-d4708ebfa119 r/w without journal. Quota mode: disabled.
I think that the prior mount check should be sufficient to ensure that the cloned fs was able to be mounted. Here's what I changed to get tests to pass:
diff --git a/Sources/Integration/ContainerTests.swift b/Sources/Integration/ContainerTests.swift
index 81ffc09..60362c8 100644
--- a/Sources/Integration/ContainerTests.swift+++ b/Sources/Integration/ContainerTests.swift@@ -4256,10 +4256,6 @@ extension IntegrationSuite {
}
try FileManager.default.copyItem(at: diskImageURL, to: cloneImageURL)
- defer {- try? FileManager.default.removeItem(at: diskImageURL)- try? FileManager.default.removeItem(at: cloneImageURL)- }
try await writerContainer.filesystemOperation(operation: .thaw, path: "/data")
@@ -4304,22 +4300,6 @@ extension IntegrationSuite {
throw IntegrationError.assert(msg: "expected ext4 mount at /data, got: \(mountOutput)")
}
- let dmesgBuffer = BufferWriter()- let dmesgExec = try await verifyContainer.exec("verify-dmesg-clean") { config in- config.arguments = [- "/bin/sh", "-c",- "if dmesg | grep -Eiq 'fsck|recovering journal|recovery complete'; then dmesg | grep -Ei 'fsck|recovering journal|recovery complete'; exit 1; fi",- ]- config.stdout = dmesgBuffer- }- try await dmesgExec.start()- status = try await dmesgExec.wait()- try await dmesgExec.delete()- guard status.exitCode == 0 else {- let dmesgOutput = String(decoding: dmesgBuffer.data, as: UTF8.self)- throw IntegrationError.assert(msg: "dmesg indicates filesystem recovery on cloned image: \(dmesgOutput)")- }-
let lsBuffer = BufferWriter()
let lsExec = try await verifyContainer.exec("verify-no-hello") { config in
config.arguments = ["ls", "-1", "/data"]Uh oh!
There was an error while loading. Please reload this page.
Addition of `vminitd` API for freeze/thaw filesystem operations Closesapple#660
Treat omitted compose commit --index and --index=0 like Docker Compose's unset service-container selection, while keeping explicit positive indexes targeted and rejecting negative indexes. Refresh commit parity docs and runtime blocker references now that apple/containerization#685 has landed and apple/container#1630 plus apple/container#1762 track the remaining live export/commit path.
Addition of
vminitdAPI for freeze/thaw filesystem operationsCloses#660