Wine msiexec fails in headless mode

Questions about Wine on Linux
Locked
awkravchuk
Newbie
Newbie
Posts: 3
Joined: Fri Feb 04, 2022 1:23 am

Wine msiexec fails in headless mode

Post by awkravchuk »

Hello!
I'm trying to use wine in headless scenario, namely - install this MSI with msiexec /quiet /qn /i. The whole thing works in non-headless mode (under Ubuntu 20.04), but fails in headless mode (on CI server with very same Ubuntu 20.04) and exits with status code 97. I've gotten a +relay debug log, here it is: https://transfer.sh/oNP8k9/relay.log . Any advice on fixing this?
jkfloris
Level 12
Level 12
Posts: 3201
Joined: Thu Aug 14, 2014 10:10 am

Re: Wine msiexec fails in headless mode

Post by jkfloris »

Some questions:
- Why don't you use the native Linux version?
- Why do you want to run an older version of sbcl?
- Which Wine version do you use?
- Does the installation work if you remove the msi options?

Code: Select all

wine msiexec /i /tmp/sbcl-1.4.14-x86-64-windows-binary.msi
# or
wine msiexec /i /tmp/sbcl-1.4.14-x86-64-windows-binary.msi /quiet
awkravchuk
Newbie
Newbie
Posts: 3
Joined: Fri Feb 04, 2022 1:23 am

Re: Wine msiexec fails in headless mode

Post by awkravchuk »

jkfloris wrote: Fri Feb 04, 2022 12:09 pm - Why don't you use the native Linux version?
- Why do you want to run an older version of sbcl?
Well, because of reasons :) I'm trying to build native Windows SBCL without using the actual Windows, so that the build does not depend on WinAPI functions from Windows 8 & 10 and is able to run on Windows 7 (ideally on XP as well). Hence the older version, since the newer version would produce binary depending on newer WinAPI functions (1.4.14 dates back to Vista). Native Linux version won't be able to crosscompile (or that would be enormously hard).
jkfloris wrote: Fri Feb 04, 2022 12:09 pm - Which Wine version do you use?
That would be 5.0-3ubuntu1, from 20.04.
jkfloris wrote: Fri Feb 04, 2022 12:09 pm - Does the installation work if you remove the msi options?

Code: Select all

wine msiexec /i /tmp/sbcl-1.4.14-x86-64-windows-binary.msi
# or
wine msiexec /i /tmp/sbcl-1.4.14-x86-64-windows-binary.msi /quiet
Nope, the first one requires both GUI and user interaction, which are absent on CI server, and the second one fails with status code 97 as well.
jkfloris
Level 12
Level 12
Posts: 3201
Joined: Thu Aug 14, 2014 10:10 am

Re: Wine msiexec fails in headless mode

Post by jkfloris »

It seems that the msi file does not perform any checks.
Even though there is no GUI available, the program is installed.

Code: Select all

$ shasum ~/Downloads/sbcl-1.4.14-x86-64-windows-binary.msi 
bc2eb3df2da434ba84f2ccce67d64652d82c4626  ~/Downloads/sbcl-1.4.14-x86-64-windows-binary.msi

$ wine --version                                                                                                                                                                 
wine-5.0.3 (Debian 5.0.3-3)

$ wine msiexec /i ~/Downloads/sbcl-1.4.14-x86-64-windows-binary.msi 

0009:fixme:ntdll:NtLockFile I/O completion on lock not implemented yet
0009:fixme:ntdll:NtQuerySystemInformation info_class SYSTEM_PERFORMANCE_INFORMATION
0009:err:winediag:nodrv_CreateWindow Application tried to create a window, but no driver could be loaded.
0009:err:winediag:nodrv_CreateWindow Make sure that your X server is running and that $DISPLAY is set correctly.
0009:err:msi:dialog_run_message_loop Failed to create dialog L"PrepareDlg"
0009:err:msi:dialog_run_message_loop Failed to create dialog L"MaintenanceWelcomeDlg"
0009:err:msi:dialog_run_message_loop Failed to create dialog L"ProgressDlg"
0009:fixme:msi:ITERATE_CreateShortcuts poorly handled shortcut format, advertised shortcut
0009:fixme:msi:internal_ui_handler internal UI not implemented for message 0x0b000000 (UI level = 5)
0009:fixme:msi:internal_ui_handler internal UI not implemented for message 0x0b000000 (UI level = 5)
0009:err:msi:dialog_run_message_loop Failed to create dialog L"ExitDialog"

$ ls -asl ~/.wine/drive_c/Program\ Files/Steel\ Bank\ Common\ Lisp/1.4.14/
totaal 42336
    4 drwxr-xr-x 3 floris floris     4096  6 feb 10:16 .
    4 drwxr-xr-x 3 floris floris     4096  6 feb 10:16 ..
    4 drwxr-xr-x 2 floris floris     4096  6 feb 10:16 contrib
38536 -rw-r--r-- 1 floris floris 39459880 29 nov  2018 sbcl.core
 3788 -rwxr-xr-x 1 floris floris  3875611 29 nov  2018 sbcl.exe
Two other possible solutions:
- Update your Wine version
- Extract the msi file manually with msiextract.
awkravchuk
Newbie
Newbie
Posts: 3
Joined: Fri Feb 04, 2022 1:23 am

Re: Wine msiexec fails in headless mode

Post by awkravchuk »

jkfloris wrote: Sun Feb 06, 2022 4:24 am - Extract the msi file manually with msiextract.
msiextract trick helped, thank you very much!
Locked