Wednesday, May 12, 2010

List All SharePoint 2010 Databases

If you're like me you've setup numerous SharePoint 2010 test boxes in order to get comfortable with all the great new features. Because I'm running in a test environment I hadn't been paying too much attention to the SQL server I was using. Yesterday I logged in and found a staggering number of similarly named databases which were no longer being used because the test boxes were done.

So how do you figure out which databases are which? There's a great SharePoint Powershell cmdlet you can run on your SharePoint server that will give you a list of all the databases your server is using:

Get-SPDatabase | Sort-Object disksizerequired -desc | Format-Table Name

When you run the command, you'll get a list of all the databases similar to the following:

Now that you have your list, log into SQL Server Management Studio and delete the corresponding databases:

Get-SPDatabase | Sort-Object disksizerequired -desc | Format-Table Name | out-file c:\databases.txt

You can also see how big the databases are by running the following:

Get-SPDatabase | Sort-Object disksizerequired -desc Format-Table Name, @{Label ="Size in MB"; Expression = {$_.disksizerequired/1024/1024}}

Tuesday, May 11, 2010

Installing the RTM Version of Microsoft Office Web Apps 2010 (OWA)

I recently had a request from my users to test Office Web Apps in our new SharePoint 2010 RTM environment. This feature comes in very handy if you have a number of users who don’t have Microsoft Office 2010 installed on their client computers yet. Most of my users are running legacy versions of Office.

For my test environment, we set apps to open in the client by default (not the browser) so we don't break existing document links in the site collections. You can achieve this by following this procedure.

1. Go to Central Administration and select Site Actions - Site Settings – Site Collection Administration and click on Site Collection Features.

2. Activate the Open Documents in Client Applications by Default feature.

Run the OWA setup

1. Run setup.exe from the root of the OWA installation source, and input your product key.

2. Accept the license agreement and specify an install path and hit Install Now.

When the install finishes, you’ll be prompted to open the Configuration Wizard. Click Next when the Wizard opens and answer yes to the service re-start warning. Let the configuration finish and perform the following steps:

Start the service instances

A service instance provides the physical location for a service application. For each server that you want to run the Office Web Apps service applications; you must start the service instances. You can start the service instances by using SharePoint Central Administration or by using Windows PowerShell.

Procedures in this task will start the service instances on those servers specified. This task must be completed after you have run WCSetup and PSConfig on each server in the farm.

To start the service instances by using Central Administration

1. Click Start, point to All Programs, Microsoft SharePoint 2010 Products, and then SharePoint 2010 Central Administration.

2. On the SharePoint Central Administration home page, in System Settings, click Manage services on this server.

3. On the Services on server:page, in Server, select a server, and then start Excel Calculation Services, Word Viewing Service, and PowerPoint Service. Repeat this step for each server in the farm you want to run Office Web Apps services. The OneNote Web App does not use a SharePoint service.

Now to test.

Upload an Office document into a document library and select the drop down menu:

When you select "Edit in Browser", the web app version of Word will open and you're free to edit your document.

Try it out for yourself and let me know how it works for you!