Hide and Restrict drives in Windows

Hide and Restrict drives or partitions in Windows

Some times for security or any reason you need to hide or restrict access to drivers; you can use these simple tricks below to achieve that.

  • Group Policy
  • Windows Registry
  • Disk Management

 

Group Policy

Run Group Policy: Type gpedit.msc in Run dialog box

HIDE DRIVES

Navigate to: Local Computer Policy > User Configuration > Administrative Templates > Windows Components > Windows Explorer. Now look for “Hide these specified drives in My Computer” and double click and set the state “Enabled” and pick one combination to hide specified drives.

NOTE: You can access these drive by typing path or drive letter in Run dialog box or in address bar.

RESTRICT ACCESS

Restrict access instead of hide a specified drive. Navigate to the same location in Group Policy; double click “Prevent access to drives in My Computer” and set the state “Enabled”

You can Select hide, restrict or combination for selected drives.

 

Windows Registry

With is method you have more option and you can choose any driver, I have personally used this method to hide/restrict access to specific drives on TS environments.

Type “regedit.exe” in Run dialog box

HIDE DRIVES

Navigate to: HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Policies\Explorerand

Right click on right side pane and create a new DWORD value “NoDrives”

Double click “NoDrives” and set decimal value from table below

 

Note: To hide multiple drives, just add drives value. For example we want to hide B: and D: drives, NoDrives value should be 2+8=10.

Logoff or restart the system to take effect.

 

RESTRICT ACCESS

Navigate to: HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Policies\Explorerand

Right click on right side pane and create a new DWORD value “NoViewOnDrive”

Double click “NoViewOnDrive” and set decimal value from table below

 

Drive Value
ALL Drives Visible 0
A 1
B 2
C 4
D 8
Z 33554432
ALL 67108863

 

Disk Management

In some case you can you can use “Disk Management” to add/remove disk or change drive letter or mount as a NTFS folder.

With this method; when you remove disk it will removed from all users not like other methods that applied to specific user/group

Navigate to   “Disk Management”; Right click on the volume that you want to remove (Drive letter/mount folder) then select”Change Drive Letter and Paths”

HDD_00

Select the drive letter and click on “Remove” button

HDD_01

NOTE: before you remove the volume make sure to remove system pagefile and reboot OS (If the volume contains system pagefile)

There is no good/bad method; Each method used in a certain scenario,  choose the one that works for you.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s