I have a need to have a network drive mounted and available on a Windows 10 machine to a specific user automatically after the machine has booted up. This user will have services running, and these services need access to the network drive.
How do I do that?
(Notes: I am not looking to mount the drive on login, but on bootup so that the drive is available to services. The drive mount must happen unattended, there is no user around to manually enter credentials)
The closest I've got is to mount the drive as follows:
net use h: https://server.example.com/storage /savecred /persistent:yes
The drive mounts successfully after asking for a username and password and gives the option to remember the credentials, however on reboot and subsequent login the drive is listed but not mounted, and I am asked to provide the password, which seems to show that /savecred isn't doing anything.