Error when installing Arduino boards by Arduino from Board manager in Arduino IDE 2.0 beta 7

I just found out about the new Arduino IDE 2.0 beta 7 version
I downloaded the exe
I installed the exe for current user only [on windows 10]
started arduino IDE and tried to install the arduino AVR boards by arduino from board manager
It failed and I got the following error:

Downloading packages
Installing arduino:avr-gcc@7.3.0-atmel3.6.1-arduino7
Failed to install platform: arduino:avr.
Error: 2 UNKNOWN: installing tool arduino:avr-gcc@7.3.0-atmel3.6.1-arduino7: moving extracted archive to destination dir: rename C:\Users\divin\AppData\Local\Arduino15\tmp\package-063101429\avr C:\Users\divin\AppData\Local\Arduino15\packages\arduino\tools\avr-gcc\7.3.0-atmel3.6.1-arduino7: Access is denied.

please can anyone help me with a solution to this?

This sort of error could be caused by your antivirus software. Try TEMPORARILY disabling your antivirus for a single compilation to see if the problem goes away, then turn the antivirus back on.

If the problem doesn't occur with the antivirus off you will need to adjust the settings of your antivirus to put the appropriate file, folder, or process on the "allow list" so it doesn't interfere with compilation.

Please be cautious about working without an antivirus. This is only about temporarily disabling it for a quick test. If you don't feel comfortable doing that, fine. You can try going straight to configuring the antivirus to not interfere with the Arduino software.

Thank you very much, it worked after I disabled my antivirus. I have never touched my Avira antivirus settings, I guess I have to figure out how to stop it from interfering with the arduino IDE.

You're welcome. I'm glad if I was able to be of assistance.

I think it can be a bit tricky to figure out the bare minimum changes needed to allow the antivirus to do its job while also allowing the Arduino IDE to do its job as well. But determining that the antivirus is the cause of the problem is surely some significant progress toward a complete solution.