I would like to post a useful comment from DanDScan on a Microsoft Answers forum. He has found that a report from Kaspersky mentioned a specific "autorun" registry item for Hard Disks should be basically disabled, and force them to be set as "non-removable", and therefore not part of an "autorun" scheme (especially the boot disk). Here is his post:
I have tried most of the solutions proposed for the long boot time with version 2004 and none has worked. I have now found a solution that does work on my computer. From login to useable screen was taking about 6 minutes and now takes 75 seconds which is the same as with previous versions of Windows 10.
Machine: Laptop, Intel i5, single HDD, Windows 10 Pro 2004
In the registry I have disabled Autorun for the HDD – see Microsoft’s documentation in the reference at the end of this post. One difference is that I have this key under HKEY_LOCAL_MACHINE rather than Microsoft’s recommendation of HKEY_CURRENT_USER.
Using Regedit create the following key (if it’s not already there):
HKEY_LOCAL_MACHINE
Software
Microsoft
Windows
CurrentVersion
Policies
Explorer
Then create NoDriveTypeAutoRun as REG_DWORD with value 0x08 (decimal 😎
The possible values are:
Bit Number Bitmask Constant Description
0x04 DRIVE_REMOVEABLE Disk can be removed (such as a floppy disk).
0x08 DRIVE_FIXED Disk cannot be removed from drive (a hard disk).
0x10 DRIVE_REMOTE Network drive.
0x20 DRIVE_CDROM CD-ROM drive.
0x40 DRIVE_RAMDISK RAM disk.
All other solutions proposed under earlier posts have worked for some users but not all and I suspect this solution will be no different. Still, this solution has zero cost, is easy to apply (if you are used to using Regedit) and is reversible. Hopefully, a few more users will find themselves dug out of the slow-boot hole.
Note:
I have not tested with Microsoft’s recommendation of using HKEY_CURRENT_USER.
Reference:
https://docs.microsoft.com/en-us/windows/win32/shell/autoplay-reg
Acknowledgement:
Kaspersky’s Total Security ‘Vulnerability Scan’ tool"
FURTHER CLARIFICATION POST from DanDScan:
"
I agree that it is a dramatic and surprising result and not at all what I was expecting. I can’t explain why it works as I have no tools to interrogate the early part of the boot process to see what actually is going on. Within Kaspersky Total Security is an analysis tool called ‘Vulnerability Scan’ which I ran with no thought of the slow boot-time. It came back with ‘Autorun from hard drives is enabled’, ‘Autorun from network drives is enabled’, ‘Autorun from removeable drives is enabled’ with suggestions to correct by disabling these entries.
Kaspersky further says that “If the autorun from hard drives option is disabled, then it will not impact your system boot and your system performance. The fix disables only the autorun of the autorun.inffile, which can contain links to launch malicious programs. By default the autorun from hard drives option is disabled.”
Subsequently, when I saw the boot process had speeded up, I did some digging to determine what had changed and a search of the registry found the NoDriveTypeAutoRun entry with a value of 0x1c (decimal 28) covering the three drive types. A test showed the HDD entry alone was sufficient to speed-up booting, value 0x08 (decimal 😎 as in my post.
A common feature of the very slow boot time in v2004 that I and other users have experienced is the continuous, heavy access to the HDD after entering login details (which is why some have suggested switching to an SSD). Pinning down why this happens in v2004 but not in earlier versions has been the challenge. The NoDriveTypeAutoRun fix has worked on my machine but I don’t know why.
Editing the registry can indeed be dangerous which is one reason I included the link to Microsoft’s autoplay-reg documentation, not least to provide some insurance if I made a typo in my post.
And a definite thank you for the link to Mark Russinnovich’s autoruns tool."