pdf發行版

Similar documents
IP505SM_manual_cn.doc

文件1

Simulator By SunLingxi 2003

TCP/IP TCP/IP OSI IP TCP IP IP TCP/IP TCP/IP

Abstract arm linux tool-chain root NET-Start! 2

ebook140-9

自由軟體教學平台

untitled

ebook140-8

工程师培训

ebook71-13

IC-900W Wireless Pan & Tilt Wireless Pan & Tilt Remote Control / Night Vision FCC ID:RUJ-LR802UWG

穨CAS1042中文手冊.doc

计算机网络概论

AL-M200 Series

穨CAS1042快速安速說明.doc

飞鱼星多WAN防火墙路由器用户手册

(UTM???U_935_938_955_958_959 V )

QL1880new2.PDF

Symantec™ Sygate Enterprise Protection 防护代理安装使用指南

C3_ppt.PDF


<B1B1BEA9B9E2BBB7D0C2CDF8BFC6BCBCB9C9B7DDD3D0CFDEB9ABCBBEB4B43F3F12FB6CB293>

一、选择题

BYOD Http Redirect convergence Client (1) 2008R2 NLB( ) (2) NLB Unicast mode switch flooding (arp ) NLB DNS Redirect 1. Round-Robin DNS DNS IP/DNS Cli

¶C¶L§§¬_™¨ A.PDF

第 1 章 概 述 1.1 计 算 机 网 络 在 信 息 时 代 中 的 作 用 1.2 计 算 机 网 络 的 发 展 过 程 *1.2.1 分 组 交 换 的 产 生 *1.2.2 因 特 网 时 代 *1.2.3 关 于 因 特 网 的 标 准 化 工 作 计 算 机 网 络 在

ebook140-11

.. 3 N

经华名家讲堂

UDP 8.2 TCP/IP OSI OSI 3 OSI TCP/IP IP TCP/IP TCP/IP Transport Control Protocol TCP User Datagram Protocol UDP TCP TCP/IP IP TCP TCP/IP TC

IP TCP/IP PC OS µclinux MPEG4 Blackfin DSP MPEG4 IP UDP Winsock I/O DirectShow Filter DirectShow MPEG4 µclinux TCP/IP IP COM, DirectShow I

05 01 X Window X Window Linux Linux X Window X Window Webmin Web Linux Linux X Window X Window Notebook PC X Window X Window module Linux Linux kernel

D E 答 案 :C 3. 工 作 站 A 配 置 的 IP 地 址 为 /28. 工 作 站 B 配 置 的 IP 地 址 为 /28. 两 个 工 作 站 之 间 有 直 通 线 连 接, 两 台

財金資訊-80期.indd

SEC-220

9 Internet 10 Internet

一.NETGEAR VPN防火墙产品介绍

Microsoft Word - PS2_linux_guide_cn.doc

A API Application Programming Interface 见 应 用 程 序 编 程 接 口 ARP Address Resolution Protocol 地 址 解 析 协 议 为 IP 地 址 到 对 应 的 硬 件 地 址 之 间 提 供 动 态 映 射 阿 里 云 内

Microsoft PowerPoint - 数据通信-ch1.ppt

中国计算机软件专业技术资格和水平考试

计算机网络

epub 61-2

Microsoft Word - XN30Chap3.doc

第 11 章 互聯網技術 11.1 互聯 網 和 萬 維 網 的 發 展 歷 史 A. 互聯網的發展 互聯網是由 ARPANET 開 始發展的 1969 年 美國國防部高級研究計劃署 (ARPA) 把部分軍事研究所和大 的電腦連接起來 建造了㆒個實驗性的電腦網絡 稱為 ARPANET 並 列 的功能

《计算机网络》实验指导书

目 彔 1. 准 备 工 作 登 彔 设 置 功 能 说 明 实 时 监 控 基 本 控 制 功 能 设 置 画 质 调 节 彔 像 与 抓 拍

GPRS IP MODEM快速安装说明

QVM330 多阜寬頻路由器

ebook62-1

Chapter #

本文由筱驀釹贡献

SiteView技术白皮书

QVM330 多阜寬頻路由器

ebook67-9

NSC-161

untitled

1 Linux Linux Linux Windows NT Linux Linux UNIX Internet Linux Internet Internet Web Linux 26.3% Web Apache 60% Sendmail Internet Linux ISP/ICP

一个开放源码的嵌入式仿真环境 ― SkyEye

<4D F736F F F696E74202D FC2B2B3F85FA44AAB49B0BBB4FABB50B977A8BEA874B2CEC2B2A4B6BB50C0B3A5CE2E707074>

ch09.PDF

1

D-link用户手册.doc

11N 无线宽带路由器

第4章网络层_2_.doc

bingdian001.com

05_資源分享-NFS及NIS.doc

BYOD IP+Optical (IP NGN) API 4. End-to-End (Service Aware) 5. IP NGN (IP Next Generation Network) ( ) Prime Carrier Management Access Edge Co

Windows 2000 Server for T100

Data Server_new_.doc

untitled

Microsoft Word htm

中文朗科AirTrackTM T600 迷你无线路由器用户手册.doc

untitled

Microsoft Word htm

Microsoft Word - YDB doc

IP Access Lists IP Access Lists IP Access Lists

C6_ppt.PDF

<4D F736F F F696E74202D20A1B6CFEEC4BFD2BB20B3F5CAB6BCC6CBE3BBFACDF8C2E7A1B7C8CECEF1C8FD20CAECCFA A1A24950D0ADD2E9BACD4950B5D8D6B72E707074>

联想天工800R路由器用户手册 V2.0

1 1 2 OSPF RIP 2

ebook67-1

第 7 章 下 一 代 网 际 协 议 IPv6 141 足 的 措 施 只 能 是 权 宜 之 计 (3) 路 由 表 膨 胀 早 期 IPv4 的 地 址 结 构 也 造 成 了 路 由 表 的 容 量 过 大 IPv4 地 址 早 期 为 网 络 号 + 主 机 号 结 构, 后 来 引 入

網路安全:理論與實務 第二版

Chapter 2

RTX3.2.0标准版 - 技术白皮书

ext-web-auth-wlc.pdf

目次 

Total Internet Connectivity in a Single Chip

ARM JTAG实时仿真器安装使用指南

IS-IS路由协议中文教程v1

1. 二 進 制 數 值 ( ) 2 轉 換 為 十 六 進 制 時, 其 值 為 何? (A) ( 69 ) 16 (B) ( 39 ) 16 (C) ( 7 A ) 16 (D) ( 8 A ) 在 電 腦 術 語 中 常 用 的 UPS, 其 主 要 功 能

Microsoft Word - template.doc

Master Thesis_專門用來製作目錄.doc

第3章 计算机网络体系结构

13 A DSS B DSS C DSS D DSS A. B. C. CPU D. 15 A B Cache C Cache D L0 L1 L2 Cache 16 SMP A B. C D 17 A B. C D A B - C - D

投影片 1

ebook 185-6

OSI OSI 15% 20% OSI OSI ISO International Standard Organization 1984 OSI Open-data System Interface Reference Model OSI OSI OSI OSI ISO Prototype Prot

Transcription:

NAT

Abstract Due to the fast improvement of Internet, vast varieties of application arose. Currently, the Internet is an important platform that cannot be missing in life. However problems do follow. The huge amount of usage of the Internet cause the IP address quickly being used up, the enormous amount of the file flow cause the cable to be obstructed, and the internet media transmission will soon to be used more frequently. Therefore, how to solve these problems is worth a study. This project targeted on an easy-to-use embedded QoS controler. Using low-priced PC, NICx, and free Linux operation system, one can design a low-cost edge router for small offices. The technigues, such as Network Address Translator (NAT), Quality of Service, Traffic Meter, and Port Forwardetc, are used to effectively solve the situation of not enough IPv4 addresses. Unfortunately, the use of NAT causes a lot of new troubles in practice. For examples, many internet-games cannot run behind a NAT. In this project, we solve most of these troubles by using application gateways and the port forward technique. We also strengthen the functionality of the IP sharing routers on the market. Most of IP sharing routers do not have the quality of service, flow meter, direct multimedia connection programs through NAT. And lastly, combined as a full set of web-based window, allowing any type of user can easily operate without any advanced skills. This system is packed and compressed its core into the DiskOnChip. Combining with the embedded system, we design a professional product.

III V 1 1.1.1 1.2.1 1.3.2 Internet Protocol (IP) 3 2.1 IPv4 3 2.2 IPv4 4 2.3 4 Network Address Translation (NAT) 7 3.1 NAT 7 3.2 NAT 8 3.2.1 NAT. 8 3.2.2 NAT. 9 3.2.3 Masquerading(NAPT).. 11 3.3 NAT... 12 3.3.1 Virtual Server(Load Balancing).. 12 3.3.2 Multiple Router per Destination.. 14 3.4 Linux NAT ipchains... 14 3.5 NAT 23 Quality of Service (QoS) 28 4.1 QoS.28 4.2 Linux QoS. 30 4.2.1 QoS 30 I

NAT (pdf) 4.2.2 Class Based Queuing(CBQ).. 32 4.3 CBQ.. 32 42 5.1 MRTG.... 42 5.2 IPFM... 45 Web 48 6.1.48 6.2.48 6.3.49 6.3.1 49 6.3.2 50 6.3.3 52 6.3.4 56 6.3.5 57 6.3.6 58 6.3.7 61 6.3.8 62 6.4 NAT 63 Linux 65 7.1 Floopy Linux.. 66 7.2 DiskOnChip.. 73 77 8.1.77 8.2.78 79 II

1-1 V 2-1IP (1).3 2-2IP (2).4 2-3 NAT(IP-msaquerade) 7 2-4 Proxy Server 7 3-1 3-2 3-3 3-4 NAT. 10 NAT IP... 11 NAT IP 12 Masquerading (NAPT) IP.... 14 3-5 Virtual Servers(Load Balancing) 15 3-6 Multiple Routes per Destination 16 3-7 17 4-1 30 4-2 Linux Traffic Control. 32 4-3 Framework for developing "intserv"&"diffserv".. 32 4-4 4-5. 35 36 5-1 5-2 MRTG 45 IPFM..48 6-1 6-2 6-3... 50 51 53 III

NAT (pdf) 6-4 6-5 6-6 6-7 6-8 6-9 6-10 6-11 6-12 6-13 6-14 6-15 6-16 54 56 57 57 59 60.. 61.. 62 63 64. 65 NAT (TCP echo Port).. 66 NAT (TCP echo Port).. 66 7-1 Linux. 69 7-2 DiskOnChip 2000 (M-system).. 74 7-3 DiskOnChip (Technology Diagram).. 75 IV

IP (PC) (NICx) Linux (Network Address Translation) (Quality of Service) (Flow Meter) (Port Forward) IPv4 IP web based DiskOnChip (Embedded System) V

1.1 ADSL 1 IP Linux IP Masquerading QoS Linux Webmin 2 (Network Address Translation) (Quality of Service) (Flow Meter) (Port Forward) (DiskOnChip) (Embedded System) IP 3 1.2 1. IP 2. 3. 4. 1 ADSLAsymmetric Digital Subscriber Line ISP HiNetSeedNet ADSL IP 2 Webmin Unix ApacheDNS 3 IP IP 1

NAT (pdf) (Load Balancing) 1.3 Perl Shell Script HTML Linux RedHat (kernel 2.2.17-14) ADSL ( 1536kbps/ 384kbps) PPPoE ADSL ( 512kbps/ 64kbps) 46 Iwill DiskOnChip(32MB) 2

Internet Protocol (IP) Internet Protocol (IP) 2.1 IPv4 IP(Internet Protocol) 70 80 IPv4(IP version 4) Domain Name IP IP. (ex:140.134.4.2) 8-bit ( ) 8-bit 32-bit IPv4 IPv6 32 NetID HostID IP NetID HostID 22558777(HostID) 04(NetID) 22558777 IP (NetID+HostID) 127.0.0.1(lo interface) IP IPv4 32 ABC IP IP (1) 3

NAT (pdf) IP Class A Class IP Net ID Host ID B Class IP Net ID Host ID C Class IP Net ID Host ID Class IP A 0 126 16,777,214 1.x.x.x ~ 126.x.x.x B 10 16,384 16,382 128.x.x.x ~ 191.x.x.x C 110 2,097,152 256 192.x.x.x ~ 223.x.x.x D 1110 - - 224.- ~ 239.- E 1111 - - 240.- ~ 255.- IP (2) 2.2 IPv4 IPv4 B B B C 2.3 CIDR B IPv4 4

Internet Protocol (IP) BGP-4 IPv4 CIDR CIDR(Classless Inter-Domain Routing) IP 650 IP B Class 3C Class 3C Class Net ID (router) CIDR CIDR IP Netmask C Class 255.255.0.0 mask Supernet Subnet IP IP (Private IP Address) RFC1918 IP IANA (Internet Assigned Number Authority) IP 10.0.0.0 10.255.255.255 172.16.0.0 172.31.255.255 192.168.0.0 192.168.255.255 5

NAT (pdf) IP IP 1. 2. Internet 3. (ex:dns) IPv4 IP Internet IP IP IP IP Intetnet IP (ex: NAT Server) IP IPv4 IP IP ( NAT Router NAT Server) IP IP IP IP IP (Masqerading) 6

Internet Protocol (IP) Proxy Server Proxy Server Proxy Server 1. Clinet Proxy 2. Proxy Internet Telnet, NFS 3. Server Proxy Server 7

NAT (pdf) Proxy NAT ( ) Proxy NAT Proxy NAT NAT IP (Masquerading) NAT IP-Masquerade Proxy Server 8

Network Address Translation(NAT) Network Address Translation 3.1 NAT NAT (Network Address Translation) RFC 1631 Server( Router) IP Header IP IP IP IP IP NAT IP IP NAT ISP (Internet Service Provider) IP (Address Block) ISP IP NAT NAT IP NAT (IP ) NAT IP (Linux FTP ICMP masq. module ) IP 9

NAT (pdf) 3.2 NAT mn m: IP IP n : IP IP NAT m NAT Server n NAT m,n1and m =n (m,n is N) NAT m,n1 and mn (m,n is N) IP masquerading m,n1 and n=1 (m,n is N) 3.2.1 NAT NAT Server entry connection entry connection IP network, NAT (Static NAT) NAT mn-translationm, n1 and m =n (m, n is N) IP IP NAT new-ip-addr = new-network-id OR (old-ip-addr AND (NOT netmask) ) 10

Network Address Translation(NAT) NAT 192.168.0 IP 61.218.157 IP 255.255.255.0 IP 192.168.0.105 IP 61.218.157.162 *old network *new network NAT IP 3.2.2 NAT NAT NAT mapping table entry redirect NAT mapping table entry Private IP network connection NAT (Dynamic NAT) NAT mn-translationm, n1 and m n (m,n is N) 11

NAT (pdf) IP IP NAT IP IP IP host unreachable ICMP NAT NAT IP IP NAT NAT Server B 172.16 IP C 61.218.157 IP NAT Server 61.218.157 IP 12

Network Address Translation(NAT) IP m = n NAT NAT IP IP 3.2.3 Masquerading (NAPT) NAPT mn-translationm, n 1 and n = 1 (m, n is N) m1 IP 1 IP IP -Masquerade Linux IP-Masquerade SNAT (Source NAT) Source address NAT Linux Masquerading TCP ports (Linux ports port 61000 port 61000+4096 /linux/include/net/ip_masq.h ) 13

NAT (pdf) Masquerading IP Internet IP Masquerading UDP based (Port forward Application level gateway) 3.3 NAT NAT IP NAT 3.3.1 Virtual Servers(Load Balancing) 14

Network Address Translation(NAT) NAT Rule Virtual ServerIP 61.218.157.100 IP 61.218.157.201 61.218.157.202 Virtual Server Real Server Client Virtual Server NAT Server Real Server NAT Server Virtual Server Real server NAT Server IP Real Server (ex: NAT Server Real Server ) Server Load Balancing Load Balancing DNS Support for Load Balancing (RFC 1794)Squid Cache Server Server 15

NAT (pdf) 3.3.2 Multiple Routes per Destination NAT Server 3.3.1 Router( NAT Server) NAT ISP (3.2 3.3) IPv6 IPv4 NAT 3.4 Linux NAT ipchains Linux IP-Masquerade kernel kernel 2.0.x ipfwadm kernel 2.1.x/2.2.x ipchains kernel 2.3.x/2.4.x iptables netfilter kernel 2.4 netfilter netfilter 1. ipchains ( ) 16

Network Address Translation(NAT) 2. Source NAT Destination NAT 3. PID 4. Routing Table 5. 6. MAC address kernel 2.4.0 release netfilter 2.4 netfilter ( module) kernel 2.2.14 ipchains ipchains RedHat Linux v6.0 masquerade (policy) (rule) port (chain) (input) (output) (forward) (redirect) (accept) (deny) (reject) (forward) (masquerade) s q 17

NAT (pdf) ipchains : ipchains -[ADC] chain rule-specification [options] ipchains -[RI] chain rulenum rule-specification [options] ipchains -D chain rulenum [options] ipchains -[LFZNX] [chain] [options] ipchains -P chain target [options] ipchains -M [ -L -S ] [options] ipchains -h [icmp] (print this help information, or ICMP list) ipchains --add A --delete D --inser I ipchains ipchains ipchains ipchains 1 --replace R --list -L --flush -F --zero -Z ipchains ipchains ( :inputoutputforward) -L, --list (list) 18

Network Address Translation(NAT) --check -C --new -N --delete-chain X --policy -P --masquerade -M --set -S --help -h -s ( ), -d ( ), -p( ), -i ( ) (user-defined) input,forward,output ( -L ) kernel (-S ) ipchains! not! -s! localhost localhost --proto -p [!] protocol tcpicmpudp all 192.168.0.10 140.134.4.5 telnet (port 23) 19

NAT (pdf) -- source -s [!] --source-port [!] port --destination -d [!] --destination-port [!] --icmp-type [!] --interface -i [!] port port ICMP loeth0eth1 -- jump -j --numeric -n DNS IP -- log -l ipchains /var/log/messages -- verbose -v TOS -L [!] --syn -y SYN TCP --TOS -t Type of Service [!] --version V ipchains --bidirectional -b ipchains ipchains ipchains ipchains L inputforwardoutput 20

Network Address Translation(NAT) input chains 192.168.0.3 192.192.69.36 forward chain IP (masq.) 192.168.0.0~192.168.0.255 IP output chain (input ) input ( ) IP 192.168.0.3 ICMP ICMP 192.168.0.3 140.134.4.5 ( ) DENY -A (-A) input ( -s 192.168.0.3 ) ( -p ICMP ) ( -j DENY ) 192.168.0.3icmp -D (-A) (-D) 21

NAT (pdf) -F -D -F input ( ) -Z -Z -p TCPUDPICMP ALL ( /etc/protocols ) IP (-s) (-d) 3 1. www.fcu.edu.tw 2. IP 140.134.4.2 3. IP 140.134.4.2/24 140.134.4.2/255.255.255.0 0/0 IP -s IP UDP TCP port port 80 ( www ) 22

Network Address Translation(NAT) TCP 192.168.0.1 port www port! 192.168.0.1 www port log /var/log/message -l ipchains /var/log/message Linux kernel klogd(kernel logging daemon) ipchains ipchains Telnet Telnet IP 23

NAT (pdf) DENY ACCEPT DENY IP (Masquerade) IP 192.168.0.0/24 IP timeout ( entry 900 ) ping ipchains ping Request timed out. icmp icmp ping ping 24

Network Address Translation(NAT) REJECT port ( ) 3.5 NAT NAT IP Internet (Netmeeting) (ex: SIP,H.323) IP NAT IP Header ipchains SYN FTP NAT Server Can't create data connection: Connection refused. ipchains module ip_masq_ftpip_masq_cuseemeip_masq_irc ip_masq_mfwip_masq_pptpip_masq_quake ip_masq_raudioip_masq_userip_masq_vdolive ip_masq_h323(sofia) (port forward) port IP IP ( ) application gateway 25

NAT (pdf) module ipchains FTP FTP (active mode) (passive mode) FTP (active mode) 1. FTP client 1024 port FTP server port 21 2. client port serverclient 1024 port 3. server port 20 client port ( server client TCP SYN ) 4. client ACK (hand shack) 5. (passive mode) 1. FTP client 1024 port FTP server port 21 2. client PASV server passive 3. server 2 1024 port client 4. client 1024 port server port SYN 26

Network Address Translation(NAT) 5. server ACK 6. ipchains Firewall client SYN ipchains # ipchains -A input -p TCP -i $EXT_IF! -y -s $ALL -j ACCEPT "! " NOT "! -y " NOT syn TCP FTP client ( 3 ) FTPserver login FTP server ls FTP ls FTP server ls FTP server Can't create data connection: Connection refused. Passive 3 4 SYN FTP server client NAT Server ip_masq_ftp NAT FTP # modprobe ip_masq_ftp 27

NAT (pdf) # modprobe ip_masq_quake # modprobe ip_masq_ kernel 2.4 netfilter module ftpirc module kernel 2.2 netfilter (port forward) kernel 2.2.x ipchains port forward port forward ipmasqadm ipmasqadm kernel ipmasqadm port NAT Server IP 61.218.157.162 server 192.168.0.105 ipmasqadm NAT Server http port(80) server port 8888. ipmasqadm NAT Server port(25) server port 25. (IP:192.168.0.105) netmeeting shell script 28

Network Address Translation(NAT) # Shell script for Microsoft NetMeeting 3.0 # NetMeeting Client IP address HI="1024:65535" NM_HOST="192.168.0.105" # port forward kernel 2.2.x CoRiTeL consortium module: ip_masq_h323 http://www.coritel.it/coritel/ip/sofia/nat/nat2/nat2.htm kernel 2.4.x OpenH323Proxy http://openh323proxy.sourceforge.net/ 29

NAT (pdf) Quality of Service (QoS) 4.1 QoS Quality of Service (QoS) QoS IP(Internet Protocol) OSI TCP Best Effort E-mailFTP ( VoIP VoD ) QoS http://www.coritel.it/coritel/documents/slides/qos/sld006.htm 30

Quality of Service(QoS) TCP/IP QoS TOS 4 TOS 8bit IP 0 0 1 0 1 0 1 TOS 0 TOS bits Telnet: "Minimum delay" bit FTP-control: "Minimum Delay" bit FTP-data: "Maximum Throughput" bit 4 Type of Service IP 31

NAT (pdf) 4.2 Linux QoS Linux kernel 2.1.90 QoS TOS iproute2 tc 4.2.1 Qos Linux Traffic Control 4-3 32

Quality of Service(QoS) (Traffic Control) IP (Queueing discipline, Classes and Filter) fwmark u32fwmark Linux netfilter u32 (header) Class Based Queue CBQ super-queue ( CBQs) (queueing) Linux Class Based Queue, Token Bucket Flow, CSZ, First In First Outm Priority, TEQL, SFL, ATM, RED CBQ(Class Based Queue) (Route) (queueing) 3 'FIFO queuing' (First IN First Out ) Internet Internet TCP/IP TCP/IP 33

NAT (pdf) ( ) 4.2.2 Class Based Queuing(CBQ) Class-based Queuing(CBQ) Class Traffic Queuing TCP Rate Shaping TCP TCP Non-TCP (Packet Level) CBQ TCP Rate Shaping CBQ Class Class (Traffic Flow) (High Priority) Class Class CBQWFQ (weighted fair queuing ) WFQ 4.3 CBQ 1. diff-serv patch linux-2.2.14 source ( http://lrcftp.epfl.ch/pub/linux/diffserv/patches/ds-3.patch.gz) 2. /usr/src/linux make xconfig 34

Quality of Service(QoS) make menuconfig make config 3. EXPERIMENTAL_OPTIONS Y (kernel 2.2.9 ) 4. [Network Options] [QoS Option] Y 5. make dep; make clean; make bzilo 6. linux (TC) (TC) 1. (ex:eth0) CBQ 2. 3. 4. 1 2 4-4 35

NAT (pdf) (eth0) IP 192.168.0.254 CBQ 1000bytes 8bytes 20bytes : (1) 1 IP 192.168.0.10 8Mbit 2 (2) 2 IP 192.168.0.20 1Mbit 1 (3) 1192.168.0.0 255.255.255.0 1Mbit 6 2 1 4-5 cbq eth0 1:0 eth0 36

Quality of Service(QoS) 10 Mbit 1000 bytes 8 bytes 64 (1) 1:1 10Mbit 8 10Mbit 20bytes MAC 1514 8 1000 bytes 8 bytes 1Mbit (2) 1:2 1:1 8Mbit 2 10Mbit 8Mbit 20bytes MAC 1514bytes 1 1000bytes 8bytes 800Kbit 1:0bounded 37

NAT (pdf) (3) 1:3 1:1 1Mbit 1 10Mbit 1Mbit 20bytes MAC 1514bytes 2 1000bytes 8bytes 100Kbit 1:0 (4) 1:4 1:1 1Mbit 6 10Mbit 64Kbit 20bytes MAC 1514bytes 1 1000bytes 8bytes 100Kbit 1:0 (1) cbq 1:0 ip 100 (2) 1:2, 1:3, 1:4 38

Quality of Service(QoS) (1) 192.168.0.10 2 ( 2 8Mbit) (2) 192.168.0.20 3 ( 3 1Mbit) (3) 192.168.0.0/24 4 ( 4 1Mbit) IP 39

NAT (pdf) (1) (ex: eth0) (ex:eth0) 13232 7646731bytes 0 (2) (ex:eth0) (ex:eth0) 40

Quality of Service(QoS) (class cbq 1:0) eth0 class cbq 1:4 8076 5552879bytes 0 0 (3) flowid 1:2 class cbq 1:2to 2 2 (4) 41

NAT (pdf) 0 realm " " " " (1) (2) tc class add tc class change bounded 42

Quality of Service(QoS) shell (3) tc filter add tc filter change tc filter del (4) ip route add ip route change ip route del qdisc/class/filter sch_fifo, sch_prio sch_cbqfilter route u32 filter qdisc/filter qdisc/filter/class 43

NAT (pdf) ( ) CPU ( Squid ) ( ) CPU MRTG IPFMMRTG IPFM NAT Server 5.1 MRTG MRTG Server Server log MRTG SNMP Server MRTG 2~4 5 MRTG UNIX like Windows Microsoft 1. CPU... 2. Server MailNewsDNSWebBBSIRC 44

MUD... 3. RouterSwitch ATM... 4. Modem Login... MRTG SNMP router( SNMP switch server) MRTG routerswitch 5-1MRTG MRTG MRTG Perl zlibgdpng zlib gd MRTG SNMP HTTP rpm qa 45

NAT (pdf) Linux perl-5.0 zlib-1.1.3 gd-1.3 libpngapache MRTG MRTG 46

MRTG MRTG 5.2 IPFM MRTG IPFM libpcap host host name lookup sort by in/out/total bytes 47

NAT (pdf) 48 ##IP,,, ( bytes) 5-2IPFM IPFM ipfm-0.10.4.tgz make install /etc/ipfm.conf

49

NAT (pdf) 50 Web 6.1 Web-BrowserHTML 6.2 6-1 GateRouter

Web 6.3 6.3.1 root guest START root root guest END 6-2 51

NAT (pdf) 6.3.2 GateRouter ISP WAN port IP PPPoE IP IP Load-balencing ( round-robin) checkbox html Form POST Server CGI 52

Web START END 6-3 53

NAT (pdf) 6-4 6.3.3 IP (192.168.0.0/24) IP (192.168.0.1~192.168.0.253) IP (MAC Address) IP Qos IP 54

Web ( / IP ) checkbox IP Java Script IP ( ) PCxx (xx IP ) IP html Form POST Server CGI Perl 55

NAT (pdf) START END 6-5 56

Web 6-6 6-7 57

NAT (pdf) 6.3.4 NAT Server ipmasqadm portfw autofw netmeeting application gateway QoS 58

Web 6.3.5 10 (filter) IP IP ( ftp) START ipchains END 6-8 59

NAT (pdf) 6-9 6.3.6 IP ipchains Static ARP IP/MAC ARP Table (kernel 2.4 iptables + mac ) tc 60

Web START (.conf) network restart / ipchains / tc? END 6-10 61

NAT (pdf) 6-11 62

Web 6.3.7 IP Flow Meter IPFM START /var/log/ipfm/*.flow END 6-12 63

NAT (pdf) 6-13 6.3.8 1. uptime 2. ifconfig 3. ipchains -L -n 4. ARP Table, arp -n 5. (configured classes) tc -s class show dev eth0 6. (queueing disciplines) tc -s class show dev eth0 7. ipmasqadm portfw -l 64

Web 6-14 6.4 NAT TCP echo Port 65

NAT (pdf) Echo Test (kb/s) Total (kb/s) Local BSD Linux Local BSD Linux 1 1 2 2 3 3 4 4 5 5 6 6 6-15NAT (TCP echo Port) 6-16NAT (TCP echo Port) 66

Linux Linux Linux kernel FreePaduCLinux PDA Linux SetTop Box embedded linux embedded embedded LINUX LINUX embedded loader lilo, syslinux embedded syslinux angleboot (gcc, glibc, binutils)gui x86 GNU StrongARM, ARM7, mips, SuperH Binutls, Gcc, Glibc embedded x86, IA64, Assbet GUI QPE, GtrFB, tinyx GUI embedded x86 x86 Iwill LAN v1.2 x86 DiskOnChip 19 Red Hat Red Hat Embedded Linux Developer Suite 7.2 glibc 2.2 67

NAT (pdf) 7.1 Floopy Linux Floopy Linux Floppy Linux BIOS 0 0 BIOS MBR (Master Boot Record) MBR (Boot Loader) loader ( Linux LILO linux loader ) Linux Kernel Kernel (protected mode) Kernel BIOS Kernel (mount) root filesystemroot filesystem / filesystemkernel root filesystem root filesystem ramdisk (image) (halt) root filesystem init init /etc/inittab sysinit script redhat rc.sysinit rc.sysinit rc.sysinit init runlevel 3 init /sbin/mingetty virtual console login : shell Linux 68

Linux runlevel 5 virtual console init xdm X window system xdm BIOS SYSLINUX KERNEL INIT SHELL Floopy Linux source package kernel sourcesyslinuxbusybox Floppy Linux LILO syslinux shell Floppy Linux kernel driver make make kernel BusyBox Open Source tool lineo, Inc LRP(Linux 69

NAT (pdf) Router Project Debian boot floppies BusyBox 60 Linux k BusyBox initlscpcat mountumountmorepssh BusyBox Floppy Linux glibc BusyBox root filesystem root filesystem root mknod root filesystem floppy-linux root filesystem /dev 70

Linux VGA Display RAM disk floppy null mknod tar shell srcipt /etc/inittab script BusyBox init init /etc/init.d/rcs /etc/rc.d/rc.sysinit Floppy Linux redhat BusyBox init.c /floppy-linux/etc/rc.d inittab 71

NAT (pdf) inittab rc.sysinit /floppy-linux/etc/rc.d/rc.sysinit /floppy-linux/etc/fstab proc /proc proc defaults 0 0 fstab BusyBox /floppy-linux/bin floppy-linux root filesystem 72

Linux floppy-linux root filesystem ram disk ram disk /tmp image.gz ram disk sysliunux syslinux syslinux.cfg syslinux.cfg syslinux.cfg kernel Image.gz 73

NAT (pdf) Floppy Linux k shell 7.2 DiskOnChip DiskOnChip 32-pin DIP TSOP-I DiskOnChip DiskOnKey DiskOnChip ( set-top-boxes) M-system DiskOnChip 2000 TrueFFSR (True Flash File System) DiskOnChip DOS, Windows Embedded NT/CE/2000, Linux, psos+, VxWorks, QNX EDC/ECC( ) (Wear leveling) 74

Linux DiskOnChip DiskOnChip Software Utilities - User Manual DiskOnChip FORMAT DFORMAT DiskOnChip M-system DINFO DiskOnChip Partitions, the memory window address, software versions, high-level, low-level geometry 75

NAT (pdf) / DiskOnChip GETIMAGE PUTIMAGE DiskOnChip Image. Image DiskOnChip. 76

Linux Linux TrueFFS Driver (, m-sys )..... DiskOnChip... 77

NAT (pdf) 8.1 Linux Router Project Linuxopen source (ipchains) 78

8.2 56k Modem ADSL/Cable Modem PC (backbone) Network Processor 79

NAT (pdf) [1] K. Egevang, P. Francis, RFC 1631, The IP Network Address Translator(NAT) (1994) [2] Michael Hasenstein, IP Address Translation (1997) [3] Werner Almesberger, EPFL ICA, Linux Traffic Control Implementation Overview (1998) [4] The University of Kansas, Linux Advanced Networking Overview Version 1 (1999) [5] Paul Russell, Linux IPCHAINS-HOWTO (1999) [6] Jiann-Ching Liu, Computer of NCU, Private IP & NAT (1999) [7] Gray B. Shelly, Thomas J. Cashman, Harry J. Rosenblatt, SYSTEM ANALYSIS and DESIGN (1999) [8] Lee Nevo., MASQ. APPS, http://www.tsmservices.com/masq/cfm/main.cfm (1999) [9] Study-Area, http://www.study-area.org (2000) [10] RedFox, How to build a floopy-linux (2000) [11] M-system.com http://www.m-sys.com/ (2000) 80