After about a week of excitement and playing around with features, I decided it was time to start optimizing and making this thing run the way I wanted. The first thing I noticed was that I could not use my SD card with my Libraries, so all my apps are going to by default save to the local SSD, which is far from what I want. I knew there had to be a way around this, so I started digging in. I feel I finally have it to the point where others should be doing the same thing, and once done, you can forget about it.
- Create a VHDX and save it on the SD card
- Create directories on this VHD for your specific libraries
- Documents
- Music
- Video
- Pictures
- Configure the libraries
- Enable Indexing on the VHDX – This is important because the Photos app doesn’t work right without it.
- Have a script automatically Attach the VHD on Boot
If you would like to know the exact steps to take, please continue reading.
Creating a VHD
- Open Charms Menu (Swipe in from the right side of the screen)
- Click Settings
- Click Tiles
- Change “Show administrative tools” to Yes
- Swipe from the bottom of the screen
- Click All apps
- Under “Administrative Tools” click Computer Management
- Click “Disk Management”
- Click “Action”
- Click “Create VHD”
- Browse to the SD Card’s storage and name the VHD whatever you want
- Allocate as much of the SD’s storage you want to this VHD,
- You can decide between Fixed or Dynamically expanding. I went with Dynamically expanding.
- Find the newly created disk in the lower panel, which should be “Disk 2”
- Right-click where it says “Disk 2”
- Click “Initialize Disk”
- Click OK
- Right-click “Unallocated”
- Click “New Simple Volume…”
- Click “Next >”
- Click “Next >”
- Select the Drive letter you want (can be anything)
- Click “Next >”
- Name the Volume whatever you want
- Click “Next >”
- Click “Finish”
Create/Configure Library Directories on VHD
- Click the “Libraries” icon from the “Task Bar”
- Single click “Documents”
- Click “Manage under “Library Tools” from the ribbon
- Click “Manage library”
- Click “Add”
- Browse to the newly Attached VHD you just created
- Click “New Folder”
- Name it whatever you want (Eg: Documents)
- DO NOT OPEN THE FOLDER, select the folder and click “Include folder”
- Remove the Default Personal folder
- Click OK
- Click “Set save location”
- Select the newly created folder
- Repeat steps 1-13 for the following
- Music
- Pictures
- Videos
Enable Indexing on VHD – Very Important
- Open the “Charms Menu”
- Click “Search”
- Type “Indexing Options”
- Click Settings
- Open “Indexing Options”
- Click “Modify”
- Select the newly Attached VHD
- Click OK
- Click Close
Create Script to Auto Attach on Startup
- Open PowerShell as an Administrator
- Type “Set-ExecutionPolicy RemoteSigned”
- Press Enter
- Type “y”
- Press Enter
- Click Computer from the navigation bar on the left of the Libraries folder
- Open the C: Drive
- Create a new folder named “PoSH”
- Double click the new folder
- Right-click in the white area and navigate to “New > Text Document”
- Name it Auto-Mount.ps1
- Open the new file with Notepad
- Paste the below code in, don’t forget to modify the red text to the path you saved the VHDX file at
- “Mount-DiskImage D:\YourVHD.vhdx”
- Open the “Charms Menu”
- Click “Search”
- Type “Task Scheduler” and open it
- Click “Task Scheduler Library”
- Click “Action”
- Click “Create Task…”
- General Tab
- Name: Attach SD VHD
- Location: \
- Description: This is the Task that automatically attaches the VHD file on the SD card on system boot.
- “Click Change User or Group…” type in SYSTEM
- Check “Run with highest privileges”
- Triggers Tab
- Click “New…”
- Begin the task: At startup
- Click OK
- Action Tab
- Action: Start a program
- Program/script: C:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe
- Add arguments: C:\PoSH\Auto-Mount.ps1
- Click “OK”
- Conditions Tab
- Under Power uncheck “Start the task only if the computer is on AC power
- Click “OK”
- Have fun testing. I recommend opening the Camera app and taking some pictures, making sure it index the new ones, try adding music to the folder make sure it shows up in the music app, the same thing for the Video app.
Update 12-30-2012: Thank you, Don, for reminding me you need to set the execution policy on the machine first.
Love it? Share it!
And what happens if I remove the sd card?
Is there any way to hide the SD card from showing up in This PC?
After having figured out that the sd card needs NFTS formatting, I’m stuck on 6) of the “Create Script to Auto Attach” step: Click Computer from the navigation bar on the left of the Libraries folder
There is nothing happening after I confirmed with yes (“y”) in the previous step. I’m running powershell as adminitrator, but on windows 10.
Update on m previous comment: Format to NTFS first!
“The requested operation could not be completed due to system requirement limitations.”
That’s the error message i get when I try to set up the VHD on my micrsd in disk management.
Does the microsd card need to be formatted first?