Welcome to Sysnet Board คู่มือ การใช้งานอุปกรณ์ Network. Please log in or sign up.
สมาชิกทั้งหมด
17,949
กระทู้ทั้งหมด
9,945
หัวข้อทั้งหมด
4,633

  • 3 wan จะให้กล้องวงจรปิดออกที่wan3
    เริ่มโดย indycg
    Read 9,656 times
0 สมาชิก และ 1 ผู้มาเยือน กำลังดูหัวข้อนี้
ตั้งฟอร์เวิร์ตพอร์ต ใช้กับ DVR ตั้งค่ายังงัยครับ ให้ออก pppoe-out3 3   ขอคำแนะนำด้วยครับ  DVR  = 192.168.1.39 port 81


ผมใช้สคริปต์ ตัวนี้ครับ     tot+3BB+3BB   (10+10+13M)

3 PPPOE to 1 LAN
#|/ip address
/ip address add address=192.168.1.10/24 network=192.168.1.0 broadcast=192.168.1.255 interface=ether5 comment="default configuration"

#|/ip firewall mangle
/ip firewall mangle add chain=input in-interface=pppoe-out1 action=mark-connection new-connection-mark=ether1_conn
/ip firewall mangle add chain=input in-interface=pppoe-out2 action=mark-connection new-connection-mark=ether2_conn
/ip firewall mangle add chain=input in-interface= pppoe-out3 action=mark-connection new-connection-mark=ether3_conn


/ip firewall mangle add chain=output connection-mark=ether1_conn action=mark-routing new-routing-mark=to_ether1
/ip firewall mangle add chain=output connection-mark=ether2_conn action=mark-routing new-routing-mark=to_ether2
/ip firewall mangle add chain=output connection-mark=ether3_conn action=mark-routing new-routing-mark=to_ether3


/ip firewall mangle add chain=prerouting dst-address-type=!local in-interface=ether5 per-connection-classifier=both-addresses-and-ports:3/0 action=mark-connection new-connection-mark=ether1_conn passthrough=yes
/ip firewall mangle add chain=prerouting dst-address-type=!local in-interface=ether5 per-connection-classifier=both-addresses-and-ports:3/1 action=mark-connection new-connection-mark=ether2_conn passthrough=yes
/ip firewall mangle add chain=prerouting dst-address-type=!local in-interface=ether5 per-connection-classifier=both-addresses-and-ports:3/2 action=mark-connection new-connection-mark=ether3_conn passthrough=yes
/ip firewall mangle add chain=prerouting connection-mark=ether1_conn in-interface=ether5 action=mark-routing new-routing-mark=to_ether1
/ip firewall mangle add chain=prerouting connection-mark=ether2_conn in-interface=ether5 action=mark-routing new-routing-mark=to_ether2
/ip firewall mangle add chain=prerouting connection-mark=ether3_conn in-interface=ether5 action=mark-routing new-routing-mark=to_ether3



#|/ip route
/ip route add dst-address=0.0.0.0/0 gateway=pppoe-out1 routing-mark=to_ether1 check-gateway=ping
/ip route add dst-address=0.0.0.0/0 gateway=pppoe-out2 routing-mark=to_ether2 check-gateway=ping
/ip route add dst-address=0.0.0.0/0 gateway=pppoe-out3 routing-mark=to_ether3 check-gateway=ping


/ip route add dst-address=0.0.0.0/0 gateway=pppoe-out1 distance=1 check-gateway=ping
/ip route add dst-address=0.0.0.0/0 gateway=pppoe-out2 distance=2 check-gateway=ping
/ip route add dst-address=0.0.0.0/0 gateway=pppoe-out3 distance=3 check-gateway=ping


#|/ip firewall nat
/ip firewall nat add chain=srcnat out-interface=pppoe-out1 action=masquerade
/ip firewall nat add chain=srcnat out-interface=pppoe-out2 action=masquerade
/ip firewall nat add chain=srcnat out-interface=pppoe-out3 action=masquerade


#| DHCP server is on switch, with address pool 192.168.1.50-192.168.1.200
/ip pool add name=default-dhcp ranges=192.168.1.50-192.168.1.200
/ip dhcp-server add name=default address-pool=default-dhcp interface=ether5 disabled=no
/ip dhcp-server network add address=192.168.1.0/24 gateway=192.168.1.10 dns-server=192.168.1.10 comment="default configuration"

#| DNS
/ip dns set allow-remote-requests=yes
/ip dns static add name=router address=192.168.1.10

#| Now Configure DNS server so users can resolve hostnames,
#| Ex.cache-size=5000KiB
#| DNS Google = 8.8.8.8,8.8.4.4
#| DNS 3BB = 110.164.252.222,110.164.252.223
/ip dns set allow-remote-requests=yes cache-max-ttl=1w cache-size=5000K max-udp-packet-size=512 servers=8.8.8.8,8.8.4.4

#1
ตอน forward port เลือก in-interface=pppoe-out3
ได้เลยป่ะครับ รอผู้รู้อีกทีเนอะ