modularml / mojo

The Mojo Programming Language
https://docs.modular.com/mojo/manual/
Other
22.81k stars 2.57k forks source link

Mojo installation fails (partially) on Linux Mint #2452

Open kulkarnima opened 4 months ago

kulkarnima commented 4 months ago

Issue description

While trying to install Mojo using Modular cli (modular install mojo) on Linux-Mint (21.3) the installation reports partial failure with following message:

vboxuser@livemint-21:~$ modular install mojo
# Found release for https://packages.modular.com/mojo @ 24.2.1-2f0dcf11-release
# Using cached archive: /home/vboxuser/.modular/mojo-x86_64-unknown-linux-gnu-24.2.1-2f0dcf11-release-12-0.tar.gz
# Extracting downloaded archives. 
Extracted    [ ██████████████████████████ ] 100%     198MiB/198MiB             
# Extraction complete, setting configs...
# Configs complete, running post-install hooks...
[mojo][error] Mojo SDK post-install test "`mojo build test_mandelbrot.mojo`" failed:
SubprocessError: Command '/tmp/tmpradqr68f/test_mandelbrot' died with <Signals.SIGILL: 4>.
  File "/home/vboxuser/.modular/pkg/packages.modular.com_mojo/scripts/post-install/self-test.py", line 212, in test_mojo_build
    "25", self.run(Path(tmp) / "test_mandelbrot")[0]
  File "/home/vboxuser/.modular/pkg/packages.modular.com_mojo/scripts/post-install/self-test.py", line 181, in run
    raise SubprocessError(
[mojo][error] Mojo SDK post-install test "`mojo build test_python.mojo`" failed:
SubprocessError: Command '/tmp/tmpradqr68f/test_python' died with <Signals.SIGILL: 4>.
  File "/home/vboxuser/.modular/pkg/packages.modular.com_mojo/scripts/post-install/self-test.py", line 223, in test_mojo_build
    self.run(Path(tmp) / "test_python")[0],
  File "/home/vboxuser/.modular/pkg/packages.modular.com_mojo/scripts/post-install/self-test.py", line 181, in run
    raise SubprocessError(
[mojo][error] Mojo SDK post-install test "`mojo package`" failed:
SubprocessError: Command '/home/vboxuser/.modular/pkg/packages.modular.com_mojo/bin/mojo run /tmp/tmps1iw5o1f/test_package_user.mojo -I /tmp/tmps1iw5o1f' died with <Signals.SIGILL: 4>.
  stderr:
    [2509:2509:20240430,182830.197578:ERROR file_io_posix.cc:144] open /sys/devices/system/cpu/cpu0/cpufreq/scaling_cur_freq: No such file or directory (2)
    [2509:2509:20240430,182830.197674:ERROR file_io_posix.cc:144] open /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq: No such file or directory (2)
    Please submit a bug report to https://github.com/modularml/mojo/issues and include the crash backtrace along with all the relevant source codes.
    Stack dump:
    0.  Program arguments: /home/vboxuser/.modular/pkg/packages.modular.com_mojo/bin/mojo run /tmp/tmps1iw5o1f/tes[2509:2510:20240430,182830.199207:ERROR directory_reader_posix.cc:42] opendir /home/vboxuser/.modular/crashdb/attachments/8b5a506f-b55d-4e9a-a898-8823c0970c84: No such file or directory (2)
    t_package_user.mojo -I /tmp/tmps1iw5o1f
    Stack dump without symbol names (ensure you have llvm-symbolizer in your PATH or set the environment var `LLVM_SYMBOLIZER_PATH` to point to it):
    0  mojo      0x00005646cc8d4f57
    1  mojo      0x00005646cc8d2b2e
    2  mojo      0x00005646cc8d55ef
    3  libc.so.6 0x00007fa026834520
    4  libc.so.6 0x00007f9fd000a17c
    0x5646cf6d1238 crashed!
    Please file a bug report.
    [2509:2510:20240430,182830.207963:ERROR http_transport_libcurl.cc:470] curl_easy_perform: Couldn't resolve host name (6)
  File "/home/vboxuser/.modular/pkg/packages.modular.com_mojo/scripts/post-install/self-test.py", line 264, in test_mojo_package
    self.run_mojo(
  File "/home/vboxuser/.modular/pkg/packages.modular.com_mojo/scripts/post-install/self-test.py", line 193, in run_mojo
    return self.run(self.mojo, subcommand, *args)
  File "/home/vboxuser/.modular/pkg/packages.modular.com_mojo/scripts/post-install/self-test.py", line 181, in run
    raise SubprocessError(
[mojo][error] Mojo SDK post-install test "`mojo test_mandelbrot.mojo`" failed:
SubprocessError: Command '/home/vboxuser/.modular/pkg/packages.modular.com_mojo/bin/mojo /home/vboxuser/.modular/pkg/packages.modular.com_mojo/test/test_mandelbrot.mojo' died with <Signals.SIGILL: 4>.
  stderr:
    [2568:2568:20240430,182839.065833:ERROR file_io_posix.cc:144] open /sys/devices/system/cpu/cpu0/cpufreq/scaling_cur_freq: No such file or directory (2)
    [2568:2568:20240430,182839.065944:ERROR file_io_posix.cc:144] open /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq: No such file or directory (2)
    Please submit a bug report to https://github.com/modularml/mojo/issues and include the crash backtrace along with all the relevant source codes.
    Stack dump:
    0.  Program arguments: /home/vboxuser/.modular/pkg/packages.modular.com_mojo/bin/mojo /home/vboxuser/.modular/pkg/packages.modular.com_mojo/test/test_mandelbrot.mojo
    Stack dump without symbol names (ensure you have llvm-symbolizer in your PATH or set the environment var `LLVM_SYMBOLIZER_PATH` to point to it):
    0  mojo      0x000055d118856f57
    1  mojo      0x000055d118854b2e
    2  mojo      0x000055d1188575ef
    3  libc.so.6 0x00007fc341199520
    4  libc.so.6 0x00007fc2ec00a17c
    0x55d11b653238 crashed!
    Please file a bug report.
  File "/home/vboxuser/.modular/pkg/packages.modular.com_mojo/scripts/post-install/self-test.py", line 363, in test_mojo_run
    "25", self.run_mojo(self.test_dir / "test_mandelbrot.mojo")[0]
  File "/home/vboxuser/.modular/pkg/packages.modular.com_mojo/scripts/post-install/self-test.py", line 193, in run_mojo
    return self.run(self.mojo, subcommand, *args)
  File "/home/vboxuser/.modular/pkg/packages.modular.com_mojo/scripts/post-install/self-test.py", line 181, in run
    raise SubprocessError(
[mojo][error] Mojo SDK post-install test "`mojo test_python.mojo`" failed:
SubprocessError: Command '/home/vboxuser/.modular/pkg/packages.modular.com_mojo/bin/mojo /home/vboxuser/.modular/pkg/packages.modular.com_mojo/test/test_python.mojo' died with <Signals.SIGILL: 4>.
  stderr:
    [2587:2587:20240430,182841.123945:ERROR file_io_posix.cc:144] open /sys/devices/system/cpu/cpu0/cpufreq/scaling_cur_freq: No such file or directory (2)
    [2587:2587:20240430,182841.124034:ERROR file_io_posix.cc:144] open /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq: No such file or directory (2)
    Please submit a bug report to https://github.com/modularml/mojo/issues and include the crash backtrace along with all the relevant source codes.
    Stack dump:
    0.  Program arguments: /home/vboxuser/.modular/pkg/packages.modular.com_mojo/bin/mojo /home/vboxuser/.modular/pkg/packages.modular.com_mojo/test/test_python.mojo
    Stack dump without symbol names (ensure you have llvm-symbolizer in your PATH or set the environment var `LLVM_SYMBOLIZER_PATH` to point to it):
    0  mojo      0x0000558c41e19f57
    1  mojo      0x0000558c41e17b2e
    2  mojo      0x0000558c41e1a5ef
    3  libc.so.6 0x00007f88c3304520
    4  libc.so.6 0x00007f887403efce
    0x558c44c16238 crashed!
    Please file a bug report.
  File "/home/vboxuser/.modular/pkg/packages.modular.com_mojo/scripts/post-install/self-test.py", line 369, in test_mojo_run
    self.run_mojo(self.test_dir / "test_python.mojo")[0],
  File "/home/vboxuser/.modular/pkg/packages.modular.com_mojo/scripts/post-install/self-test.py", line 193, in run_mojo
    return self.run(self.mojo, subcommand, *args)
  File "/home/vboxuser/.modular/pkg/packages.modular.com_mojo/scripts/post-install/self-test.py", line 181, in run
    raise SubprocessError(
[mojo][error] Mojo SDK post-install test "`mojo repl`" failed:
CheckError: expected '42' to appear in output:

  File "/home/vboxuser/.modular/pkg/packages.modular.com_mojo/scripts/post-install/self-test.py", line 306, in test_mojo_repl
    self.assert_contains("42", out)
  File "/home/vboxuser/.modular/pkg/packages.modular.com_mojo/scripts/post-install/self-test.py", line 156, in assert_contains
    raise CheckError(needle, haystack)
[mojo][error] Some components of the Mojo SDK may have been installed successfully, but others may not work as expected.
[mojo][error] Please submit an issue to https://github.com/modularml/mojo and include the full output of the command you just ran.
modular: error: failed to run script
==========================
Failure Information:
    - Script: `PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin HOME=/home/vboxuser PYTHONPATH=/home/vboxuser/.modular/pkg/packages.modular.com_mojo/venv/lib/home/vboxuser/.modular/pkg/packages.modular.com_mojo/venv/bin/python /home/vboxuser/.modular/pkg/packages.modular.com_mojo/scripts/post-install/self-test.py --modular-home /home/vboxuser/.modular --package-path /home/vboxuser/.modular/pkg/packages.modular.com_mojo --mojo-config-section mojo`
    - Result: 1
    - Stderr:
[mojo][error] Mojo SDK post-install test "`mojo build test_mandelbrot.mojo`" failed:
SubprocessError: Command '/tmp/tmpradqr68f/test_mandelbrot' died with <Signals.SIGILL: 4>.
  File "/home/vboxuser/.modular/pkg/packages.modular.com_mojo/scripts/post-install/self-test.py", line 212, in test_mojo_build
    "25", self.run(Path(tmp) / "test_mandelbrot")[0]
  File "/home/vboxuser/.modular/pkg/packages.modular.com_mojo/scripts/post-install/self-test.py", line 181, in run
    raise SubprocessError(
[mojo][error] Mojo SDK post-install test "`mojo build test_python.mojo`" failed:
SubprocessError: Command '/tmp/tmpradqr68f/test_python' died with <Signals.SIGILL: 4>.
  File "/home/vboxuser/.modular/pkg/packages.modular.com_mojo/scripts/post-install/self-test.py", line 223, in test_mojo_build
    self.run(Path(tmp) / "test_python")[0],
  File "/home/vboxuser/.modular/pkg/packages.modular.com_mojo/scripts/post-install/self-test.py", line 181, in run
    raise SubprocessError(
[mojo][error] Mojo SDK post-install test "`mojo package`" failed:
SubprocessError: Command '/home/vboxuser/.modular/pkg/packages.modular.com_mojo/bin/mojo run /tmp/tmps1iw5o1f/test_package_user.mojo -I /tmp/tmps1iw5o1f' died with <Signals.SIGILL: 4>.
  stderr:
    [2509:2509:20240430,182830.197578:ERROR file_io_posix.cc:144] open /sys/devices/system/cpu/cpu0/cpufreq/scaling_cur_freq: No such file or directory (2)
    [2509:2509:20240430,182830.197674:ERROR file_io_posix.cc:144] open /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq: No such file or directory (2)
    Please submit a bug report to https://github.com/modularml/mojo/issues and include the crash backtrace along with all the relevant source codes.
    Stack dump:
    0.  Program arguments: /home/vboxuser/.modular/pkg/packages.modular.com_mojo/bin/mojo run /tmp/tmps1iw5o1f/tes[2509:2510:20240430,182830.199207:ERROR directory_reader_posix.cc:42] opendir /home/vboxuser/.modular/crashdb/attachments/8b5a506f-b55d-4e9a-a898-8823c0970c84: No such file or directory (2)
    t_package_user.mojo -I /tmp/tmps1iw5o1f
    Stack dump without symbol names (ensure you have llvm-symbolizer in your PATH or set the environment var `LLVM_SYMBOLIZER_PATH` to point to it):
    0  mojo      0x00005646cc8d4f57
    1  mojo      0x00005646cc8d2b2e
    2  mojo      0x00005646cc8d55ef
    3  libc.so.6 0x00007fa026834520
    4  libc.so.6 0x00007f9fd000a17c
    0x5646cf6d1238 crashed!
    Please file a bug report.
    [2509:2510:20240430,182830.207963:ERROR http_transport_libcurl.cc:470] curl_easy_perform: Couldn't resolve host name (6)
  File "/home/vboxuser/.modular/pkg/packages.modular.com_mojo/scripts/post-install/self-test.py", line 264, in test_mojo_package
    self.run_mojo(
  File "/home/vboxuser/.modular/pkg/packages.modular.com_mojo/scripts/post-install/self-test.py", line 193, in run_mojo
    return self.run(self.mojo, subcommand, *args)
  File "/home/vboxuser/.modular/pkg/packages.modular.com_mojo/scripts/post-install/self-test.py", line 181, in run
    raise SubprocessError(
[mojo][error] Mojo SDK post-install test "`mojo test_mandelbrot.mojo`" failed:
SubprocessError: Command '/home/vboxuser/.modular/pkg/packages.modular.com_mojo/bin/mojo /home/vboxuser/.modular/pkg/packages.modular.com_mojo/test/test_mandelbrot.mojo' died with <Signals.SIGILL: 4>.
  stderr:
    [2568:2568:20240430,182839.065833:ERROR file_io_posix.cc:144] open /sys/devices/system/cpu/cpu0/cpufreq/scaling_cur_freq: No such file or directory (2)
    [2568:2568:20240430,182839.065944:ERROR file_io_posix.cc:144] open /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq: No such file or directory (2)
    Please submit a bug report to https://github.com/modularml/mojo/issues and include the crash backtrace along with all the relevant source codes.
    Stack dump:
    0.  Program arguments: /home/vboxuser/.modular/pkg/packages.modular.com_mojo/bin/mojo /home/vboxuser/.modular/pkg/packages.modular.com_mojo/test/test_mandelbrot.mojo
    Stack dump without symbol names (ensure you have llvm-symbolizer in your PATH or set the environment var `LLVM_SYMBOLIZER_PATH` to point to it):
    0  mojo      0x000055d118856f57
    1  mojo      0x000055d118854b2e
    2  mojo      0x000055d1188575ef
    3  libc.so.6 0x00007fc341199520
    4  libc.so.6 0x00007fc2ec00a17c
    0x55d11b653238 crashed!
    Please file a bug report.
  File "/home/vboxuser/.modular/pkg/packages.modular.com_mojo/scripts/post-install/self-test.py", line 363, in test_mojo_run
    "25", self.run_mojo(self.test_dir / "test_mandelbrot.mojo")[0]
  File "/home/vboxuser/.modular/pkg/packages.modular.com_mojo/scripts/post-install/self-test.py", line 193, in run_mojo
    return self.run(self.mojo, subcommand, *args)
  File "/home/vboxuser/.modular/pkg/packages.modular.com_mojo/scripts/post-install/self-test.py", line 181, in run
    raise SubprocessError(
[mojo][error] Mojo SDK post-install test "`mojo test_python.mojo`" failed:
SubprocessError: Command '/home/vboxuser/.modular/pkg/packages.modular.com_mojo/bin/mojo /home/vboxuser/.modular/pkg/packages.modular.com_mojo/test/test_python.mojo' died with <Signals.SIGILL: 4>.
  stderr:
    [2587:2587:20240430,182841.123945:ERROR file_io_posix.cc:144] open /sys/devices/system/cpu/cpu0/cpufreq/scaling_cur_freq: No such file or directory (2)
    [2587:2587:20240430,182841.124034:ERROR file_io_posix.cc:144] open /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq: No such file or directory (2)
    Please submit a bug report to https://github.com/modularml/mojo/issues and include the crash backtrace along with all the relevant source codes.
    Stack dump:
    0.  Program arguments: /home/vboxuser/.modular/pkg/packages.modular.com_mojo/bin/mojo /home/vboxuser/.modular/pkg/packages.modular.com_mojo/test/test_python.mojo
    Stack dump without symbol names (ensure you have llvm-symbolizer in your PATH or set the environment var `LLVM_SYMBOLIZER_PATH` to point to it):
    0  mojo      0x0000558c41e19f57
    1  mojo      0x0000558c41e17b2e
    2  mojo      0x0000558c41e1a5ef
    3  libc.so.6 0x00007f88c3304520
    4  libc.so.6 0x00007f887403efce
    0x558c44c16238 crashed!
    Please file a bug report.
  File "/home/vboxuser/.modular/pkg/packages.modular.com_mojo/scripts/post-install/self-test.py", line 369, in test_mojo_run
    self.run_mojo(self.test_dir / "test_python.mojo")[0],
  File "/home/vboxuser/.modular/pkg/packages.modular.com_mojo/scripts/post-install/self-test.py", line 193, in run_mojo
    return self.run(self.mojo, subcommand, *args)
  File "/home/vboxuser/.modular/pkg/packages.modular.com_mojo/scripts/post-install/self-test.py", line 181, in run
    raise SubprocessError(
[mojo][error] Mojo SDK post-install test "`mojo repl`" failed:
CheckError: expected '42' to appear in output:

  File "/home/vboxuser/.modular/pkg/packages.modular.com_mojo/scripts/post-install/self-test.py", line 306, in test_mojo_repl
    self.assert_contains("42", out)
  File "/home/vboxuser/.modular/pkg/packages.modular.com_mojo/scripts/post-install/self-test.py", line 156, in assert_contains
    raise CheckError(needle, haystack)
[mojo][error] Some components of the Mojo SDK may have been installed successfully, but others may not work as expected.
[mojo][error] Please submit an issue to https://github.com/modularml/mojo and include the full output of the command you just ran.

==========================

vboxuser@livemint-21:~$ 

Steps to reproduce

modular install mojo on LinuxMint 21.3 (inside virtualbox vm)

Version Info

- Provide Modular CLI version by pasting the output of `modular -v`

vboxuser@livemint-21:~$ modular -v
modular 0.7.4 (df7a9e8b)
vboxuser@livemint-21:~$ lsb_release -ar
No LSB modules are available.
Distributor ID: Linuxmint
Description: Linux Mint 21.3
Release: 21.3
Codename: virginia

vboxuser@livemint-21:~$ uname -a
Linux livemint-21 5.15.0-105-generic #115-Ubuntu SMP Mon Apr 15 09:52:04 UTC 2024 x86_64 x86_64 x86_64 GNU/Linux
kulkarnima commented 4 months ago

Is there any workaround which I can use meanwhile? I've the same error with WSL

walter-erquinigo commented 2 months ago

Please ensure that the VM has at least 2 GB of free ram for every compiler invocation.