Troubleshooting SharePoint
Troubleshooting?
The Unified Logging Service
The Unified
Logging Service (ULS) is the service that sends messages to the Windows Event
Logs and to the SharePoint trace logs. Trace logs referred to as the ULS logs
and it is the only place ULS information surfaces.
a) Trace Logs
Trace logs contains only SharePoint-specific information, but much of it
is about normal operations, not specifically errors. By default, the trace logs
are found in
C:\Program Files\Common
Files\Microsoft shared\Web Server Extensions\15\LOGS
The log files themselves have names like SERVERNAME-20121026-1200.log.
2012 – indicating year
10 – for the tenth month
26 – for the 26th day
12 – for the 12th hour
b) Windows Event
Logs
As ULS tends to send messages to the Windows Event logs only when
something serious happens, they are a good place to start looking for clues. To
open the Event Viewer for Windows Server, go to the start panel that has all
the Windows tiles and begin typing Event
Viewer until it appears in the
apps list.
The Correlation ID
They are the GUIDs (A Globally Unique identifier that’s 32
hexadecimal characters long) that sometimes appear when an error occurs.
To get the meat of the error message, you have click the
Technical Details link. When you do, you are rewarded with a Correlation ID as
well as the exact time of the error. Both details can be used to hone in on all
the log events that led up to the error. In this case, you also received an
error message indicating exactly what the problem is, but SharePoint is not
always that generous.
Tools for Troubleshooting
a) Central
Administration
Monitoring->Review Problems and Solutions
b) Log file data
location
C:\Program Files\Common Files\Microsoft Shared\Web Server
Extensions\15\LOGS
c) Event Viewer
Start->Run>eventvwr
Typical SharePoint
error looks like in the Event Viewer when no filters are applied.
Details tab that is displayed
when you double-click on a particular Event Viewer entry
d) ULSLogViewer
¡
Open ULS Viewer (Hit CTRL + U for a
shortcut)
¡
Select File -> Open From ->
ULS
¡
Point to the SharePoint Logs
¡
Refresh the SharePoint page that is
causing the error
¡
Match the error Correlation ID to
the Correlation column in ULS viewer
e) SQL Logs
f) Developer
Dashboard
The Developer Dashboard
can’t be activated from SharePoint Central Administration. Instead, the best
method is to use PowerShell.
To enable the developer
dashboard, open the SharePoint 2013 Management Shell and enter the following
commands:
$devdash = [Microsoft.SharePoint. Administration.SPWebService]::ContentService.DeveloperDashboardSettings
$devdash.DisplayLevel = “On”
$devdash.Update()
To disable the Dashboard
after you are finished using it, simply use the preceding commands but replace
$devdash.DisplayLevel = “On” with $devdash.DisplayLevel = “Off”
You can also use the
following stsadm commandsif you insist on doing things the uncool way:
Stsadm -o setproperty
-pn developer-dashboard -pv on
Stsadm -o setproperty
-pn developer-dashboard -pv off
g) Performance
Monitor
¡
View performance in Real Time and
log data for later analysis.
¡
Open Server Manager
¡
Select Tools
¡
Select Performance Monitor
¡
Right Clock the graph and select Add
counters and begin tracking performance
h) PowerShell
¡
Merge-SPLogFile –Path “c:\error.log”
–correlation “cid”
¡
SPDiagnosticsLog (Get,Set)
¡
Identify the problem
¡
Get-SPLogEvent | ?{$_.Correlation
–eq “CID”} |
¡
Ft EventID,Message | Out-GridView
¡
Filter by Area,EventID,Level,MEssage
Common Solutions
·
Grant
Access to User
ü Set-SPSiteAdministration –OwnerAlias
<contoso>\<userid>
·
Flush
DNS on server to solve network issues.
·
Add
the website to trusted sites
·
Web
Part Error:
ü Web Parts Maintenance Page
[?contents=1]
ü Remove Web/App Part
More Troubleshooting Techniques
As you spend
more time troubleshooting SharePoint, you pick up little techniques here and
there that help you get to the bottom of an issue.
·
Using
Fiddler to Watch your Web Traffic
·
Creating
a New Web Application
·
Making
all your Service Accounts Local Administrators
·
Checking
for failed Timr jobs
·
Starting
Fresh with IISReset
·
Reboots
for Everyone
·
Shoot
Trouble Before it Happens














No comments:
Post a Comment