Monday, November 24, 2008

Backup / Restoring SharePoint 2007 Site from SQL Database

I got this excellent article on SharePointdogs for backup / restoring the SharePoint site from SQL DB :

Here is one of defined approach which worked wonders for me :

Using SQL, Backup the SQL Content Databases which are required and Restore them to a new databases in the SQL and attach these databases to the new application.
(Briefly we can say that take your content db ‘Offline’ using the Central admin. Take the content database offline in SQL Studio (Take Offline context menu item). Copy your database mdf and ldf files to the new machine (the destination machine). Attach the copies on the new SQL server using SQL Studio. Add the copied content DB to the Web Application on the new machine using the Central Admin on the new web server.)
1)Find the content Database
These are listed under Central Admin->Application Management->Site Collection List
2) Backup the content database
You could alternatively detach it, and copy it. Just doing a backup in SQL Server 2005 Management studio is easier.
3) Restore content database to new server
Copy the BAK file to new server. Create an empty DB in Management Studio, restore from backup, you may need to change an option in the “options” tabof the restore dialog to get it to work. (Overwrite db).
4) Create Web App on new Server
Central Admin->Application Management->Create or extend Web App->Create New Web App.
5) Associate restored DB with new Web App
Central Admin->Application Management->
SharePoint Web Application Management->Content Databases->
Remove Content Database from your new web app.
Now use STSADM to add restored DB to this web app
c:\program files\common files\microsoft shared\web server extentions\12\bin on new server is where you can find the STSADM.
run this command from there.
stsadm -o addcontentdb -url http://yourwebapp:port -databasename yourcontentdb -databaseserver yoursqlserver
6) Run ISSRESET from command prompt.

Tuesday, November 11, 2008

Setting RSS Update time limit in SharePoint 2007

My previous blog on RSS ended with a very un-satisfied note as i was still trying to find the way to set the update time for RSS feeds in SharePoint 2007 . I am glad i got it now. It was a setting in Site Collection Level . Here it goes :

  • Go to Site Settings

  • In Site Adminisration Section click on link RSS

  • Set the Time To Live(Minutes) filed with required refresh time

Outlook 2007 RSS feed not updating when Sync with SharePoint 2007 List

I had issue wherein my Outlook 2007 RSS was not updating once new data is added to the SharePoint List. After lot of brain damage it came to my notice that it starts working when i remove the "Update check box " as shown in figure below while adding the New feed.Well i am still working on actual issue and trying to understand how to define content feed publisher time limit.

Tuesday, November 04, 2008

Get Discussion List Items from SharePoint Discussion Forum

If you are trying to retrieve all the root items of the Discussion List this way , it's not going to work :
SPSite site = new SPSite("Site URL");
SPWeb web = site.OpenWeb();
SPList list1 = web.Lists["DiscussionListName"];

SPListItemCollection coll = list1.Items ;

Well Here is the right way of doing it :-)
SPSite site = new SPSite("Site URL");
SPWeb web = site.OpenWeb();
SPList list1 = web.Lists["DiscussionListName"];
SPListItemCollection coll =list1.Folders ;

Gray Failures: What is it and how to detect one?

If you are reading this article , i guess you are curious to know about gray failures and different methods to detect gray failures.  Hopefu...