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

Can't update from 1.8 to 1.9 on Windows: could not rename component file #501

Closed
jacobmorzinski opened this Issue May 26, 2016 · 10 comments

Comments

Projects
None yet
7 participants
@jacobmorzinski
Copy link

jacobmorzinski commented May 26, 2016

I'm not sure if this is related to #426 or different... but the error message is different, so I'll open a new issue ticket and you can close if desired.

I can't update from 1.8 to 1.9, using the MSVC stable branch:

C:\Users\Jacob> rustup self update
info: checking for self-updates
info: downloading self-update
info: rustup updated successfully

C:\Users\Jacob>rustup --version
rustup 0.1.12 (c6e430a 2016-05-12)

C:\Users\Jacob>rustup show
stable-i686-pc-windows-msvc (default)
rustc 1.8.0 (db2939409 2016-04-11)

C:\Users\Jacob>rustup update
info: syncing channel updates for 'stable-i686-pc-windows-msvc'
info: downloading component 'rustc'
 35.0 MiB /  35.0 MiB (100 %)   5.2 MiB/s ETA:   0 s
info: downloading component 'rust-std'
 46.6 MiB /  46.6 MiB (100 %)   5.5 MiB/s ETA:   0 s
info: downloading component 'rust-docs'
  5.6 MiB /   5.6 MiB (100 %)   4.9 MiB/s ETA:   0 s
info: downloading component 'cargo'
info: rolling back changes
error: could not rename component file from 'C:\Users\Jacob\.multirust\toolchains\stable-i686-pc-windows-msvc\bin/test-4fda350b.dll.lib' to 'C:\Users\Jacob\.multirust\tmp\hvxiy3mkmyzhkgdr_file'
info: checking for self-updates
info: rustup is up to date

  stable-i686-pc-windows-msvc update failed - rustc 1.8.0 (db2939409 2016-04-11)

I do have a .multirust\tmp folder. I don't see anything in it that would block the creation of files in it. If I try to move test-4fda350b.dll.lib by hand, I can move it by hand.

@jacobmorzinski

This comment has been minimized.

Copy link
Author

jacobmorzinski commented May 27, 2016

...but rustup update worked fine on a second computer of mine (again stable windows msvc). I wonder what's up with my first computer.

@peschkaj

This comment has been minimized.

Copy link
Contributor

peschkaj commented May 27, 2016

It also worked flawlessly on my own test system.
On Thu, May 26, 2016 at 5:07 PM Jacob Morzinski notifications@github.com
wrote:

...but rustup update worked fine on a second computer of mine (again
stable windows msvc). I wonder what's up with my first computer.


You are receiving this because you are subscribed to this thread.

Reply to this email directly, view it on GitHub
#501 (comment),
or mute the thread
https://github.com/notifications/unsubscribe/AAEXkouw_yXSJtVSLZpJMUDmrtKBL2yAks5qFjW5gaJpZM4In7hQ
.

Jeremiah Peschka

@jacobmorzinski

This comment has been minimized.

Copy link
Author

jacobmorzinski commented May 27, 2016

Trying it a few more times (and with RUST_BACKTRACE=1) gave a more clear indication that there is an OS access error:

error: could not rename component file from 'C:\Users\Jacob\.multirust\toolchains\stable-i686-pc-windows-msvc\bin/rustc_borrowck-4fda350b.dll.lib' to 'C:\Users\Jacob\.multirust\tmp\lffl4knje_vwe2m5_file'
info: caused by: Access is denied. (os error 5)
info: backtrace:

I didn't care enough to debug it, so I worked around the issue with rustup toolchain remove stable followed by rustup toolchain install stable.

All set here.

@brson

This comment has been minimized.

Copy link
Contributor

brson commented Jun 3, 2016

Thanks for the report. I'm afraid I don't know what the issue is offhand.

@mati865

This comment has been minimized.

Copy link
Contributor

mati865 commented Feb 3, 2017

Just ran into this issue upgrading x86_64 msvc rust 1.14 to 1.15 but after 3 fails next try succeed.

@jacobmorzinski

This comment has been minimized.

Copy link
Author

jacobmorzinski commented Mar 16, 2017

My original report is solved: it turns out that my anti-virus (Sophos) was blocking one of the file replacement actions that rustup was trying to perform. Sorry for not catching this earlier.

@BatmanAoD

This comment has been minimized.

Copy link

BatmanAoD commented Apr 28, 2017

I am also seeing this issue trying to upgrade from 1.16 to 1.17 (the first time I've attempted and update).

I'm on a company-provided Windows 7 laptop running McAfee antivirus (which AFAIK I can't disable, even temporarily), so I wouldn't be at all surprised if McAfee is somehow preventing file-access.

I tried eight times, and each time the file that could not be renamed was different. (The failure always came when attempting to install the rust-src component.)

@tjkierzkowski

This comment has been minimized.

Copy link

tjkierzkowski commented Jun 6, 2017

I'm having the same issue with McAfee, specifically Endpoint Security as well. I too cannot whitelist rustup or remove the program as I don't have admin rights entirely on my VM at work. They may not have updated some of the virus definitions or maybe their fuzzer is over-eager but some of the files are being blocked. This only seems to be affecting the stable channel but not the nightly one. I've deleted everything and reinstalled rust via rustup at least 2 times and this still seems to be happening. Here's a snippet from powershell in my VM:

image

The stable channel hasn't been able to update for at least since I installed it February. Let me know what I else I can do to help out!

@emabee

This comment has been minimized.

Copy link

emabee commented Dec 22, 2017

McAfee explicitly reports rustup and/or rustc and/or cargo and deletes them every now and then. Reinstall is possible, but mcafee kicks in about every second day! This should be fixed in McAfee generally! Are there any negotiations already?

@mati865

This comment has been minimized.

Copy link
Contributor

mati865 commented Dec 22, 2017

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment