2018年3月19日 星期一

研究 | Switch 的三種 switching 方式

Switch 的三種 switching 方式

1. Store and forward
儲存整個 frame 到 switch 的記憶體,檢查 CRC 後,沒有錯誤則根據 frame 的 destination MAC address (DMAC) 查詢 forwarding table 後轉發出去,如果有錯誤則丟棄 frame。

優點: 可以完整偵測各種錯誤的 frame

缺點: 延遲時間長 (long latency)

2. Cut-through
只儲存 frame 的 destination MAC address (DMAC) 到 switch 的記憶體,查詢 forwarding table 後就轉發出去。

優點: 延遲時間短 (low latency)

缺點: 無法偵測錯誤的 frame,所以連錯誤的 frame 也轉發,由接收端的網卡來檢查 frame 的正確性

3. Fragment-free (Cut-through 的改良)
儲存 frame 的前 64-byte 到 switch 的記憶體,因為大部分的網路錯誤或是 collision 都是發生在前 64-byte。雖然延遲時間比 Cut-through 久一點,但是可以處理一些錯誤的 frame (例:runt frame)。

參考
1. http://www.ciscopress.com/articles/article.asp?p=357103&seqNum=4
2. http://felixhis2011.pixnet.net/blog/post/41439040-switch
3. https://hlchang.com/2010/08/cut-through-%E6%8D%B2%E5%9C%9F%E9%87%8D%E4%BE%86/
4. http://www.omnisecu.com/cisco-certified-network-associate-ccna/methods-of-switching.php
5. http://www.netadmin.com.tw/article_content.aspx?sn=1203290001&jump=1
6. https://www.cisco.com/c/en/us/products/collateral/switches/nexus-5020-switch/white_paper_c11-465436.html
7. https://community.fs.com/blog/comparison-between-store-and-forward-switching-and-cut-through-switching.html


沒有留言:

張貼留言