79
WFCI - Storage Introduction What options do we have? Prepared by Murilo Miranda November, 2013

WFCI Storage Introduction

Embed Size (px)

Citation preview

Page 1: WFCI Storage Introduction

WFCI - Storage Introduction

What options do we have?

Prepared by Murilo MirandaNovember, 2013

Page 2: WFCI Storage Introduction

About MeMurilo MirandaDBA @ The Pythian Group

© 20132

@murilocmiranda

http://www.sql.pt/

http://pt.linkedin.com/in/murilomiranda/

Page 3: WFCI Storage Introduction

Agenda• WFC Overview.

• WFCI Supported storage types:

– Local Disk.– SMB File Share.

– Shared Storage.

– Clustered Shared Volumes.

• Conclusion

• Questions and Answers.

© 20133

Page 4: WFCI Storage Introduction

Windows Failover Cluster

Overview

© 20134

Page 5: WFCI Storage Introduction

WFC – The advantages

• In a SQL Server perspective:– The WFC’s role is to make the instance highly available (WFCI).

– Protects from hardware failures.

– Applying service packs and hotfixes are less impactful.

– It’s transparent for the applications/users connecting to the instance.

© 20135

Page 6: WFCI Storage Introduction

WFC – Handicaps

• Still in a SQL Server perspective :– Expensive than a standalone installation.

• In € and effort:– More hardware.– More maintenance.

– It’s a HA solution only.• No performance improvements.

– Doesn’t guaranties you 100% uptime.

• You always will have the “fail over period”.

© 20136

Page 7: WFCI Storage Introduction

Standalone instance

© 20137

Page 8: WFCI Storage Introduction

Standalone instance

© 20138

Page 9: WFCI Storage Introduction

Standalone instance

© 2013 Pythian9

HO

ST

NA

ME

• One hostname.

Page 10: WFCI Storage Introduction

Standalone instance

© 201310

HO

ST

NA

ME

• One hostname.• One or more IP addresses.

Page 11: WFCI Storage Introduction

Standalone instance

© 201311

HO

ST

NA

ME

• One hostname.• One or more IP addresses.• One or more disks.

Page 12: WFCI Storage Introduction

Standalone instance

© 201312

HO

ST

NA

ME

• One hostname.• One or more IP addresses.• One or more disks.

Page 13: WFCI Storage Introduction

Standalone instance

© 201313

HO

ST

NA

ME

Page 14: WFCI Storage Introduction

Standalone instance

© 201314

HO

ST

NA

ME

Page 15: WFCI Storage Introduction

Standalone instance

© 201315

HO

ST

NA

ME

Page 16: WFCI Storage Introduction

Clustered instance

© 201316

Failover Cluster

Failover Cluster

Local Hostname

Local Hostname

Local Hostname

Local Hostname

Page 17: WFCI Storage Introduction

Clustered instance

© 201317

Failover ClusterFailover Cluster

HO

ST

NA

ME

IPIP

Assigned Storage

Assigned Storage

Local Hostname

Local Hostname

Local Hostname

Local Hostname

Page 18: WFCI Storage Introduction

Clustered instance

© 201318

Failover ClusterFailover Cluster

Local Hostname

Local Hostname

Local Hostname

Local Hostname

HO

ST

NA

ME

IPIP

Assigned Storage

Assigned Storage

Page 19: WFCI Storage Introduction

Clustered instance

© 201319

Failover ClusterFailover Cluster

Local Hostname

Local Hostname

Local Hostname

Local Hostname

HO

ST

NA

ME

IPIP

Assigned Storage

Assigned Storage

Page 20: WFCI Storage Introduction

Clustered instance

© 201320

Failover ClusterFailover Cluster

Local Hostname

Local Hostname

Local Hostname

Local Hostname

HO

ST

NA

ME

IPIP

Assigned Storage

Assigned Storage

Page 21: WFCI Storage Introduction

Clustered instance

• The connection “is made to” the hostname assigned to the SQL Server role.

© 201321

Page 22: WFCI Storage Introduction

Clustered instance

• The connection “is made to” the hostname assigned to the SQL Server role.

• The cluster service redirects the connection to the appropriate (active) node.– Where the SQL Server service is UP and listening.

– Where all the disks are mounted.

© 201322

Page 23: WFCI Storage Introduction

WCFI supported storage types What is supported for the database files.

© 201323

Page 24: WFCI Storage Introduction

WCFI supported storage types

• For SQL Server, we have four options:– Local Disk

• From SQL Server 2012

© 201324

Page 25: WFCI Storage Introduction

WCFI supported storage types

• For SQL Server, we have four options:– Local Disk

• From SQL Server 2012– SMB File Share

© 201325

Page 26: WFCI Storage Introduction

WCFI supported storage types

• For SQL Server, we have four options:– Local Disk

• From SQL Server 2012– SMB File Share – Shared Storage

© 201326

Page 27: WFCI Storage Introduction

WCFI supported storage types

• For SQL Server, we have four options:– Local Disk

• From SQL Server 2012– SMB File Share – Shared Storage– Clustered Shared Volumes

• From SQL Server 2014

© 201327

Page 28: WFCI Storage Introduction

Local Disk

• In a clustered instance it’s possible to store the TempDB into a local disk.

© 201328

Page 29: WFCI Storage Introduction

Local Disk

• In a clustered instance it’s possible to store the TempDB into a local disk.

• This local disk is not a cluster resource, so, this is not an option to user database files.

© 201329

Page 30: WFCI Storage Introduction

Local Disk

• What are the benefits in have the TempDB stored in a local disk?– More flexibility to chose the storage type.

• Utilize disks with a higher rotational speed.

– TempDB will utilize a different path than user databases to access data and log files.

• Less congestion and contention on shared storage.

• This is a benefit for both TempDB and other databases.

© 201330

Page 31: WFCI Storage Introduction

Local Disk– We can take advantage of PCIe.

• At least 6 times the speed of traditional PCI.

– More throughput than a disk interface or HBA.

© 201331

Page 32: WFCI Storage Introduction

Local Disk• Fusion-IO, OCZ and LSI Corp products are options.

– Fusion-IO is the first firm to provide a direct PCI Express storage solution that doesn’t utilize an internal storage interface like SATA, but is not bootable.

© 201332

Page 33: WFCI Storage Introduction

Local Disk• Good article about PCIe and SSDs:“Three PCI Express-Based SSDs: When SATA 6 Gb/s Is Too Slow” – http://goo.gl/dhDaTy

© 201333

Page 34: WFCI Storage Introduction

SMB File Share

• SMB 3.0 was introduced with Windows Server 2012.– It brought several significant changes to add functionality and improve SMB performance.

• System and User DBs can be installed with SMB file server as a storage option. – This applies to both SQL Server stand-alone and SQL Server WFCI.

© 201334

Page 35: WFCI Storage Introduction

SMB File Share • Windows Server 2008 (SMB 2.0)– Durability, which helps recover from temporary network glitches.

• Windows Server 2008 R2 (SMB 2.1)– Significant performance improvements, specifically for SQL OLTP style workloads.

• Windows Server 2012 (SMB 3.0)– Support for transparent failover of file shares providing zero downtime.

• Windows Server 2012 R2 (SMB 3.02)– MTU is turned on by default, which significantly enhances performance in large sequential transfers like SQL Server data warehouse and database backup or restore.

© 201335

Page 36: WFCI Storage Introduction

SMB File Share • Supported Universal Naming Convention (UNC):– \\ServerName\ShareName\– \\ServerName\ShareName

• Not supported UNC:– Loopback path:

• \\localhost\..\ or \\127.0.0.1\...\

– Administrative shares:• \\servername\x$

– Other UNC path formats like \\?\x:\

– Mapped network drives.© 201336

Page 37: WFCI Storage Introduction

SMB File Share • SMB protocol version is transparent to SQL Server.

• The SQL Server engine and SQL Server agent service accounts should have FULL CONTROL share permissions and NTFS permissions on the SMB share folders.

© 201337

Page 38: WFCI Storage Introduction

SMB File Share

© 201338

Page 39: WFCI Storage Introduction

SMB File Share

© 201339

Page 40: WFCI Storage Introduction

SMB File Share • Network performance starts to be more than critical!– Consider use a dedicated network to access the share.

• We will need to monitor the file share performance.– Physical disk counters.– Memory.– CPU. © 201340

Page 41: WFCI Storage Introduction

SMB File Share • This option is not so good as SAN, but we can take advantage in few points:

– In non-prod/DR servers.– Light databases.– Emergency/Temporary storage.

– Database migrations.

© 201341

Page 42: WFCI Storage Introduction

Shared Storage• Shared storage allows direct disk access from multiple computers simultaneously. – All nodes of the WFC are physically connected.

– Only the active node is able to access the disk.

© 201342

Page 43: WFCI Storage Introduction

Shared Storage• Shared storage allows direct disk access from multiple computers simultaneously. – All nodes of the WFC are physically connected.

– Only the active node is able to access the disk.

• A shared storage allows connections on either:– Multiple ports. – Single port - tracking multiple sessions.

• Typically this shared storage is on a SAN.

© 201343

Page 44: WFCI Storage Introduction

Shared Storage

• SAN – Storage Area Network.– Network to connect systems and storage for the purpose of transmitting storage I/O.

• Based on Fiber Channel, iSCSI or FC over Ethernet (FCoE).

• Support speed up to 16 GB/s

• Centralizes storage and management.

• Provides access to block level data storage.

– SAN may contain shared storage devices.

© 201344

Page 45: WFCI Storage Introduction

Shared Storage

© 201345

HP EVA 3000

Page 46: WFCI Storage Introduction

Shared Storage

© 201346

FC SANFC SANIP NetworkIP Network

Clients Servers Storage Arrays

Page 47: WFCI Storage Introduction

Shared Storage

• iSCSI Initiator:

© 201347

Page 48: WFCI Storage Introduction

Shared Storage

• Disk Management:

© 201348

Page 49: WFCI Storage Introduction

Shared Storage

• FC manager:

© 201349

Page 50: WFCI Storage Introduction

Shared Storage

© 201350

Page 51: WFCI Storage Introduction

Shared Storage

• Be careful with dependencies!– Adapt your disk strategy to you cluster configuration.

© 201351

Page 52: WFCI Storage Introduction

Shared Storage

© 201352

W2012SQL01 W2012SQL02

Page 53: WFCI Storage Introduction

Shared Storage

© 201353

W2012SQL01 W2012SQL02

Page 54: WFCI Storage Introduction

Shared Storage

© 201354

W2012SQL01 W2012SQL02

Page 55: WFCI Storage Introduction

Shared Storage

© 201355

Page 56: WFCI Storage Introduction

Shared Storage

© 201356

Page 57: WFCI Storage Introduction

Shared Storage

© 201357

Page 58: WFCI Storage Introduction

Shared Storage

© 201358

W2012SQL01 W2012SQL02

SAN

Page 59: WFCI Storage Introduction

Shared Storage

© 201359

W2012SQL01 W2012SQL02

SAN

Page 60: WFCI Storage Introduction

Clustered Shared Volume

• CSV was being used to facilitate Virtual Machines management.– Supported since Windows 2008 R2.

• Clustered Shared Volumes (CSV) could be a solution to increase the HA!

• ”Now” is supported on SQL Server 2014.

© 201360

Page 61: WFCI Storage Introduction

Clustered Shared Volume

• How it works?– CSVs are still on SAN.– The difference is the way they’re managed.

© 201361

Page 62: WFCI Storage Introduction

Clustered Shared Volume

• How it works?– CSVs are still on SAN.– The difference is the way they’re managed.

• Only one node is the owner – Coordinator Node

– CN can be any node, even if is not the SQL active node.

© 201362

Page 63: WFCI Storage Introduction

Clustered Shared Volume

• How it works?– CSVs are still on SAN.– The difference is the way they’re managed.

• Only one node is the owner – Coordinator Node

– CN can be any node, even if is not the SQL active node.

• The CN uses SMB (Server Message Block) to manage the I/O between the storage and all the cluster nodes.

© 201363

Page 64: WFCI Storage Introduction

Clustered Shared Volume

• How it works?– CSVs are still on SAN.– The difference is the way they’re managed.

• Only one node is the owner – Coordinator Node

– CN can be any node, even if is not the SQL active node.

• The CN uses SMB (Server Message Block) to manage the I/O between the storage and all the cluster nodes.

• All the metadata write is controlled by the CN.

© 201364

Page 65: WFCI Storage Introduction

Clustered Shared Volume

• How it works?– CSVs are still on SAN.– The difference is the way they’re managed.

• Only one node is the owner – Coordinator Node

– CN can be any node, even if is not the SQL active node.

• The CN uses SMB (Server Message Block) to manage the I/O between the storage and all the cluster nodes.

• All the metadata write is controlled by the CN.

• The data I/O is directly passed to the shared storage.

© 201365

Page 66: WFCI Storage Introduction

Clustered Shared Volume

© 201366

W2012SQL01 W2012SQL02

SAN

Coordinator Node

Page 67: WFCI Storage Introduction

Clustered Shared Volume

© 201367

W2012SQL01 W2012SQL02

SAN

Coordinator Node

Metadata write

Request

Page 68: WFCI Storage Introduction

Clustered Shared Volume

© 201368

W2012SQL01 W2012SQL02

SAN

Coordinator Node

Metadata write

Request

Metadata write

Page 69: WFCI Storage Introduction

Clustered Shared Volume

© 201369

W2012SQL01 W2012SQL02

SAN

Coordinator Node

Metadata write

Request

Metadata write

Data I/O Data I/O

Page 70: WFCI Storage Introduction

Clustered Shared Volume

• Advantages:– The storage is accessible from all nodes.

• To read and write!• SQL Server files are locked by the SQL process.

– Helps to increases the availability rate.

• The failover proccess faster.

– No need to mound disks.

• Alternative path is open.

© 201370

Page 71: WFCI Storage Introduction

Clustered Shared Volume

• With CSV, another path to the shared storage is opened, helping to increase the availability. – This alternative path is opened in case of a fail.

– The cluster will use the less costly path to perform the I/O operations.

© 201371

Page 72: WFCI Storage Introduction

Clustered Shared Volume

© 201372

W2012SQL01 W2012SQL02

SAN

Page 73: WFCI Storage Introduction

Clustered Shared Volume

© 201373

W2012SQL01 W2012SQL02

SANData I/O

I/O request

Page 74: WFCI Storage Introduction

Clustered Shared Volume

• CSV is a "NTFS reparse point”, so it’s presented like a mountpoint.– Is not mounted as a disk (not assigned to a letter).

– Accessible via %SystemDrive%\ClusterStorage.

© 201374

Page 75: WFCI Storage Introduction

Conclusion

• Consider the TempDB in a local disk, when designing a SQL Server 2012 solution.

© 201375

Page 76: WFCI Storage Introduction

Conclusion

• Consider the TempDB in a local disk, when designing a SQL Server 2012 solution.

• For non-mission critical instances, SMB File Share is a great option!– Also useful for emergencies.

© 201376

Page 77: WFCI Storage Introduction

Conclusion

• Consider the TempDB in a local disk, when designing a SQL Server 2012 solution.

• For non-mission critical instances, SMB File Share is a great option!– Also useful for emergencies.

• Shared Storage is expensive, but still the best solution. © 201377

Page 78: WFCI Storage Introduction

Conclusion

• Consider the TempDB in a local disk, when designing a SQL Server 2012 solution.

• For non-mission critical instances, SMB File Share is a great option!– Also useful for emergencies.

• Shared Storage is expensive, but still the best solution.

• CSV has all the advantages of a Shared Storage and increases the uptime.

© 201378

Page 79: WFCI Storage Introduction

Thank you – Q&A

To contact

[email protected]

To follow

© 201379

@murilocmiranda

http://pt.linkedin.com/in/murilomiranda/

http://www.sql.pt/