Download Content-Aware Switch: Architecture and Mechanisms and more Slides Computer Architecture and Organization in PDF only on Docsity!
Introduction to
Content-aware Switch
Content-aware Switch (CS)
Switch
Image Server
Application Server
HTML Server
www.yahoo.com Internet
GET /cgi-bin/form HTTP/1. Host: www.yahoo.com…
IP TCP APP. DATA
• Front-end of a web cluster
• Route packets based on layer 5/7 (content)
information
Content-aware Switch Architecture
• Two way architecture
Server returns the
response to the switch
• One way architecture
Server returns the
response to the client
client switch server
Layer 7 Two-way Architecture
TCP Splicing
client content switch server
step
step
SYN(CSEQ)
SYN(DSEQ)
ACK(CSEQ+1)
DATA(CSEQ+1)
ACK(DSEQ+1)
step
step
step
step step
step
SYN(CSEQ)
SYN(SSEQ)
ACK(CSEQ+1)
DATA(CSEQ+1)
ACK(SSEQ+1)
DATA(SSEQ+1)
ACK(CSEQ+lenR+1)
DATA(DSEQ+1)
ACK(CSEQ+LenR+1)
ACK(DSEQ+lenD+1) (^) ACK(SSEQ+lenD+1)
lenR: size of http request. lenD: size of return document
.
TCP Splicing w/ Pre-forked
Connections
client switch^ server
step
step
SYN(CSEQ)
SYN(DSEQ)
ACK(CSEQ+1)
DATA(CSEQ+1)
ACK(DSEQ+1)
step
step
step
step
step
step DATA(PSEQ+1) ACK(SSEQ+1) DATA(SSEQ+1) ACK(PSEQ+lenR+1)
DATA(DSEQ+1)
ACK(CSEQ+LenR+1)
ACK(DSEQ+lenD+1) (^) ACK(SSEQ+lenD+1)
lenR: size of http request. lenD: size of return document
.
SYN(PSEQ)
SYN(SSEQ)
ACK(PSEQ+1)
ACK(SSEQ+1)
step
Degenerated to TCP Splicing
If Guess Wrong
client content switch
Pre-allocated
server
step
step
SYN(CSEQ)
SYN(SSEQ)
ACK(CSEQ+1)
DATA(CSEQ+1)
ACK(SSEQ+1)
step
SYN(CSEQ)
SYN(SSEQ)
ACK(CSEQ+1)
step
step
DATA(RSEQ+1)
ACK(CSEQ+lenR+1)
DATA(SSEQ+1)
ACK(CSEQ+LenR+1)
ACK(DSEQ+lenD+1)^ ACK(SSEQ+lenD+1)
FIN(CSEQ+1)
step step
step
SYN(CSEQ)
SYN(RSEQ)
ACK(CSEQ+1)
DATA(CSEQ+1)
ACK(SSEQ+1)
Right server
Sequence # conversion needed
Case Study
• Linux-based content aware switch [Yang99]
• IBM Layer 5 [Pradhan00]
Results
- Overhead of the switch
- 89usec reduced pre-forked
connections
- CS vs. Layer 4 switch
- Affinity-based routing vs. WRR
- Content-segregation vs. WRR
IBM Switch Architecture
- Switch core
- Port controller:
(layer 5) and send
them to CPU
packets
- CPU: PowerPC 603e
- Parse http request
- URL based routing
Results
• CS vs. Layer 4
switch
– Entire set of files
are replicated
– Some servers
share files by
NFS
– Partitioned file
set
Layer-7 one-way architecture
TCP Handoff
client content switch server
step
step
SYN(CSEQ)
SYN(DSEQ)
ACK(CSEQ+1)
DATA(CSEQ+1)
ACK(DSEQ+1)
step
step
step
step
DATA(DSEQ+1)
ACK(CSEQ+lenR+1)
ACK(DSEQ+lenD+1) (^) ACK(DSEQ+lenD+1)
Migrate (Data, CSEQ, DSEQ)
- Migrate the created TCP connection from the switch to the back-end sever
- Create a TCP connection at the back-end without going through the TCP three-way handshake
- Retrieve the state of an established connection and destroy the connection without going through the normal message handshake required to close a TCP connection
- Once the connection is handed off to the back-end server, the switch must forward packets from the client to the appropriate back-end server