Sunday, January 29, 2012

Shutdown Virtual Machine without changes in VM Player

Edit the vmx and add this line if the VM uses a scsi-disk

scsi0:0.mode = "independent-nonpersistent"

or this if the VM uses an IDE-disk

ide0:0.mode = "independent-nonpersistent"

Friday, January 27, 2012

Extract WSP through C# or Powershell.

C# code extract WSP file:

SPSolutionCollection solutions = SPFarm.Local.Solutions;

foreach (SPSolution solution in solutions)
{
SPPersistedFile wspFile = solution.SolutionFile;
wspFile.SaveAs("c:\\wsp\\" + solution.Name);
}

Powershell script:
Start-Transcript "c:\wsp\transcript.txt"
[System.Reflection.Assembly]::LoadWithPartialName("Microsoft.SharePoint")

$solutions = [Microsoft.SharePoint.Administration.SPFarm]::Local.Solutions;
foreach ($solution in $solutions) {
$solution.SolutionFile.SaveAs("c:\wsp\" + $solution.Name);
}
Stop-Transcript

MOSS 2007 versions information

12.0.0.6535 MOSS 20071 or WSS 3.0 SP2 + December 09 cumulative Update (KB960010 + KB960011)

12.0.0.6524 MOSS 20071 or WSS 3.0 SP2 + 15th December Update (KB977027 + KB977026)

12.0.0.6520 MOSS 20071 or WSS 3.0 SP2 + October 09 cumulative Update (KB974989 + KB974988)

12.0.0.6514 MOSS 20071 or WSS 3.0 SP2 + August 09 cumulative Update (KB973400 + KB973399)

12.0.0.6510 MOSS 20071 or WSS 3.0 SP2 + June 09 cumulative Update (KB971538 + KB971537)

12.0.0.6504 MOSS 20071 or WSS 3.0 SP2 + April 09 cumulative Update (KB968850 + KB968851)

12.0.0.6421 MOSS 20071 or WSS 3.0 SP2 (KB953338 + KB953334) [Updated 1st Aug 09: SP2 download now includes the hotfix (KB971620) that corrects the activation issue more information on the Microsoft SharePoint team blog]

12.0.0.6341 MOSS 20071 or WSS 3.0 February 09 cumulative Update (KB961755 + KB961756)

12.0.0.6335 MOSS 20071 or WSS 3.0 December 08 cumulative Update (KB960010 + KB960011)

12.0.0.6331 MOSS 20071 or WSS 3.0 October 08 cumulative Update (KB957691 + KB957693,KB958567 and KB958569)

12.0.0.6327 MOSS 20071 or WSS 3.0 August 08 cumulative update (KB956056 & KB956057)

12.0.0.6318 MOSS 20071 or WSS 3.0 Infrastructure Update (KB951695 & KB951297)

12.0.0.6303 MOSS 20071 or WSS 3.0 post-SP1 hotfix (KB948945)

12.0.0.6301 MOSS 20071 or WSS 3.0 post-SP1 hotfix (KB941274)

12.0.0.6300 MOSS 20071 or WSS 3.0 post-SP1 hotfix (KB941422)

12.0.0.6219 MOSS 20071 or WSS 3.0 SP1

12.0.0.6039 MOSS 20071 or WSS 3.0 October public update

12.0.0.6036 MOSS 20071 or WSS 3.0 August 24, 07 hotfix package

12.0.0.4518 MOSS 20071 or WSS 3.0 RTM

12.0.0.4407 MOSS 20071 or WSS 3.0 Beta 2 TR

12.0.0.4017 MOSS 20071 or WSS 3.0 Beta 2

12.0.0.3111 Office 12 (PDC image - pre-beta) - This version of Office does not have a support link in the Add/Remove programs dialog box.

Top 10 SharePoint Tools from CodePlex

Useful Tools for SharePoint from CodePlex

SharePoint Content Deployment Wizard by Chris O’Brien
This is a great tool for quickly deploying SharePoint content from one environment to another. Here are some salient feature of this tool:

Ability to “cherry-pick” content to deploy using a tree view - this is from entire site collection down to individual lists, folders, list items (including files)
Dependencies of selected content (e.g. referenced CSS files, master pages) are automatically included in the export - check ‘Exclude dependencies of selected objects’ to disable this.
All required content types, columns etc. are automatically included in the export.
In contrast to STSADM export, it is possible to retain GUIDs during deployment. This is required for scenarios where the destination should be a mirror-image of the source, such as staging/production environments for the same site
Open Source and free.
Read the detailed review of this tool

Download from CodePlex
http://www.codeplex.com/SPDeploymentWizard

Chris Obrien’s Blog
http://www.sharepointnutsandbolts.com/2007/12/introducing-sharepoint-content.html

SharePoint SmartTemplates for Visual Studio
The SmartTemplates for SharePoint project delivers a collection of Visual Studio templates which allow developers to create a range of SharePoint customizations in a painless and professional fashion.

SmartTemplate comes in 2 flavors:

Web Part Project Template:
It allows developers to create quickly a project which contains the base infrastructure to write the web part code, generate a SharePoint Solution file (WSP) for easy deployment and generate a setup package for a wizard driven installation.

SmartPart Web Part Project
Allows developers to create quickly a project which contains the base infrastructure to write a web user control (ASCX), wrap the user control in a SmartPart instance, generate a SharePoint Solution file (WSP) for easy deployment and generate a setup package for a wizard driven installation.

Download from CodePlex
http://www.codeplex.com/smarttemplates

SharePoint 2007 Features
SharePoint 2007 Features add new functionality to a SharePoint 2007 farm, site collection, or site. It install bunch of custom Features to address deficiencies in SharePoint 2007 or add new capabilities.

Some of the popular feature are Debugger Feature, Log Viewer, Print List, Toolbar Manager etc.

Download from CodePlex
http://www.codeplex.com/features

SPIEFolder
Allows you to either Import a file system folder (And all files and subfolders) into a SharePoint Document Library, and also export a SharePoint Document Library to the file system for WSS 2.0/SPS2003 or WSS 3.0/MOSS 2007.

This tool completely replicates the document libraries folder hierarchy to the file system when exporting, and replicates the folder hierarchy from the file system to the document library when importing.

Download from CodePlex
http://www.codeplex.com/SPIEFolder

SPSiteManager
The purpose of the SharePoint Site Manager (SPSiteManager) is to assist customers with performing SharePoint Site Collection maintenance activities for SharePoint Products and Technologies (which includes Windows SharePoint Services 2.0 and SharePoint Portal Server 2003). This sample source can be compiled to produce a tool that will allow you to analyze your farm looking for problems, repartition/level sites across content databases, perform batch backups, restores, and deletes of site collections, and perform Site maintenance and cleanup for SharePoint Portal Server.

Download from CodePlex
http://www.codeplex.com/SPSiteManager

SPPurgeList
Allows you to purge the contents from any list or document library on WSS 2.0/SPS2003 or WSS 3.0/MOSS 2007.

If you need to retain a list/document library itself (Maintaining its original GUID) without completely deleting the entire list/document library and re-creating, this tool can help.
You could certainly use Web Folders (WebDAV) to clear the contents, but users stand the chance of accidentally deleting the contents of the forms folder which is not desirable. As well, you could script and automate the task using this tool if you desired.

Download from CodePlex
http://www.codeplex.com/sppurgelist

SPLSBackup
The purpose of SPLSBackup is to mimic STSADM site collection level backup/restore but with options for setting/unsetting the sites lock state during the operation, therefore eliminating the need to manually visit the SharePoint Central Admin pages before and after.

Download from CodePlex
http://www.codeplex.com/splsbackup

SharePoint Access Checker Web Part
Quickly check what objects within a SharePoint site hierarchy a user has access to.

The Access Checker Web Part is a Windows SharePoint Services Web Part, for use within Windows SharePoint Services v3 and Microsoft Office SharePoint Server 2007, that displays a tree view showing permissions on objects for a user scoped to a Site hierarchy. It also has a second mode which will show the permission inheritance of objects within a Site hierarchy.

Download from CodePlex
http://www.codeplex.com/AccessChecker

WSPBuilder
The WSPbuilder is a console application that creates SharePoint Solutions files based on a folder structure. WSPBuilder will automatically traverse a “12″ folder structure and creates a SharePoint solution manifest.xml and the wsp file based on the files it finds.

Therefore you do not need the knowledge of how to create a solution manifest.xml and wsp file any more.

Download from CodePlex
http://www.codeplex.com/wspbuilder

SharePoint Used Space Information
SharePoint Used Space Information is a console application which allows to retrieve information about space used (bytes) by all sites and sub-sites for a specific site collection into .csv files.

Download from CodePlex
http://www.codeplex.com/SPUsedSpaceInfo

If you have used any of these tools, please drop a comment and share your views.

You might be interested in:
SharePoint 2007 Test Data Population Tool
SHAREPOINT DESIGNER 2007 IS NOW FREE!
Review of: SharePoint Content Deployment Wizard
Using STSADM.EXE to Create Empty Site Collection
Set the SharePoint Welcome Page through code

Install WSPs using STSADM- Sample batch file

set WSP_NAME=###WSPNAME##.wsp
cd E:\Builds\PreBuild

stsadm -o retractsolution -name %WSP_NAME% -immediate
stsadm -o execadmsvcjobs
stsadm -o deletesolution -name %WSP_NAME% -override
stsadm -o execadmsvcjobs
stsadm -o addsolution -filename %WSP_NAME%
stsadm -o execadmsvcjobs
stsadm -o deploysolution -name %WSP_NAME% -immediate -url ###URL### -allowgacdeployment -force
stsadm -o execadmsvcjobs



pause

A tool to extract WSP solutions from SharePoint to hard disk

http://archive.msdn.microsoft.com/SPSolutionExtractor


Resource Page Description
This tool allows to verify all wsp files installed on SharePoint 2007 Farm. And it allows to download the wsp files from SharePoint Database to hard disk.

Usage:

SharePointFarmSolutionExtractor.exe -list
(This command list all WSP-Solution installed on the SharePoint Farm)


SharePointFarmSolutionExtractor.exe -extractAll c:\SharePointSolutions
(This command download all WSP-Solutions installed on the SharePoint Farm to the specified path)


SharePointFarmSolutionExtractor.exe -extractById c:\SharePointSolutions
(This command will download all WSP-Solution with matching the SolutionGUID to the secified path)

SharePointFarmSolutionExtractor.exe -extractByName
c:\SharePointSolutions
(This command will download all WSP-Solution with matching the SolutionName to the secified path)

Requirements:
- .NET 2.0
- Microsoft.SharePoint.dll

Wednesday, January 25, 2012

Recreate Shared Service Provider (SSP)

Recreating a Shared Service Provider

SSP and MySite is not working and displaying Page Cannot be displayed error. Previously It was working fine and suddenly it stopped working. Web application pool is working properly. When click on SharedServices1 it display the error “Page Cannot be displayed” same is happening with MySite.

Find out old Database name

Open Central Administration Site and click on Shared Services Administration. Go to SharedServices1–>Edit Properties. Copy the old content database name & search database name.

Create Dummy SSP

Open Central Administration Site and click on Shared Services Administration. Click on New SSP to create a new one.

Make default SSP

Click on Shared Services Administration–>Change Default SSP (from the Shared Services Administration) and choose your new SSP (SharedServices2).

Delete old SSP

Delete the original SSP (SharedServices1) by choosing delete from its context menu. DO NOT DELETE ITS ASSOCIATED DATABASES! This might take a second to complete.

Restore the SSP

Now we’re going to click on Restore SSP and restore the original SSP with a brand new Administration site. Name it SharedServices1 and fill out fields. Create a new web application and when it comes time to fill out the fields for Search Database and but this time fill out the two databases for the SSP. This will include the databases that we identified in step 1. This will ensure that you don’t lose all your data from the SSP like Search Content Sources, Excel Services Settings, Audiences, and BDC etc.

Delete Dummy SSP

Now we should have two working SSPs, SharedServices1 and SharedServices2. Click Change Default SSP and change it back to SharedServices1. After that delete SharedServices2 (this might take a while).

Now reboot the machine and check your SSP.