Rustup: complete profile is an attractive nuisance

Created on 13 Feb 2021  路  11Comments  路  Source: rust-lang/rustup

Problem
rustup-init fails with: detected conflict: '"share/doc/rust/html/rustc/favicon.svg"'
when installing nightly complete:

info: profile set to 'complete'    
info: setting default host triple to x86_64-unknown-linux-gnu               
info: syncing channel updates for 'nightly-x86_64-unknown-linux-gnu'                                                                                    
info: latest update on 2021-02-13, rust version 1.52.0-nightly (3f5aee2d5 2021-02-12)                                                                   
info: downloading component 'cargo'   
info: downloading component 'clippy'
info: downloading component 'llvm-tools-preview'                            
 20.2 MiB /  20.2 MiB (100 %)   6.3 MiB/s in  3s ETA:  0s        
info: downloading component 'miri'                                          
info: downloading component 'rls'     
  8.4 MiB /   8.4 MiB (100 %)   6.5 MiB/s in  1s ETA:  0s       
info: downloading component 'rust-analysis'                                 
info: downloading component 'rust-analyzer-preview'                         
info: downloading component 'rust-docs'                                     
 15.0 MiB /  15.0 MiB (100 %)   6.4 MiB/s in  2s ETA:  0s                   
info: downloading component 'rust-src'                                      
info: downloading component 'rust-std'
 25.0 MiB /  25.0 MiB (100 %)   6.6 MiB/s in  3s ETA:  0s                   
info: downloading component 'rustc'   
 50.2 MiB /  50.2 MiB (100 %)   6.5 MiB/s in  8s ETA:  0s                   
info: downloading component 'rustc-dev'                                     
103.7 MiB / 103.7 MiB (100 %)   6.2 MiB/s in 16s ETA:  0s     
info: downloading component 'rustc-docs'                                    
 11.1 MiB /  11.1 MiB (100 %)   6.3 MiB/s in  1s ETA:  0s   
info: downloading component 'rustfmt'
info: installing component 'cargo'    
info: using up to 500.0 MiB of RAM to unpack components                     
info: installing component 'clippy'   
info: installing component 'llvm-tools-preview'                  
 20.2 MiB /  20.2 MiB (100 %)   9.8 MiB/s in  2s ETA:  0s
info: installing component 'miri'     
info: installing component 'rls'
info: installing component 'rust-analysis'                                  
info: installing component 'rust-analyzer-preview'                          
info: installing component 'rust-docs'                                      
 15.0 MiB /  15.0 MiB (100 %)   6.8 MiB/s in  2s ETA:  0s                   
info: installing component 'rust-src' 
info: installing component 'rust-std'
 25.0 MiB /  25.0 MiB (100 %)   8.6 MiB/s in  2s ETA:  0s                   
info: installing component 'rustc'    
 50.2 MiB /  50.2 MiB (100 %)  10.1 MiB/s in  4s ETA:  0s
info: installing component 'rustc-dev'                                      
103.7 MiB / 103.7 MiB (100 %)   9.5 MiB/s in 12s ETA:  0s                   
info: installing component 'rustc-docs'                                     
 11.1 MiB /  11.1 MiB (100 %)   4.9 MiB/s in  3s ETA:  0s                   
info: rolling back changes                                                  
error: failed to install component: 'rustc-docs-x86_64-unknown-linux-gnu', detected conflict: '"share/doc/rust/html/rustc/favicon.svg"'                 

Steps

Operating system: Linux amd64

Use installer settings:

   default host triple: x86_64-unknown-linux-gnu
     default toolchain: nightly
               profile: complete
  modify PATH variable: no

Possible Solution(s)

Notes

bug help wanted

Most helpful comment

I'm using the default profile and I'm getting a similar error failed to install component: 'rust-docs-x86_64-unknown-linux-gnu', detected conflict: '"share/doc/rust/html/std/keyword.self.html"'. The non-native-host toolchain is required by cross, but I've boiled the issue down to the default profile used by rustup.

I even removed the ~/.rustup dir before installing to avoid other toolchain conflicts.

Host: macOS big sur 11.1 (20C69)
Target: raspberry pi 3b+

$ rustup --version                                                       
rustup 1.23.1 (3df2264a9 2020-11-30)
info: This is the version for the rustup toolchain manager, not the rustc compiler.

$ rm -rf ~/.rustup                                                      

$ sw_vers
ProductName:    macOS
ProductVersion: 11.1
BuildVersion:   20C69

$ rustup show profile                                                   
default

$ rustup toolchain add stable-x86_64-unknown-linux-gnu                  
warning: toolchain 'stable-x86_64-unknown-linux-gnu' may not be able to run on this system.
warning: If you meant to build software to target that platform, perhaps try `rustup target add x86_64-unknown-linux-gnu` instead?
info: syncing channel updates for 'stable-x86_64-unknown-linux-gnu'
info: latest update on 2021-02-11, rust version 1.50.0 (cb75ad5db 2021-02-10)
info: downloading component 'cargo'
info: downloading component 'clippy'
info: downloading component 'rust-docs'
 14.7 MiB /  14.7 MiB (100 %)  12.2 MiB/s in  1s ETA:  0s
info: downloading component 'rust-std'
 24.5 MiB /  24.5 MiB (100 %)  12.5 MiB/s in  2s ETA:  0s
info: downloading component 'rustc'
 60.3 MiB /  60.3 MiB (100 %)  13.6 MiB/s in  4s ETA:  0s
info: downloading component 'rustfmt'
info: installing component 'cargo'
info: using up to 500.0 MiB of RAM to unpack components
info: installing component 'clippy'
info: installing component 'rust-docs'
 14.7 MiB /  14.7 MiB (100 %)   5.0 MiB/s in  2s ETA:  0s
info: rolling back changes
error: failed to install component: 'rust-docs-x86_64-unknown-linux-gnu', detected conflict: '"share/doc/rust/html/std/keyword.self.html"'

The install works using the minimal profile though, probably because it's not installing rust-docs component.

$ rm -rf ~/.rustup                                    

$ sw_vers                                             
ProductName:    macOS
ProductVersion: 11.1
BuildVersion:   20C69

$ rustup set profile minimal                               
info: profile set to 'minimal'

$ rustup show profile       
minimal

$ rustup toolchain add stable-x86_64-unknown-linux-gnu
warning: toolchain 'stable-x86_64-unknown-linux-gnu' may not be able to run on this system.
warning: If you meant to build software to target that platform, perhaps try `rustup target add x86_64-unknown-linux-gnu` instead?
info: syncing channel updates for 'stable-x86_64-unknown-linux-gnu'
info: latest update on 2021-02-11, rust version 1.50.0 (cb75ad5db 2021-02-10)
info: downloading component 'cargo'
info: downloading component 'rust-std'
 24.5 MiB /  24.5 MiB (100 %)   9.6 MiB/s in  2s ETA:  0s
info: downloading component 'rustc'
 60.3 MiB /  60.3 MiB (100 %)  13.6 MiB/s in  4s ETA:  0s
info: installing component 'cargo'
info: using up to 500.0 MiB of RAM to unpack components
info: installing component 'rust-std'
 24.5 MiB /  24.5 MiB (100 %)  11.2 MiB/s in  2s ETA:  0s
info: installing component 'rustc'
 60.3 MiB /  60.3 MiB (100 %)  13.2 MiB/s in  4s ETA:  0s

  stable-x86_64-unknown-linux-gnu installed - (error reading rustc version)

info: default toolchain set to 'stable-x86_64-unknown-linux-gnu'
info: checking for self-updates

All 11 comments

You may have interrupted the download.
If it's true.
You may need to clear your download cache.
Usually in ~/.rustup and ~/.cargo.

You may have interrupted the download.

No.

You may need to clear your download cache.
Usually in ~/.rustup and ~/.cargo.

No. This is a completely fresh start. rustup and cargo directories don't exist.

It only happens in complete profile. I guess two components provide the same file or something like that.
Please try to reproduce the problem.

$ RUSTUP_HOME=/tmp/rustup CARGO_HOME=/tmp/cargo sh ./rustup-init.sh --profile complete --no-modify-path --default-toolchain nightly -y
info: downloading installer
Warning: Not enforcing strong cipher suites for TLS, this is potentially less secure
Warning: Not enforcing TLS v1.2, this is potentially less secure
warning: downloading with complete profile isn't recommended unless you are a developer of the rust language
info: profile set to 'complete'
info: default host triple is x86_64-unknown-linux-gnu
info: syncing channel updates for 'nightly-x86_64-unknown-linux-gnu'
info: latest update on 2021-02-14, rust version 1.52.0-nightly (8e54a2113 2021-02-13)
info: downloading component 'cargo'
  6.0 MiB /   6.0 MiB (100 %)   5.7 MiB/s in  1s ETA:  0s
info: downloading component 'clippy'
info: downloading component 'llvm-tools-preview'
 20.2 MiB /  20.2 MiB (100 %)   6.1 MiB/s in  3s ETA:  0s
info: downloading component 'miri'
info: downloading component 'rls'
  8.4 MiB /   8.4 MiB (100 %)   6.0 MiB/s in  1s ETA:  0s
info: downloading component 'rust-analysis'
info: downloading component 'rust-analyzer-preview'
  6.3 MiB /   6.3 MiB (100 %)   5.5 MiB/s in  1s ETA:  0s
info: downloading component 'rust-docs'
 15.0 MiB /  15.0 MiB (100 %)   6.3 MiB/s in  2s ETA:  0s
info: downloading component 'rust-src'
info: downloading component 'rust-std'
 24.9 MiB /  24.9 MiB (100 %)   6.2 MiB/s in  4s ETA:  0s
info: downloading component 'rustc'
 50.1 MiB /  50.1 MiB (100 %)   5.9 MiB/s in  8s ETA:  0s
info: downloading component 'rustc-dev'
103.6 MiB / 103.6 MiB (100 %)   6.1 MiB/s in 17s ETA:  0s
info: downloading component 'rustc-docs'
 11.1 MiB /  11.1 MiB (100 %)   6.2 MiB/s in  1s ETA:  0s
info: downloading component 'rustfmt'
info: installing component 'cargo'
info: using up to 500.0 MiB of RAM to unpack components
info: installing component 'clippy'
info: installing component 'llvm-tools-preview'
 20.2 MiB /  20.2 MiB (100 %)  10.4 MiB/s in  1s ETA:  0s
info: installing component 'miri'
info: installing component 'rls'
info: installing component 'rust-analysis'
info: installing component 'rust-analyzer-preview'
info: installing component 'rust-docs'
 15.0 MiB /  15.0 MiB (100 %)   7.3 MiB/s in  1s ETA:  0s
info: installing component 'rust-src'
info: installing component 'rust-std'
 24.9 MiB /  24.9 MiB (100 %)   9.0 MiB/s in  2s ETA:  0s
info: installing component 'rustc'
 50.1 MiB /  50.1 MiB (100 %)  10.4 MiB/s in  4s ETA:  0s
info: installing component 'rustc-dev'
103.6 MiB / 103.6 MiB (100 %)   9.9 MiB/s in 10s ETA:  0s
info: installing component 'rustc-docs'
 11.1 MiB /  11.1 MiB (100 %)   7.6 MiB/s in  1s ETA:  0s
info: rolling back changes
error: failed to install component: 'rustc-docs-x86_64-unknown-linux-gnu', detected conflict: '"share/doc/rust/html/rustc/favicon.svg"'

Don't use the complete profile. It is not intended for use.

Ah Ok.

So could we remove this user visible option?
It's pretty confusing to have a visible option that's not supposed to be used.

I agree that it is confusing and I'll bring it up for discussion at our next dev-tools meeting. I'm considering hiding complete entirely as we've never really made it work properly.

I'm using the default profile and I'm getting a similar error failed to install component: 'rust-docs-x86_64-unknown-linux-gnu', detected conflict: '"share/doc/rust/html/std/keyword.self.html"'. The non-native-host toolchain is required by cross, but I've boiled the issue down to the default profile used by rustup.

I even removed the ~/.rustup dir before installing to avoid other toolchain conflicts.

Host: macOS big sur 11.1 (20C69)
Target: raspberry pi 3b+

$ rustup --version                                                       
rustup 1.23.1 (3df2264a9 2020-11-30)
info: This is the version for the rustup toolchain manager, not the rustc compiler.

$ rm -rf ~/.rustup                                                      

$ sw_vers
ProductName:    macOS
ProductVersion: 11.1
BuildVersion:   20C69

$ rustup show profile                                                   
default

$ rustup toolchain add stable-x86_64-unknown-linux-gnu                  
warning: toolchain 'stable-x86_64-unknown-linux-gnu' may not be able to run on this system.
warning: If you meant to build software to target that platform, perhaps try `rustup target add x86_64-unknown-linux-gnu` instead?
info: syncing channel updates for 'stable-x86_64-unknown-linux-gnu'
info: latest update on 2021-02-11, rust version 1.50.0 (cb75ad5db 2021-02-10)
info: downloading component 'cargo'
info: downloading component 'clippy'
info: downloading component 'rust-docs'
 14.7 MiB /  14.7 MiB (100 %)  12.2 MiB/s in  1s ETA:  0s
info: downloading component 'rust-std'
 24.5 MiB /  24.5 MiB (100 %)  12.5 MiB/s in  2s ETA:  0s
info: downloading component 'rustc'
 60.3 MiB /  60.3 MiB (100 %)  13.6 MiB/s in  4s ETA:  0s
info: downloading component 'rustfmt'
info: installing component 'cargo'
info: using up to 500.0 MiB of RAM to unpack components
info: installing component 'clippy'
info: installing component 'rust-docs'
 14.7 MiB /  14.7 MiB (100 %)   5.0 MiB/s in  2s ETA:  0s
info: rolling back changes
error: failed to install component: 'rust-docs-x86_64-unknown-linux-gnu', detected conflict: '"share/doc/rust/html/std/keyword.self.html"'

The install works using the minimal profile though, probably because it's not installing rust-docs component.

$ rm -rf ~/.rustup                                    

$ sw_vers                                             
ProductName:    macOS
ProductVersion: 11.1
BuildVersion:   20C69

$ rustup set profile minimal                               
info: profile set to 'minimal'

$ rustup show profile       
minimal

$ rustup toolchain add stable-x86_64-unknown-linux-gnu
warning: toolchain 'stable-x86_64-unknown-linux-gnu' may not be able to run on this system.
warning: If you meant to build software to target that platform, perhaps try `rustup target add x86_64-unknown-linux-gnu` instead?
info: syncing channel updates for 'stable-x86_64-unknown-linux-gnu'
info: latest update on 2021-02-11, rust version 1.50.0 (cb75ad5db 2021-02-10)
info: downloading component 'cargo'
info: downloading component 'rust-std'
 24.5 MiB /  24.5 MiB (100 %)   9.6 MiB/s in  2s ETA:  0s
info: downloading component 'rustc'
 60.3 MiB /  60.3 MiB (100 %)  13.6 MiB/s in  4s ETA:  0s
info: installing component 'cargo'
info: using up to 500.0 MiB of RAM to unpack components
info: installing component 'rust-std'
 24.5 MiB /  24.5 MiB (100 %)  11.2 MiB/s in  2s ETA:  0s
info: installing component 'rustc'
 60.3 MiB /  60.3 MiB (100 %)  13.2 MiB/s in  4s ETA:  0s

  stable-x86_64-unknown-linux-gnu installed - (error reading rustc version)

info: default toolchain set to 'stable-x86_64-unknown-linux-gnu'
info: checking for self-updates

@blesson3 no, you're hitting #2672

For reference, from the dev-tools meeting, I was tasked with taking the discussion to the release team to see what they'd prefer to do between redefining the set of things in complete to something which can be guaranteed to install on stable toolchains, or to deprecating/removing it entirely.

In the meantime the dev-tools team, as a whole, was okay with the idea of hiding the complete profile (ie. removing it from documentation and CLI help) but leaving it possible to use. Perhaps increasing the warning that it is currently considered an unstable choice might be a good way to decrease people's expectations until we have a release team decision.

Like @blesson3, I'm running into the exact same issue, but on Linux, Pop!_OS 20.04 (an Ubuntu variant). Note that this happens both with complete and default. The fact that complete could/should be hidden has nothing to do with this issue:

rm -rf ~/.cargo ~/.rustup
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh
(...)
info: profile set to 'default'
info: setting default host triple to x86_64-unknown-linux-gnu
info: syncing channel updates for 'stable-x86_64-unknown-linux-gnu'
info: latest update on 2021-03-25, rust version 1.51.0 (2fd73fabe 2021-03-23)
info: downloading component 'cargo'
info: downloading component 'clippy'
info: downloading component 'rust-docs'
info: downloading component 'rust-std'
info: downloading component 'rustc'
 50.4 MiB /  50.4 MiB (100 %)  36.2 MiB/s in  2s ETA:  0s
info: downloading component 'rustfmt'
info: installing component 'cargo'
info: using up to 500.0 MiB of RAM to unpack components
info: installing component 'clippy'
info: installing component 'rust-docs'
 14.9 MiB /  14.9 MiB (100 %)   4.9 MiB/s in  4s ETA:  0s
info: rolling back changes
warning: could not delete temp directory: /home/rubin/.rustup/tmp/csn105hulr00a8d6_dir
error: failed to install component: 'rust-docs-x86_64-unknown-linux-gnu', detected conflict: '"share/doc/rust/html/std/keyword.self.html"'

Note also that it's the exact same file that's conflicting (share/doc/rust/html/std/keyword.self.html). I can confirm that minimal works, because it does not install rust-docs-x86_64-unknown-linux-gnu.

@rubin55 The rust-docs problem is not the same as the other problems on this. This implies you're installing a linux toolchain onto a non-linux host as that kind of error is more related to the fact that 1.50 and 1.51's documentation contains filenames which differ only by case which upsets Windows and mac filesystems in their default configuration

Please I am unable to install rust 1.51.0 on Ubuntu 20.10 (groovy).
What could be wrong?

eshikafe@eshikafe-vb:~$ curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh
info: downloading installer

Welcome to Rust!

This will download and install the official compiler for the Rust
programming language, and its package manager, Cargo.

Rustup metadata and toolchains will be installed into the Rustup
home directory, located at:

  /home/eshikafe/.rustup

This can be modified with the RUSTUP_HOME environment variable.

The Cargo home directory located at:

  /home/eshikafe/.cargo

This can be modified with the CARGO_HOME environment variable.

The cargo, rustc, rustup and other commands will be added to
Cargo's bin directory, located at:

  /home/eshikafe/.cargo/bin

This path will then be added to your PATH environment variable by
modifying the profile files located at:

  /home/eshikafe/.profile
  /home/eshikafe/.bashrc

You can uninstall at any time with rustup self uninstall and
these changes will be reverted.

Current installation options:


   default host triple: x86_64-unknown-linux-gnu
     default toolchain: stable (default)
               profile: default
  modify PATH variable: yes

1) Proceed with installation (default)
2) Customize installation
3) Cancel installation
>1

info: profile set to 'default'
info: default host triple is x86_64-unknown-linux-gnu
info: syncing channel updates for 'stable-x86_64-unknown-linux-gnu'
info: latest update on 2021-03-25, rust version 1.51.0 (2fd73fabe 2021-03-23)
info: downloading component 'cargo'
  6.0 MiB /   6.0 MiB (100 %)   3.4 MiB/s in  2s ETA:  0s
info: downloading component 'clippy'
info: downloading component 'rust-docs'
 14.9 MiB /  14.9 MiB (100 %)   1.4 MiB/s in 17s ETA:  0s
info: downloading component 'rust-std'
 24.9 MiB /  24.9 MiB (100 %)   1.3 MiB/s in 23s ETA:  0s 
info: downloading component 'rustc'
 50.4 MiB /  50.4 MiB (100 %)   3.2 MiB/s in 19s ETA:  0s
info: downloading component 'rustfmt'
info: installing component 'cargo'
info: using up to 500.0 MiB of RAM to unpack components
info: installing component 'clippy'
info: installing component 'rust-docs'
 14.9 MiB /  14.9 MiB (100 %)   3.1 MiB/s in  4s ETA:  0s
info: installing component 'rust-std'
 24.9 MiB /  24.9 MiB (100 %)   5.4 MiB/s in  5s ETA:  0s
info: installing component 'rustc'
 30.1 MiB /  50.4 MiB ( 60 %)   6.0 MiB/s in  5s ETA:  3sKilled
eshikafe@eshikafe-vb:~$ 

rustup is unable to install rustc. It gets Killed while installing rustc.

Was this page helpful?
0 / 5 - 0 ratings