After deploying several event receivers to a variety of lists I found that one of the event receivers did not seem to be working, but instead was firing a old version of the DLL.

So, to check that it was indeed attached, I ran the following PowerShell command.

After running this I discovered that one of the event receivers had been attached to the list twice! I’m not entirely sure why or how this happened, but my problem was resolved by deleting the duplicate receivers and reattaching it once.

The script is used to delete was:

And to add it was:

 

In a publishing environment we often create custom page layouts based on our own content types, and of course if we are also creating custom site definitions, we’ll probably want to create pages in the site defs which are based on our custom page laouts – how do we do this?

Again, it’s all done using a CAML module element as shown below

The Property elements are used to set the column values of the new list item which is created in the Pages library for this page.

  1. Title – The page title, this is what is usually displayed at the top of the browser window
  2. ContentType – the listitems contentype (name), which should be the content type used as the basis of the page layout
  3. PublishingPageLayout – this is the important one, this tells SharePoint what page layout to associate with the list item (page), it has a very specific format and a gotcha (see below)
  4. PublishingPageImage, PublishingPageContent etc – you can populate any other columns here.

The PublishingPageLayout property format is;

The gotcha is in the use of the comma (,); either don’t use it and just specify the url of the page layout, or, if you do use it make sure you leave a space character after the comma.

The title value specified after the comma is displayed in the “Page Layout” column in the Pages library.

If you designed a custom master page for your SharePoint 2016 and the ribbon is in your way, SharePoint has a built-in control that lets you hide it from  anonymous users  in few easy steps. Open and check-out your master page, find where your ribbon control starts or look for

wrap your publishing ribbon control in SPSecurityTrimmedControl

Don’t forget to set the correct permissions in the Permissions attribute. Here are few of the choices SPSecurityTrimmedControl allows:

 List Permissions  Site Permissions  Personal Permissions
 ManageLists  ManagePermissions  ManagePersonalViews
 CancelCheckout  ViewUsageData  AddDelPrivateWebParts
 AddListItems  ManageSubwebs  UpdatePersonalWebParts
 EditListItems  ManageWeb  
 DeleteListItems  AddAndCustomizePages  
 ViewListItems  ApplyThemeAndBorder  
 ApproveItems  ApplyStyleSheets  
 OpenItems  CreateGroups  
 ViewVersions BrowseDirectories  
DeleteVersions CreateSSCSite  
CreateAlerts ViewPages  
ViewFormPages EnumeratePermissions  
  BrowseUserInfo  
  ManageAlerts  
  UseRemoteAPIs  
  UseClientIntegration  
  Open  
  EditMyUserInfo  

I have completed a Single-Server installation of SharePoint Server 2016 with Database server on a separate machine in the domain. I am sharing the installation details here which can be helpful for many who are new to SharePoint. The installation is similar to the older versions of SharePoint except MinRoleTopolgy which is introduced for the first time in SharePoint 2016.

System Requirement

I have used the below hardware and software configuration for my current installation.

Hardware Requirement

Scenario Processor RAM Hard disk
Database Server 64-bit, 4 cores 8-24 GB 80 GB for system drive100 GB for second drive and additional drives
SharePoint Server 64-bit, 4 cores 8-12 GB 80 GB for system drive80 GB for second drive

Software Details

Server OS Installation media
Database Server Windows Server 2012 R2 – with latest updates SQL Server 2014 with SP1 – x64
SharePoint Server Windows Server 2012 R2 – with latest updates SharePoint Server

 

Prerequisites

The SharePoint Server 2016 prerequisite installer (prerequisiteinstaller.exe) installs the following software if it has not already been installed on the target server, in the following order:

  1. Application Server Role, Web Server (IIS) Role
  2. Microsoft SQL Server 2012 SP1 Native Client 
  3. Microsoft ODBC Driver 11 for SQL Server 
  4. Microsoft Sync Framework Runtime v1.0 SP1 (x64) 
  5. Windows Server AppFabric 1.1 
  6. Windows Identity Foundation (KB974405) 
  7. Microsoft Information Protection and Control Client 2.1 
  8. Microsoft WCF Data Services 5.6 
  9. Microsoft .NET Framework 4.6 
  10. Cumulative Update Package 7 for Microsoft AppFabric 1.1 for Windows Server (KB 3092423) 
  11. Visual C++ Redistributable Package for Visual Studio 2012 
  12. Visual C++ Redistributable Package for Visual Studio 2015 

Service Accounts

It is highly recommended to use the different service account with least-privilege to install and configure the SharePoint. This will enhance the security of the farm. As we are going to install Single-Server farm, we, at least, need 2 accounts (SQLAdmin, SPFarm).

Name Description Local Rights Domain Rights
SQL_Admin The SQL Server service account is used to run SQL Server. It is the service account for the following SQL Server services: MSSQLSERVER SQLSERVERAGENT. SQL Administrator on the SQL Server Local Administrator on the SQL Server Domain User
SP_Farm The server farm account is used to perform the following tasks:

Setup

SharePoint Products Configuration Wizard

Configure and manage the server farm.

Act as the application pool identity for the SharePoint Central Administration Web site.

Run the Microsoft SharePoint Foundation Workflow Timer Service.

Local Administrator on all the SharePoint Servers. SecurityAdmin and DB_Creator rights on the SQL Instance Domain User
SP_Pool The Pool account is used to run the Web Application Pools None Domain User
SP_Services The Services Account is used to run the Service Application Pool None Domain User
SP_Crawl The Default Content Access Account for the Search Service Application None Domain User
SP_UserProfiles The User Profile Synchronization Account None Replicate Directory Changes permission on the domain
SP_Search Service Account to run the SharePoint Search “Windows Service”. None Domain User

Single Server Installation

Before processed with installation, please make sure the:

  • SQL Server Installed (SQL server 2014 SP1 x64).
  • Windows server 2012 R2 x64.
  • Make sure it is clean installation (fresh OS).
  • You have the installation Media ready (downloaded on the one of Server’s drive or CD/DVD).
  • Product Key for the SharePoint Server 2016.
  • The account which will be used during the Installation should have the proper permission.
  • Disk Drive space meet the minimum requirement.
  • Max degree of Parallelism set to 1 on the SQL Server.
  • Server has access to Internet
  • Disable the Anti-Virus during installation and configuration.
  • Make Sure Firewall is not blocking

Prerequisite Installations

On the Splash Screen, Click on the Install SharePoint Server.

spalsh-1

Now put the SharePoint Server 2016 Key( the key showed below is the Trial Key.). Click Continue.

set2-1

Now Accept the Software Terms and click Continue.

set3-1

On this screen, you can mention the location of the SharePoint Installation. Click Install Now.

set4-1

this will start the installation of SharePoint.

set5-1

Once its Installed successfully you will get this.

set6-1

Configure the SharePoint Server

  1. Click on the SharePoint Products Configuration Wizard.
  2. On the Welcome to SharePoint Products Page, click Next.

1-1

Click Yes on the Warning Page.

2-1

Connect to Server Farm Screen, Please Click the Create a new Server Farm Radio Button and Click Next.

3-1

On Configuration Database Windows, please provide the following details
  • Database Server Name
  • Database Name( Name of the Configuration Database)
  • UserName In the following format: domain\UserName ( this should your farm admin account)
  • Password for the account

4-1

Please Specify the Passphrase ( write it down to some safe place, you need it if new server joins to the farm).Click next.

6-1

New MinRole feature in SharePoint 2016, As this is Single Server farm Configuration, please select Single server farm and click Next.

7-1

Please specify the Port Number for the Central Admin website and click next.

8-1

On this page, please review the configuration and click next.

9-1

Now It will start configuring the SharePoint.

10-1

Finally, you will get this successful screen.

11-1

SharePoint Configuration Wizard

Once you Click on the Finish Button, This will Launch the Central admin with SharePoint Configuration Wizard.

Please select the appropriate options as I selected No and Click OK.

13-1

On Welcome screen You have two options either use the wizard and configure the Service Application or Say No(Cancel) and do it everything Later. Click On the Start The Wizard.

14-1

Use the existing account, then check service applications you would like configure and then click Next.

15-1

During this process, it will create a New Web Application on Port and ask you to create the root site collection. You can Skip this and complete the Initial Setup.

18-1

This will complete the SharePoint Installation and Configuration

Post Installation

It is not over, still you can use the SharePoint and start adding the content, But it is highly recommended to complete the following steps.

  • Configure incoming e-mail
  • Configure diagnostic logging
  • Configure usage and health data collection
  • Configure Search settings
  • Configure the Workflow Manager
  • Exclude the SharePoint Folders from the Anti-Virus

 

 

 

 

Close