• No results found

Tyche: An efficient Ethernet-based protocol for converged networked storage

N/A
N/A
Protected

Academic year: 2021

Share "Tyche: An efficient Ethernet-based protocol for converged networked storage"

Copied!
30
0
0

Loading.... (view fulltext now)

Full text

(1)

Tyche: An efficient Ethernet-based

protocol for converged networked storage

Pilar González-Férezand Angelos Bilas

30thInternational Conference on Massive Storage Systems and Technology MSST 2014

June 6, Santa Clara, California

(2)

1

Introduction

2

Design

3

Results

4

Conclusions and Future Directions

(3)

1

Introduction

2

Design

3

Results

4

Conclusions and Future Directions

(4)

Efficient access to networked storage

Public clouds use shared storage ⇒ lower cost Easier to support migration and other operations

Converged storage places low-latency storage devices in all servers

Storage requests exchanged between all compute servers Network protocol ⇒ important for achieving high I/O throughput Modern servers increase number of cores and NICs

Cost to access storage a concern as well

Cannot use custom NICs or controllers in all servers Ethernet ⇒ dominant technology for datacenters

Lower cost and complexity ⇒ single Ethernet network for storage and network data

How to reduce protocol overheads for accessing remote storage over Ethernet?

(5)

Efficient access to networked storage (ii)

Challenges

Synchronization from 10s of cores to a single link Link bundling for spatial parallelism

NUMA affinity

Dynamic assignment of links to cores

Our goal

Design a networked storage access protocol that dynamically manage cores, NICs, NUMA affinity

(6)

1

Introduction

2

Design

3

Results

4

Conclusions and Future Directions

(7)

Our Proposal

Tyche a network storage protocol that efficiently shares remote resources by using transparently several NICs and connections

Design goals

Connection-oriented protocol

Edge-based communication subsystem Use Ethernet

Provide RDMA-type operations without any hardware support Can be deployed in existing infrastructures

Create block device ⇒ local view of a remote storage device Support any existing file system

(8)

Overview

NIC Netwok layer Physical devices

Kernel Space

Tyche block layer

Send path (Initiator) Receive path (Target)

Storage device

NIC NIC NIC NIC NIC NIC NIC NIC NIC NIC NIC

Tyche network layer VFS File System

Ethernet Driver

Block device

Ethernet Driver Tyche block layer

Tyche network layer

(9)

Design Challenges

Efficiently map I/O requests to network messages Memory managment

NUMA affinity Sychronization

Allow high concurrency to saturate many NICs

(10)

Map I/O Requests to Network Messages

Network messages

Request/completion messages ⇒ I/O requests and completions A request message corresponds to a single request packet Request packet transferred as small Ethernet frames (< 100 bytes) Data messages ⇒ data pages

RDMA operations ⇒ scatter-gather list of memory pages Data packets transferred as Jumbo Ethernet frames Zero copy ⇒ avoid data copy in receive path

For writes ⇒ interchange NIC pages with Tyche pages For reads, interchange cannot be applied

F Ethernet header ⇒ information about packets/messages Provide end-to-end flow-control

Facilitate communication between block layer and network layer

(11)

Memory Management Overhead

Block layer

remq ⇒ Queue of pre-allocated request messages

Request and completion use the same message buffers damq ⇒ Queue of pre-allocated descriptors for data messages

Target uses pre-allocated pages – avoids alloc/free Initiator uses pages of “regular” I/O requests

(12)

NUMA Affinity

Maximum throughput only with right placement

Logical connection per NIC Resources allocated on NUMA node where NIC is attached

remq damq tx_ring rx_ring not_ring Private NIC rings

Connection selected depending on location of buffers of users I/O requests

Memory 0 Memory 1

Processor 0 Core 1 Core 0 Core 2 Core 3

Processor 1 Core 5 Core 4 Core 6 Core 7 QPI 0

PCIe x8

NIC 0NIC 1NIC 2

QPI 1 PCIe x8 NIC 5NIC 4NIC 3 QPI 1

I/O hub 0 I/O hub 1

(13)

Tyche Overview

NIC

damq remq

tx_ring_small N etwok layer Physical devices

Kernel Space

Tyche block layer

not_ring_req

Send path (Initiator) Receive path (Target)

not_ring_data rx_ring_small rx_ring_big tx_ring_big

Storage device

NIC NIC NIC NIC NIC NIC NIC NIC NIC NIC NIC

Tyche network

layer

Tyche network

layer Tyche block layer VFS

File System

Ethernet Driver

Block device

Ethernet Driver damq remq

(14)

Synchronization Overhead

Context synchronization reduced for shared structures

Each connection has its own private resources Network layer

Three logical rings

tx_ring⇒ Transmission ring rx_ring⇒ Receive ring not_ring⇒ Notification ring

For each logical ring ⇒ 2 different physical rings A “small” ring ⇒ request packets

A “large” ring ⇒ data packets

Each physical ring has only two sync variables: head and tail Initiator specifies fixed positions at remq and damq

For each packet, the sender specifies its position in rx_ring’s

(15)

Synchronization Overhead (ii)

Block layerNetwork layerEthernet driver

data pages I/O request

remq damq

tx_ring_big tx_ring_small

tx NIC ring

request msg data msg

L L

L

L

L

A A

Block layerNetwork layerEthernet driver

data pages I/O request

remq damq

rx_ring_big rx_ring_small

rx NIC ring

request msg data msg

not_ring_req not_ring_data

L L

(16)

Synchronization Overhead (iii)

Many threads simultaneously issuing write requests cause lock synchronization overhead and lock contention at the NIC level

Two modes of operation Inline mode:

Application context issues requests with no context switch Queue mode:

Applications insert I/O requests in a Tyche queue Several threads submit network requests

(17)

Allow High Concurrency to Saturate Many NICs

Tyche scales with load at initiator and target Send path

Initiator uses queue mode

Multiple threads place requests in a queue

Tyche controls the number of threads accessing each link Target uses work queues to send I/O completions back

One work queue thread per physical core Receive path

Network layer ⇒ one thread/NIC processes incoming data Block layer ⇒ several threads per NIC issue/complete requests Tested up to 6 x 10 Gbits/s

(18)

1

Introduction

2

Design

3

Results

4

Conclusions and Future Directions

(19)

Experimental Testbed

Hardware & Software

Two nodes 4-core Intel Xeon E5520 @2.7GHz Initiator: 12 GB DDR-III DRAM

Target: 48 GB DDR-III DRAM 36 GB used as ramdisk

6 Myri10ge cards each node ⇒ connected back to back CentOS 6.3

Linux kernel 2.6.32

Benchmarks: zmIO, FIO, Hbase+YCSB, Psearchy, Blast,. . . Tyche compared to:

Linux Network Block Device – NBD (today)

TSockets ⇒ Tyche block layer using TCP/IP protocol

(20)

Baseline Performance

zmIO, 32 threads, raw device (no file system), 1 MB request size Tyche throughput scales with the number of NICs

Tyche achieves between 82% and 92 % of NIC throughput Tyche improves around 10x the throughput of NBD

0 1 2 3 4 5 6 7

1 2 3 4 5 6

Throughput (GB/s)

# NICs Tyche

TSockets NBD

Read requests

0 1 2 3 4 5 6 7

1 2 3 4 5 6

Throughput (GB/s)

# NICs Tyche

TSockets NBD

Write requests

(21)

Impact of Affinity

zmIO, 32 threads, raw device (no file system), 1 MB request size Tyche achieves maximum throughput only with right placement:

Full-mem placement improves no affinity performance up to 97%

Kmem-NIC placement improves no affinity performance up to 54%

0 1 2 3 4 5 6 7

1 2 3 4 5 6

Throughput (GB/s)

# NICs No affinity

Kmem-NIC Full-mem

Read requests

0 1 2 3 4 5 6 7

1 2 3 4 5 6

Throughput (GB/s)

# NICs No affinity

Kmem-NIC Full-mem

Write requests

(22)

Receive Path Scaling

zmIO, 32 threads, raw device, 4 kB, 64 kB, and 1 MB request sizes A single thread can process requests for three NICs: ' 30 GBits/s By using a thread per NIC:

Can achieve maximum throughput Reduce receive path synchronization

0 1 2 3 4 5 6 7

1 2 3 4 5 6

Throughput (GB/s)

# NICs 4k-SinTh

4k-MulTh 64k-SinTh 64k-MulTh 1M-SinTh 1M-MulTh

Read requests

0 1 2 3 4 5 6 7

1 2 3 4 5 6

Throughput (GB/s)

# NICs 4k-SinTh

4k-MulTh 64k-SinTh 64k-MulTh 1M-SinTh 1M-MulTh

Write requests

(23)

Send Path Scaling

FIO, XFS, 256 MB file size, several threads, each one its own file 4 kB requests: queue mode makes context switch

Inline mode outperforms queue mode up to 31%

512 kB requests: inline mode ⇒ synchronization overhead and lock contention Writes: queue mode outperforms inline mode up to 45%

0 1 2

4 8 16 32 64 128

Throughput (GB/s)

# Threads Read-queue

Read-inline Write-queue Write-inline

4 kB request size

0 1 2 3 4 5 6 7

4 8 16 32 64 128

Throughput (GB/s)

# Threads Read-queue

Read-inline Write-queue Write-inline

512 kB request size

(24)

Queue vs. Inline Mode Overhead: 4 kB

Queue mode pays context switch overhead Initiator: CPU utilization increases up to 29%

Target: lower throughput ⇒ CPU utilization drops up to 19%

0 20 40 60 80 100

4 8 16 32 64 128

CPU utilization (sys + user)

# Threads Read-queue

Read-inline Write-queue Write-inline

Initiator, 4 kB request size

0 20 40 60 80 100

4 8 16 32 64 128

CPU utilization (sys + user)

# Threads Read-queue

Read-inline Write-queue Write-inline

Target, 4 kB request size

(25)

Queue vs. Inline Mode Overhead: 512 kB

Writes: inline mode ⇒ synchronization overhead and lock contention Initiator: CPU utilization increases up to 30%

Target: lower throughput ⇒ CPU utilization drops up to 40%

0 20 40 60 80 100

4 8 16 32 64 128

CPU utilization (sys + user)

# Threads Read-queue

Read-inline Write-queue Write-inline

Initiator, 512 kB request size

0 20 40 60 80 100

4 8 16 32 64 128

CPU utilization (sys + user)

# Threads Read-queue

Read-inline Write-queue Write-inline

Target, 512 kB request size

(26)

Other benchmarks

Tyche always performs better than NBD and TSockets

Throughput (MB/s)

Tyche NBD TSockets

# NICs 1 6 1 1 6

Psearchy 1,154 4,117 499 488 1,724

Blast 775 882 438 391 564

IOR-R 512k 573 1,670 212 226 745 IOR-W 512k 603 1,670 230 243 751

HBase-Read 303 295 154 168 229

HBase-Insert 106 112 99 54 92

(27)

Conclusions and Future Work

Conclusions

Tyche ⇒ networked storage protocol

Transparently use multiple NICs and multiple connections Address contention, memory mgmt, and network ordering Address NUMA affinity issues

Achieve scalable throughput Reads: up to 6.4 GBytes/s ( 7 max) Writes: up to 6.7 GBytes/s ( 7 max)

Significantly outperform NBD and TSockets

Future Directions

Consider how can co-exist with other network protocols over Ethernet

(28)

Tyche: An efficient Ethernet-based protocol for converged networked storage

Pilar González-Férez and Angelos Bilas

[email protected] [email protected]

(29)

Send Path Overview

Block layerNetwork layerEthernet driver

data pages I/O request

remq damq

tx_ring_big tx_ring_small

tx NIC ring

request msg data msg

1 2

3

4 5

6

Write requests

Block layerNetwork layerEthernet driver

data pages I/O request

remq damq

tx_ring_small

tx NIC ring request msg

1 2

3

4

Read requests

(30)

Receive Path Overview

Block layerNetwork layerEthernet driver

data pages I/O request

remq damq

rx_ring_big rx_ring_small

rx NIC ring

request msg data msg

not_ring_req not_ring_data

Write requests

Block layerNetwork layerEthernet driver

data pages I/O request

remq damq

rx_ring_small

rx NIC ring request msg

not_ring_req

Read requests

References

Related documents