Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.
RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.

Bug 692394

Summary: inspect-list-applications fails to detect 32 bit apps installed under WOW64 emulator on 64 bit Windows
Product: Red Hat Enterprise Linux 6 Reporter: Jinxin Zheng <jzheng>
Component: libguestfsAssignee: Richard W.M. Jones <rjones>
Status: CLOSED ERRATA QA Contact: Virtualization Bugs <virt-bugs>
Severity: medium Docs Contact:
Priority: medium    
Version: 6.1CC: mshao
Target Milestone: rc   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: libguestfs-1.7.17-24.el6 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
: 692545 (view as bug list) Environment:
Last Closed: 2011-12-06 10:31:36 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On: 692545    
Bug Blocks:    
Attachments:
Description Flags
Compressed hive file of the Windows image
none
Second version of hive file that contains 64bit 7-zip installed none

Description Jinxin Zheng 2011-03-31 08:44:48 UTC
Description of problem:
inspect-list-applications cannot detect applications installed in x64-based Windows image, whereas it works for 32 bit Win.

Taking the xenpv driver as an example, I installed xenpv on a 32 bit Windows 2003 image from inside the guest, and guestfish successfully could detect it:

...
[2] = {
  app_name: Red Hat Paravirtualized Xen Drivers for Windows(R)
  app_display_name: Red Hat Paravirtualized Xen Drivers for Windows(R) 1.3.4-1
  app_epoch: 0
  app_version: 1.3.4-1
  app_release:
  app_install_path:
  app_trans_path:
  app_publisher: Red Hat, Inc.
  app_url: http://www.redhat.com
  app_source_package:
  app_summary:
  app_description:
}

But when we come to the 64 bit Windows, we get nothing from the output.

Version-Release number of selected component (if applicable):
libguestfs-1.7.17-16.el6

How reproducible:
Always

Steps to Reproduce:
1.
Setup a x64-based Windows image. Boot into the guest using KVM or Xen, and install some applications like xenpv driver.

2.
Quit the guest and use guestfish to detect the installed application.

guestfish -a windows-64bit.img
...
><fs> inspect-os 
/dev/vda1
><fs> inspect-get-mountpoints /dev/vda1
/: /dev/vda1
><fs> mount /dev/vda1 /
><fs> inspect-list-applications /dev/vda1 
><fs> 

  
Actual results:
No output.

Expected results:
Descriptions of installed applications.

Additional info:
I think you need to look for some registry key other than HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall for the 64 bit Windows.

This page might help:
http://support.microsoft.com/kb/896459

Comment 1 Jinxin Zheng 2011-03-31 08:56:47 UTC
OH, I think the xenpv driver is a 32-bit program that run in WOW64 mode. It should be found in HKEY_LOCAL_MACHINE\Software\WOW6432node.

I did not try the native 64-bit program case, which I'll later have a test.

Comment 2 Richard W.M. Jones 2011-03-31 09:01:19 UTC
Could you attach the HKLM\SOFTWARE hive from this
windows guest to the bug?

Do:

$ guestfish --ro -a windows-64bit.img -i \
  download win:/windows/system32/config/software software
$ file software 
software: MS Windows registry file, NT/2000 or above

Those commands should produce a binary file called 'software' in
the current directory which you can just attach.

Comment 3 Jinxin Zheng 2011-03-31 09:21:22 UTC
Created attachment 489012 [details]
Compressed hive file of the Windows image

I compressed the hive file. It's from a Windows 7 x64 image.

Well, I tried the 7zip 64bit version, and it was correct.

><fs> inspect-list-applications /dev/vda1
[0] = {
  app_name: {23170F69-40C1-2702-0920-000001000000}
  app_display_name: 7-Zip 9.20 (x64 edition)
  app_epoch: 0
  app_version: 9.20.00.0
  app_release: 
  app_install_path: 
  app_trans_path: 
  app_publisher: Igor Pavlov
  app_url: http://www.7-zip.org/
  app_source_package: 
  app_summary: 
  app_description: 
}

Then it's a 32bit-on-64bit issue.

Comment 4 Jinxin Zheng 2011-03-31 09:26:58 UTC
Created attachment 489013 [details]
Second version of hive file that contains 64bit 7-zip installed

The hive file on which I performed the test with 64 bit 7-zip.

Comment 6 Richard W.M. Jones 2011-08-10 16:00:46 UTC
https://brewweb.devel.redhat.com/taskinfo?taskID=3546057

Comment 8 Jinxin Zheng 2011-08-18 06:56:46 UTC
Reproduced on libguestfs-1.7.17-19 using:

$ guestfish -a windows-64.img <<EOF
inspect-os
mount /dev/vda1 /
inspect-list-applications /dev/vda1
EOF

The windows-64.img has xenpv-win driver installed.
There's no output running the script.

Verified with libguestfs-1.7.17-26. We get:

[0] = {
  app_name: Red Hat Paravirtualized Xen Drivers for Windows(R)
  app_display_name: Red Hat Paravirtualized Xen Drivers for Windows(R) 1.3.4
  app_epoch: 0
  app_version: 1.3.4
  app_release: 
  app_install_path: 
  app_trans_path: 
  app_publisher: Red Hat, Inc.
  app_url: http://www.redhat.com
  app_source_package: 
  app_summary: 
  app_description: 
}

Comment 9 errata-xmlrpc 2011-12-06 10:31:36 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

http://rhn.redhat.com/errata/RHBA-2011-1512.html