Bài đăng

Đang hiển thị bài đăng từ 2019

Peer-to-Peer Communication Across Network Address Translators

Hình ảnh
-           What is NAT ? Convert Network Address ( and Port) between private and public. Ví dụ: Máy tính A đứng sau NAT (inside) gửi một gói ra bên ngoài thông qua NAT, NAT device sẽ thực hiện map 1 ip private với 1 ip public và lưu vào 1 table trong bộ nhớ của nó. Và khi gói tin bên ngoài (outside) đi đến NAT device nó sẽ tìm lại trong table để tìm xem gói tin này cần chuyển đến thiết bị nào nằm sau nat (inside) NAT Table Inside outside 10.0.0.1:80 10.0.0.2:80 202.124.211.25:10080 202.124.211.25:20080 -           Type of NAT ·          Full Cone ·          Restricted Cone ·          Port Restricted Cone ·          Symmetric Full Cone §   Client có iAddr:iPort ...

ActiveMQ 5.x

Hình ảnh
- How does ActiveMQ work ?   ActiveMQ sends message between client application -  producers   Consumers sẽ là recived and process massage. The ActiveMQ broker router each message throught one of two type of destinations:         - a queue : point-to-point         - topic : publish/subscribe - Memory and Storage    A.  Memory      ActiveMQ uses memory to store messages awaiting dispatch to consumers.      ActiveMQ also writes messages to disk , in either a message store (where persistent messages go), or a temp store (where non-persistent messages go when the broker runs out of memory to store them).     Có 2 cách thức gửi message : persistent và non-persistent             non-persistent : Each non-persistent message is stored in memory as it arrives. When the available memory is full, all messages in memory are moved to th...

Linux sysctl Tuning

Hình ảnh
TCP Buffer Sizes # Settings for 1Gb network (16Mb buffer) net.core.rmem_max = 16777216 net.core.wmem_max = 16777216 net.ipv4.tcp_rmem = 4096 87380 16777216 net.ipv4.tcp_wmem = 4096 16384 16777216 # Settings for 10Gb network (32Mb buffer) net.core.rmem_max = 33554432 net.core.wmem_max = 33554432 net.ipv4.tcp_rmem = 4096 87380 33554432 net.ipv4.tcp_wmem = 4096 16384 33554432 # Settings for 10Gb network (54Mb buffer) net.core.rmem_max = 56623104 net.core.wmem_max = 56623104 net.ipv4.tcp_rmem = 4096 87380 56623104 net.ipv4.tcp_wmem = 4096 16384 56623104 Max size (bytes) of the TCP receive buffer as settable with setsockopt. Max size (bytes) of the TCP send buffer as settable with setsockopt. Auto-tuning limits (bytes) for TCP receive buffer: min, default, and max number of bytes. Auto-tuning limits (bytes) for TCP send buffer: min, default, and max number of bytes Queue Sizes While a socket is listen...