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

Aniviruses cause a huge slowdown for 'rust-docs' installation #763

Closed
UtherII opened this issue Oct 18, 2016 · 18 comments
Closed

Aniviruses cause a huge slowdown for 'rust-docs' installation #763

UtherII opened this issue Oct 18, 2016 · 18 comments

Comments

@UtherII
Copy link

UtherII commented Oct 18, 2016

On my Windows 7 computer at work, the install/update process can't pass the docs installation phase, while it works fine on my personal Linux computer.

Messages :

C:\Windows\system32>rustup update stable
info: syncing channel updates for 'stable-x86_64-pc-windows-gnu'
info: downloading component 'rustc'
 45.2 MiB /  45.2 MiB (100 %) 403.2 KiB/s ETA:   0 s
info: downloading component 'rust-std'
 57.5 MiB /  57.5 MiB (100 %) 476.8 KiB/s ETA:   0 s
info: downloading component 'rust-docs'
  6.3 MiB /   6.3 MiB (100 %) 464.0 KiB/s ETA:   0 s
info: downloading component 'cargo'
  4.9 MiB /   4.9 MiB (100 %) 393.6 KiB/s ETA:   0 s
info: downloading component 'rust-mingw'
  7.1 MiB /   7.1 MiB (100 %) 456.5 KiB/s ETA:   0 s
info: installing component 'rustc'
info: installing component 'rust-std'
info: installing component 'rust-docs'

I have to use Ctrl+C or rustup never end.

@UtherII
Copy link
Author

UtherII commented Oct 19, 2016

I did further testing, it seems I was wrong. Rust-docs actually installs if I wait long enough, but it takes more than 1 hours, while the other components are installed in a few seconds.

@UtherII UtherII changed the title 'rust-docs' installation blocks 'rust-docs' installation can be far too long Oct 19, 2016
@GyrosOfWar
Copy link

Yeah, I've had similar issues on my PC at home. This is anecdotal (I should do some actual measuring) but I've got both Ubuntu and Windows 10 installed (both on SSD) on that PC and on Windows, installing the docs takes a lot longer (a couple of minutes instead of less than 30 seconds) than on Ubuntu.

@k4rtik
Copy link

k4rtik commented Oct 28, 2016

I use rustup on multiple machines and face the same issue. Is it not possible to just make installation of docs optional?

@oherrala
Copy link

@k4rtik, optional rust-docs installation is separate issue: #747

@k4rtik
Copy link

k4rtik commented Oct 31, 2016

@oherrala thanks for the pointer. But I also face this problem of huge delays in rust-docs installation on some systems.

@gaites
Copy link

gaites commented Dec 14, 2016

Windows 10, using WSL also experiencing hangs on rust-docs installation. Have not yet verified whether full install will complete.

@carey
Copy link

carey commented Apr 24, 2017

I see this on my Windows 10 laptop, but it seems to take hours with Trend Micro OfficeScan running, minutes with Windows Defender, and seconds with no antivirus software at all. 7-Zip manages to extract the documentation relatively quickly, so it appears that rustup is doing something which makes disk access very slow in my case.

I have a hypothesis that AV software is much more suspicious about temporary files with random extensions than files with .html extensions.

@UtherII
Copy link
Author

UtherII commented Apr 25, 2017

It seem you identified the culprit.

My company use Trend Micro OfficeScan on desktop computers, where I noticed the installation take hours.
I had no antivirus at home and everything was installed in a few seconds.
I just enabled Windows defender at home : I can confirm it takes a few minutes now.

@UtherII UtherII changed the title 'rust-docs' installation can be far too long Aniviruses cause a huge slowdown for 'rust-docs' installation Apr 25, 2017
@bschwind
Copy link

I also ran into this. I have a mostly default installation of Windows 10 (I just have Steam installed). The installation hung on rust-docs. I checked Windows Defender and Real-time protection was enabled.

I removed rust with rustup self uninstall, then tried installing again with Windows Defender's options turned to Off (Real-time protection, Cloud-based protection, Automatic sample submission). The installation completed successfully in a normal amount of time. Gotta love antivirus...

@avpaderno
Copy link

I have the same problem with Windows 10 Creators Update and WSL. The funny part is that I have problems only on my netbook, not my desktop computer, despite the fact they both have Ubuntu 16.04.2 LTS and the same version of the same antivirus (Bitdefender).

@bbqsrc
Copy link

bbqsrc commented Jul 24, 2018

Is there any workaround for this issue? Seems adding .rustup to Exclusions in the Windows Defender Security Center makes it work again, but there is surely a better way.

@retep998
Copy link
Member

The workaround is either adding exclusions to your antivirus or disabling your antivirus.

@ndrewxie
Copy link

ndrewxie commented Nov 5, 2018

Hello,

Disabling the antivirus, while it did speed rustup up a little bit, still doesn't fix the problem. Previously, rustup took 20-25 minutes, ON AVERAGE, to install, now it's more like 15-20 minutes.

@ndrewxie
Copy link

ndrewxie commented Nov 5, 2018

Shouldn't Rust-Docs (which is the part that hangs) be optional? It's not like the docs are 100% needed for Rust... there should be an option to delete that. Also, maybe merge a few doc pages into the same page and have a table of contents? Then you'll have a few big files rather than a TON of small files, so it should be faster...

@faern
Copy link
Contributor

faern commented Nov 9, 2018

Making the rust-docs component optional is being worked on: #998

@David-OConnor
Copy link

I can confirm that this problem still exists.

@weirdev
Copy link

weirdev commented Jun 12, 2019

This same issue can cause the installation on WSL to fail completely. Deleting Rust's leftover installation files and turing off antivirus got things working for me. https://stackoverflow.com/a/56566419/4064698

@rbtcollins
Copy link
Contributor

I think #1866 is a better place to track this going forward

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