Winetricks: Unable to install vcrun2015 on Ubuntu 20.04 (Focal)

Created on 16 Apr 2020  路  14Comments  路  Source: Winetricks/winetricks

I'm getting the following issue when installing vcrun2015 under Ubuntu 20.04.

Here is a minimal Dockerfile to reproduce the issue:

FROM ubuntu:20.04

RUN dpkg --add-architecture i386 && apt update && DEBIAN_FRONTEND=noninteractive apt install -y --no-install-recommends wine32 wine-stable winetricks xvfb libssl-dev:i386 ca-certificates wget
RUN cd "$(mktemp -d)" && \
    wget https://raw.githubusercontent.com/Winetricks/winetricks/master/src/winetricks && \
    chmod +x winetricks && \
    xvfb-run bash ./winetricks -q vcrun2015
# RUN xvfb-run winetricks -q vcrun2015

I've tried both installed winetricks as well as pulling the latest from Github. If you switch it back to Ubuntu:18.04, then the installation completes successfully with both versions. Otherwise, here is the failure:

------------------------------------------------------
Running Wine/winetricks as root is highly discouraged. See https://wiki.winehq.org/FAQ#Should_I_run_Wine_as_root.3F
------------------------------------------------------
Executing mkdir -p /root
Using winetricks 20200412-next - sha256sum: 1daad9db206d3b2a024147aa3f04925328d10d7eeaa450ac5b4b90353df9858c with wine-5.0 (Ubuntu 5.0-3) and WINEARCH=win32
Executing w_do_call vcrun2015
Executing mkdir -p /root
Executing load_vcrun2015 
Executing mkdir -p /root/.cache/winetricks/vcrun2015
Executing cd /root/.cache/winetricks/vcrun2015
Downloading https://download.microsoft.com/download/9/3/F/93FCF1E7-E6A4-478B-96E7-D4B285925B00/vc_redist.x86.exe to /root/.cache/winetricks/vcrun2015
--2020-04-16 18:41:42--  https://download.microsoft.com/download/9/3/F/93FCF1E7-E6A4-478B-96E7-D4B285925B00/vc_redist.x86.exe
Resolving download.microsoft.com (download.microsoft.com)... 2600:141b:7000:5a0::e59, 2600:141b:7000:592::e59, 2600:141b:7000:590::e59, ...
Connecting to download.microsoft.com (download.microsoft.com)|2600:141b:7000:5a0::e59|:443... failed: Network is unreachable.
Connecting to download.microsoft.com (download.microsoft.com)|2600:141b:7000:592::e59|:443... failed: Network is unreachable.
Connecting to download.microsoft.com (download.microsoft.com)|2600:141b:7000:590::e59|:443... failed: Network is unreachable.
Connecting to download.microsoft.com (download.microsoft.com)|23.78.136.109|:443... connected.
HTTP request sent, awaiting response... 200 OK
Length: 13767776 (13M) [application/octet-stream]
Saving to: 'vc_redist.x86.exe'

     0K .......... .......... .......... .......... ..........  0% 3.35M 4s
    50K .......... .......... .......... .......... ..........  0% 2.73M 4s
...
 13350K .......... .......... .......... .......... .......... 99% 20.0M 0s
 13400K .......... .......... .......... .......... .....     100% 27.8M=1.1s

2020-04-16 18:41:46 (12.0 MB/s) - 'vc_redist.x86.exe' saved [13767776/13767776]

Executing cd /tmp/tmp.xkvyBUCaqL
------------------------------------------------------
Working around wine bug 37781 
------------------------------------------------------
------------------------------------------------------
This may fail in non-XP mode, see https://bugs.winehq.org/show_bug.cgi?id=37781
------------------------------------------------------
Using native,builtin override for following DLLs: api-ms-win-crt-private-l1-1-0 api-ms-win-crt-conio-l1-1-0 api-ms-win-crt-heap-l1-1-0 api-ms-win-crt-locale-l1-1-0 api-ms-win-crt-math-l1-1-0 api-ms-win-crt-runtime-l1-1-0 api-ms-win-crt-stdio-l1-1-0 api-ms-win-crt-time-l1-1-0 atl140 concrt140 msvcp140 msvcr140 ucrtbase vcomp140 vcruntime140
Executing wine regedit /S C:\windows\Temp\override-dll.reg
Setting Windows version to winxp
Executing wine regedit /S C:\windows\Temp\set-winver.reg
------------------------------------------------------
Running /usr/bin/wineserver -w. This will hang until all wine processes in prefix=/root/.wine terminate
------------------------------------------------------
Executing cd /root/.cache/winetricks/vcrun2015
Executing wine vc_redist.x86.exe /q
0009:err:mscoree:LoadLibraryShim error reading registry key for installroot
0009:err:mscoree:LoadLibraryShim error reading registry key for installroot
0009:err:mscoree:LoadLibraryShim error reading registry key for installroot
0009:err:mscoree:LoadLibraryShim error reading registry key for installroot
0009:err:msi:ACTION_InstallFiles compressed file wasn't installed (L"api_ms_win_core_console_l1_1_0.dll")
0009:err:msi:execute_script Execution of script 0 halted; action L"InstallFiles" returned 1603
0009:err:msi:ITERATE_Actions Execution halted, action L"InstallFinalize" returned 1603
------------------------------------------------------
Note: command wine vc_redist.x86.exe /q returned status 67. Aborting.
------------------------------------------------------
The command '/bin/sh -c cd "$(mktemp -d)" &&     wget https://raw.githubusercontent.com/Winetricks/winetricks/master/src/winetricks &&     chmod +x winetricks &&     xvfb-run bash ./winetricks -q vcrun2015' returned a non-zero code: 1
bug docker download help wanted

Most helpful comment

Same problem here.
I can't install msxml3 using docker image with Ubuntu 20.04.
The same works using docker image with Ubuntu 18.04.

Sample docker image based on Ubuntu 20.04

FROM ubuntu:20.04

RUN dpkg --add-architecture i386 && apt update
RUN DEBIAN_FRONTEND=noninteractive apt-get install -y -o APT::Immediate-Configure=false --no-install-recommends wine32 wine-stable winetricks xvfb libssl-dev:i386 ca-certificates wget
RUN export WINEARCH=win32 && xvfb-run bash winetricks -q msxml3

You can see the following error:

...
002c:err:msi:ACTION_InstallFiles compressed file wasn't installed (L"msxml3.dll.C8C0673E_50E5_4AC4_817B_C0E4C4466990")
002c:err:msi:execute_script Execution of script 0 halted; action L"InstallFiles" returned 1603
002c:err:msi:ITERATE_Actions Execution halted, action L"InstallFinalize" returned 1603
0040:err:ole:TLB_ReadTypeLib Loading of typelib L"C:\\windows\\system32\\msxml3.dll" failed with error 2
------------------------------------------------------
Note: command wine msiexec /i msxml3.msi /q returned status 67. Aborting.
------------------------------------------------------
...

If you install the software sharing host XWindows you can see the same error image seen in issue 1543

Extracting file failed. It is most likely caused by low memory (low disk space for swapping file) or corrupted Cabinet file.

The same but based on Ubuntu 18.04

FROM ubuntu:18.04

RUN dpkg --add-architecture i386 && apt update
RUN DEBIAN_FRONTEND=noninteractive apt-get install -y -o APT::Immediate-Configure=false --no-install-recommends wine32 wine-stable winetricks xvfb libssl-dev:i386 ca-certificates wget
RUN export WINEARCH=win32 && xvfb-run bash winetricks -q msxml3

The installation success (you can't see the error messages seen with Ubuntu 20.04)

NOTE: I think the problem is with wine, not winetricks (as I think you end with the same problem using wine directly) but I can't find the right place to report the issue.

All 14 comments

That dockerfile fails here (Docker version 19.03.5, build 633a0ea):

Processing triggers for wine (5.0-3) ...
E: Could not configure 'libc6:i386'. 
E: Could not perform immediate configuration on 'libgcc-s1:i386'. Please see man 5 apt.conf under APT::Immediate-Configure for details. (2)
The command '/bin/sh -c dpkg --add-architecture i386 && apt update && DEBIAN_FRONTEND=noninteractive apt install -y --no-install-recommends wine32 wine-stable winetricks xvfb libssl-dev:i386 ca-certificates wget' returned a non-zero code: 100

Interesting. I was able to reproduce your issue on my MacBook. Try this Dockerfile:

FROM ubuntu:20.04

RUN dpkg --add-architecture i386 && apt update
RUN DEBIAN_FRONTEND=noninteractive apt install -y -o APT::Immediate-Configure=false --no-install-recommends wine32 wine-stable winetricks xvfb libssl-dev:i386 ca-certificates wget
RUN cd "$(mktemp -d)" && \
    wget https://raw.githubusercontent.com/Winetricks/winetricks/master/src/winetricks && \
    chmod +x winetricks && \
    xvfb-run bash ./winetricks -q vcrun2015
# RUN xvfb-run winetricks -q vcrun2015

Apparently it needed the -o APT::Immediate-Configure=false like the error message was elluding to.

I can reproduce with that, thanks.

It's probably related to:

0009:err:msi:ACTION_InstallFiles compressed file wasn't installed (L"api_ms_win_core_console_l1_1_0.dll")
0009:err:msi:execute_script Execution of script 0 halted; action L"InstallFiles" returned 1603

though it's not obvious what's going on. A quick look shows that that dll is installed on both versions. Setting it to native,builtin as we do some other dlls in winetricks doesn't help, either.

I suspect it's a packaging bug (probably different gcc/mingw), but this would take some effort to dig into. I don't have time for that, but if someone else does and finds we can workaround in winetricks, I'll be happy to review the patch.

Has anyone made headway on this issue? I'm trying to install dotnet40 rather than vcrun, and for me the error is on rgb9rast_2._x86, though if I run the installer again it errors on a different file. Works perfectly outside of docker which is very perplexing and frustrating.

Same problem here.
I can't install msxml3 using docker image with Ubuntu 20.04.
The same works using docker image with Ubuntu 18.04.

Sample docker image based on Ubuntu 20.04

FROM ubuntu:20.04

RUN dpkg --add-architecture i386 && apt update
RUN DEBIAN_FRONTEND=noninteractive apt-get install -y -o APT::Immediate-Configure=false --no-install-recommends wine32 wine-stable winetricks xvfb libssl-dev:i386 ca-certificates wget
RUN export WINEARCH=win32 && xvfb-run bash winetricks -q msxml3

You can see the following error:

...
002c:err:msi:ACTION_InstallFiles compressed file wasn't installed (L"msxml3.dll.C8C0673E_50E5_4AC4_817B_C0E4C4466990")
002c:err:msi:execute_script Execution of script 0 halted; action L"InstallFiles" returned 1603
002c:err:msi:ITERATE_Actions Execution halted, action L"InstallFinalize" returned 1603
0040:err:ole:TLB_ReadTypeLib Loading of typelib L"C:\\windows\\system32\\msxml3.dll" failed with error 2
------------------------------------------------------
Note: command wine msiexec /i msxml3.msi /q returned status 67. Aborting.
------------------------------------------------------
...

If you install the software sharing host XWindows you can see the same error image seen in issue 1543

Extracting file failed. It is most likely caused by low memory (low disk space for swapping file) or corrupted Cabinet file.

The same but based on Ubuntu 18.04

FROM ubuntu:18.04

RUN dpkg --add-architecture i386 && apt update
RUN DEBIAN_FRONTEND=noninteractive apt-get install -y -o APT::Immediate-Configure=false --no-install-recommends wine32 wine-stable winetricks xvfb libssl-dev:i386 ca-certificates wget
RUN export WINEARCH=win32 && xvfb-run bash winetricks -q msxml3

The installation success (you can't see the error messages seen with Ubuntu 20.04)

NOTE: I think the problem is with wine, not winetricks (as I think you end with the same problem using wine directly) but I can't find the right place to report the issue.

Seeing the same issue with my Dockerfile in https://github.com/Haaroon/AssettoCorsaCompetizioneDockerServer/blob/main/Dockerfile, compiles fine on ubuntu docker but fails on mac docker

This does not seem to be related to winetricks but to wine msiexec

err:msi:ACTION_InstallFiles"..., 790009:err:msi:ACTION_InstallFiles compressed file wasn't installed (L"LICENSE")
err:msi:execute_script Execution of script 0 halted; action L"InstallFiles" returned 1603

I get the above error when running the dockerfile below:

FROM ubuntu:20.04

RUN export DEBIAN_FRONTEND="noninteractive" \
    && dpkg --add-architecture i386 \
    && apt-get update \
    && apt-get install -o APT::Immediate-Configure=false -y wine \
    && apt-get install -y wget winbind xvfb unzip curl jq \
    && apt-get remove -y libmysqlclient21 mysql-common \
    && apt autoremove -y 

RUN useradd -ms /bin/bash wineuser

WORKDIR /home/wineuser

RUN wget http://dl.winehq.org/wine/wine-gecko/2.40/wine_gecko-2.40-x86.msi
RUN apt-get install strace
RUN wine wineboot 
RUN wine msiexec /i wine_gecko-2.40-x86.msi
CMD ["/bin/bash"]

This only happens when building/running within docker for windows. Linux works fine.

I guess this issue can be closed as the issue is not winetricks related.

Reference:
https://github.com/wine-mirror/wine/blob/ba9f3dc198dfc81bb40159077b73b797006bb73c/dlls/msi/files.c#L437

I opened a wine issue after confirming that this still happens in the newest wine-devel https://bugs.winehq.org/show_bug.cgi?id=50079

This works for me:

the magic -> xvfb-run as usual, but withint he command start with wineboot before any winetricks...
(i ommit the long discussion of wineserver in side process and docker managing or processes between each layer generation..)

RUN rm -f /tmp/.X*-lock && xvfb-run -e /dev/stdout sh -c "\
WINEDLLOVERRIDES=\"mscoree,mshtml=\" wineboot --init && \
wineserver -w"

RUN rm -f /tmp/.X*-lock && xvfb-run -e /dev/stdout sh -c "\
wineboot && \
winetricks --optout --force -q vcrun2008 && \
winetricks --optout --force -q vcrun2019 && \
winetricks --optout --force -q wsh57 && \
winetricks --optout --force -q msxml3 && \
winetricks --optout --force -q msxml6 && \
winetricks --optout --force -q corefonts && \
winetricks --optout --force -q vb6run && \
wineserver -w"

RUN rm -f /tmp/.X-lock && xvfb-run -e /dev/stdout sh -c "\
wineboot && \
winetricks --optout --force -q dotnet40 && \
wineserver -w"
RUN rm -f /tmp/.X
-lock && xvfb-run -e /dev/stdout sh -c "\
wineboot && \
winetricks --optout --force -q dotnet45 && \
wineserver -w"
RUN rm -f /tmp/.X-lock && xvfb-run -e /dev/stdout sh -c "\
wineboot && \
winetricks --optout --force -q dotnet46 && \
wineserver -w"
RUN rm -f /tmp/.X
-lock && xvfb-run -e /dev/stdout sh -c "\
wineboot && \
winetricks --optout --force -q dotnet461 && \
wineserver -w"
RUN rm -f /tmp/.X-lock && xvfb-run -e /dev/stdout sh -c "\
wineboot && \
winetricks --optout --force -q dotnet462 && \
wineserver -w"
RUN rm -f /tmp/.X
-lock && xvfb-run -e /dev/stdout sh -c "\
wineboot && \
winetricks --optout --force -q dotnet471 && \
wineserver -w"
RUN rm -f /tmp/.X-lock && xvfb-run -e /dev/stdout sh -c "\
wineboot && \
winetricks --optout --force -q dotnet472 && \
wineserver -w"
RUN rm -f /tmp/.X
-lock && xvfb-run -e /dev/stdout sh -c "\
wineboot && \
winetricks --optout --force -q dotnet48 && \
wineserver -w"

Switching from docker build (which is actually podman build on my system) to buildah bud --security-opt seccomp=unconfined worked for me.

I only figured this out because strace showed a call to clock_gettime64(CLOCK_REALTIME, ...) that returned EPERM right before Wine reported an installation error, which led me to https://bugzilla.redhat.com/show_bug.cgi?id=1887445#c23. (By the way, I had to run docker build with --cap-add=SYS_PTRACE to get strace to work.)

There are, however, still issues if Xvfb shuts down early or fails to clean up after itself, so I like the idea to use xvfb-run sh -c 'wine <program> && wineserver -w' && rm -f /tmp/.X*-lock as suggested in the previous comment :-)

I have similar problem with vcrun2019, status 67, kubuntu 20.10

when I tried to install a script which needs vcrun2013, I obtained that error:
https://paste.ubuntu.com/p/82Vz4PF3qv/
Could be related?

when I tried to install a script which needs vcrun2013, I obtained that error:
paste.ubuntu.com/p/82Vz4PF3qv
Should be related?

Seems vcrun201{3,5,7,9} are all broken.

seems to affect dotnetXX verbs too:


Executing mkdir -p /home/legluondunet/.cache/winetricks/dotnet472
Executing cd /home/legluondunet/.cache/winetricks/dotnet472
Downloading https://download.microsoft.com/download/6/E/4/6E48E8AB-DC00-419E-9704-06DD46E5F81D/NDP472-KB4054530-x86-x64-AllOS-ENU.exe to /home/legluondunet/.cache/winetricks/dotnet472
Executing cd /home/legluondunet
------------------------------------------------------
warning: sha256sum mismatch! Rename /home/legluondunet/.cache/winetricks/dotnet472/NDP472-KB4054530-x86-x64-AllOS-ENU.exe and try again.
------------------------------------------------------

Was this page helpful?
0 / 5 - 0 ratings

Related issues

Gcenx picture Gcenx  路  7Comments

greencopper picture greencopper  路  6Comments

GoogleCodeExporter picture GoogleCodeExporter  路  14Comments

Ads20000 picture Ads20000  路  11Comments

prcastro picture prcastro  路  9Comments