ubuntu - rustup 在下载过程中安装稳定错误
问题描述
我使用以下命令安装 Rust:
$ curl -sSf https://static.rust-lang.org/rustup.sh | sh
当我运行时:
$ rustc main.rs
这出现了:
error: no default toolchain configured
所以我跑:
rustup install stable
然后:
info: downloading component 'rust-std'
23.2 MiB / 56.2 MiB ( 41 %) 67.2 KiB/s ETA: 503 s error: component download failed for rust-std-x86_64-unknown-linux-gnu
info: caused by: could not download file from 'https://static.rust-lang.org/dist/2018-07-10/rust-std-1.27.1-x86_64-unknown-linux-gnu.tar.xz' to '/home/kwebi/.rustup/downloads/d3b0d00357cfaecf85651bea6f1d72793a5a859b6b07e9613ba21285922d5d58.partial'
info: caused by: error during download
info: caused by: [56] Failure when receiving data from the peer (OpenSSL SSL_read: error:1408F119:SSL routines:SSL3_GET_RECORD:decryption failed or bad record mac, errno 0)
一开始,我用follow来安装rust,打印的错误信息和之前一样,有下载错误:
$ curl https://sh.rustup.rs -sSf | sh
curl: (56) OpenSSL SSL_read: SSL_ERROR_SYSCALL, errno 104
rustup: command failed: downloader https://static.rust-lang.org/rustup/dist/x86_64-unknown-linux-gnu/rustup-init /tmp/tmp.2EZ69sGKWR/rustup-init
我现在可以做些什么来完全安装 rust?
解决方案
我已经通过以下方式解决了这个问题:
rustup update
rustup default stable
sudo apt-get install gcc
推荐阅读
- r - 错误:EmailException (Java):将电子邮件发送到以下服务器失败:smtp.office365.com:587。R
- r - 如何在 R 数据框中满足条件后的第二天有条件地删除数据值?
- reactjs - Material-UI & React:使用 Fade 组件 onScroll
- c# - 计算列表中自己结构的重复项
- python - Python:将一维数组(具有等面积坐标系)转换为二维数组(具有地理坐标参考系)
- javascript - Javascript - 切片对象数组
- saml-2.0 - SAML 2.0 - 身份验证问题即时太旧或未来
- python - 如何从用户输入的某个字典中随机选择
- java - android studio中存储的实现库在哪里?
- c# - 在 Windows ML (UWP) 中张量 0-1 像素范围内的图像