Server 2012 – Deny file extensions on shared folders

If you manage one or several file servers in your infrastructure, you may have the will to prevent users to paste files with specific extensions. This behavior can be motivated because you don’t have enough storage for big files or for security reasons. Moreover, if you use DFSR to replicate shared folder to another site, you don’t want to block the bandwidth with a movie replication.

Microsoft Windows Server included a role which provide us the ability to manage files on shared folder: File Server Resource Manager (FSRM).

File Server Resource Manager FSRM

File Server Resource Manager FSRM

In order to block, deny some file extensions, we need to install and configure this role. Let’s see how to do that with Server 2012 R2.

Continue reading


Powershell – Create Shared Folder for DFS

When you want to use DFS (Distributed File System), and get benefit of the replication, you have to create a shared folder and install features on each server. It can be time consuming to do this for a lot of server.

To create it quickly, you can create a package on SCCM with a Powershell script, and deploy it to all of your servers.

Create shared Folder for DFS

You can find below a powershell script to execute :

  1. Create a folder.
  2. Share it with a specific group.
  3. Install Windows Features to enable DFS Replication.
New-Item "D:\Share\MyFolder" -type directory
New-SMBShare –Name "MyShareName" –Path "D:\Share\MyFolder" -ReadAccess "everyone"
Install-WindowsFeature FS-DFS-Replication, RSAT-DFS-Mgmt-Con

You can find more information about DFS :