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

Rustup 1.27.0 Segmentation fault on macOS Catalina #3731

Closed
masihyeganeh opened this issue Mar 22, 2024 · 5 comments
Closed

Rustup 1.27.0 Segmentation fault on macOS Catalina #3731

masihyeganeh opened this issue Mar 22, 2024 · 5 comments
Labels

Comments

@masihyeganeh
Copy link

Problem

Recently tried to do a rustup update and it went well, but failed at self update.
Then I tried to run the rustup self update:

~ rustup self update
info: checking for self-update
info: downloading self-update
  rustup updated - (unknown) (from 1.26.0)

error: self-updated failed to replace rustup executable

It shows nothing that can help.
Instead I tried to download new version of rustup manually from https://static.rust-lang.org/rustup/archive/1.27.0/x86_64-apple-darwin/rustup-init and run it after making it executable and it said:

[1]    19953 segmentation fault  /Users/xxx/.cargo/bin/rustup-init

Then I tried running it in gdb:

sudo gdb -quiet --args rustup-init
Reading symbols from rustup-init...

warning: Could not open OSO archive file "/Users/runner/.rustup/toolchains/stable-x86_64-apple-darwin/lib/rustlib/x86_64-apple-darwin/lib/libcompiler_builtins-1ebaaaec5ccf50e8.rlib"

warning: `/Users/runner/work/rustup/rustup/target/x86_64-apple-darwin/release/deps/rustup_init-b0eb698e74583c90.rustup_init.5417f959965d7a3b-cgu.0.rcgu.o': can't open to read symbols: No such file or directory.

warning: Could not open OSO archive file "/private/var/folders/f8/xn9w26457_v2fc5qzhbrlyj00000gn/T/rustckiRNtn/libring-eb7db2a4ce87c7b2.rlib"
(No debugging symbols found in rustup-init)
(gdb) break std::sys_common::once::queue::Once::call
Breakpoint 1 at 0x100572c74
(gdb) run
Starting program: /Users/xxx/.cargo/bin/rustup-init
[New Thread 0x2803 of process 72475]
[New Thread 0x2603 of process 72475]
warning: unhandled dyld version (16)

Thread 2 hit Breakpoint 1, 0x0000000100572c74 in std::sys_common::once::queue::Once::call ()
(gdb) bt
#0  0x0000000100572c74 in std::sys_common::once::queue::Once::call ()
#1  0x00000001000a5b32 in curl::INIT_CTOR::init_ctor ()
#2  0x00007ffeefbfcfdf in ?? ()
#3  0x0100000000000000 in ?? ()
#4  0x00007ffeefbfd140 in ?? ()
#5  0x00000001008b3320 in ?? ()
#6  0x0000000000000000 in ?? ()
(gdb) s
Single stepping until exit from function _ZN3std10sys_common4once5queue4Once4call17hdffec4ca98751720E,
which has no line number information.

Thread 2 received signal SIGSEGV, Segmentation fault.
0x0000000100573006 in std::sys_common::once::queue::Once::call ()

Steps

  1. Download rustup-init 1.27.0:wget https://static.rust-lang.org/rustup/archive/1.27.0/x86_64-apple-darwin/rustup-init
  2. Make it executable: chmod +x ./rustup-init
  3. Run it even with no arguments: ./rustup-init

Possible Solution(s)

No response

Notes

My machine is an Intel MacBook Pro (Late 2013) running macOS Catalina (10.15.3)

Rustup version

rustup 1.26.0 (5af9b9484 2023-04-05)
info: This is the version for the rustup toolchain manager, not the rustc compiler.
info: The currently active `rustc` version is `rustc 1.77.0 (aedd173a2 2024-03-17)`

Installed toolchains

Default host: x86_64-apple-darwin
rustup home:  /Users/xxx/.rustup

installed toolchains
--------------------

stable-x86_64-apple-darwin (default)
nightly-x86_64-apple-darwin

active toolchain
----------------

stable-x86_64-apple-darwin (default)
rustc 1.77.0 (aedd173a2 2024-03-17)
@djc
Copy link
Contributor

djc commented Mar 22, 2024

I think this is a duplicate of #3708? Should be fixed in a soon-to-be-released 1.27.1 release.

@masihyeganeh
Copy link
Author

@djc Yeah, I believe it's duplicate of that.
I tried to find it in issues, but couldn't.
So, I think it's best to close this one and check again after the release of 1.27.1.

@rami3l
Copy link
Member

rami3l commented Mar 22, 2024

@masihyeganeh Can you try the quick fix in #3708 (comment)?

@djc djc reopened this Mar 22, 2024
@djc djc closed this as not planned Won't fix, can't repro, duplicate, stale Mar 22, 2024
@masihyeganeh
Copy link
Author

@rami3l I can confirm that the quick fix works on my machine

@rami3l
Copy link
Member

rami3l commented Mar 22, 2024

@rami3l I can confirm that the quick fix works on my machine

Thanks! I think it's safe to close it as a dup of #3708 then.

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

No branches or pull requests

3 participants