Featured Posts

  • How to recreate SharePoint 2010’s User Profile Service Application without losing all that delicious data

    Body: There comes a time in every SharePoint 2010 admin’s life when they must make a choice. Continue to be pushed around by that bully the User Profile Service Application (UPA) , or fight back, give it a bloody nose and show it who’s boss. Today’s blog post is about the latter. At various times the UPA gets fuzz in its head and won’t behave. When that’s the case, you can often fix the issue by blowing the UPA away and recreating it. When you do that you lose all your existing profile information. If your profile information consists entirely of information pulled from Active Directory then it’s no big loss. That’s not the case with most farms though. Users have augmented their profile information with pictures or other information, and there’s also the whole social aspect. The UPA stores all the tags and notes and activities. You don’t want to lose that. When things go missing in SharePoint, users lose faith in the platform. We don’t want that. This blog post will walk you through how...
  • Moving SharePoint to a different SQL server

    Body: This question seems to come up from time to time, so I decided to write a blog post on it. Yeah, I know there are other blog posts on the process, but none of them have the finish or flair of a Todd Klindt blog post so here we go. The reasons for doing this are many, but the problem boils down to this, “How do I move the databases SharePoint uses without seriously pissing it off?” This could be because you have SharePoint and SQL on the same machine and you need to split SQL out. It could be because your current SQL server is underpowered and you want to move it to a more capable server. Or, it could be because your existing SQL server is 32 bit, and you need a 64 bit instance for SharePoint 2010, and probably an upgrade to a newer version too. At the core these are all the same tasks. Now, how hard is it? Turns out, if you have the right tools it’s pretty simple. So simple even I can do it. Here are the basic steps to move from SQL A to SQL B: Stop any processes that might be accessing...
  • Using Web Analytics in SharePoint 2010

    Body: The topic of Web Analytics has come up a couple of times in the last month, so I thought I’d jot down a few notes about it to get you guys all excited about it. Here I go. First, what is Web Analytics? Much like it sounds, it’s a way to analyze web traffic. There are many 3rd party products that provide this service. In this blog post I’ll be discussing solely the Web Analytics functionality that comes with SharePoint 2010. It is a service application that provides analytical information about your web applications. It provides the same kind of information as the SharePoint 2007 Usage reports. It also gives you insight on how Search is working, or not working. It also gives you inventory information like amount of space used per site collection, and the number of subwebs a site collection or web has. The information is invaluable and it’s free to use as long as you have Search Server or SharePoint server. Unfortunately this is one of the service applications that is not included with...
  • How to delete a large list in SharePoint 2010

    Body: As is often the case, my PowerShell boundaries were expanded because of a question from a coworker. This week Laura had a document library that had over 7000 files and she needed to delete it. Unfortunately it had blown long past the large list throttling limit. When she tried to delete it in the interface she was greeted with this very unfriendly page: There are a few ways to deal with that, but she asked for a PowerShell way and who was I to say no? She could have gone into Central Admin and tweaked the throttling settings. She could have also logged into the site collection as the farm account. SharePoint will let you delete it that way too. But she wanted PowerShell, so by god I gave her PowerShell. But first, let’s reproduce the large list, using PowerShell of course. Use the following PowerShell to create a list and add column to it: $web = Get-SPWeb http://sharepoint/sites/team $lists = $web.Lists $lists.add("Gordo","Mucho Grande", "GenericList"...
  • Using PowerShell to find site collection size in SharePoint 2010

    Body: Today on Twitter I received a message from Nik Patel : “How would I determine the site collection size using powershell? I am sure you have figured it out.. ;)” As luck would have it, I had. The good news is that PowerShell exposes that information pretty easily. Even an admin like myself can figure it out. Let’s walk through how I put this all together. First I set a variable to a site collection so that I could take a look at the properties that were exposed. $sc = get-spsite http://sharepoint $sc | get-member From here I saw the Usage property. That looks promising. executed $sc.usage did give me the storage used by a site collection, but it looked a bit more complicated: PS C:\> $sc.Usage Storage : 9621220 Bandwidth : 0 Visits : 0 Hits : 0 DiscussionStorage : 0 I only wanted the storage usage, so I needed a good way to pull all that out. Plus I needed it for all the site collections, not just one. That lead me to this line: Get-SPSite | select url, @{label="Size in MB";Expression...
  • Service Account Suggestions for SharePoint 2010

    Body: During our daylong Admin session at SPTechCon , the question came up about what service accounts we thought people should be using with SharePoint 2010. I promised I’d blog the recommendations that we made. Here is the table I put up. Account name Role Domain rights Local SharePoint Server rights needed SQL rights needed sp_install Used to install SharePoint binaries. Domain User Local administrator on all SharePoint boxes dbcreator and securityadmin SQL roles sp_farm Farm account. Used for Windows Timer Service, Central Admin and User Profile serve Domain User Local Admin during UPS provisioning, log on locally right None sp_webappapp App pool id for content web apps Domain User None None sp_serviceapps Service app pool id Domain User None None, unless using Office Web Apps. Them must give access to content databases manually sp_search Search process id Domain User None None sp_content Account used to crawl content Domain User None None sp_userprofile 1 Account used by the User Profile...
  • How to use PowerShell to set the Master Page in SharePoint 2010

    Body: A couple of months ago Randy Drisgill asked me if there was a way to use the mighty PowerShell to set a web's master page in SharePoint 2010. Not being a branding guy I hadn't tried it before. Heck, I'm not even sure what a master page is, but for Randy I dug into it. The master page setting is scoped at the web level, so the first thing I did was use Get-SPWeb to get a variable for the web I want to change. There are two properties that control the master page settings; MasterUrl and CustomMasterUrl. The former controls the master page used to render the System pages (the ones that start with /_layouts) and the latter controls the master page used to render the content pages. This picture helps explain it better: To alter those settings for a publishing site at http://sharepoint , use the following PowerShell script: $web = Get-SPWeb http://sharepoint $web.CustomMasterUrl = "/_catalogs/masterpage/nightandday.master" $web.MasterUrl = "/_catalogs/masterpage...
  • Event ID 6801 “Invalid URI” with User Profile Service on SharePoint 2010

    Body: In the continuing saga of the User Profile Service (UPS) kicking my butt, I have a heartwarming tale of one victory I can claim. It involves Event ID 6801 "Invalid URI: A port was expected because of there is a colon (':') present but the port could not be parsed." and me besting the User Profile Service. Don't believe me? Well, here's my tale… It was the best of times; it was the worst of times. I was getting a handle on the UPS, but it threw another error at me. A customer contacted us. The UPS refused to sync on their farm. It had never worked. I looked in the Application log and saw a string of Event ID 6801s and 6803s. The 6801s included the text "Invalid URI: A port was expected because of there is a colon (':') present but the port could not be parsed." The 6803s were just saying that portion of the sync failed. A normal profile sync has 10 steps. Some pull from AD, some from SharePoint, some push, and so on. The initial AD import...
  • SharePoint 2010 SP1 Install Error: An unhandled exception (‘System.Security.Cryptography.CryptographicException’) occurred in OWSTIMER.EXE [3004]

    When you are installing SharePoint 2010 Service Pack 1 (SP1), you might encounter the following error multiple times during the installation. An unhandled exception (‘System.Security.Cryptography.CryptographicException’) occurred in OWSTIMER.EXE [3004...
    Posted to Dot Net Mafia by Dot Net Mafia on 07-07-2011
  • Getting rid of GUIDs in SharePoint 2010 database names

    It is like your typical battle of good vs. evil. SharePoint 2010 has a secret plot to run the world out of GUIDs and between you and me I think it has a good shot of accomplishing its goal. Well, me and boy wonder (aka Todd ) have seen the pain and suffering they are trying to evoke and we have plan to stop it. Creating blog posts to remove as many of the GUIDs as possible. "But dynamic duo who cares if the world runs out of GUIDs?" Well, to be honest the people it scares the most are the poor developers. And while we generally consider developers second class citizens that doesn't mean we wish them harm. And let's face it, if they didn't have GUIDs they would have nothing to do. And we all know bored developers will wander the halls of your office building aimlessly. Or worse they will congregate in places like the break room and will want to make small talk with you when you go to get an afternoon Mt. Dew. I don't know about you, but nothing ruins my day worse...
  • Setting a SharePoint 2010 Config DB failover server with PowerShell

    Body: One of the great new improvements in SharePoint 2010 is native support for SQL mirroring and automatic failover. In SharePoint 2007 you had to use some complicated SQL aliases to provide failover support. SharePoint 2010 has built in support for database mirrors, and allows you to define a failover SQL server for any databases you have mirrored. You can mirror one database, you can mirror several, it's all up to you. You can do this with content databases or service application databases. To take advantage of this simply add the instance name of the SQL server where the mirror of your database is in the settings for the database, like below: You will have to configure the database mirroring independent of SharePoint. SharePoint does not configure the mirroring in SQL for you. SharePoint will however verify the instance you specify is valid. With your new found knowledge you'll probably start running through your SharePoint farm mirroring all your databases. You'll find...
  • Creating a Site Collection with a custom Site Template

    Body: One of my coworkers, John Ross , recently asked me if it was possible to create a new Site Collection in SharePoint 2010 and use a custom site template for it. I'm usually more of a server and infrastructure guy, but this made me curious. In SharePoint 2007 site (really web) templates were saved as .STP files. Those STP files could be in the site collection gallery, or the farm gallery. If it was in the farm gallery then it was available at site collection creation. In SharePoint 2010 site (really web) templates are stored as user solutions in the site collection solution store as WSP files. Those WSP files don't upload at the farm level (at least not that I've been able to find). So how does one create a new site collection with a custom template? Stick around, we're going to find out. J The first thing to keep in mind is that site collections don't have templates, webs do. When a new site collection is created there is a template picker. That doesn't apply...
  • Self Service Site Creation and custom site templates in SharePoint 2010

    Body: A couple of months ago I wrote a blog post on how to create a site collection with a custom Site Template. At the time I hadn’t figured out how to add a template at the farm level, as the process has changed from SharePoint 2007. In this blog post I will show how to add the custom site template to the farm, and for extra credit I’ll show you the nasty process needed to use a custom site template with a new site collection. To start our journey, read over my blog post Creating a Site Collection with a custom Site Template . If you haven’t already created a site template, go ahead and do so. You don’t have to do it all, just go through the part where you save the file Secret.wsp to your file system. Now, instead of copying up to a Solution Gallery, we’re going to upload it to the entire farm. To do that, open up the SharePoint Management Shell. As with any Solution, we need to add it to the farm with Add-SPSolution and then deploy it with Install-SPSolution. It should look like this...
  • Getting the GUID out of the AdminContent database in SharePoint 2010

    Body: One of my more popular blog posts is about getting rid of the GUID at the end of SharePoint 2007 central admin content database. DBAs world round sang my praises. There were statues put up in my honor, and babies, boy and girl alike, were named in my honor. It was a good day. Then SharePoint 2010 came out. If you think SharePoint 2007 liked its GUIDs, wait until you install SharePoint 2010. In Shane and I's continuing quest to rid the world of GUIDs Shane recently posted a blog post on how to get the GUIDs out of your Search Service Application. It's too soon to see if it will take the world by storm or not. Not to be outdone, I'm writing this blog post to show how to fix the central admin content database the SharePoint 2010 way. Sit back, put your seatbelts on, and keep your arms and legs inside the ride at all times, it's gonna get crazy in here for a few minutes. First, let's identify the enemy. Here it is in its natural habitat: Oh my, look at all those GUIDs...
  • Workflow to automatically approve my comments

    Body: As you can imagine, a top-notch web site like mine gets a lot of traffic. Sometimes those people leave me comments. Usually to tell me I’ve typoed the name of a Netcast, or that I’m flat out wrong about something. The important thing is that they care enough to leave comments. There is another, darker, evil group of people that leave comments on my blog. Spammers. We hate them. To discourage spammers from leaving comments on my blog I’ve taken two steps. First, I require a valid date to be entered for a comment to go through. Second, I require each comment be lovingly approved by yours truly before it shows up. That way if a spam comment sneaks through I can delete it before it shows up. It also gives me the opportunity to edit out any unflattering things that might accidently get submitted. Together I think these do a pretty good job of keeping the riff-raff out. There is one downside to all these hoops, when I submit my own comments in reply to other comments I have to approve them...
1 2 3 4 5 Next > ... Last »
Idera SharePoint Reviews SMBology, Inc. Rackspace Hosting Sponsored by Idera and SharePoint Reviews and SMBology and EPCGroup.net
Copyright 2011 SecretsOfSharePoint.com. All rights reserved.