Posts

Showing posts from 2016

Installing SharePoint Server 2010 Cumulative Update

Image
Download the appropriate hotfixes for SharePoint Server 2010  Click here to download the CU Log into each SharePoint server using the same account that you used to initially install SharePoint. This account should have  dbcreator  and  securityadmin rights on the SQL server that is part of your SharePoint farm. On one of the servers, open up  Central Administration > Upgrade and Migration > Check product and patch installation status  and take notice of the current build version  14.0.4763.1000 On each web front end server, open up   Services.msc  and stop the  World Wide Web Publishing Service  to prevent users from getting into SharePoint during the upgrade Install the five hotfixes on each SharePoint server in the farm. Start with the SharePoint Foundation hotfix, then the remaining SharePoint Server hotfixes. On the KB983497 install, you might get a screen to stop some services before continuing. Some of the hotfixes may also require a reboot. Perform the reboot be

Get Site Collection URL Content DataBase name and Size with PowerShell

Add-PSSnapin   microsoft.sharepoint.powershell $SizeLog   =   "D:\temp\SPSiteSize.csv" ############################################################ $CurrentDate   =   Get-Date   -format   d $WebApps   =   Get-SPWebApplication foreach ( $WebApp   in   $WebApps ) {   $Sites   =   Get-SPSite   -WebApplication   $WebApp   -Limit   All   foreach ( $Site   in   $Sites ) {   $SizeInKB   =   $Site . Usage . Storage   $SizeInGB   =   $SizeInKB / 1024 / 1024 / 1024   $SizeInGB   =   [ math ]:: Round( $SizeInGB , 2 )   $CSVOutput   =   $Site . RootWeb . Title  +   "*"   +   $Site . URL  +   "*"   +   $Site . ContentDatabase . Name  +   "*"   +   $SizeInGB   +   "*"   +   $CurrentDate   $CSVOutput   |   Out-File   $SizeLog   -Append } } $Site . Dispose()

Export SharePoint List Item Version History to Excel

I wrote a PowerShell script and C# object model codes to generate SharePoint version history report in  SharePoint document version history report , related to that, got a new requirement to export version history to excel. This version history report helps to compare what data is changed, who changed the list data, etc over time.  just replace the values of WebURL, ListName variables with your Site/List values and run the script to export version history SharePoint 2013 # ******* Variables Section ****************** #Define these variables $WebURL = "http://sharepoint. constsco. com/sites/Sales/" $ListName   = "Invoice" $ReportFile   =  "D:\Invoice_VersionHistory.csv" # ********************************************* #delete file if exists If ( Test-Path   $ReportFile )   {   Remove-Item   $ReportFile   } #Get the Web and List $Web   = Get -SPWeb   $WebURL $List   =  $web .Lists.TryGetList( $ListName )   #Check if lis

SharePoint 2010: List and Delete List Item Versions using PowerShell

Image
Introduction When versioning is turned on for a SharePoint list or document library, there are times when you may need to report on the number of list item versions, or delete versions that exceed a threshold. These scenarios can happen if; 1. Version limits (for the maximum number of major/minor versions) were not set, and the list has too many versions 2. Version limits are being applied or reduced, and you need to retrospectively delete all the versions in a list that exceed the new threshold* 3. You are performing an upgrade, and you want to prune the versions of pages in the pages library (on a publishing site) 4. You want to run a report to determine how many items in a list have more than "x" number of versions  *When the version settings are changed on a list, existing versions on existing items in the list are not changed until the item is modified. Therefore, if you reduce the maximum number of versions to be kept for items in a list, the changes only take effec

Clearing the Configuration Cache for SharePoint

Clearing the Configuration Cache for SharePoint Perform the below steps on all the servers in the farm. 1. Stop the Timer service Start  ->  services.msc  ->   SharePoint Timer Service  (SPTimerV4) ->  Stop 2. Browse to  %SystemDrive%\ProgramData\Microsoft\SharePoint\Config\GUID Note: The  Program Data  folder is a hidden file There could be more than 2 folders in this location. 3. Open the folder named as GUID’s with ‘-’ (dashed filename for the folder). Example -  1f8c67d2-2cd9-4196-ab1a-d1a2daed2aa7 4. Arrange the files by Type. You would find few xml files and a file named  cache.ini . 5. Delete all files except cache.ini (DO NOT DELETE THIS FILE - cache.ini) 6. Reset cache.ini (If you open this file, you will find a number like this – 3400261. Change the value in cache.ini to 1) 7. Start the Timer service Start  ->  services.msc  ->   SharePoint Timer Service  (SPTimerV4) ->  Start. 8. Note: The file system cache