During your migration from On-Prem to the cloud, you may need to map drives to workstations from your on-Prem file server. Currently Intune doesn’t have a native method to do this, so we are left to our own means of a solution. In the solution I will be providing, we are going to take a step back into the past. Using Task Scheduler to manage our scripts and control when they are executed. It’s not the best method, but its a nice quick and simple solution to fill the void until the migration has completed.
The two scenario’s I will be covering are:
SCENARIO 01: REMOTE VPN CONNECTED USERS
SCENARIO 02: ON-PREM MDM USERS
DRIVE MAPPING SCRIPT
For the first part, the actual drive mapping script will be the same for both methods. We first create log files so we can troubleshoot the issue easily. Then we conditionally check that the network paths are accessible, and map the successfully accessible drives. If all drives fail, the logs will show the error so we can troubleshoot.
This method may seem a little over the top for drive mapping, but this is supposed to be a robust method that can last if things don’t work out the way you thought, during your migration.
Now that we have the core of our script made! From here, you can trigger this however you like! If you have GPO’s or OMA-URI methods that work or your own software to trigger scripts on windows, let me know! In the future parts, I will be showing you how to set this up in Task Scheduler for automated execution and deployment of Intune.
PART 02: TRIGGER NETWORK SCRIPT VIA TASK SCHEDULER: VPN USERS
PART 03: TRIGGER NETWORK SCRIPT VIA TASK SCHEDULER: NON-VPN USERS
PART 04: UPLOAD MAPPED DRIVE SCRIPT TO INTUNE