Friday 12 July 2013

Understanding SharePoint 2013 On-Premise Licencing

Overview:  SharePoint licencing is pretty confusing in SP2010 and MOSS.  MS have changed how licencing works and in this post I try simply how licencing works.

SharePoint 2013 uses the Server/Client Access License (CAL) licensing model. 

Server Licences:
Unlike SP2010 in SP2013 there is only 1 model for a server licence (Internet Site server licences no longer exist).  Your only choice in the paid versions on the Server licencing is: Standard or Enterprise.  Full list price according to the site Directions on Microsoft states "US$6,798" for the SharePoint Server licence.

CALs:
  • CALs are based on per user or per device. 
  • CALs come in 2 favours: Standard or Enterprise.  You can mix these together on the same farm/servers being accessed.  So if you have 100 internal users using Enterprise functionality and 900 using Standard functionality you pay for 100 enterprise licences and 900 standard licences (pretty obvious however in SP2010 if didn't work like this).
  • Internet users are external users and normally access the servers using anonymous access - they do not need CALs.
  • External Users* that access the Intranet/internal sites don't need CALs.  This is the trickiest 1 to define for me.  "External Users: Users who are not the licensee’s or its affiliates’ employees or on-site agents or contractors."  MSDN 2012.
Disclaimer:  I am not a licencing expert - speak to you licencing rep for your scenario.
 * External Users - are people that don't work for your company/organisation (it has noting to do with location from where you access the SP farm).

Notes:
  • FAST is not used in SP2013 so there is no licencing requirement on a SP2013 farm.
  • Office Web Apps (OWA) cals are licenced against the Office client licences.  You don't need licences for using OWA in read only mode but to edit the end users needs either the Standard Office or Professional Office licence.  I don't believe you pay for OWA server licences.
  • SP2013 version comparison chart from Dave Coleman.
  • SQL Server and Windows licencing is outside the scope of this post - you will need them.

More Info:
http://www.microsoft.com/licensing/about-licensing/briefs/SharepointServer2013.aspx
http://www.directionsonmicrosoft.com/licensing/30-licensing/4074-licensing-internet-sites-built-on-sharepoint-2013.html
http://www.johntimney.com/?p=58
http://www.degdigital.com/blog/sharepoint-2013-licensing-for-dummies/
http://blogs.technet.com/b/wbaer/archive/2012/11/12/introduction-to-user-license-enforcement-in-sharepoint-server-2013.aspx
http://blogs.technet.com/b/jessmeats/archive/2012/12/14/sharepoint-2013-snippet-user-license-enforcement.aspx
http://blogs.technet.com/b/volume-licensing/archive/2013/05/22/how-to-license-office-web-apps-server.aspx
 

Thursday 11 July 2013

Importing an SSRS report and displaying it on a new environment

This is a 3 Series Post on SSRS 2012 for SharePoint 2010


Part 2 - (This Post) Importing an SSRS report and displaying it on a new environment

Overview:  This post looks at moving your SQL Server Report Services Report into a new farm (e.g. production).  I use the UI in this step-by-step guide.  I am using SQL 2012 for SSRS and SP 2010 as created in this post.

Assumptions:
  1. SP 2010 WFE's
  2. SQL 2012 SP1 is the database server
  3. Report (.rdl) is already created and uses a .rsds file to specify the connection string. 
Steps to migrate and deploy an existing SSRS report:
1. CA > Application Management > Manage Service Applications.
2. New > SQL Server Reporting Services Service Application > Fill in as shown below:
















3. Verify the Service Application is running.













4. Once Completed.  Open a Web Application that has the SSRS Service Application associated to it so we can test it out.  Login to a site collection and create a new library based on the "Reports Library" template.

5. Upload a report (.rdl) and the Connection (.rsds) file int he new "Report library". Then click the dataset/connection (.rsds) file, and test it is working.

6. Edit the binding of the rdl to it rsds as shown below:

7. Ensure you have the SP, scheme ect on the database server to perform the query logic.
8. Click on the report (rdl) file to see it working.
Tip: The install is fragile in that if the order, versions or settings are not right it doesn't work without giving error often.  Make sure SQL Servsions on all machines are the same!  I got caught by not having the same SQL version on 1 WFE as the backend SQL SSRS server.
This is a 3 Series Post on SSRS 2012 for SharePoint 2010

Part 2 - (This Post) Importing an SSRS report and displaying it on a new environment
 
Also I have an updated post on using SP2013 to us SSRS in SharePoint mode here.
 
Update: 24 Jan 2014 - PS to upload rdl's and data sources into a reporting library
 
$spWeb = Get-SPWeb "http://demo.dev/"
$spList = $spWeb.Lists["SSRS"]
$file = [io.file]::ReadAllBytes('C:\test.rdl')
$spList.RootFolder.Files.Add("test.rdl",$file)
# This code finds the SSRS reporting library called "SSRS" and takes a rdl file off the local drive and adds it to the library.

Installing SSRS 2012 in SharePoint Mode on SP2010


This is a 2 Series Post on SSRS 2012 for SharePoint 2010.  Note: SP2013 steps are the same.

Part 1 - (This Post) Installing SSRS 2012 in SharePoint Mode on SharePoint 2010
Part 3 Update - Installing SSRS 2012 SP1 onto a SP2013 Farm
 
Overview:  Install SSRS 2012 onto an existing SP 2010 farm.  The image below shows a 4 server SP2010 farm.  2 of the web server roles (WFE) have the "SQL Server Reporting Services Service" running.  The 2 images below show the setup we are aiming for. 
Goal: SSRS working on a SP2010 farm using SQL 2012 / SSRS 2012
Another way of displaying what I am trying to achieve is document below:
There are essentially 2 parts:
1) Install SSRS on the database server (this does not need to be the same as the SharePoint database server/s) that will support SSRS in SharePoint mode mode.  This relies on SQL Server 2012 Enterprise edition (I used SQL Server 2012 SP1). 
2) Install minimal SQL Server 2012 with the 2 features mention: "Reporting Services - SharePoint" and "Reporting Services Add-in for SharePoint Products" on each WFE that will run the SSRS role.

The image below shows the SQL Server 2012 installation required for the two roles:
1) For the SSRS server click/select all features as shown below:
2) For the SQL/SSRS role on the WFE's install the 2 features marked in red (ignore the checks on the other features). 


If you have an existing SQL Server instance you can verify which features are installed as shown below:
 
You can do this on the SQL Server and the WFE's to check the correct versions and features are being used.
Tip: Ensure the SQL Server Server 2012 versions are identical on the datbase server and the WFE/App servers.

These are the 2 SQL Server 2012 features to needed for SSRS (SharePoint Mode) on the SharePoint App/WFE servers that will run the SSRS Service (Features if you automate the SQL installs -FEATURES=RS_SHP,RS_SHPWFE):
RS_SHPReporting Services – SharePoint (Installed on the SharePoint WFE where the Reporting Service Application will\ be run).
RS_SHPWFEReporting Services Add-in for SharePoint Products (Installed on the SharePoint WFE where the Reporting Service Application will\ be run).

Provision the SSRS Service on the Farm using PowerShell:
Install-SPRSService

Install-SPRSServiceProxy
Get-SPServiceInstance -all | where {$_.TypeName -like "SQL Server Reporting*"}| Start-SPServiceInstance



Validate the installation:
  • CA > Manage Servers in the farm > Verify the Service "SQL Server Reporting Services Service"is on the WFE/App server.
  • CA > Manage Services on Server > Select the Server where the SSRS-add-in has been installed and > Verify the "SQL Server Reporting Services Service" service is "Started".
  • Using the Discovery Reports discussed above verify that the SQL Server with SSRS (SP mode is the same SQL version as the web/app servers in the farm (all my servers are version 11.1.3000.0 - SQL 2012 SP1). 
More Info:

Errors to Lookout for:

Problem: Install SSRS on my SP2010 farm - I get the following error:
Exception calling "Provision" with "0" argument(s): "Installation Error: Could not find SOFTWARE\Microsoft\Microsoft SQL Server\110 registry key.

Initial Hypothesis:  Originally I thought I could overcome the issue by updating the folder layout and registry on each WFE that would run the reporting role.  I could not get this to work.

Resolution:  Don't use the rsSharePoint.msi file (even the SQL 2012 SP1 version).  You need to install the 2 features (1)Reporting Services – SharePoint and 2)Reporting Services Add-in for SharePoint Products.) during/using a SQL installation.

This is a 2 Series Post on SSRS 2012 for SharePoint 2010
Part 1 - (This Post) Installing SSRS 2012 in SharePoint Mode on SharePoint 2010


Saturday 29 June 2013

SharePoint Host Apps - User Permissions

Problem:  How do I give users or groups permissions in a SP Host App?  This post is not looking at giving the App Web permissions against the SharePoint Site.  It merely looks at giving users rights to work within the app.

Initial Hypothesis:
SharePoint has a structure Object hierarchy that developers can secure users against namely: SPSite (Site Collection), SPWeb (Sitess/Webs), SPList (Lists/Document Libraries) and SPItem (Rows).  Based on the hierarchy I initially assumed SP Apps would maintain their own security.  Well this would get rather confusing as you would need to maintain the host web and the app web user permissions.

There is no UI in the App web to be setting security but on the UI you can get to the lists permission page.  In the SP Hosted App, navigate to the list, in my case the url is: http://dev-d8f436fea0378f.apps.dev.local/SPHostedApp/Lists/Comment/AllItems.aspx this takes me to the "Comments" list.  I click the "List" tab on the ribbon.  Click the "Shared With" button and Choose "Advanced".


Here we can stop inheriting the security permissions for the list.
I thought I could set the App webs permissions by selecting the "Web" link.  You receive an error.

Resolution:  You need to stop inheriting permissions on the Host App (parent) and then the App web inherits theses permissions.

How if works:
 

Friday 7 June 2013

Why I like VS/TFS 2012 no I mean VS/TFS 2013


Visual Studio (VS) 2013 and Team Foundation Server (TFS) 2013 is being released in the next few weeks - that was quick.  I'm just getting comfortable with VS 2012 and the announcement comes that VS 2013 is being released later this month.

http://blogs.msdn.com/b/bharry/archive/2013/06/03/visual-studio-2013.aspx

So, this is going to be a blog on VS 2012 with TFS, my number 1 favourite new feature in VS 2012 is local workspaces.  Pre VS2012 all workspaces were Server based workspaces.  "Local" workspaces differ in that when you go offline you have version control on your local machine.  You can rollback/compare to an old version.  So for me and my laptop on client sites I find it a big improvement.  Very simply this is how GitHub works (from my extremely limited knowledge of GitHub).  You have local version control and this is synced up with the central source control repository.

Another feature worth looking at will be Release Management.  I am working with TeamCity to build my Infrastructure (PowerCli for VMware and Powershell to build SQL Server.  Autoinstaller runs the SP part).
TFS 2012 - Scrum template home page

Team Rooms are already on TFSPreview, seems like a nice idea - not sure how the takeup will be from devs.

Saturday 1 June 2013

Retrieving lookup list columns using REST SharePoint 2013 API

Problem:  I have 2 related SharePoint lists: 1) Question and a Child (linked) list 2)Comment.  I need to perform an JS call using jQuery to retrieve a specific comment item and I need to also know the Title field from it's related parent list (Question).  The 2 lists are shown below.  The post Creating related lists for SP Hosted Apps using VS2012 show you how to do this.

Resolution:
Open you browser  and check the query works:
http://dev-d8f436fea03755.apps.dev.local/SPHostedApp/_api/web/lists/getByTitle('Comment')/items(1)?$select=*,Question/Title&$expand=Question/Title
(replace the url)

jQuery Ajax code I used to call the REST API is shown below:

The ajax call is made in the document.Ready() method call.