Introduction to User License Enforcement in SharePoint Server 2013 [Updated]

Introduction

SharePoint Server 2013 introduces new User License Enforcement capabilities that enable the definition, assignment, and mapping of licenses to users associated with specific Active Directory security groups. For example an administrator can map Enterprise features to individual users who appear in the ‘Enterprise CAL’ Active Directory security group or limit usage of Duet capabilities to users in the ‘Duet CAL’ Active Directory security group.

By default in SharePoint Server 2013 User License Enforcement is disabled when SharePoint Server 2013 is deployed and must first be enabled to begin assigning, using, and implementing user licensing capabilities. When User License Enforcement is enabled, usage data is logged and access to unlicensed features are blocked at runtime if the user does not have the appropriate license assignment.

The assignment of license is based on individual users Active Directory security group membership. There are five basic CAL categories that may be assigned which include Standard, Enterprise, Project, Duet, and WAC (these categories are explained in more detail later in this article). In the event a user has membership in more than one of the available user CAL categories a separate entry for that user is logged for each license they are assignment. Unlicensed users, or those who do not have membership in a security group with license assignment are logged as “Unlicensed”.

In scenarios where User License Enforcement has not been enabled in an environment, license usage is logged; however, is mapped to the installed SKU. For example, a user accessing an environment where the Enterprise CAL is deployed is considered an Enterprise licensed user as it is likely that user will traverse a page where Enterprise features exist (such as a Web Part). Conversely, in a Standard CAL environment, a user would be considered Standard CAL licensed.

An important note however is that User License Enforcement does not provide complete coverage across all SharePoint entities.  User License Enforcement can be used to compliment blended CAL scenarios (such as serving Enterprise and Standard CALs within a single-server farm), but does not enable compliance.  In addition the MAP toolkit can be implemented for reporting purposes.

When User License Enforcement is disabled, only Standard and Enterprise (based on SKU) is logged. Project, Duet, and WAC are not logged when User License Enforcement is disabled.

User License Enforcement is enabled, disabled, and managed through Windows PowerShell. Eight cmdlets are available for use with User License Enforcement.

1. Get-SPUserLicensing

2. Enable-SPUserLicensing

3. Disable-SPUserLicensing

4. Get-SPUserLicense

5. Get-SPUserLicenseMapping

6. New-SPUserLicenseMapping

7. Add-SPUserLicenseMapping

8. Remove-SPUserLicenseMapping

Enabling User License Enforcement

To verify if user licensing is enabled in an environment:

Click Start | All Programs | SharePoint Server 2013 | SharePoint 2013 Management Shell

In the SharePoint 2013 Management Shell at the command prompt enter Get-SPUserLicensing and press Enter.

If user licensing is disabled the cmdlet will return the value ‘False’. To enable user licensing in an environment: 

Click Start | All Programs | SharePoint Server 2013 | SharePoint 2013 Management Shell

In the SharePoint 2013 Management Shell at the command prompt enter Enable-SPUserLicensing and press Enter.

To verify user licensing is enabled in an environment:

Click Start | All Programs | SharePoint Server 2013 | SharePoint 2013 Management Shell

In the SharePoint 2013 Management Shell at the command prompt enter Get-SPUserLicensing and press Enter.

If user licensing is enabled the cmdlet will return the value ‘True’.

Mapping User Licenses

The assignment of licensing is established through mapping security groups or individual users to specific licensing categories associated with one or more features. Feature categories include Unlicensed, Standard, Enterprise, Project, and WACEdit.

Sample Windows PowerShell Code

The following code sample will map users in the Enterprise Client Access License AD security group to the Enterprise licensing attribute.

$a = New-SPUserLicenseMapping -SecurityGroup “CORPEnterprise Client Access License” -Li
cense Enterprise

Add-SPUserLicenseMapping -Mapping $a 

User License Enforcement Categories

The Standard licensing category enables user access to all Standard CAL features of SharePoint Server 2013.

The Enterprise licensing category provides access to Enterprise CAL features to include:

  • InfoPath Form Web part
  • Excel Web Access
  • Visio Web Access
    PerformancePoint Filter
    PerformancePoint Report
    PerformancePoint Scorecard
    PerformancePoint Stack Selector
    Indicator Details (deprecated but may show up in adder on sites that have been upgraded from 14 to 15)
    Status List (deprecated but may show up in adder on sites that have been upgraded from 14 to 15)
    Taxonomy Refinement Panel
    Catalog-Item Reuse
    Search-Driven Content (all web parts in this category)
    Business Data Actions
    Business Data Connectivity Filter
    Business Data Item
    Business Data Item Builder
    Business Data List
    Business Data Related List

Licensable Entities

Licensable entities include:

  • AccessServices
  • BCS
  • Duet
  • InfoPath
  • PPS
  • Project
  • EntSearch
  • VisioServices
  • WAC
  • ExcelServices
  • MySites

Users who are not licensed to use a specific Web Part, such as Business Data List, will not have the Web Part visible when visiting a page where that particular Web Part has been added. In the event the Web Part has been added using SharePoint Designer or already inserted on the page the user will presented with an error as illustrated below in place of the Web Part.

image

 

Licensing scope includes user CAL and device CAL information which include the username initiating the request and their IP address respectively. Log usage is by license name as opposed to specific feature or role.

Logging Handling

Logging occurs each time a user accesses SharePoint. SharePoint maintains a cache (provided through Distributed Cache) to temporarily store logging data in the event the same user accesses the environment again preventing that request from begin logged. The cache is maintained for 24 hours until its cleared and that same user will be logged again.

Resources

Learn more about SharePoint Server 2013

Use Windows PowerShell cmdlets to manage user licenses in SharePoint 2013

Introduction to Machine Translation Services in SharePoint 2013

Introduction

SharePoint Server 2013 introduces several new service applications; among them is the new Machine Translation Service. The new Machine Translation Service enables you to reach more people with new cloud-based translation services capable of translating not only sites, but also their content. These services have a comprehensive set of APIs, REST, and CSOM support, so content can be pre-translated when needed, or translated on the fly by users—asynchronously, synchronously, or streaming.

This article provides a Machine Translation Services overview including to references to other useful Machine Translation Services resources.

Machine Translation Services provides machine translation; machine translation is the use of software to translate text from one natural language such as English to another, such as German basically substituting one word in one natural language to its corresponding word in another (see illustration).

image

In Machine Translation Services the actual translation process is performed by a cloud-hosted machine translation service where processed requests are submitted.

image

There are a variety of methods that can be used to submit translation requests discussed further in this article.

Architecturally the Machine Translation Service shares several components with Word Automation Services introduced in SharePoint Server 2010 including Timer Jobs, Document Queues, etc.  To that extent if you’re working with the server Object Model you’ll find similarities between Machine Translation Services and Word Automation Services including the Queue Manager/Schedule and Timer Job infrastructure which are responsible for the scheduling and adding of jobs to the Queue Database which also shares similarities with the Word Automation Services implementation in addition to the Application Manager which manages downloading files from content databases, creating and managing Application Workers, adding documents to Application Worker queues, and writing files back to a specified location.

The Application Worker Process; however, is unique to Machine Translation Services.

image

Machine Translation Services is capable of processing translation requests both synchronously and asynchronously.  Jobs submitted to the Machine Translation Service synchronously are processed when the translation service timer job (SharePoint Translation Services) executes on its configurable, default interval of 15 minutes. Conversely jobs submitted synchronously are instantly translated as the synchronous working queue is prioritized over the asynchronous working queue.

Asynchronous requests can be also be processed manually by running the SharePoint Translation Services Timer Job Definition through SharePoint 2013 Central Administration or optionally through Windows PowerShell (see example below):

$job = Get-SPTimerJob “SharePoint Translation Services”

$job.Runnow()

For Object Model and REST-based code samples related to the Machine Translation Service see also http://msdn.microsoft.com/en-us/library/jj163145(v=office.15).aspx

Provisioning and Configuring the Machine Translation Service

Prerequisites

To provision and configure the Machine Translation Service your environment must meet the following minimum requirements:

The App Management Service is started.

Server-to-server and app authentication is configured.

The User Profile Service Application Proxy must be in the Default Proxy Group and the User Profile Service provisioned and configured.

Internet connectivity is available.

Provision and Configure the Machine Translation Service

To learn more about provisioning and configuring Machine Translation Service see also http://technet.microsoft.com/en-us/library/jj553772(v=office.15).aspx.

Resources

Learn more about SharePoint Server 2013

IT Professionals

Create and Configure Machine Translation Services in SharePoint 2013

Developers

Machine Translation Services in SharePoint 2013

Server Object Model Code Samples

Client Side Object Model Code Samples

Support

The Machine Translation Service is not running when it should be running (SharePoint 2013)

SharePoint Server 2013 Known Issues

Introduction to PowerPoint Automation Services in SharePoint Server 2013

Introduction

PowerPoint Automation Services is a new service application in SharePoint Server 2013 that provides automatic server-side conversion of PowerPoint Presentations from one format to another, for example, a PowerPoint Presentation in Open XML File Formar .pptx format can be converted into Portable Document Format (.pdf) for archival purposes, distribution to clients who do not have Microsoft PowerPoint installed, or to protect the presentation from editing.

PPTAutomation

PowerPoint Automation Services supports conversion of Open XML File Format (.pptx) and PowerPoint 97-2003 presentation format (.ppt) to .pptx, .pdf, .xps, .jpg, and .png.

PowerPoint Automation Services provides conversion capabilities similar to Word Automation Services introduced in SharePoint Server 2010.  The code samples that follow show the similarities between Word Automation Services and PowerPoint Automation Services programming.

Word Automation Services

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Microsoft.SharePoint;
using Microsoft.Office.Word.Server.Conversions;

class Program
{
    static void Main(string[] args)
    {
        string siteUrl = "
http://www.contoso.com";
        string wordAutomationServiceName = "Word Automation Services";
        using (SPSite spSite = new SPSite(siteUrl))
        {
            ConversionJob job = new ConversionJob(wordAutomationServiceName);
            job.UserToken = spSite.UserToken;
            job.Settings.UpdateFields = true;
            job.Settings.OutputFormat = SaveFormat.MHTML;
             job.AddFile(siteUrl + "/Documents/Foo.docx",
                siteUrl + "/Documents/Foo.mht");
            job.Start();
        }
    }
}

PowerPoint Automation Services

using System;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using System.Text;
using System.Web;
using Microsoft.SharePoint;
using Microsoft.Office.Server.PowerPoint.Conversion;

class Program
{
    static void Main(string[] args)
    {
        string siteURL = "
http://www.contoso.com";
        using (SPSite site = new SPSite(siteURL))
      {
          using (SPWeb web = site.OpenWeb())
          {
              SPFolder docs = web.Folders[siteURL +
              "/Shared Documents"];
              SPFile file = docs.Files[siteURL +
              "/Documents/foo.ppt"];

              Stream fStream = file.OpenBinaryStream();
              SPFileStream stream = new SPFileStream(web, 0x1000);

              PresentationRequest request = new PresentationRequest(
                fStream,
                ".ppt",
                stream);

              IAsyncResult result = request.BeginConvert(
                SPServiceContext.GetContext(site),
                null,
                null);

              request.EndConvert(result);

              SPFile newFile = docs.Files.Add(
                "foo.pptx",
                 stream,
                 true);
           }
       }
    }
}

Conclusion

PowerPoint Automation Services is a new service application in SharePoint Server 2013 that provides automatic server-side conversion of PowerPoint Presentations from one format to another.

Resources

Learn more about SharePoint Server 2013

Learn more about PowerPoint Automation Services

Introduction to Shredded Storage in SharePoint 2013 [RTM Update]

Introduction

Shredded storage is a new data platform improvement in SharePoint 2013 related to the management of large binary objects (I.e. BLOBS such as Microsoft PowerPoint Presentations, Microsoft Word Documents, etc.).

Shredded Storage is both improves I/O and reduces compute utilization when making incremental changes to document or storing documents in SharePoint 2013. Shredded Storage builds upon the Cobalt (I.e. File Synchronization via SOAP of HTTP) protocol introduced in SharePoint 2010.

Cobalt

In SharePoint 2010 when saving a document, such as a documented opened from SharePoint with the Office 2010 client, only the incremental change to the document are submitted over the network from the client to the server; however, the document is coalesced on the Web server requiring a full read from the database server, and subsequently the new file inclusive of the change are written to the database server.

Shredded Storage at its most basic is designed to ensure the write cost of updating a document is proportional to the size of the change, and not of the file itself.

SharePoint 2013 allows content to be stored either a monolithic stream or as a collection of independent BLOBs (Shredded Storage). When shredded the data associated with a file such as Document.docx is distributed across a set of BLOBs associated with the file. The independent BLOBS are each assigned a unique ID (offset) to enable reconstruction in the correct order when requested by a user.

In SharePoint 2010 when a file is uploaded to a Document Library/List a single row is created in AllDocStreams to host the BLOB associated with the upload. As previously discussed, on subsequent edits to the file only the changes bytes (incremental change) are sent to the server across the network reducing the clients overall bandwidth utilization; however, in order to coalesce the changes, the file is read from the database server by the web server where the merge occurs and the file sent back to the database server for storage. In SharePoint 2010 this process improved the reliability of file I/O operation; however, the web server incurred a penalty as the result of the change. Shredded Storage improves on the SharePoint 2010 model by breaking an individual BLOB into “shredded BLOBS” that are stored in new database Table, DocStreams. Each BLOB contains a numerical Id representative of the source BLOB when coalesced. When a client updates a file only the shredded BLOB that corresponds to the change is updated with the update occurring on the database server as opposed to the Web server. As a result File IO operations are reduced by ~2x when compared to FSSHTTP in SharePoint 2010 and the storage footprint significantly reduced.

SharePoint 2010 BLOB Storage

image

SharePoint 2013 BLOB Storage

image

For example, suppose a user is working with a 10MB Microsoft PowerPoint Presentation and makes a change either adding a new slide, removing a slide, modifying attributes, etc. and saves the file back to the document library where it was initially accessed. The improved protocols associated with Shredded Storage identify the rows (in the new DocStreams table) necessary to be updated to support the change and updates the BLOB associated with that change in the corresponding row.

DocStreams

Within each content database a new data table DocStreams exists where each shredded BLOB is stored in an individual row.

Several new columns are present in the DocStreams table that represent a shredded BLOB including:

  • BSN: The BSN of the stream binary piece.
  • Data: Contains a subset of the binary data of the stream binary piece unless the stream binary piece is stored in Remote BLOB Storage.
  • Offset: The offset into the stream binary piece where this subset data belongs.
  • Length: The size, in bytes, of this subset data of the stream binary piece.
  • RbsId: If this stream binary piece is stored in remote BLOB storage, this value MUST contain the remote BLOB storage identifier of a subset of the binary data of the stream binary piece. Otherwise it MUST be NULL.

image

Shredded Storage Schema 

image

Shredded Storage is enabled by default and cannot be disabled. (enabled by default) can be both enabled and disabled on the server farm through available storage APIs.

FileReadChunkSize

SharePoint 2010 introduced a new FileReadChunkSize property as a control associated with the BLOB cache which enabled a server farm administrator to control the size of incremental reads when a client requested a file.

The BLOB Cache was particularly useful when serving rich media from SharePoint as the FileReadChunkSize property could be used to server files smaller than the FileReadChunkSize (100 KB) in a single SQL Server round trip and files up to the LargeFileChunkSize (5 MB) served directly from SQL Server without disk buffering, resulting in low latency.

Another advantage that the BLOB cache provides is HTTP range request support. This enables a browser (or other client application) to request pieces of a file instead of the entire file. For example, if a browser only needs the last 1 MB of a 10 MB file, it can make a range request and the cache will serve only the last 1 MB. Without the BLOB cache, SharePoint Server ignores the HTTP range request and serves all 10 megabytes. The BLOB cache will help increase throughput by reducing unnecessary network load.

FileWriteChunkSize

In SharePoint 2013 a new property loosely related to FileReadChunkSize is provided to allow control of the size of a shredded BLOB. The size of shredded BLOBS can be configured by a server farm administrator in a manner similar to updating FileReadChunkSize with SharePoint 2010 using the FileWriteChunkSize property value. Configuring the FileWriteChunkSize property should be thoroughly tested in a non-production environment prior to committing any changes as a performance penalty may be incurred when too small a chunk size is configured and large file such as video files are being used frequently.

Resources

Learn more about SharePoint Server 2013