2016 01 08 introduction to performance optimization for sharepoint and office 365

60
08. – 09. Januar 2016 in Köln

Upload: patrick-guimonet

Post on 24-Jan-2017

7.674 views

Category:

Technology


0 download

TRANSCRIPT

08. – 09. Januar 2016 in Köln

3

Office Servers and Services

MVP ( for the 6th time)

Microsoft Regional Director

Hi, I’m Patrick.

Paris, France

Enterprise Solutions

Architect at Abalon

International French

speaking community @patricg

Bloggerhttps://yos365. wordpress.com

Designed by Gokan Ozcifci

[email protected]

Hi, I’m Gokan.

Brussels, BELGIUM neoxy.be

Most Valuable

Professional

Community Member @GokanOzcifci http://gokan.ms

SharePoint on-premises Performances

Find this session and all others here:https://docs.com/gokanozcifci

[email protected]

According to Microsoft: there are a few methods availableto minimize the amount of downtime; however it’s just notpossible to achieve a zero downtime solution for yourupgrade. A common way to minimize downtime is viaimplementation of a parallel upgrade farm.

« should be possible

with #SP2016 »

I’ve the best topologie…

[email protected]

Click, Next, Next, I Agree, Finish…

• This is the non IT-PRO ideology

• But it’s up to you to manage all components

[email protected]

Windows Server | Performance

Windows Server performance options

Computer > Properties > Advanced system settings > Performance > Settings > Visual Effects

[email protected]

Windows Server | Page File

Determine page file size

Factor 1,5 of the server RAM. Ex:

8192 MB RAM x 1,5 = 12288 MB pagefile

[email protected]

Windows Server | Power Options

Use the proper power plan | High Performance

Start > Control Panel > Power Options

[email protected]

System, Log and Index files:

C:\

G:\

H:\

Reduce Disk I/O

System

Index

Logs

[email protected]

Latency between servers should be less than 1ms

Host all the servers in the same datacenter. /!\ If the datacenter has a problem, your SharePoint farm can be down /!\

Use a real Load Balancer

N+1

Importance of a Load Balancer

[email protected]

SQL Server Collation

Dedicated SQL Server

For optimal performance when operating server farms, we recommend that you install SQL

Server 2008 R2 with SP1 and SQL Server 2012 on a dedicated server that is not running otherroles of farm and n 'not host databases for other

Collation: Latin1_General_CI_AS_KS_WS

[email protected]

SQL Server NTFS

NTFS Allocation Unit Size: 64KSQL reads and writes 64K at a time, but your disk allows only 4K by default. This change alone may show you up to 30% improvement in speed.

• Cannot be changed after wise.

• Format disk is necessary.

• “chkdsk [DRIVE]”.

• Move the LDF and MDFs to another drive.

[email protected]

Set min. and max. Server/!\ Total amount memory x 0,80 /!\ The default value of SQL Server for Maximum Memory is : 2147483647 MB

Maximum fill factor per index (80%)

Activate backup compressionIt’s faster and needs less disks space

Max Degree of Parallelism (MAXDOP) = 1Prerequisite for SharePoint 2013

SQL Server options

[email protected]

Web Application tier

• Set Quotas on all Web Applications

• Disable Certificate Revocation List

• AuthenticationAnonymous, Claims, Kerberos, NTLM, Forms, ADFS

• Wake-Up• Scripts, WAF F5, AppDynamics

• Only extend if you have a different authentication protocol.

200 GB

Fastest to slowest

Limitation of Application Pools

[email protected]

Web Application Tier

• Content Databases shouldn’t be more than 200GBBackup / Restore

Operational tasks5000 Site collections per Content Database

• 10 Application Pools (can be extended depending hardware)

• 20 web Applications per SharePoint Farm

[email protected]

SharePoint Server

Distribute the load on multiple crawl servers

Throttle crawling, adjust crawling schedule

Know the limitations of continuous crawl

Content Crawling

• Group by

• Crawl outside business hours

• Days & Weekends

[email protected]

Resource Requirements

Component CPU Network Disk Memory

Search administration * * *

Crawler ** *** *** **

Content processing (CPC) *** ** ***

Analytics processing (APC) ** *** * **

Index *** ** *** ***

Query processing (QPC) * ** *

[email protected]

Components Placement

Search is the most resource intensive SharePoint service

What we do is:

• CPC & APC

• Admin & Crawl

• Index & Query

Together on one server

Together on second server

Together on third server

[email protected]

Performance Level Explained

Reduced

PartlyReduced

Maximum

By default

Total number of threads

= 16 times the number

of processors

Set-SPEnterpriseSearchService -PerformanceLevel Reduced

Total number of threads = number of processors

Total number of threads = 4 times the number of processors

[email protected]

Take advantage of caching

Distributed cache

Object cache

Output cache

Blob cache

provides caching functionality to features (Authentication,

Page Load…)

Is used internally store properties of sites, page layouts, and

pages. reduces the amount of traffic between the WFE and

SQL

Stores rendered output of all controls on a given page, and it

also stores several different versions of this pre-rendered

page.

Disk-based cache that stores files that are used by web pages

to help them load quickly in the browser, and reduces the

load on the database server when it uses those files.

[email protected]

Logical decomposition

Stop unnecessary services

Separate user and database traffic

Create a Maintenance Plan

IIS compression

Try to minimize customisation

Between 0 and 10

Index degrafmentation

2 NICs

[email protected]

Antivirus Check your Real time

scan &

Exclusions = /15

Drive:\Program Files\Common Files\Microsoft Shared\Web Server Extensions

Drive:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\15\Logs

Drive:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\15\Data\Applications

[email protected]

Using BranchCache to optimize WAN performanceBranchCache is a feature of the Windows 7, 8, Windows Server 2008 R2 and 2012

Valuable in a geographically distributed SharePoint Server 2013 environment

• OneDrive for Business, OneNote, Word, Excel, Visio, PowerPoint

F(x) = Every time a branch office user requests a cached file from SharePoint Server 2013, BranchCache checks to

see if a more recent file exists on the server. If not, BranchCache will serve the cached version of the file.

Will optimize WAN performance by caching large files

[email protected]

SharePoint Health Score and Throttling

Health Score Between 0 and 10, where 0 is the healthiest value

[email protected]

SharePoint Health Score and Throttling

Health Score

Every HTTP Request, creates a threat and every threat

calculates the value within the 5 seconds

Between 0 and 10, where 0 is the healthiest value

[email protected]

SharePoint Health Score and Throttling

Health Score

Every HTTP Request, creates a threat and every threat

calculates the value within the 5 seconds

Get-SPWebApplicationHttpThrottlingMonitor

11 Buckets

Between 0 and 10, where 0 is the healthiest value

Between 0 and 10

[email protected]

SharePoint Health Score and Throttling

Add a new category

Add an array of buckets

[email protected]

SharePoint Health Score and Throttling

You can enable/disable the throttling via CA

If the server can’t handle the requests

[email protected]

The top 5 performance killers are:

Indexing and crawling

SQL / SharePoint Backup

Full Profile import

Backend Applications

Storage state

After Business hours if possible

After Business hours

Before Business Hours and once

To be monitored

Everything is behind the NAS/SAN

Office 365 Performances

Find this session and all others here:http://fr.slideshare.net/Patricg

Helsinki Airport, Finnair Airbus A330-300 OH-LTU arriving from Bangkok as AY89.

Infrastructure should

be configured

following best

practices and fully

tuned

Application code and

logic should always

be checked, and

optimized – this is

where we can find the

greatest improvements

Local network access is

usually not an issue

even if its configuration

is sub-optimal

Infrastructure is fully

tuned and

optimized by

Microsoft

Application code and

logic should always

be checked, and

optimized – this is

where we can find the

greatest improvements

Network access is

critical and should

be checked, and

optimized if

necessary

Microsoft perspectiveSource: MVA Course – Office 365 Performance management

Internet Service

providers

networks

Server

workloads

Rich client

applications

Microsoft network +

edge nodes peering

and routing

Corporate

Internal

network

Internet

egress

point

Office 365

endpoint

Content

delivery

network (CDN)

Public

DNS

Microsoft internal worldwide network is one of the top 3 in the world with public peering in 23 countries with over 2000 ISPs.

Multi-terabits of capacity.

Data transfers using that network is much better than through the Internet.

7

14

51

4 5

16

0

10

20

30

40

50

60

6 MB file 10 MB file 42 Mb file

Upload time to an Office 365

tenant based in Dublin

From a Stockholm PC From an Azure WM

Test 2 : From a VM

hosted in Azure North

Europe Region

Test 1 : From a PC in

Stockholm

• http://azurespeedtest.azurewebsites.net

• http://www.azurespeed.com

• ping <your tenant name>.sharepoint.com

• psping -n 20 <your name>.sharepoint.com:443

• tracert -4 <your name>.sharepoint.com

• Priasoft Office 365 endpoint testing tool

http://www.microsoft.com/online/legal/v2/en-us/MOS_PTC_Geo_Boundaries.htm

Site data is published at http://www.peeringdb.com/view.php?asn=8075

Some cities have multiple peering points

Peering locations may be on-net or off-net

Peering may involve physical connection and/or routing advertisements

Data as of July 2014 is subject to change

Brisbane Australia

Melbourne Australia

Perth Australia

Sydney Australia

Vienna Austria

Luxembourg Luxembourg

Sao Paulo Brazil

Montreal Canada

Toronto Canada

Prague Czechoslovakia

Paris France

Frankfurt Germany

Hong Kong Hong Kong

Dublin Ireland

Milan Italy

Turin Italy

Tokyo Japan

Seoul Korea

Kuala Lumpur Malaysia

Amsterdam Netherlands

Auckland New Zealand

Wellington New Zealand

Moscow Russia

Singapore Singapore

Stockholm Sweden

Zurich Switzerland

Taipei Taiwan

London UK

Ashburn USA

Atlanta USA

Boston USA

Chicago USA

Dallas USA

Denver USA

Honolulu USA

Las Vegas USA

Los Angeles USA

Miami USA

New York USA

Palo Alto USA

San Jose USA

Seattle USA

Ignite 2015 BRK 2161

http://www.priasoft.com/solutions/office_365_endpoint_testing_tool/

Ignite 2015 BRK 2161

This topic lists current Microsoft Azure CDN point of presence (POP) locations.

https://azure.microsoft.com/en-us/documentation/articles/cdn-pop-locations/

From support.office.com/en-us/article/Client-connectivity...

The SharePoint wayThe Exchange way

From ExpressRoute partners and peering locations

• Round Trip Time (RTT) is the key indicator of network connectivity performances

• There can be a lot of performance issues regarding your network configuration…

• It can be wrong internally or externally

• OCPA tool is very good as a first check. It will say if further investigation is needed and where

https://support.office.com/en-us/article/Office-365-Client-Performance-Analyzer ...

Inside Microsoft Network

Source: How to measure the Network Round Trip Time to Office 365 by Paul Collinge

Internal should be less than 100 ms, ideally 50 msEMEA to EMEA should be less than 150 ms

Outlook in cached mode can cope well with worse RTTBut for SharePoint 350 to 400 ms is the tipping between good and bad performances

aka Edge or Egress point

1. Latency/Round Trip Time (RTT)

2. DNS Geo location

3. DNS performance

4. Proxy Scalability

5. Proxy Authentication

6. TCP Window Scaling

7. TCP Idle time settings

8. TCP Max Segment size (Should be >= 1300)

9. Selective Acknowledgement

10. Application Level troubleshooting

Top 10 tips for optimizing and troubleshooting your

Office 365 network connectivity by Paul Collinge

Use the fastest

way to the

backbone

Identify Office

365 DC and Edge Check with OPCA

• F12 tool in the browser give access to the network monitoring tool

• In SPO and SharePoint on-premises you can access the information that is sent back to the browser in the response header for each file. The two most useful values for diagnosing performance issues are:

SPRequestDuration

X-SharePointHealthScore

Diagnosing performance issues with SharePoint Online

https://support.office.com/en-us/article/Diagnosing-performance-issues-with-SharePoint-Online-3c364f9e-b9f6-4da4-a792-c8e8c8cd2e86

Using the object cache with SharePoint Online

https://support.office.com/en-us/article/Using-the-object-cache-with-SharePoint-Online-38bc9c14-3826-449c-beb6-b1003bcbeaaf

• Adapt navigation method to your sites structure

OOTB structural navigation is the most straightforward but can be really slow with a complex structure of multiple subsites

Managed metadata navigation is much faster. However there is no way to security trim the results so if a user doesn’t have access to a given site, the link will still show but will lead to an error message.

Search-driven navigation can also be used to get fastest loading time but require some master page customizations.

Navigation options for SharePoint Online

https://support.office.com/en-us/article/Navigation-options-for-SharePoint-Online-adb92b80-b342-4ecb-99a1-da2a2b4782eb

Structural navigation Managed navigation Search-driven navigation

Pros:

•Easy to configure

•Security-trimmed

•Automatically updates as sites

are added

Pros:

•Easy to maintain

•Faster than Structural

navigation

Pros:

• Security-trimmed

• Automatically updates as sites

are added

• Fastest loading time and

locally cached navigation

structure

Cons:

•Can perform poorly with

complex site structure

Cons:

•Not automatically updated to

reflect site structure

•Not Security trimmed

Cons:

• No ability to easily order sites

• Requires customization of the

master page (technical skills

required)

• Adapt content rollup method to your needs

• From Slowest to Fastest

Content By Query web part (CQWP)

Content By Search web part (CSWP)

Static content

Static content in CDN (typically for popularjavascript and CSS assets)

• Using CDNs only makes sense in a SharePoint Online context and should be avoided with SharePoint Server 2013.

When to use the Content Query Web Part or the Content Search Web Part in SharePoint

https://support.office.com/en-us/article/When-to-use-the-Content-Query-Web-Part-or-the-Content-Search-Web-Part-in-SharePoint-346a0f48-38de-409b-

8a58-3bdca1768929?CorrelationId=6cd3bd08-b745-4611-b467-d6ddcb18d22b&ui=en-US&rs=en-US&ad=US

Using Content Search Web Part instead of Content Query Web Part to improve performance in SharePoint Online

https://support.office.com/en-us/article/Using-Content-Search-Web-Part-instead-of-Content-Query-Web-Part-to-improve-performance-in-SharePoint-Online-

e8ce6b72-745b-464a-85c7-cbf6eb53391b

• Use methods corresponding to files types

Images

• Image renditions allows you to serve up different versions of images based on pre-defined image dimensions.

• Sprites are images that contain many smaller images. So you download one image instead of several and then cache and reuse it. Example: spcommon.png

• Lazy loading, using js, load only visible images when needed

Videos

• Office 365 Video Portal

Javascript

• Bundling and Minifying (via third party like Web Essentials)

• CDN

Tune SharePoint Online performance

https://support.office.com/en-us/article/Tune-SharePoint-Online-performance-f0522d4a-fbf4-41f9-854e-c9b59555091d

How to: Avoid getting throttled or blocked in SharePoint Online

https://msdn.microsoft.com/en-us/library/office/dn889829.aspx

SharePoint Online uses throttling to maintain optimal

performance and reliability of the SharePoint Online

service.• Throttling limits the number of user actions or concurrent calls (by script

or code) to prevent overuse of resources.

• For requests that a user performs directly in the browser, SharePoint

Online redirects you to the throttling information page, and the requests

fail.

• For all other requests, including CSOM or REST calls, SharePoint Online

returns HTTP status code 429 ("Too many requests"), and the requests

fail.

• If the offending process continues to exceed usage limits, SharePoint

Online might completely block the process; in this case, you may see

HTTP status code 503 ("Service unavailable"), and we’ll notify you of the

block in the Office 365 Message Center. The error message is:

SharePoint Online Throttling

https://github.com/OfficeDev/PnP/tree/dev/Samples/Core.Throttling

Capacity planning and load testing SharePoint Online

https://support.office.com/en-us/article/Capacity-planning-and-load-testing-SharePoint-Online-c932bd9b-fb9a-47ab-a330-6979d03688c0

08. – 09. Januar 2016 in Köln