MoveSysvol – Automate the relocation of the Sysvol folder
Written in 2009 for the Windows versions of the time. Check that the tool or steps still suit your environment before using them.
- linkd.exe in working folder or path
- robocopy.exe in working folder or path
MoveSysvol automated by Shaun Vermaak is a batch to automatically relocate the Sysvol folder as per http://support.microsoft.com/kb/842162
The following must be in the working folder or in path:
MoveSysvol.bat
SetFRS.vbs
sysvol.inf
linkd.exe (Not included)
robocopy.exe (Not included)
Publishers website: https://www.ittelligence.com
ITtelligence mirror: MoveSysvol.zip (1.66 KB)
Usage: MoveSysvol.bat OLDSYSVOLPATH NEWSYSVOLPATH DOMAINFQDN
Example: MoveSysvol.bat C:\Windows\SYSVOL D:\SYSVOL TESTDOMAIN.COM
How to Use ItLink to this section
Run it as an administrator on the domain controller whose Sysvol you are moving, from a folder that holds SetFRS.vbs and sysvol.inf, with linkd.exe and robocopy.exe in the path.
MoveSysvol.bat OLDSYSVOLPATH NEWSYSVOLPATH DOMAINFQDN
MoveSysvol.bat C:\Windows\SYSVOL D:\SYSVOL TESTDOMAIN.COMParameter | Meaning |
|---|---|
OLDSYSVOLPATH | Current Sysvol folder. |
NEWSYSVOLPATH | New Sysvol folder. |
DOMAINFQDN | Domain name. Used to skip the junction folders during the copy, to create the new ones and to point the junctions at them. |
It disables and stops the File Replication Service (NtFrs), copies the folder with robocopy, updates the Netlogon SysVol path, sets BurFlags to D2, reapplies the default Sysvol permissions with secedit, recreates the junctions with linkd, updates the FRS paths in Active Directory with SetFRS.vbs, then sets NtFrs back to automatic and starts it.
Note: earlier copies of the download had the domain hard-coded. Since 5 October 2026 the junctions use DOMAINFQDN and SetFRS.vbs looks up the current domain, so no editing is needed.
MoveSysvol version history
- DFSR version, following Microsoft's DFSR SYSVOL relocation procedure
- Uses SetDFSR.vbs in place of SetFRS.vbs; linkd.exe and robocopy.exe no longer listed
- Update: all DCs must be in the default Domain Controllers OU
- Initial release: batch to relocate SYSVOL as per KB842162
- Needs linkd.exe and robocopy.exe (not included)
No comments yet
Comments are moderated and appear once approved.