Friday, May 23, 2014

SharePoint 2013 Search Errors and Permission Settings

Configuring Search in SharePoint 2013 can be a tricky process that is best accomplished via PowerShell scripts. For starters, those messy database names with GUID's in them that get created from UI provisioning are just hideous, but the real issue is that a proper topology (meaning search components running on more than a single machine) can only be deployed via PowerShell cmdlets. Despite our best efforts to script the entire process and avoid the kind of small mistakes that lead to endless hours of frustration, it's inevitable that some small setting or configuration step will crop up that creates a giant headache.

Take, for example, the new "SPSearchDBAdmin" role. This role, which didn't exist in 2010, is added to each search database when it is created in SQL server. If you are following best practices and assigning service accounts for search operations (one for administration, one for crawling, and neither should be the SharePoint Farm or Admin accounts), the account you assign as the Search admin will be added to the SQL logins and given the "public" role. That's all well and good for least privileged purposes but that role alone is insufficient for the Search application to function. Unfortunately, there's no warning about this when the Search service application is created – provisioning will succeed but nothing really works. In order to kick Search into gear, you first need to assign the "SPSearchDBAdmin" role to the Search admin account in SQL server.

The SPSearchDBAdmin role in SQL Server
Assigning the SPSearchDBAdmin Role in SQL Server Management Studio
Also bear in mind that the Search admin account requires read/write permissions to the folder in which the index files reside. As this account should *not* be a local administrator it's very likely that it won't have access to the folders that hold the primary and replica index files. Be sure to assign the appropriate permissions on each server in the topology which contains an index partition (the default location is "C:\Program Files\Microsoft Office Servers\15.0\Data\Office Server\Applications" which, ideally, should be changed as part of the provisioning process). Possible error messages which indicate your search admin account may not have the correct SQL or folder permissions include:

"Content Plugin can not be initialized - list of CSS addresses is not set."
"Unable to retrieve topology component health states. This may be because the admin component is not up and running"
"Topology activation failed. No system manager locations set, search application might not be ready yet"
"Could not access the Search database. A generic error occurred while trying to access the database to obtain the schema version info."

There are a lot of blogs, forum posts, and articles with all sorts of advice on how to deal with these errors, most of which prescribe repetitive un-provisioning and re-provisioning of service applications. Although those solutions may apply to your environment at some point, before going down that road first ensure that the Search admin account has the proper database and file permissions, as no amount of provisioning will overcome basic security limitations.

(Note: For a good walkthrough on Search provisioning via powershell, refer to this post from Ryan Bushnell and the Search cmdlet reference on TechNet)

 
Take the trouble out of troubleshooting.  
Improve service levels and avoid downtime with
SmartTrack Operational Analytics for SharePoint
 


Articles

Ten Steps to Optimize SharePoint Performance by Eric Alan Shupps


Webcasts

Eric Shupps - Secrets of SharePoint Part 5: Configuring Microsoft Office SharePoint Server 2007 for Optimal Performance
Creating End User SharePoint Solutions for Performance and Scalability by Eric A. Shupps
SharePoint 2010 Performance Enhancements for Administrators with Eric Shupps
Microsoft SharePoint Server 2010 for the ASP.NET Developer
Eric Shupps on Following Best Practices and Avoiding Common Errors with Microsoft Office SharePoint Server 2007 Development
SharePoint Performance and Capacity Planning Essentials from Eric Alan Shupps
Eric Shupps on Troubleshooting Common Performance Problems in SharePoint 2010


Videos

Channel 9 Interview with Eric Shupps
SharePoint TechTalk - Different Views on Social Computing
Eric Alan Shupps talks SharePoint Post-Deployment Planning and Management


Podcasts

SharePoint Pod Show - Design for Performance eith Eric Shupps
SharePoint Pod Show - Test Driven Development with Eric Shupps
Run As Radio - Eric Shupps Improves SharePoint Performance


Social

Eric Shupps - ConferenceHound
Eric Shupps on Talk TechNet
Eric Alan Shupps on Channel 9
Planet SharePoint Eric Shupps profile
Eric Shupps Lanyrd
Eric Shupps MVP Profile
Eric Alan Shupps About.me
The SharePoint Cowboy Tumblr
Eric Shupps on Speakerfile
Eric Shupps - Facebook
Eric Shupps LinkedIn Profile
Eric Shupps Google+
Twitter - @eshupps


Tuesday, January 14, 2014

Confessions of a Recovering Windows Phone User

After two years on the Windows Phone platform, I switched back to IOS to see how things had changed and what the Microsoft mobile ecosystem might be missing.  Here are my random observations so far, in no particular order or priority.

[Before the Android fans chime in, I absolutely will not trust Google with any of my personal communications, so don't waste time trying to convince me - it won't do you any good.  Just move along, nothing for you here.]

  • The only real innovation that Windows Phone introduces is the UI.  Everything else falls far behind the competition.  Don't get me wrong, the UI is hands down the best mobile experience IMO - it makes IOS look like a Palm Pilot circa 1999.  But that's where it ends.  There are so many little things missing, simple stuff that more mature platforms already have, that Microsoft will probably never catch up without doubling or tripling the size of their core development teams.  And that's what is needed just to keep pace - jumping ahead seems totally impossible at this point.

  • The predictive text typing experience in IOS is simply archaic.  Really, Apple, one choice and that's it?  But then that pretty much sums up the entire Apple experience, doesn't it?

  • Microsoft really needs to figure out their device specification story (CPU + Memory).  The iPhone 5S is blazing fast compared to all the latest WP devices.  Apps pop open, screen transitions are snappy, pages render quickly - none of which happened on any of the Windows Phones I tried.  The whole OS just feels sluggish.  I know a lot of that is the underlying app framework - believe me, I've been writing XAML code for years now and it can sometimes be excruciating even on the desktop - but perception is reality and it just feels like everything takes longer than it should.

  • Xbox music sucks.  In every way imaginable.  It's not like iTunes is so great - it's not - but XBOX music really is terrible.  Zune was and still is the best music app - why can't we get that experience on our phones/tablets?  It's not like they don't already have the code!  Get a grip and get it right.

  • The IOS email client may just be worse than XBOX music and that's saying a lot.  I stuck with WP because of email and it's almost enough to make me want to go back.  OWA on iPhone is OK but not the same as an integrated email app.  Apple obviously has no clue how real enterprise email works.

  • The app ecosystem is where it's at and Apple simply owns the appverse.  If Microsoft wants to have a prayer in mobile they'd better start doing anything and everything to get more apps.  And don't tell me that all the apps for IOS are junk.  That's a cop out - sure there's a lot of crap but there's so much quality stuff available it's frightening.  Even the crossover apps are better on IOS (like Facebook and Twitter just to name a couple).  Part of the problem here is the horribly fractured development story for phone and tablet, requiring completely different code for the two platforms.   As a Windows developer, I can attest that this is a real PITA; in IOS  I need only worry about screen size and some device functions but for my native platform I have three separate solutions (Windows 8, Windows 8 ARM, and Windows Phone) requiring different emulators, with different capabilities and using different sets of reference assemblies with varying  degrees of functionality.  It's maddening.  Microsoft has got to figure out a "write once, run anywhere" strategy and they need to do it fast.  But I fear it's probably already too late.

  • I had forgotten what a tremendous aftermarket there is for iPhone accessories.  There were maybe five cases for my HTC 8x and that was it.  Having an iPhone is like getting a never ending set of Legos - you just keep snapping things on until you are happy for a while then you tear it apart and start over.  Perhaps a reduction in the number of form factors would help Windows Phone in this regard (maybe Microsoft becomes the sole hardware manufacturer) but I don't see how anyone ever gets close to the sheer volume of iGadgets. 

  • One of the most refreshing aspects of being back on IOS is the unified messaging and video experience.  I travel internationally on a regular basis so staying in touch with the family is of utmost importance.  On IOS, FaceTime and iMesaage are baked in as native apps.  Even better, the messaging app automatically uses the free Apple service when the recipient is also on an IOS device.  That saves a ton on SMS charges - and if you think that's peanuts then you don't get out of the country very often.  On Windows Phone there's Skype which, honestly, just isn't anywhere close.  It's buggy, crashes often, doesn't sync messages across platforms reliably, and isn't integrated into the core OS.  I don't want a separate app for messaging that's separate from all my other messages - I want it all to be integrated with no thought required on my part.  Oh, and FaceTime rarely, if ever, crashes or fails to login.  Skype?  Um, yeah…

  • I know SkyDrive takes a lot of knocks but I rather like it and I wish it were integrated into my iPhone like it was on my Windows Phone.  Sure, the SkyDrive IOS app is OK but it was better on the native platform.  iCloud just isn't my style. AirDrop is an entirely different matter - it works great (so long as other iPhone users are the ones you want to share with) and SkyDrive could use a similar feature that makes it dead easy to share stuff without going through the invitation email process.  Yeah, I know Windows Phone has NFC tap and send but AirDrop just feels more natural and has the advantage of being able to connect to non-mobile devices (granted, they have to be Macs, so that's a big negative).  I suppose it's a wash but maybe some tweaks to SkyDrive could give Microsoft a leg up here. 

  • Apple made a huge blunder with their less-than-impressive maps application but even that is better than the horrible atrocity that is maps on Windows Phone.  A blind mule with a broken compass has more of a chance of finding an address than a Windows Phone user.  And trying to search for places within the maps app?  Just forget about it - the closest thing to you will always be "No results found".  Whip out your ten pound blue Nokia brick and try to find a location when you're anywhere an iPhone user and they will literally laugh until they can't breathe - not that you'll be able to hear them as they'll already have arrived at their destination (and found all the swank places to eat, booked a reservation, and ordered appetizers).  Of course, Apple can't do too much of a victory dance as I'm pretty sure the first app every iPhone user installs and anchors to the home screen is Google Maps but at least Siri can actually find stuff around you when you ask her nicely.  Which brings me to another big problem...

  • Voice control.  Wow, did Microsoft miss the boat on this one.  Apple is on their third iteration of this feature and Windows Phone still doesn't have anything comparable.  The built-in voice commands are a complete joke - it's impossible to even send "on my way" via SMS because you'll never even get it to find the right contact in the first place.  If it responds at all, that is, which is rare.  This isn't a make-or-break feature for me but it's handy when you're driving or walking around and don't want to break your neck while thumbing.  Siri isn't perfect by any means but she sure does run rings around anything Windows Phone can do.  I've read a few rumors that Microsoft is working on this but again that just brings them up to some level of parity - it doesn't move the needle towards "Awesome".

  • I thought I would miss Live Tiles but I don't.  Most apps don't really take advantage of them anyway and the ones that do are mostly just annoying.  The auto power saving feature when the battery reached a certain level was nice, and the low light mode was killer for discreetly checking messages in a movie theater, but what I really miss is the lock screen status icons.  I like being able to tell how many emails and messages there are without having to swipe but since Windows Phone completely lacks anything even approaching a notification center or control center the productivity advantage still resides with Apple (and yes, I know there are tweaks for jailbroken phones that allow the lock screen to be customized).  

  • Wow, is IOS 7 ugly.  I mean make-a-train-take-a-dirt-road F-U-G-L-Y.  As I mentioned at the outset, Microsoft scored a big win with Metro/Modern UI/Whatever The Heck We're Supposed to Call It interface and Apple hasn't figured out how to change their aesthetic in a similar fashion.  IOS 7 is a half-hearted attempt at keeping up and it shows - the unified visual theme from previous versions is now just a haphazard mess of melted crayons and disjointed fonts.  It makes my eyes hurt.  At least on a Windows Phone all the necessary commands were down at the bottom of the screen or hiding behind an ellipsis.  I can't even count how many times I've tried to press and hold an app icon in IOS trying to get to a context menu, or hunted for a back arrow, "Add" button, or some other basic navigational element which used to be easy to find.  Here's a big hint for Apple and all IOS app developers: we all use our thumbs on a phone.  Stop putting navigation elements at the top where they are hard to reach.  Put them at the bottom so they are actually within range of the digits we're using to interact with the device.  Time for all those pretentious design mavens in Cupertino to go back to the drawing board and come up with something entirely new - 'cause this is just embarrassing.    
   
One final thought.  The Microsoft culture encourages product managers to think small by constantly evaluating features using the dollar method ("you only have a dollar to spend so what are you going to spend it on and what are you going to cut?").  This puts the focus on getting lots of small, relatively unimportant features into the spec at the expense of big, earth-shattering features that burn the entire budget.  It's an approach that completely stifles innovation - you can't leapfrog the competition when you're constantly working under such contrived constraints. 

What the guys earning the big paychecks in Redmond really need to ask is this: Do we want to win this market?  If the answer is yes, then throw out the feature cutting exercises, put "whatever it takes" into the budget line item, and innovate until the competition screams for mercy.  It's too late for incremental improvements - you've got to go big or go home.  And no more excuses about cost cutting or politics or OEM's or anything else. Either mobile is important or it's not - make a decision. Because right now you're getting your butt kicked and it isn't going to change until the current play book gets thrown out the window and a new one is written from scratch.  Talking about how much your own captive market grew year over year when you're in a very distant third place isn't exactly a rallying cry for victory.  For Pete's sake, after several years and billions of dollars invested Windows Phone is still only a few points ahead of BlackBerry in market share and they're dropping faster than the mercury during a polar vortex. Even Charlie Sheen knows that's not the definition of "Winning!".

At the end of the day, I'm a Microsoft guy and I want them to succeed.  I tried really hard to stick with their mobile offering but I grew tired of waiting for them to deliver the goods.  I'd happily switch back if they can knock my socks off with a future release.  I really don't want the ghost of Steve Jobs dictating what I want, when I'm going to get it and how much I'm supposed to like it.  But whether we like it or not Apple is setting the pace in this market and I just don't have high hopes that the situation will change anytime soon.

(This post was thumbed on an iPhone 5S.  Now my thumbs hurt and I'm depressed.  Siri says I need a drink.  And now that I have become an Apple drone I must do what Siri tells me...)