SharePoint 2016 – Changes in Filenames Support

With the release of SharePoint 2016, Microsoft is planning on removing some filenames restrictions that have been in the product for multiple versions. In this article, I will be comparing SharePoint 2013, which is blocking filenames based on these restrictions, and 2016 which works fine.

Special characters

As part of the SharePoint 2016 IT Preview, Microsoft has removed restrictions regarding filenames containing the following characters:

~

&

{ } *GUID

In SharePoint 2016:


Uploading a file with an invalid character in SharePoint 2016 will result in the following screen:

BadFileName2016

 

In SharePoint 2013:

Long Filenames

SharePoint 2016 now allows you to have filenames that are longer than 128 characters.

SharePoint 2016:

SharePoint 2013:

What is New for Web Applications in SharePoint 2016

The main reason why I love PowerShell so much, is that it allows me to surface information that is kept deep into the application’s model and find interesting jewels that are kept in the background (or hidden).Today, I decided to dig deeper into the SharePoint 2016 Web Application. I went ahead and created two identical web applications, one on my SharePoint 2013 environment, and the second on my SharePoint 2016. After extracting the value of each property, I went ahead and compared the defaults between SharePoint 2013 and SharePoint 2016 using PowerShell. I ran the following lines of PowerShell on both environment and compared the resulting tab delimited files:

Add-PSSnapin Microsoft.SharePoint.PowerShell

$webApp = Get-SPWebApplication http://localhost

$webApp | Select -Property * | Export-CSV <FilePath>.csv

So what differs? The following table compares all properties that differ between SharePoint 2013 and SharePoint 2016:

SPWebApplication:

Property Name

SharePoint 2016

Default Value

SharePoint 2013

Default Value

AnonymousResourceTrackingSettings

Object

SPAnonymousResourceTrackingSettings

Does not exist

BlockNewContentDatabaseWhenMounting

FALSE

Does not exist

ChangeLogRetentionPeriod

120 Days

60 Days

DeploymentLocked

FALSE

Does not exist

FileSavePostProcessExtensions

Jpg

Jpeg

Does not exist

HttpStrictTransportSecuritySettings

Object

SPHttpStrictTransportSecuritySettings

Does not exist

IPAddressAccessControlSettings

SPIPAddressAccessControlSettings Name=SPIPAddressAccessControlSettingsObject

Does not exist

ListViewAuditEnabled

FALSE

Does not exist

MaxAuditLogTrimmingRetention

30

Does not exist

MaximumFileSize

2047

250

MaxPreAuthorizedAccessUrlTimeToLive

2 Days

Does not exist

MaxSizeForSelfServiceEvalSiteCreationMB

20,480

102,400

ODBSettings

Object

SPODBSettings

Does not exist

OutboundMailCertificateThumbprint

Null

Does not exist

OutboundMailEnableSsl

Null

Does not exist

OutboundMailOverrideEnvelopeSender

Null

Does not exist

OutboundMailPort

Null

Does not exist

PingProcessDelay

90,000

Does not exist

PingTimeAvailable

NULL

Does not exist

PingWarmupPage

NULL

Does not exist

PolicyLoggingEnabled

TRUE

Does not exist

SharePoint2010WorkflowsEnabled

TRUE

Does not exist

ShouldDeferUpgradeActions

FALSE

Does not exist

ShowStartASiteMenuItem

FALSE

Does not exist

SiteResourceTrackingSettings

Object

SPSiteResourceTrackingSettings

Does not exist

SiteSubscriptionResourceTrackingSettings

Object

SPSiteSubscriptionResourceTrackingSettings

Does not exist

SyncPolicySettings

SyncPolicySettings Name=SyncPolicySettingsDefault

Does not exist

SyncSiteProvisioningDBThrottle

0

Does not exist

SyncSiteProvisioningThrottle

1

Does not exist

SyncSiteProvisioningWaitTime

5

Does not exist

TrimAuditLogEnforced

TRUE

Does not exist

WebFileExtensions

Ascx

Asmx

Aspx

Htc

Jar

Master

Swf

Xap

Xsf

Does not exist

WnsConfigurationSettings

SPWnsConfigurationSettings Name=Wns Configuration Settings

Does not exist

While some properties names are intuitive, others are more “obscure” and we don’t have all the details as to what they actually do. I will be posting more details as they become available.

Enable the SharePoint 2016 App Launcher

It’s now been close to a year since Microsoft introduced the app launcher in Office 365. SharePoint 2016 brings some of that goodness down to the on-premises world, but there are some caveats to watch for. By default, when installing SharePoint 2016, the app launcher is not available in the suite bar.

In order for it to appear, you need to go in Central Administration or to use PowerShell to provision an instance of the User Profile Service Application.

Doing this will automatically enable the app launcher in the suite bar.

Now, in the SharePoint 2016 IT Preview it is currently impossible for you to modify (add/remove) app tiles, but we can all assume that this will be made available to us once the final product ships.

Change a Server’s MinRole in SharePoint 2016

So you went ahead and installed SharePoint 2016 for the first time, but now when running the PSConfig wizard, you are presented with a new screen you’ve never seen or heard of before? Yeah, that is called the MinRole, and it’s a shiny new feature in SharePoint 2016. Actually, without a single doubt, it is the biggest noticeable change you will see in the SharePoint 2016 IT Preview compared to previous versions of SharePoint. MinRoles are based on configuration best practices that Microsoft has established over the years. It automatically enables and configure specific services on the SharePoint server based on the role it was assigned. The PSConfig wizard screen that is made available in the SharePoint 2016 IT Preview looks like the following:

Now, the first question that probably comes to mind when playing with those bits for the first time, is “What role should I choose”? Followed by “What if I pick the wrong one, can I change it after?” In order to help you determine what role to choose, Microsoft has developed a great TechNet article that goes in length about what each role does (https://msdn.microsoft.com/en-us/library/mt346114(v=office.16).aspx ), so I will let them answer the first question, but to answer the second question, yes you can change it after you selected one. The SharePoint 2016 Preview includes an administrative page in Central Administration to allow you to quickly change a role, but we’re not interested in that! Let’s look at how it can be achieved using PowerShell.

Before we get started I go into the details of how to change the MinRole assigned to a server in your farm, let’s take a step back for a minute and look at how MinRole are actually assigned. When using the PSConfig wizard to create a new farm, what we are really doing in the background (from a PowerShell perspective) is call the New-SPConfigurationDatabase cmdlet (and a whole bunch of other ones as well off course). It is this cmdlet that got updated in SharePoint 2016 to receive the MinRole parameter. This cmdlet now accepts a new parameter called –LocalServerRole which specifies the MinRole to assign to a server. However, if you are using the PSConfig wizard to join a server to an existing farm, the cmdlet being used is called Connect-SPConfigurationDatabase, and just like the other cmdlet, this one has been updated in SharePoint 2016 to also accept a new parameter called –LocalServerRole. The value for these roles is obtained from Microsoft.SharePoint.Administration.SPServerRole. Using PowerShell we can easily extract the available values from this list:

Add-PSSnapin Microsoft.SharePoint.PowerShell

[System.Enum]::GetNames([Microsoft.SharePoint.Administration.SPServerRole]


Now that we are done with the theory part, let’s get our hands dirty. In my scenario, I have created a new farm with a single server in it (for dev purposes off course J). When using the initial PSConfig wizard, I selected my server to run the Search MinRole. However, I now want to change it to use the Single Farm MinRole. What I need to do first is to disconnect my server from the farm’s Configuration Database. This can be achieved by calling the Disconnect-SPContentDatabase PowerShell cmdlet. Note that you may need to close an re-open the SharePoint Management Shell after running this operation.

Disconnect-SPConfigurationDatabase -Confirm:$False

Now that the server has been properly disconnected from the Configuration Database, we need to join it back to the farm calling the Connect-SPConfigurationDatabase PowerShell cmdlet, but this time passing the new value for its MinRole, in our case SingleServerFarm.

$PassPhrase = ConvertTo-SecureString “pass@word1” -AsPlainText -Force

Connect-SPConfigurationDatabase -DatabaseServer “.” -DatabaseName “SharePoint_Config” -PassPhrase $PassPhrase -LocalServerRole “SingleServerFarm”

Once the operation completes, your server will be joined to the farm, and be assigned the new specified MinRole!

*Note: You may have to re-run PSConfig after reconnecting to the Configuration Database for your changes to kick in.

Installing the SharePoint 2016 Prerequisites Offline using PowerShell

Most of the virtual machines I build are not connected to the internet due to some corporate restrictions my company has enforced. Therefore, I always need to do offline installations of all of my software. Now, I do build a lot of SharePoint farms and by a lot I mean, A LOT. I probably spin off a new farm every two days or so for various purposes, so for me having a repeatable installation process is key. The first thing I did when SharePoint 2016 IT Preview came out on August 24th 2015 was to download all of the prerequisites components and write a PowerShell script that would automatically go and install them offline.

For SharePoint 2016, the prerequisites are almost essentially the same as they were for SharePoint 2013, with one or two differences (e.g. .Net Framework 4.5.2). The following is a list of all of the SharePoint 2016 Prerequisites components you would need to download if you were to do an offline installation. Note, that if your virtual machine is connected to the internet, the prerequisite installer module of the SharePoint 2016 media will automatically take care of downloading and installing the bits for you, so you don’t need to manually download them all.

SharePoint2016 Prerequisites:

The way my script works is that it requires you to download all of the prerequisites components listed above and have them placed in a new folder called “prereqs” at the root of the server’s C:\ drive (e.g. C:\prereqs\). Then, making sure the SharePoint 2016 installation media is loaded (and in my case on drive D:), execute the following two lines of PowerShell code:

$SharePoint2016Path = "C:\Prereqs"
Start-Process "D:\PrerequisiteInstaller.exe" –ArgumentList "/SQLNCli:$SharePoint2016Path\sqlncli.msi /IDFX11:$SharePoint2016Path\MicrosoftIdentityExtensions-64.msi /Sync:$SharePoint2016Path\Synchronization.msi /AppFabric:$SharePoint2016Path\WindowsServerAppFabricSetup_x64.exe /MSIPCClient:$SharePoint2016Path\setup_msipc_x64.exe /WCFDataServices56:$SharePoint2016Path\WcfDataServices.exe /DotNetFx:$SharePoint2016Path\NDP453-KB2969351-x86-x64-AllOS-ENU.exe /MSVCRT11:$SharePoint2016Path\vcredist_x64.exe /MSVCRT14:$SharePoint2016Path\vc_redist.x64.exe /KB3092423:$SharePoint2016Path\AppFabric-KB3092423-x64-ENU.exe"

Executing the above lines of PowerShell will automatically launch the SharePoint 2016 Prerequisites installer application:

SP2016Prereqs

From there you can simply click Next on the wizard to initiate the installation sequence. Please note that you may be asked to reboot the server once or twice during the installation. After a reboot, the prerequisites installer should automatically continue its execution where it left.