- Poor man’s SharePoint warm-up script
-
It’s simple, it’s a little bit manual, but it works well.
warmup.cmd
stsadm
pages.html
pages.html
<html>
<body>
<iframe src=”http://spca:18000/”></iframe>
<iframe src=”http://myssp.domain/ssp/admin/”></iframe>
<iframe src="http://sandbox/"></iframe>
</body>
</html>
warmup.cmd assumes you have added the 12 hive to your path, else you can just fully qualify the path to stsadm. It’ll finish by calling your simple html page which will hit all the urls you want to warmup.
I use this iframe approach on my SharePoint admin site so I can see if all the site collections that I care about are up and running. Sometimes I throw a width=100% attribute in the iframe tag so all the websites stack on top of each other nicely.
This simple SharePoint warmup script is great to run at the end of your deployment scripts or as a task to put in your startup menu.
My other warmup script is a little bit of powershell which lists all of the site collection urls in the farm and adds them to the pages.html file, but I mostly just use the simple approach without powershell to start with at a new client site.
- SharePoint uninstall - "the product installation has been corrupted, run setup from original source"
-
"the product installation has been corrupted, run setup from original source"
See this message before? I saw this when trying to uninstall SharePoint from the Add/Remove Programs menu. This happened after someone uninstalled IIS before trying to uninstall SharePoint and then reinstalled IIS.
The suggestion was a good one. After finding the SharePoint source files we ran the setup.exe, entered the product key and let it run. A few minutes later we got a more specific error message:
“Microsoft Office SharePoint Server 2007 encountered an error during setup. An installation package for the product Microsoft Search Front End cannot be found. Try installation again using a valid copy of the installation package 'osrchwfe.msi'.”
Well, that’s a much better error message. Apparently the Microsoft Search Front End component is not happy. Reinstall required. After a quick search through the SharePoint installation source files we find the ‘osrchwfe.msi’ file at \Global\Search\osrchwfe.msi. Double click to run, and a few seconds later it’s finished.
Run setup.exe again and all goes well. Takes a few minutes.
Select remove from the Add/Remove Programs menu and all goes well. SharePoint is gone.
Reboot required.
- Don’t recycle the Application Pool for Central Admin site for faster load times
-
The default app pool setting for the SharePoint Central Admin site is to recycle at a set time each day.
Given that most of us rarely use Central Admin more than once or twice each day (because we script all the changes to the SharePoint farm configuration, don’t we? Don’t we?? Ok) we don’t like it when you hit the CA url and it’s takes ages for the site to JIT compile. Because the app pool recycles every night you’ll take the hit every time you hit the site for the first time in a day.
Solution: Don’t recycle the Central Admin app pool.
- Browse to IIS Manager (Start >> Run >> inetmgr)
- Expand the “Application Pools” node
- Select the “SharePoint Central Administration v3” app pool
- Edit Application Pool Recycling Settings
- Uncheck the Specific time(s) box
Test it yourself. Decide if it’s something you should configure in your own SharePoint environment.
- How to uninstall Microsoft Office SharePoint Server 2007 if you accidently deleted IIS first
-
So you’ve gone to uninstall SharePoint and you find that someone has removed IIS first. You go to Add/Remove programs and select uninstall for SharePoint but it fails with an error message “Error 1920.Service 'W3SVC' (W3SVC) failed to start. Verify that you have sufficient privileges to start system services”. No kidding, there is no IIS and it can’t start W3SVC. Ok.
Now what do we do?
Reinstall IIS and then uninstall SharePoint from Add/Remove Programs.
Done.
- Scripted provisioning of multiple Central Admin web applications
-
After reading some other posts about setting up the SharePoint Central Admin Web Application on multiple servers I thought it would be useful to post just a little more information on the topic.
The From the Field blog covered this topic really well. I then read a post by Spence Harbar on Central Admin high availability, load balancing, security and general recommendations. You must read that one!
My day to day work has recently had a focus on automating the deployment of SharePoint farms. So in the spirit of automation, here's how to approach the basic provisioning of Central Admin (CA) on multiple servers in a SharePoint farm.
Farm Topology
-------------
Server1: CA, Web App (WFE)
Server2: Indexer
Server3: Web App (WFE), Query
Server4: Web App (WFE), Query
Server3 and Server4: NLB
Scenario
--------
You have CA provisioned on Server1 (http://server1:1234) and you'd like to provision CA on Server2 (http://server2:1234) for redundancy.
Quick Answer
------------
Logged on to Server2 cmd line, run the following commands:
psconfig -cmd adminvs -provision -port 1234 –windowsauthprovider onlyusentlm
stsadm -o deletealternatedomain -incomingurl http://server1:1234
stsadm -o addalternatedomain -url http://server2:1234 –incomingurl http://server1:1234 -urlzone intranet
Now you can browse to either http://server1:1234 or http://server2:1234 and you'll have a CA web application.
Note: Here’s where my experience has differed from other posts on this topic. If you launch SharePoint Central Administration from the "Start > Program Files..." shortcut you will always go to http://server2:1234 i.e. the last CA wins, it’s the one that gets put in the registry on all servers. This is because others start the CA service on a new server via the existing CA web page, whereas I provision the CA on the new server by using the above psconfig command.
I encourage admins to script their tasks where ever possible as it leaves a clear record of the action taken. Provisioning a redundant CA will most likely be done as a part of the initial farm build, in which case you should definitely be scripting the farm configuration.
Some more information
----------------------
After running through the commands above you're left with the most recent CA server being the "primary" CA. What I mean by “primary” is that every server in the SharePoint farm now has a registry entry for THE CA server and it points to the new one (Server2).
Why is this?
Well it makes sense. If you have CA running on a single machine and it goes down, you'll want to put the CA on another server in the farm.
After installing the CA on the new server SharePoint updates all servers in the farm and says "hey... this new server is THE CA, forget about the old one". If it didn't do that you would need to manually update every server in the farm so it no longer points to the non-existant, original, CA server (the dead one).
But what if you want to add CA to another server in the farm for redundancy but you still want the original CA server to be the "primary" CA, the one in the registry and hence the one that the link in the Start menu takes you to?
Well, you can do it a few ways:
1. You can modify the registry on all servers currently in the SharePoint farm. The problem is that when you add a new server to the farm it's registry entry will still point to the latest CA server.
2. You can unprovision CA from your original server and then provision it again, making it the latest CA server added and therefore the one in the registry and start menu on every server in the farm.
I like number 2. It's an extra few commands to run in the command line, but it does the job well and handles new servers being added to the farm in the future.
Given that I usually have a SharePoint Admins team site with links to the Central Admin web applications directly, I don’t feel the need to have the registry updated on each server running CA to point to it’s own url. My second CA in the farm is just there in case something happens to my primary CA server. If it goes down I’ll browse directly to the second url. I don’t need the start menu link. You may work differently.
Wrapping up
------------
So, read the two great posts I mentioned at the beginning and then put the commands above into a script to get the job done. Test it and refine the scripts until they fit your own scenario.
- The secrets of SQL Syntax Queries for Relevant Results in MOSS 2007 Enterprise Search
-
I've been handing out this blog post URL (below) so much lately that I thought I'd share it here.
The secrets of SQL Syntax Queries for Relevant Results in MOSS 2007 Enterprise Search
http://blog.mondosoft.com/ontolica/archive/2007/07/31/The-secrets-of-SQL-Syntax-Queries-for-Relevant-Results-in.aspx
Article has links to the MSDN pages explaining the syntax further.
- SharePoint Search site
-
http://SharePointSearch.com
- Visual Studio 2008 ("Orcas") and .NET 3.5
-
Daniel Moth has a bunch of great posts on Visual Studio 2008 and .NET 3.5
Here are two great entry points:
http://www.danielmoth.com/Blog/2007/06/visual-studio-2008-stack.html
http://www.danielmoth.com/Blog/2007/06/net-framework-35.html
- Orcas Beta 2 Download URLs
-
http://blogs.msdn.com/bharry/archive/2007/07/26/orcas-beta-2-download-urls.aspx
Great post with all the download URLs for Orcas Beta 2. Very handy.
- Mastering PowerShell in your lunch break -- Awesome!!
-
http://powershelllive.com/blogs/lunch/default.aspx
Highly, highly recommended.
- Great MOSS 2007 Search Blog
-
http://blogs.msdn.com/miketag/
Enough said.
- Krzysztof Cwalina on Framework Design
-
Krzysztof has been recorded for MS Research and gives an excellent presentation on framework design. The details are on his blog. Lots of great notes. His book on the same subject was well worth the read.
- Invitation to the inaugural Canberra VSTS user group - Jan 24th
-
I’d like to make you aware of the new Canberra Visual Studio Team System user group!
The purpose of the VSTS User Group is to form a community of practice for Canberra-based IT professionals interested in the use of Visual Studio Team System (VSTS) to support the Software Development Lifecycle. The group meetings will not be used to deliver marketing or sales content, but instead will focus on knowledge sharing on effective use of VSTS (tips, tricks, traps).
The inaugural meeting is on Wednesday 24th January at 8:00am to 9:30am
WHERE:
Microsoft Canberra
Level 2, 44 Sydney Ave
Barton
The topics for the first meeting are
· Migrating from VSS to TFS (Andrew Lynes based on experiences at DEWR)
· Source Code Control – Approaches to branching, shelving etc (Sean Ferguson and AFP experiences)
Registration is essential! Please email Grant.Holliday@readify.net
- New Web Service Software Factory released on msdn
-
The second version of the Service Factory (that helps build both ASP.NET and WCF services) has been released on msdn. The download is now available.
For those that don't know, the Web Service Software Factory (also known as the Service Factory) is an integrated collection of tools, patterns, source code and prescriptive guidance. It is designed to help you quickly and consistently construct Web services that adhere to well known architecture and design patterns.
- Visual Studio 2005 Service Pack 1 (SP1)
-
Love the dual core perf :)
Snippet from http://msdn.microsoft.com/vstudio/support/vs2005sp1/default.aspx
"
Visual Studio 2005 Service Pack 1 (SP1)
Visual Studio 2005 represents one of the most significant developer tools releases since the introduction of Visual Studio nearly a decade ago. It offers all types of developers a wider spectrum of development possibilities and a greatly advanced design experience. By expanding the Visual Studio product line to include the Visual Studio Team System and the Visual Studio Express Editions, Visual Studio 2005 delivers a compelling toolset for everyone, from hobbyists to enterprise developer teams.
Visual Studio 2005 Service Pack 1 continues Microsoft’s investment in market leading development tools. Service Pack 1 addresses issues that were found through a combination of customers and partner feedback, as well as internal testing. The issues addressed range in severity from places where the syntax coloring was incorrect to customer reported crashes in various scenarios. In some areas, more than 50% of the bugs addressed were reported by customers through the MSDN Product Feedback Center and Microsoft Connect. Overall, Service Pack 1 offers customers improvements in responsiveness, stability and performance for Visual Studio 2005.
Through further advancement and feedback, Service Pack 1 also provides over 70 improvements for common development scenarios including:
- New processor support (e.g., Core Duo) for code generation and profiling
- Performance and scale improvements in Team Foundation Server
- Team Foundation Server integration with Excel 2007 and Project 2007
- Tool support for occasionally connected devices and SQL Server Compact Edition
- Additional support for project file based Web applications
- Windows Embedded 6.0 platform and tools support
For developers using Visual Studio 2005 on Windows Vista, Microsoft is in current development on an update to Service Pack 1 called the ‘Visual Studio 2005 SP1 Vista Refresh Beta’. This update builds on the improvements made in SP1 and delivers a first class experience for developers wanting to take advantages of the new features in Windows Vista. The Visual Studio 2005 SP1 Update for Windows Vista is expected to ship after the consumer availability of Windows Vista in Q1 of 2007 and is now available in beta.
For more information, see the Microsoft Download Center:
In addition, see the Visual Studio 2005 Service Pack 1 release notes.
"