"Ignoring children of non-directory file" when applying dism-created image of system with WSL and UWP apps installed

Comments, questions, bug reports, etc.
Post Reply
Googulator
Posts: 2
Joined: Mon May 13, 2019 8:47 pm

"Ignoring children of non-directory file" when applying dism-created image of system with WSL and UWP apps installed

Post by Googulator » Fri May 24, 2019 3:51 pm

I recently had to migrate a Windows installation to a new partition, and I chose to create a WIM of the install (using dism), and apply it to the new partition.
Upon trying to apply with dism, I ran into a known bug where dism fails to apply images that have WSL preinstalled, throwing Access Denied. So I tried wimlib instead.

With wimlib (after setting ObCaseInsensitive=0 on the system, to allow WSL's case-difference-only file names to be extracted properly - it would be nice if this could be overridden on the command line of wimlib-imagex without having to edit Registry and reboot), I was successful in applying the image, but I got several "Ignoring children of non-directory file" warnings, and the directories referenced there were indeed created empty.

Upon investigating further, I found these directories to have both the directory and reparse point flags set in the WIM. I patched inode_is_directory to ignore the reparse point flag, and this time the affected directories got filled properly - however, I got "[WARNING] - Could not set short names on 236309 files or directories" at the end.
It appears that this is due to ObCaseInsensitive=0, which (per https://docs.microsoft.com/en-us/opensp ... 00c13441c9), will cause NtSetInformationFile(FileShortNameInformation) to always fail with STATUS_INVALID_PARAMETER.

This leaves us with 2 issues identified:
- Children of directory reparse points shouldn't be ignored, at least not always (perhaps dependent of reparse tag value)
- Case-sensitive extraction should be made possible even without ObCaseInsensitive=0, using the techniques described in https://devblogs.microsoft.com/commandl ... y-and-wsl/

Post Reply