SharePoint 2010 Site Templates are now Solutions

There are still Site Template in SharePoint 2010, but they’re no longer .STP files. Instead, they’re packaged in .WSP files just like web parts and features. No longer is there a "Site Template Gallery", instead there is a "Solutions Gallery".

You can find the solutions gallery here: http://sharepoint/_catalogs/solutions/Forms/AllItems.aspx

To create a Site Template, browse to the Site you want to create from. Go to Site Actions –> Site Settings –> Save site as template (under the Site Actions heading).

If “Save site as template” is not there, you can go directly to it under the site’s layouts directory here: /_layouts/savetmpl.aspx

Give your template a name, and don’t forget to check the "Include Content" box if you want to include library and list content in the template. This will create a new site template in your Solutions Gallery, which you can then use when creating new sites. You can also download directly from the Solutions Gallery to a .WSP file.

To upload a Site Template to the Solutions Gallery, go to Site Actions –> Site Settings –> Solutions Gallery (under the Galleries heading). On the Solutions tab of the ribbon, click "Upload Solution". Before you close that dialog, you’ll need to click "Activate" to activate it if you want your Site Template to appear in the "New Site" dialog later.

To use the Site Template, go to Site Actions –> New Site. You’ll find your Site Template in the list of Installed Items, in the All Categories or Blank & Custom filters.

Note however:

All solutions in "Solution Gallery" are SANDBOXED (no matter how you compile your solution).

Sandboxed solutions do not support these things:

  • Custom Action groups
  • HideCustomAction element
  • Content Type Binding
  • Web Application-scoped Features
  • Farm-scoped Features
  • CustomPropertyToolPart Class
  • Programmatic workflow
  • Event receivers
    • SPLimitedWebPartManager
  • Timer jobs
  • Visual WebParts
  • SharePoint mapped folders (e.g. "_layouts", and "images")

Additionally, the following .NET namespaces are not supported by sandboxed solutions:

  • ADO.NET
  • System.IO
  • System.Security.Cryptography
  • System.Web.UI.ClientScriptManager

including mapped folders (resources and etc..), so there is now way to add resources through "Solution Gallery".

Active Directory Attributes List

Quick reference guide for me to remember what things are called in Active Directory:

 

ADSearch User Property Attributes:

Display Name

ADSearch Name

International ISDN Number (Others)

internationalISDNNumber

accountExpires

accountExpires

accountNameHistory

accountNameHistory

aCSPolicyName

aCSPolicyName

adminCount

adminCount

altSecurityIdentities

altSecurityIdentities

Assistant

assistant

badPasswordTime

badPasswordTime

badPwdCount

badPwdCount

City

l

codePage

codePage

Comment

comment

Company

company

controlAccessRights

controlAccessRights

Country

co

Country Abbreviation

c

countryCode

countryCode

dBCSPwd

dBCSPwd

defaultClassStore

defaultClassStore

Department

department

desktopProfile

desktopProfile

destinationIndicator

destinationIndicator

Division

division

dynamicLDAPServer

dynamicLDAPServer

E-Mail Address

mail

E-Mail Address (Others)

otherMailbox

Employee ID

employeeID

Fax Number

facsimileTelephoneNumber

Fax Number (Others)

otherFacsimileTelephoneNumber

First Name

givenName

garbageCollPeriod

garbageCollPeriod

Generational Suffix

generationQualifier

groupMembershipSAM

groupMembershipSAM

groupPriority

groupPriority

groupsToIgnore

groupsToIgnore

Home Address

homePostalAddress

Home Drive

homeDrive

Home Folder

homeDirectory

Home Phone

homePhone

Home Phone (Others)

otherHomePhone

Initials

initials

International ISDN Number

primaryInternationalISDNNumber

IP Phone Number

ipPhone

IP Phone Number (Others)

otherIpPhone

Job Title

title

lastLogoff

lastLogoff

lastLogon

lastLogon

legacyExchangeDN

legacyExchangeDN

lmPwdHistory

lmPwdHistory

localeID

localeID

lockoutTime

lockoutTime

Logon Name

userPrincipalName

Logon Name (pre-Windows 2000)

sAMAccountName

Logon Workstations

userWorkstations

logonCount

logonCount

logonHours

logonHours

logonWorkstation

logonWorkstation

Manager

manager

maxStorage

maxStorage

mhsORAddress

mhsORAddress

Middle Name

middleName

Mobile Number

mobile

Mobile Number (Others)

otherMobile

mS-DS-CreatorSID

mS-DS-CreatorSID

mSMQDigests

mSMQDigests

mSMQDigestsMig

mSMQDigestsMig

mSMQSignCertificates

mSMQSignCertificates

mSMQSignCertificatesMig

mSMQSignCertificatesMig

msNPAllowDialin

msNPAllowDialin

msNPCallingStationID

msNPCallingStationID

msNPSavedCallingStationID

msNPSavedCallingStationID

msRADIUSCallbackNumber

msRADIUSCallbackNumber

msRADIUSFramedIPAddress

msRADIUSFramedIPAddress

msRADIUSFramedRoute

msRADIUSFramedRoute

msRADIUSServiceType

msRADIUSServiceType

msRASSavedCallbackNumber

msRASSavedCallbackNumber

msRASSavedFramedIPAddress

msRASSavedFramedIPAddress

msRASSavedFramedRoute

msRASSavedFramedRoute

Name

cn

networkAddress

networkAddress

Notes

info

ntPwdHistory

ntPwdHistory

nTSecurityDescriptor

nTSecurityDescriptor

o

o

objectSid

objectSid

Office Location

physicalDeliveryOfficeName

operatorCount

operatorCount

otherLoginWorkstations

otherLoginWorkstations

ou

ou

Pager Number

pager

Pager Number (Others)

otherPager

Phone Number (Others)

otherTelephone

Post Office Box

postOfficeBox

postalAddress

postalAddress

preferredDeliveryMethod

preferredDeliveryMethod

preferredOU

preferredOU

primaryGroupID

primaryGroupID

profilePath

profilePath

pwdLastSet

pwdLastSet

registeredAddress

registeredAddress

rid

rid

sAMAccountType

sAMAccountType

scriptPath

scriptPath

securityIdentifier

securityIdentifier

servicePrincipalName

servicePrincipalName

showInAddressBook

showInAddressBook

sIDHistory

sIDHistory

State/Province

st

street

street

Street Address

streetAddress

supplementalCredentials

supplementalCredentials

Telephone Number

telephoneNumber

teletexTerminalIdentifier

teletexTerminalIdentifier

Telex Number

primaryTelexNumber

Telex Number (Others)

telexNumber

terminalServer

terminalServer

textEncodedORAddress

textEncodedORAddress

thumbnailLogo

thumbnailLogo

thumbnailPhoto

thumbnailPhoto

Title

personalTitle

tokenGroups

tokenGroups

tokenGroupsGlobalAndUniversal

tokenGroupsGlobalAndUniversal

tokenGroupsNoGCAcceptable

tokenGroupsNoGCAcceptable

unicodePwd

unicodePwd

userAccountControl

userAccountControl

userCert

userCert

userCertificate

userCertificate

userParameters

userParameters

userSharedFolder

userSharedFolder

userSharedFolderOther

userSharedFolderOther

userSMIMECertificate

userSMIMECertificate

x121Address

x121Address

ZIP/Postal Code

postalCode

Windows 7–Get Rid of “Group By” in Explorer View

Windows Explorer on Windows 7 tries to be intelligent and offers to group the contents of a directory according to certain parameters. A lot of times when it cannot do this, it lumps them in a group named Unspecified. I find this grouping affair very irritating, especially when selecting files using the keyboard.

To turn off Group By completely:

  1. Open any directory in Windows Explorer.
  2. Right-click and choose Group by(None)
  3. Press the Alt key, so that the Explorer menu bar appears and choose ToolsFolder Options.
  4. Go to the View tab and click Apply to Folders. This will apply the Group By setting to all folders.

SharePoint 2010–Multitenancy and Hosting Service Providers

Multitenancy in this context mean isolation of data (including backups), Isolation of usage (what data and services are exposed to the users), isolation of administration (administration of sites, services, customizations), etc. If we consider a hosted environments like SharePoint Online it offers customers 2 mode of hosting

1. Standard: This is a shared infrastructure where multiple customers will be hosting their web applications/site collections (what we call as multi-tenant mode)

2. Dedicated: This is a separate infrastructure of the customer

Some of the biggest challenges that existed in MOSS 2007 for multitenancy include:

1. Where do we host a tenant.. Should we create a separate Web Application or creating a separate site collection will suffice… Of course both have their own pros and cons

2. Services were part of SSP and the alacarte model did not exists and one cannot keep creating a separate Web Application and SSP for each and every tenant

3. Other major challenge was around customizations as the 12 hive folder is a shared one

4. Ensuring the performance of customizations of one tenant does not affect others

So what is that SharePoint 2010 offers to overcome the above challenges

SharePoint 2010 has introduced a new concept called Site Subscriptions to group site collections based on the tenants even if all the site collections are part of the same Web Application. Site Subscriptions not only externally separates out the Site collections but also the underlying data in the content database. This goes to the extent of one tenants data will not be seen as search result of other tenants data. The same subscription id also helps in grouping of features and services to the tenants.

SharePoint 2010 has introduced a new concept called Sandboxed solutions. What this means is that the tenant administrators (Site Collection admins) can now deploy features local to their site collections without affecting other site collections of other tenants in the same Web Application.  Part of the administration is getting delegated to the tenants. However the central admin still has control and can ensure that farm features can be disabled if seen to show any performance degradation.

Below is the PowerShell Script to provision a Subscription service for a multitenancy farm:

#set up variables
$acc = get-SPManagedAccount "<Domain\account>"
$appPoolName = "Subscription Settings Service Application Pool"
$appName = "Subscription Settings Service Application"
$appDB = $env:computername+"_SettingsServiceDB"
$userLogin = $env:userdomain+"\"+$env:username


#set up application pool
$appPool = new-SPServiceApplicationPool -name $appPoolName -Account $acc

#start subscription service
$svc = Get-SPServiceInstance -Server $env:computername | where {$_.TypeName -eq "Microsoft SharePoint Foundation Subscription Settings Service"}
if ($svc.Status -ne “Online”) { $svc | Start-SPServiceInstance }

#Create Application
$app = New-SPSubscriptionSettingsServiceApplication -ApplicationPool $appPool -Name $appName -DatabaseName $appDB

#Create Proxy
$proxy = New-SPSubscriptionSettingsServiceApplicationProxy -ServiceApplication $app

#Create new Subscription to be assigned to a site
$sub = New-SPSiteSubscription

And at this point, the Site subscription can be set on the SPSite using the “-SiteSubscription $sub” flag to group together various Site Collections.

In SharePoint 2010 multi-tenancy is offered through several key contributing solutions:

Site Subscriptions

Site subscriptions can be loosely described as a collection of sites that subscribe to a set of service partitions, settings, and individual features – site subscriptions are also known as tenants. In summary we can approach site subscriptions as a loose association of content. In the Object Model site subscriptions are represented through Microsoft.SharePoint.SPSiteSubscription.

Tenant Administration

The management of site subscriptions occurs through a new administration site template, Tenant Administration, which is used to manage many aspects of the site collections that subscribe from the subscription.

Creating a new site subscription object in SharePoint Server 2010 requires an administrator to:

  1. Create a SPSiteSubscription object
  2. Create and add a SPSite object to the SPSiteSubscription

Feature Packs

Feature Packs are a method by which allows the developer to group a collection of individual features (Site or Web scoped) into a larger overall package. Feature Packs are used to provide functionality or capabilities to individual site subscriptions in a multi-tenant model enabling or preventing access to certain functionality or solutions on a tenant by tenant basis.

Partitioning

Data, usage, and operational isolation are provided through many of these new capabilities. The ability to partition many of SharePoint 2010’s Service Applications enable individual and unique tenants to consume the Service Application while maintaining logical separation from other tenants also consuming from the partitioned Service Application.

Creating a new partitioned Service Application in SharePoint Server 2010 requires an administrator to:

  1. Create a partitioned Service Application using the -partitionmode flag
  2. Create a partitioned Service Application proxy using the -partitionmode flag

Multi-tenancy in SharePoint Server 2010 is a method by which both traditional hosters and Enterprises can gain value in both operation and data isolation. Properly planned and implemented can help reduce operating expenditures and reduce the administrative burden on the IT Professional.