IT-Spirit Knowledge Base

To content | To menu | To search

Tag - SharePoint

Entries feed - Comments feed

Saturday 30 January 2010

Configuring your web application with IIS 7.0 and Kerberos

This Article describes how to set Kerberos for your SharePoint Web Application, we consider that the kerberos is correctly confugured on the SQL side: SQL Service run with an Active Directory Account and the associated SPN is configured...

To create and configure web application with kerberos follow these steps:

  1. Create an Active Directory user account to run the IIS application pool.
  2. Set the SPN on this account.
  3. Trust Kerberos delegation on this account.
  4. Grant the rights "Local and Remote Activation" on the application pool account for the following DCOM object: IIS WARMREG ADMIN (for all web front end servers).
  5. Add the application pool account into the User Rights Assignments: "Act as a part of Operating System" (for all web front end servers).
  6. Create the web application with Host Header and select Kerberos for the authentication methods. Run the application pool with the application pool account created before.
  7. Edit the ApplicationHost.Config file on all web front end servers, locate this tag: <local path="name of yoursite">, next locate <windows security...> and modifify this tag as follow: <Windows security=.... UseAppPoolCredentials="TRUE" UseKernelMode="TRUE">
  8. Your are done.

Sunday 10 January 2010

SharePoint 2010 Beta - First Contact

Prerequisites

First thing when you decide to test MOSS 2010 is to install an W2k8 64 bits, the SQL server must be a SQL 2008 64 bits SP1 with CU2.
After that launch the setup and read the following instructions (In our Case SQL and MOSS are installed on the same machine).
We decide to install the Farm in Kerberos authentication procotol.

Before to begin the MOSS installation you must install the following hotfix:

http://connect.microsoft.com/VisualStudio/Downloads/DownloadDetails.aspx?DownloadID=21953

Good Thing

You can install prerequistes software automaticlally through internet!!!! The setup module Install IIS7 and configure it transparently!!!!
During the installation prerequistes the setup install the following softwares:

• Windows Server 2008 Service Pack 2

• Application Server Role, Web Server (IIS) Role

• Microsoft SQL Server 2008 Native Client

• Microsoft .NET Framework 3.5 SP1

• Windows PowerShell(TM) V2 (CTP3)

• Microsoft "Geneva" Framework Runtime

• Microsoft Sync Framework Runtime v1.0 (x64)

• Microsoft Chart Controls for Microsoft .NET Framework 3.5

• Microsoft Filter Pack 2.0

• Microsoft SQL Server 2008 Analysis Services ADOMD.NET

 

After Installing the prerequisites softwares, launch the setup installation MOSS program and choose the following options:

 

_Installation choice step, please choose Server Farm, look the Web Front options is not here....

_Server type step, please choose Complete install and leave the default options.

 

SharePoint Products Wizzard step

 

Before to launch the wizzard, please create two Active Directory accounts: One for setup MOSS and another one for Farm Admin purpose, for the Farm Admin account please set the SPN, grant this into IIS WarmReg Dcom object with local and remote activation. Grant the farm admin account local admin of the MOSS server. For the Setup MOSS account grant this into SQL with the following roles: DBCreator, SecuriyAdmin.

After that, log on the MOSS server with the setup account credentials and apply the following procedure:

 

_Create a New Farm.

_Specify the SQL instance and give theFarm Admin credentials.

_Wait few minutes,the setup is creating your farm.



New Security features during the setup wizzard: Passphrase to secure communication between farm, data and servers:



 

As you can see no great news about the installation, the new things is just to simplify the setup process with no choice between complete, web front or stand alone, juste Server Farm or Stand Alone and the last thing is the setup process is capable to dowlnload the requirement.

 




 

Saturday 17 October 2009

Exporting/Importing a Site Collection with a cab file (STSADM)

It's usefull to export Site Collection when you need to migrate your site between SharePoint farm, or just to pass from one environment to another envirnment (i.e :dev to QA).

On the source server:

Connect one of your MOSS server and type the following command:

stsadm -o export -URL http://your_site_collection -filename youtpath\your_filename.cab -cabsize 1024 -versions 1

Versions: 1 to 4, 1 for Major Version (default) ; 2 the current version, either the last major or the last minor; 3 Last major and last minor version for files and list items and 4 All versions for files and list items.

If you need to import the security, you can the following switch: -includeusersecurity.

Note:If you want to increase import performance add the following switch: -nofilecompression.

Technical reference: http://technet.microsoft.com/en-us/library/cc262759.aspx

On the target server:

Copy all the cab files from the source server to the target server, create a new web application befor to import the site collection, and type the following command:

stsadm -o import -URL http://your-web_app -filename path_of_your_cab_file_or_folder(nofilecompression only) -updateversions 1 to 3

Updateversions:

  1. Add new versions to the current file (default)

  2. Overwrite the file and all of its versions (delete then insert)

  3. Ignore the file if it exists on the destination

Technical reference: http://technet.microsoft.com/en-us/library/cc261866.aspx

 

Scripting inside SharePoint with PowerShell - PART I Getting Started...

Download the following tools:

_PowerShell for windows 2003: http://www.microsoft.com/downloads/details.aspx?FamilyID=10EE29AF-7C3A-4057-8367-C9C1DAB6E2BF&displaylang=en

_Powergui: http://www.powergui.org/downloads.jspa , this is optional but is a very useful gui for scripting and navigating between methods and class...

_Powerpacks for SharePoint: http://www.powergui.org/kbcategory.jspa?categoryID=354

Install all products and when you are finished to install Powergui, add the SharePoint packages.

Note:Keep in mind, you can write yourscript only on the WSS server because the remote commands does not exists, all tools must be installed on one of WSS server who is member of your farm. 

The basics...

When you write a script for WSS, the first line begin by:

[System.Reflection.Assembly]::LoadWithPartialName("Microsoft.SharePoint") | Where-Object { $_.GetType().FullName -ne "System.Reflection.Assembly" } --->Recomended

OR

[System.Reflection.Assembly]::LoadWithPartialName("Microsoft.SharePoint") --->In some examples through Internet...

After loading into the GAC the DLL for SharePoint, you must to connect on the site where you need to script...

$SiteUrl = http://yoursite

#Creating your SP site object....

$Site = new-object Microsoft.SharePoint.SPSite($Site)

After that, you can display for example the site properties:

$Site.AllWebs | format-table | URL, LastItemModifiedDate, Created

Note: If you use the SharePoint PowerPack, you can browse through the $Site variable and you can see all propreties and methods.

 

 

 

Saturday 3 October 2009

How to upload new SharePoint Template?

First see if you have "Application Template" tab, when you create a new site, if not please follow this procedure:

Download the ApplicationTemplateCore file: http://www.microsoft.com/downloads/details.aspx?FamilyId=C1039E13-94DA-4D7D-8CAE-3B96FA5A4045&displaylang=en

Extract the WSP file and type the following command lines:

stsadm - o addsolution -filename <path>\ApplicationTemplateCore.wsp (result:Operation completed successfully.)

stsadm -o deploysolution -name Application TemplateCore.wsp -immediate -allowGacDeployment (result: Timer job successfully created.)

stsadmn -o copyappbincontent

 

If the Application Template Core is already deployed, please follow this procedure:

After you have extract the WSP file:

stsadm -o addsolution -filename <path>\Your_WSP_File

stsadm -o deploysolution -name Your_WSP_File -immediate -allowGacDeployment

After that check in the Solution management (Click the Operations tab, and then click Solution management under global configuration.) if your template is deployed (status is shown Globally Deployed), type the follwing command: iis reset.

You are done, one time you go to the Create Site, you will see under the Application Template tab, your template.