Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error building docker image: install_unix_legacy: not found #19

Open
HaotianHuang opened this issue Dec 11, 2022 · 1 comment
Open

Error building docker image: install_unix_legacy: not found #19

HaotianHuang opened this issue Dec 11, 2022 · 1 comment

Comments

@HaotianHuang
Copy link

Trying to build docker image via docker build -t ubuntu:ctseg -f CTseg/Dockerfile .
Process failed due to install_unix_legacy: not found

System: macOS Monterey (12.5.1)
Architecture: M1

Error logs included:

Desktop % docker build -t ubuntu:ctseg -f CTseg/Dockerfile .
[+] Building 1.7s (10/17)                                                                                   
 => [internal] load build definition from Dockerfile                                                   0.0s
 => => transferring dockerfile: 1.91kB                                                                 0.0s
 => [internal] load .dockerignore                                                                      0.0s
 => => transferring context: 2B                                                                        0.0s
 => [internal] load metadata for docker.io/library/ubuntu:20.04                                        1.3s
 => [ 1/14] FROM docker.io/library/ubuntu:20.04@sha256:0e0402cd13f68137edb0266e1d2c682f217814420f2d43  0.0s
 => CACHED [ 2/14] RUN apt-get update && DEBIAN_FRONTEND=noninteractive apt-get -y install      unzip  0.0s
 => CACHED [ 3/14] RUN mkdir /opt/mcr_install                                                          0.0s
 => CACHED [ 4/14] RUN mkdir /opt/mcr                                                                  0.0s
 => CACHED [ 5/14] RUN wget --progress=bar:force -P /opt/mcr_install https://ssd.mathworks.com/suppor  0.0s
 => CACHED [ 6/14] RUN unzip -q /opt/mcr_install/MATLAB_Runtime_R2021b_glnxa64.zip -d /opt/mcr_instal  0.0s
 => ERROR [ 7/14] RUN /opt/mcr_install/install -destinationFolder /opt/mcr -agreeToLicense yes -mode   0.3s
------                                                                                                      
 > [ 7/14] RUN /opt/mcr_install/install -destinationFolder /opt/mcr -agreeToLicense yes -mode silent:
#10 0.269 /opt/mcr_install/install: 1: exec: /opt/mcr_install/bin/unknown/install_unix_legacy: not found
------
executor failed running [/bin/sh -c /opt/mcr_install/install -destinationFolder /opt/mcr -agreeToLicense yes -mode silent]: exit code: 127
@gllmflndn
Copy link
Collaborator

Hi @HaotianHuang

I get the same error on Apple M1. It seems that Docker will run in emulation mode and that it is not fully supported yet. I tried adding a --platform=linux/amd64 flag to docker build but the MATLAB Runtime installer still gets stuck:

=> [ 7/14] RUN /opt/mcr_install/install -destinationFolder /opt/mcr -agreeToLicense yes -mode silent                                                            1887.3s 
 => => # (Dec 12, 2022 12:28:32) libdir /opt/mcr_install
 => => # (Dec 12, 2022 12:28:32) destinationFolder /opt/mcr
 => => # (Dec 12, 2022 12:28:32) agreeToLicense yes
 => => # (Dec 12, 2022 12:28:32) mode silent
 => => # (Dec 12, 2022 12:28:32) standalone true
 => => # (Dec 12, 2022 12:28:32) connectionMode OFFLINE_ONLY

If you try to run a pre-built SPM image, you get another error:

% docker run ghcr.io/spm/spm-docker:docker-matlab
WARNING: The requested image's platform (linux/amd64) does not match the detected host platform (linux/arm64/v8) and no specific platform was requested
Fatal Internal Error: std::exception: uint64_t foundation::core::system::linux::x86_64::getMaximumProcessorFrequencyImpl(): Numerical result out of range

Unless someone suggests a workaround, I'm afraid I don't have a solution here. Do you have access to a non-M1 machine (Apple Intel, Linux, Windows)? We will hope to provide a native ARM64-based Docker image at some point but MATLAB is still in an Open Beta on that architecture.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants