Menu ▾ ▴

#2731 APFS volume in DMG cannot be opened (“Cannot open the file as [APFS] archive”)

open
nobody
None
5
7 hours ago
7 hours ago
Chris
No

Summary: APFS volume in Google Drive for macOS DMG cannot be opened ("Cannot open the file as [APFS] archive")

7-Zip version: 7-Zip 26.06 (x64), Windows 11. Our Linux pipeline uses 7zz 26.00 and can't extract the file either.

File:

  • Google Drive for macOS installer DMG, downloaded from https://dl.google.com/drive-file-stream/5-percent/GoogleDrive.dmg
  • Size: 139,128,902 bytes
  • SHA-256: 81133901d4dc794c5f736e862af69a89a34b5d79feab975e0b13fbd09fc1dcc0
  • The vendor replaces the file at this URL with every release. I can provide this exact copy if it is no longer available there

Problem:
The DMG contains a single APFS partition (Untitled 1 (Apple_APFS : 4)). The volume holds one file, GoogleDrive.pkg (~137.8 MB). macOS mounts the image and shows the file without problems. 7-Zip opens the DMG container, but it fails on the APFS volume:

Path = 4.apfs
Size = 253755392
Packed Size = 139097954
Comment = Untitled 1 (Apple_APFS : 4)
--
Path = 4.apfs
Open WARNING: Cannot open the file as [APFS] archive
Type = Xar
WARNINGS:
There are data after the end of archive
Offset = 1490944
Physical Size = 137847276
Tail Size = 114417172

7-Zip then falls back to a signature scan and finds the xar header of GoogleDrive.pkg at offset 1490944. It lists the xar contents instead of the APFS file system, so the file GoogleDrive.pkg itself can't be extracted.

The xar shown that way is not usable. The file is fragmented in the APFS volume. If you extract 4.apfs with 7z e -tdmg and cut out the byte range 1490944 + 137847276, the result has a valid xar! header, but 7z t reports 17 Data Error / CRC Failed items. So the data can only be read correctly through the APFS extent mapping.

Steps to reproduce:

  1. 7z l GoogleDrive.dmg
  2. Look for "Open WARNING: Cannot open the file as [APFS] archive" and a xar listing instead of the APFS file tree.

Expected: 7-Zip opens the APFS volume and lists Install Google Drive/GoogleDrive.pkg (volume name as shown by macOS), which can then be extracted.

Context: Older Google Drive DMGs extracted fine with the same command, up to version 132.0.0.0 (Sep 2026). The image above was built on 2026-11-09, so the newer images probably use an APFS feature or layout that 7-Zip's APFS handler doesn't support yet.

Discussion


Log in to post a comment.