Showing posts with label SPS 2010. Show all posts
Showing posts with label SPS 2010. Show all posts

Saturday, July 27, 2013

Service Pack 2 for Microsoft SharePoint 2010 (KB2687453)

Service Pack 2 (SP2) for Microsoft SharePoint 2010 contains new updates which improve security, performance, and stability. Additionally, the SP is a roll-up of all previously released updates.

Download it from this link http://www.microsoft.com/en-us/download/details.aspx?id=39672

Sunday, April 7, 2013

Sign in as Different User - Redirect to /_layouts/accessdenied.aspx Page in SharePoint 2010

I have a web application was a classic authentication mode and then by script we converted it to Claim authentication by the below powershell :

$web = Get-SPWebApplication "http://YourSiteURL"
$web.UseClaimsAuthentication = 1;
$web.Update()

but when I tried to Sign in as Different User , It's always redirect me to  /_layouts/accessdenied.aspx page.

So to fix this issue ( I don't know the reason but I think It's bug ) (My Farm Updated with SP 1 and  Feb CU 2013)

  1. Delete web application from Central administration (Just IIS web site and keep and content database)
  2. Create new Web application with Claim Authentication mode 
  3. Attach the content database with this new Web application


Tuesday, December 18, 2012

Sharepoint 2010 first search slow

I have an issue in my new farm that first search is very slow so I have tried the fix by Microsoft [Option 1] and it was perfect.
[Even this will speed up your SharePoint site]

Check this link
http://support.microsoft.com/kb/2639348

Sunday, June 24, 2012

Wiki Categories is Not Visible to users in SharePoint 2010


My friend faced a problem that Wiki Categories only visible to admin users and after I searched this problem I found that SharePoint Store these terms in hidden list under the site collection [http://site/Lists/TaxonomyHiddenList/AllItems.aspx] so after we set the permission for this list properly the users become able to see the Wiki Categories.

Monday, April 16, 2012

Service Unavailable HTTP Error 503 - SharePoint Central Administration


Yesterday I installed fresh SharePoint 2010 Development server Farm and then when I tried to open Central administration I got the following error “Service Unavailable HTTP Error 503” so I checked the IIS and I found that the application pool for Central administration is stopped so I restarted again and then refresh the page and again I got the same error and the application pool is stopped.
I opened the Server Manager >> Roles >> Web Server (IIS) and I found errors and warning and these are the details:

The main reasons for this error are:
    1.Service account of application pool has invalid password or locked
    2.The user has to added to Log on as a batch job policy
So my problem solved by adding the service account to Log on as a batch job  local policy.
Steps:
    1.Control Panel >> Administrative Tools >> Local Security Policy >> Security Settings >> Local Policies     >> User Rights Assignment >> Log on as a batch job.
    2. Or ask the Network guy to add it from group policy of Active Directory.


Thursday, January 12, 2012

Extend Search Core Result Web part with FAST for SharePoint 2010

I have tried to extend Search Core Result Web part with simple customization and deployed as feature to FAST SharePoint 2010 Template as following:

[ToolboxItemAttribute(false)]
    public class AppendCoreResultWebPart : CoreResultsWebPart
    {
protected override void ConfigureDataSourceProperties()
        {
        //Just Append Search Query with My Name
            this.AppendedQuery = "Fadi Abdulwahab";

            base.ConfigureDataSourceProperties();
        }
    }
}



But the problem in this web part that did not show any result by default but the rest controls like paging or Refinement web parts returned results as the below image

 So to fix this problem as Mr. Mikael Svenson [I asked him to help me in this issue] said just "Export the settings from the default core results webpart.. And add those to the .webpart file of your custom webpart"
Note: I advice you to visit  Mr. Mikael Svenson  blog  http://techmikael.blogspot.com/ 
So just go to Web Parts page under Site Actions >> Site Settings >> Galleries and export the .webpart file of Default Search Core Result web part and then copy the below properties and then export your custom web part file and add the below properties and then upload it again to web part galleries

        <property name="ChromeType">None</property>
        <property name="AllowMinimize" type="bool">true</property>
        <property name="AllowClose" type="bool">true</property>
        <property name="Hidden" type="bool">false</property>
        <property name="ShowActionLinks" type="bool">false</property>
        <property name="ShowMessages" type="bool">true</property>

Finally Go to SharePoint page and remove the old web part and add the new web part J.


Tuesday, September 27, 2011

Exception from HRESULT: 0x80041054

The following error "Exception from HRESULT: 0x80041054" related to ForeFront Protection 2010 for SharePoint and if you check the log [Windows Log] you will find the following error "The SharePoint service is running but the Forefront VSAPI Library is not registered"

so to fix this error from SharePoint Side just go to Central administration >> Security >> Manage antivirus settings >> then Uncheck all check boxex and then browse the site .

To fix it from Forefront Protection production by follow the steps in this URL
http://ikarstein.wordpress.com/2010/12/07/forefront-protection-2010-for-sharepointerror-the-sharepoint-service-is-running-but-the-forefront-vsapi-library-is-not-registered/

then Re-Check the Settings in Manage antivirus settings to enable scan documents when upload or download.

The BDC Service application ... is not accessible. The full exception text is: There are no addresses available for this application

Today i have faced this problem "The BDC Service application ... is not accessible. The full exception text is: There are no addresses available for this application" in sharePoint 2010


so to fix it do the following :
1-Delete the created BDC Service App
2- Make sure Business Data Connectivity Service started on the server
3- Re-Create BDC Service App.


Done.

Saturday, August 6, 2011

Sandbox Solutions and Load Balancing schemes

Sandbox solution or User Solution as Microsoft Definition "A sandbox is a restricted execution environment that enables programs to access only certain resources and keeps problems that occur in the sandbox from affecting the rest of the server environment".

So Sandbox solution more secure,safer and the user who deploy the solutions has limitation to server resources for example you can't deploy a files to Servers like Visual Web Part, You can't execute SPWebApplication , SPSecurity , Reflection code (Connected Web Parts uses Reflection so you can't Implemented also)… and these solution deployed or stored at Site collection level .

Administrator Can monitors these solutions and gives them specific resources or can block these solutions.
These solutions run under specific process located under 14\UserCode\ folder not under w3c.exe process.


In this article I will explain the Sandbox solution and Load Balancing schemes which affect the execution of code in the servers.

If you go to Central Administration >> System Settings >> Manage user solutions
You will find the below options:

The first option means:
If you have two frontend servers with Microsoft Load balance configuration (NLB) and the user request a page which run sandbox solution code; if the NLB routed the request to one these server the code run in the same server which received the request so in this case all frontend servers must started Microsoft SharePoint Foundation Sandboxed code Service and if in case this service not started on the server which received the request; the code will not run and the user will get an error.

Second option:

If in case the service started in Frontend 1 server only and the NLB routed the request to Frontend 2; here the Sandbox process will route this request again to Frontend 1 and then run this code and the user will get the Response (this is known as solution affinity).


So for example I created a web part (not visual web part) with basic code like below:
public override void RenderControl(HtmlTextWriter writer)
        {
            base.RenderControl(writer);

            writer.Write("Hello Fadi From Sandbox Solution");
        }


And then I uploaded this solution to Site Settings >> Solutions and then activated and then I add this web part to a test page.



Now I stopped Frontend 1 from the NLB and then I requested the page which has sandbox solution code; sandbox process route the request to Frontend 1 to run the code and get the Response.

Note: try the first option with this an example and you will get an error because when the NLB route the request to Frontend 2 which the service in this server not started so the code will not run.
so the benifits with second option as microsoft wrote : "The more you isolate sandboxed solutions, the better your ability to protect the main part of your SharePoint Server 2010 site from code that might consume too many resources. You can increase isolation by using remote load balancing and by running the sandboxed solution service only on specific servers."

Wednesday, July 27, 2011

Excel SpeardSheet can't be open in Sharepoint Server 2010 with Office Web Apps

Today I came across an error with Excel service and Office web apps with that I make sure all features running and application service associated with my web application so I check the log and I found this error:
SQL Database 'WSS_Content_SCTAIntranet_80' on SQL Server instance '[Instance Name]' not found. Additional error information from SQL Server is included below.

Cannot open database "WSS_Content_SCTAIntranet_80" requested by the login. The login failed.
Login failed for user '[DomainName]\EPM_ExcelService'.



So to fix this problem just go to SQL Server Management Studio > Security Folder > Logins >[DomainName]\EPM_ExcelService then Right click and Properties


Select the database name (WSS_Content_SCTAIntranet_80) and then in down part check [db_owner].

Note: the above solution apply to this error also [But you need also to run IISReset]

"There is a compatibility range mismatch between the Web server and database "WSS_Content_RecordCenter", and connections to the data have been blocked to due to this incompatibility. This can happen when a content database has not been upgraded to be within the compatibility range of the Web server, or if the database has been upgraded to a higher level than the web server. "

Sunday, July 24, 2011

How to encrypt the connection string in web.config in Asp.net Web Application or Site and SharePoint Web Application

In order to encrypt sensitive information in the web.config of Asp.net Web application/Site or SharePoint Web application like connection String which include user name and password or any data in appSettings so to secure your data easily you can use .net 2.0 tool called (aspnet_regiis.exe).


In this post I will show you how to encrypt/decrypt appSettings data in Web.config using the aspnet_regiis tool.

So first go to command prompt of .net 2.0 which located in this path:

C:\Windows\Microsoft.NET\Framework\v2.0.50727>


Then I have a Test Web application with this section in web.config

<appSettings>
    <add key="MyPassword" value="1234"/>
</appSettings>


Now to encrypt this data, just run the following command:


aspnet_regiis -pef "appSettings" "D:\CustomFunctoids\TestWeb\TestWeb"

first parameter : name of section you want to encrypt it
second parameter : the folder directory of the web application which contains the web.config



So you will get a succeeded message tell you that the encryption done.
Now check your web.config /appSettings section and you will see something like this:

<appSettings configProtectionProvider="RsaProtectedConfigurationProvider">
    <EncryptedData Type="http://www.w3.org/2001/04/xmlenc#Element"
      xmlns="http://www.w3.org/2001/04/xmlenc#">
      <EncryptionMethod Algorithm="http://www.w3.org/2001/04/xmlenc#tripledes-cbc" />
      <KeyInfo xmlns="http://www.w3.org/2000/09/xmldsig#">
        <EncryptedKey xmlns="http://www.w3.org/2001/04/xmlenc#">
          <EncryptionMethod Algorithm="http://www.w3.org/2001/04/xmlenc#rsa-1_5" />
          <KeyInfo xmlns="http://www.w3.org/2000/09/xmldsig#">
            <KeyName>Rsa Key</KeyName>
          </KeyInfo>
          <CipherData>
            <CipherValue>BPLmgrIVZKTDerhKlyktxqnn5iybr8aO0IInylE8uT1Pe3zCB5y9DIHqlllH3e0sz6TtJaU/wS0oEiPIWMMO0BL/BPdj9E5Onq4nYiA2r/zBPCR6H0nYhk9/uMjao4YDcg6daask65Y8Mx1RBO/xM/IKzdNGXICpiF09Mrwrv1Q=</CipherValue>
          </CipherData>
        </EncryptedKey>
      </KeyInfo>
      <CipherData>
        <CipherValue>kziM2nK5Ej6kg7hxnN2shTB8EiMW/I5jrgQRJAIRD5gSV/KG6iYslstFz+r+6Wk9OKXKP2zUhDRl42++HOWbtjqJn5XjmHuzy3tHy+7YMvRL6CNY7lXQTQ==</CipherValue>
      </CipherData>
    </EncryptedData>
  </appSettings>


So it encrypted by using RsaProtectedConfigurationProvider algorithm
Now if your browse your site and you get this error :

"Failed to decrypt using provider 'RsaProtectedConfigurationProvider'. Error message from the provider: The RSA key container could not be opened"


this means the user used by the Asp.Net web site does not have access to read this key container so to know what the name of user ?  you can create a simple .aspx page and place this code inside it
to determine the user account or identity under which ASP.NET runs by retrieving the current WindowsIdentity name.


<%@ Page Language="C#" %>
<%
Response.Write(System.Security.Principal.WindowsIdentity.GetCurrent().Name);
%>


So this page will print the current user used to run the web site so in my PC I got this result "VAIO-PC\VAIO"
now to grant this user ability to read this encrypted data run the following command


aspnet_regiis -pa "NetFrameworkConfigurationKey" "VAIO-PC\VAIO"


Now what if you want to decrypt the data to modify it so how to decrypt the appSettings section ?
run the following command to return to the normal status (Plan text)

aspnet_regiis -pdf "appSettings" "D:\CustomFunctoids\TestWeb\TestWeb"


Notes:
1.       You need to run this in all front end servers
2.       No need to any changes in your code because .net code can recognize this changes
3.       You can do the above steps by .net code

Friday, May 13, 2011

Tips for Anonymous site in SharePoint 2010

These are some tips to publish your site with anonymous access.
  1. From Central Administration >> Web Applications Management >> then select your web application >> Authentication Providers >> Select the zone which publish it to the internet (In my case is Default Zone) >> Enable anonymous access
2.  Then open your site collection and go to Site Settings >> Site Permissions >> Anonymous Access (top in Ribbon) >> Select Entire Web site.
3.  Make sure all pages, master pages , layouts , images ,item style and css have published (Checked in and Published).

4. If you have a page in layouts folder (14-hive folder) then make sure the page inherence from System.Web.UI.Page not other namespace and class (like LayoutsPageBase).

5. If you have Client Object Model (ECMAScript) in your page make sure to run the following script to remove the striction from SharePoint 2010 with anonymous access (be careful when you are using Client Object with anonymous access to access any sensitive information )

$wa = Get-SPWebApplication -Identity "http://SiteCollectionUrl"
$wa.ClientCallableSettings.AnonymousRestrictedTypes.Remove([Microsoft.SharePoint.SPList], "GetItems")
$wa.Update()

6. If you have for example a page which insert an item to custom list and you need to enable the user insert the item anonymously you have to break the permission of this list from list Settings >> then Select Permissions for this list and then Click on Anonymous Access and Select Add Items permission.

7. Avoid Operation of attaching a workflow (ex. SharePoint Designer workflow) with the item insertion or uploading file because these functions not work properly in anonymous access.

8.Finally to access the site via mobile device and avoid the unauthorized page error or to browse the site same as normal browser so just past this configuration in web.config of Web application under system.web section

<browserCaps>
  <result type="System.Web.Mobile.MobileCapabilities, System.Web.Mobile, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"/>
  <filter>isMobileDevice=false</filter>
</browserCaps>

Friday, April 8, 2011

SharePoint Central Administration (SPCA)


These are good articles related to SharePoint Central Administration every SharePoint Administrator or DBA must know :


SharePoint Central Administration: High Availability, Load Balancing, Security & General Recommendations

http://www.harbar.net/articles/spca.aspx



Easy access to SharePoint Central Administration for developers
http://blog.mastykarz.nl/easy-access-sharepoint-central-administration-developers/


How to change the URL for SharePoint Central Administration site
http://blogs.objectsharp.com/cs/blogs/max/archive/2008/11/14/how-to-change-the-url-for-sharepoint-central-administration-site.aspx


Change the Central Administration Web site port number (SharePoint Server 2010)
http://technet.microsoft.com/en-us/library/cc298580.aspx


Thursday, March 31, 2011

SharePoint 2010 Branding - Tips 1

These group of tips which are related to SharePoint 2010 Branding which I gathered from Pro SharePoint 2010 Branding book - Wrox publishing and my experience so maybe these tips will benefit anyone read this article.
  • We have to reduce the gap between the designer and developer because many times the developer does some designing tasks in SharePoint 2010 and vice versa.
  • Branding of SharePoint different from Branding and designing of custom web application because it's not just CSS ,images and HTML but it's also include XSLT , MaterPage and Web Parts.
  • SharePoint Designer 2010 setup available for free from Microsoft download site (32 bit or 64 bit).
  •  Having some knowledge in ASP.NET help you to get comfortable to work with SharePoint Branding components like Master page and Content place holders.
  • Branding means create your site which reflects your standards or schema and colors so for example your colors and fonts of your company site inherent form Your Logo.
  • Some feature of branding available in SharePoint Server 2010 not available in SharePoint foundation like publishing features.
  • Branding of Your site can be different based on the type of your environment which can be intranet, internet or extranet (combination of intranet and internet).
  • In SharePoint 2007, custom theme can be apply by creating CSS, images and XML in 12 hive folder then applies these changes to master page but in SharePoint 2010 the task now easier so just we can apply a custom theme by creating .thmx file by using Office software 2007 or later version to customize your theme with 12 colors and 2 fonts then applies these changes to any site by uploading one file only from site settings.
  • Out of the box master pages available in SharePoint 2010 as the following:
    • V4.master – like default master page in SharePoint 2007
    •  Nightandday.master – this master page used with publishing site
    •  Minimal.master – less functionality master page and used with search site but it's not a minimal master page like in SharePoint 2007 so can't be used as starter master page as previous version.
  •  Wiki pages enable the user to create the page on the spot just when he enter a link for the page by using [[ in edit mode.
  •  In SharePoint 2007 the core.css was a file which contains all css useing with SharePoint so when you browse a page the sharepoint load this file which has thousands of lines and this produce the performance issues but in SharePoint 2010 the concept changes so the main file now coreV4.css and just the needed style will be load it when you request the page for example if load the search page so just css needed for search page will be load it.
  • We can divide the supported browser by SharePoint 2010 :
    • Fully supported like IE 7 or 8 32 bit
    • Supported with some limitations like Firefox 3.6 , IE 7 or 8 64 bit and chrome
    • Not supported like IE 6
  • SharePoint 2010 output cleaner HTML code more than SharePoint 2007
  • You can customize the Media Player web part which is sliver light control with using Microsoft expression blend.
  • Multi-lingual User Interface (MUI) enable the user to have multiple language feature for one site not like the variation which create separated site for each language.
    Note: Variation and MUI can be used together.
  • SharePoint 2010 has been designed to follow more closely (not 100%) the XHTML standard which enables Web Content Accessibility Guidelines WCAG 2.0 of W3C.
  • Application Pages (which are under _layouts folder ) can be now customize their master page from site settings not like SharePoint 2007 you have to customize application.master (this master page lives under layout folder directory and all web application read from this master page unless you have a separate layout folder for each web application) or assign a new master page by using custom code (not supported by Microsoft specially when you apply hot fix or service back).
  • If any an error occur in custom master page for application pages SharePoint will fall back automatically to v4.master to make sure all application pages still accessed.
  • You can still use Branding of SharePoint 2007 in upgrading environment or you can upgrades to new look and feel by using Visual Upgrade feature.
  • A DOCTYPE is a piece of code that is declared at the top of a document that instructs the browser to use a specific language to interpret the rest of code.
  • List of Popular DOCTYPE in use today :
    • HTML 4.01 Strict — allows all HTML elements but does not allow deprecated elements such as the tag.
    • HTML 4.01 Transitional — allows all HTML elements including deprecated elements.
    •  XHTML 1.0 Strict — Similar to HTML 4.01 Strict, but all tags must be well-formed XML. Deprecated elements are allowed but must also be well-formed XML
    • XHTML 1.0 Transitional — Similar to HTML 4.01 Transitional, but all tags must be well formed XML. Deprecated elements are allowed but must also be well-formed XML
  • SharePoint 2010 use XHTML 1.0 Strict DOCTYPE by default.
  • Compatibility mode tells the browser (IE only ) how to interpret and render a website and there are several supported modes in IE 8:
    • IE=5 IE5.5/Quirks rendering mode
    • IE=7 IE7 Standards rendering mode
    •  IE=EmulateIE7 IE7 Standards or Quirks rendering mode, depending on the DOCTYPE
    • IE=8 IE8 Standards rendering mode
    • IE=EmulateIE8 IE8 Standards or Quirks rendering mode, depending on the DOCTYPE
    • IE=edge Uses the latest rendering mode, which is currently IE8 Standards Mode
  • All SharePoint 2010 Master page by default use IE=8 compatibility mode.
  • You have to connect and login to a site in SharePoint Designer 2010 to use it as editor not like SharePoint Designer 2007 you can use it as editor without login required.
  • Check the bottom left corner in SharePoint Designer 2010 to find the current login used or to login by other user
  • To apply custom CSS in SharePoint 2010 you can use the following methods:
    • Apply inline style in master page and page layouts
    • Create custom CSS and add link to custom master page
    • Alternate CSS feature with publishing site only.
  • In SharePoint 2007 you can create view for list by using web browser but in SharePoint 2010 you can also create the views for the list by using SharePoint Designer 2010
  • All view of list of SharePoint 2010 based on XSLT so you can customize by using SharePoint Designer 2010 (use XSLT List View Web Part) not like SharePoint 2007 which based on CAML
  • Type of workflow supported by SharePoint Designer 2010
    • List workflows — workflows that are directly associated with a list.
    • Reusable workflows — these are workflows that can be associated with many lists, or libraries and it's based on a specific content type.
    • Site workflows — these workflows are not associated with a specific list or content type.
    • Globally reusable workflows —out-of-the-box workflows (Approval, Collect Feedback, and Collect Signatures) are listed as globally Reusable Workflows. These workflows can be edited with SPD  2010 or used as the basis to create new workflows.
  • Workflow of SharePoint 2010 can be design also by using Microsoft Visio 2010 and Visual studio 2010 and then can be imported to SharePoint Designer 2010 to customized
  • You can connect through SharePoint Designer to different type of line of business with easier editor and read and write operation not like SharePoint 2007
  • Not like SharePoint Designer 2007 , now you can control who can access the SharePoint Designer 2010 and which items can be edit by this user for example if the user can edit the master page or detach a page and this can be control from
    • Central Administration >> General setting of Web application
    • Site Settings of site collection

Saturday, March 12, 2011

Get Current Site Name in Item Style in SharePoint

If you want to get current site Name in item style you can use this field "FileRef" which return the complete url of page like this (/Faq/Pages/faq1.aspx) so to get only the (Faq) site Name you can do the following:

<xsl:value-of select="substring-before(substring-after(@FileRef, '/'),'/')" ></xsl:value-of>

to see all fields and its value in item style use the following:
 <xsl:for-each select="@*">               
         <xsl:value-of select="name()" /> <xsl:value-of select="."/> <br/>                    
 </xsl:for-each>

Ref:
Content Query Web Part Display all fields + values
http://vspug.com/rohan/2008/08/12/content-query-web-part-display-all-fields-values/

Monday, February 28, 2011

Can't Open PDF Files in SharePoint 2010

If you try to open PDF file in the Browser in SharePoint Server 2010 you will not able to open it by default in the browser just you have an option to save a PDF file like the below images



 so to solve this issue make sure you read and implement the following Links:



First Check if your PC or system and browser support to open PDF file in the browser by the following Link:
Can't view PDF on the web
http://kb2.adobe.com/cps/328/328233.html

 Second Implement the following solution by changing settings in General Setting of Web Application in Central administration and run the some specific power shell:
SharePoint 2010 forces users to save PDFs – Solution Found!
http://nerdtastictips.blogspot.com/2010/08/sp2010-forces-users-to-save-pdfs.html

Regards,

Thursday, January 13, 2011

SharePoint Server 2010 Farm Service Account - Logon as a service - SharePoint Services Timer V4

One of the requirements of SharePoint Server 2010 to build a Farm is to create a service account "Farm Service Account".


So I will describe it as person to make sure your environment run smoothly.
  1. He is as Normal user (domain user not domain admin user)
  2. This user Belong to the following SQL Roles
    1. Public
    2. Securityadmin
    3. Dbcreator
  3. Belong to Local administrators group of SharePoint servers
  4. Belong to the following local security groups:
    1.  IIS_IUSRS
    2. Performance Log Users
    3. Performance Monitor Users
    4. WSS_ADMIN_WPG
    5. WSS_RESTRICTED_WPG
    6. WSS_WPG
Note: this person will add to these groups during SharePoint Configuration Wizard but also make sure he is included in these groups.


5. Belong to the following Local Security Policy >> User Rights Assignments:
  1. Adjust memory quotas for a process
  2. b. Logon as a service (very important)
  3. c. Replace a process level token
6. This user will run the following windows services:
  1. SharePoint Services Timer V4 (very important)
  2. SharePoint Services User Code Host V4
7. This user will be used to run the application pool for Central Administration and Security Token Service.


Now couple of times I have faced this problem which is:


For example you have in your environment 2 front-end servers and when I create web application from central administration from Server A, the problem that the web application will not automatically provisioning or replicated to server B. I mean In Server B ,for example if you go to IIS you will not find the Application pool and if you go to C:\inetpub\wwwroot\wss\VirtualDirectories folder you will not find Application folder so any action occurred in Server A not copied or mirrored to Server B.


So the problem is from SharePoint Services Timer V4 which it's job to provision any modifications or updates happen in Server A to other servers because as Microsoft said "Microsoft SharePoint Server 2010 uses the Windows SharePoint Services Timer V4 (SPTimerV4) service to run most system tasks" so I found this service stopped. Why? So I try to start it again then I got this error


By the way no one reset the password of the Farm service account but I think because this service account not added to Logon as a service local policy.
So I have to go to properties of SharePoint Services Timer V4 >> Log On tab and update the password with the Old password then run the service and the problem of provision gone.


Finally make sure this user added to Logon as a service and SharePoint Services Timer V4 is running.

Wednesday, January 12, 2011

Hot Fixing ,Disconnecting and Rebuilding Sharepoint Server 2010 Farm

I have four SharePoint servers 2010 connected to SQL Server 2008 R2 Clustered in one Farm and these servers are two for Crawling and Indexing Servers and two for front-end servers so the story start from here.
I have installed this hotfix in all four servers:
http://support.microsoft.com/kb/2459257/en-us
"Description of the SharePoint Server 2010 Cumulative Update Server Hotfix Package (MOSS server-package): December 31, 2010"

so after that I restarted all servers then I run Configuration Wizard to upgrade or apply these updates.
First server in the farm run smoothly without any problem and it has updated successfully so when i tried to run the Configuration Wizard for the second server i got a message that tell me i have to install the above hotfix in current server even i have installed on it.
So after long time search and tries i have decided to remove all servers from the configuration database farm and create new Farm so first thing i did
  • remove all servers from Central Administration  >> Servers in Farm and then remove server
  • also run this power shell command in each server  PSConfig -cmd configdb -disconnect
Now the current status all server updated by the installed hotfix so i run configuration wizard in the first server and i create new farm and database.
When i tried to connect or join the other server to the new farm by running the Configuration Wizard , still the Wizard Connect to Old Configuration Database or Update mode so the configuration will failed because i have deleted the old Configuration Database even if you try through powershell by using this command PSConfig -cmd configdb -connect
so again i get help from google for searching in the internet and i read this article
http://www.sharepointblues.com/2010/05/31/disconnecting-a-sharepoint-server-from-a-farm-when-the-config-database-is-missing/
"Disconnecting a SharePoint Server from a Farm When the Config Database Is Missing"
so i come across the idea to remove the following from the regedit
ConfigDb and FarmAdmin forlder
[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Shared Tools\Web Server Extensions\14.0\Secure


and i did it ( I know it's risk).
Then I run the configuration Wizard again to join the remaining servers and all joined and connected smoothly.

so maybe all this would not have happend if I had disconnected all servers from the farm then install the hotfix and then rejoin the servers to the farm to be all server in the same build version.

Tuesday, January 11, 2011

How to Change Diagnostic Log path in SharePoint 2010 by using PowerShell

Best Practice to change the path of Diagnostic Log to avoid disk run out of space C:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\14\LOGS in SharePoint 2010 and this can be done by PowerShell so go to
Start >> All Programs >> Microsoft SharePoint 2010 Products >> SharePoint 2010 Management Shell

Create folder for example in D:\SharePointLog
then run this command

Set-SPDiagnosticConfig -LogLocation D:\SharePointLog\

to check if your changes applied just run this command

Get-SPDiagnosticConfig

and see the Log location path

Done