ข่าว: ข่าวประกาศ

  • 07 กรกฎาคม 2024, 03:16:45

เข้าสู่ระบบด้วยชื่อผู้ใช้ รหัสผ่าน และระยะเวลาในเซสชั่น

แสดงกระทู้

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - admin

หน้า: 1 ... 96 97 [98] 99 100 ... 115
1456
ในการตรวจสอบจะใช้เวลาประมาณ 5 วิ


1457
ฺBonded ADSL คือ การรวม ADSL หลาย ๆ เส้นให้วิ่งเหมือนเป็นเส้นเดียว

ถ้าเกิดกรณี Co-lo Down หรือ ไม่สามารถ Bonded ADSL ได้ในกรณีต่าง ๆ

Server ก็จะปรับวิ่งเป็นแบบ MultiWAN ธรรมดา

1458
คุยกับทีมวิจัย / Re: Ubuntu Distro Hadyai Internet Version WebInterface
« เมื่อ: 16 กรกฎาคม 2008, 23:43:54 »
สำหรับตัว Version WebInterface จะำเก็บค่า Config ต่าง ๆ ไว้ใน database
เพื่อง่ายต่อการ backup และ Restore

สำหรับผู้ที่ติดตั้งเดิมอยุ่แล้ว ก็สามารถอัพเดทได้เลย ไม่ต้องลงใหม่
แต่จำเป็นต้อง Config ค่าต่าง ๆ ใน WebInterface ให้เสร็จก่อน
แล้วทำการ Apply ตัว Script ก็จัดการสร้าง config ให้อัตโนมัติ คล้ายกับตัว Version แรก

สามารถ Backup และ Restore ค่า Config เก็บไว้ได้ เพื่องานในการติดตั้งครั้งต่อไป
หรือในกรณีเครื่อง Server เกิดมีปัญหา Hardware เสียขึ้นมาครับ


1459
Linux Server System / Procedure to change OpenSSH pre login banner
« เมื่อ: 16 กรกฎาคม 2008, 06:47:07 »
Procedure to change OpenSSH pre login banner
1) By default sshd server turns off this feature.

2) Login as the root user; create your login banner file:

# vi /etc/ssh/sshd-bannerAppend text:
Welcome to nixCraft Remote Login!

3) Open sshd configuration file /etc/sshd/sshd_config using a text editor:

# vi /etc/sshd/sshd_config4) Add/edit the following line:

Banner /etc/ssh/sshd-banner5) Save file and restart the sshd server:

# /etc/init.d/sshd restart6) Test your new banner (from Linux or UNIX workstation or use any other ssh client):

$ ssh vivek@rh3es.nixcraft.orgOutput:
Welcome to nixCraft Labs!
vivek@ rh3es.nixcraft.org's password:

Please note that this feature may not work with third party ssh client such as Putty.


1460
Linux Server System / Procedure to change /etc/issue - pre login file
« เมื่อ: 16 กรกฎาคม 2008, 06:45:17 »
Procedure to change /etc/issue - pre login file

Login as the root user. Open a file

# vi /etc/issue

Append new text as follows:
Welcome to nixCraft Labs!
Today is \d \t @ \n
Save and close the file. \d, \t or \n will expand as follows on run time.

/etc/issue - escape code

The issue-file (/etc/issue or the file set with the -f option) may contain certain escape codes to display the system name, date and time etc. All escape codes consist of a backslash (\) immediately followed by one of the letters explained below.

\b : Insert the baudrate of the current line.
\d : Insert the current date.
\s : Insert the system name, the name of the operating system.
\l : Insert the name of the current tty line.
\m : Insert the architecture identifier of the machine, eg. i486
\n : Insert the nodename of the machine, also known as the hostname.
\o : Insert the domainname of the machine.
\r : Insert the release number of the OS, eg. 1.1.9.
\t : Insert the current time.
\u : Insert the number of current users logged in.
\U : Insert the string "1 user" or " users" where is the number of current users logged in.
\v : Insert the version of the OS, eg. the build-date etc.

1461
มัวแต่พัฒนาตัว WebInterface อยู่น่ะ

เอาเป็นว่า ตัวใหม่จะรองรับ Bonded ADSL ไว้ด้วยละกัน

ถ้ามีสนใจหลายคนจะวาง Colo ไว้เป็นส่วนกลาง สำหรับระบบ Bonded ADSL

1462
คุยกับทีมวิจัย / Ubuntu Distro Hadyai Internet Version WebInterface
« เมื่อ: 16 กรกฎาคม 2008, 00:55:25 »
ความสามารถของ Version นี้

- สามารถ Config ได้จากหน้าเวป Interface
- รองรับ VLAN, DHCP, PPPoE, Static
- รองรับการทำงานไม่จำกัด WAN ตาม Interface ที่มี
- สามารถใช้งาน vpn ได้
- สามารถทำ Port Forwarding สำหรับ Create/Join  DotA ทั้งภายในร้านและนอกร้าน
- สามารถ config เพิ่มเกมส์ใหม่ ๆ ผ่านทางหน้าเวปได้
- สามารถ block web ที่ไม่พึ่งประสงค์ได้
- สามารถกำหนด ความเร็วของ ip กลุ่ม ip หรือ ช่วงของ ip ไ้ด้
- เก็บ Logfile ตามแบบ พรบ (Plawan)
- รองรับ Bonded ADSL
- รองรับ Module Authentication
- รองรับ Module Billing
- อื่น ๆ

สามารถอัพเดทได้วันที่ 12 สิงหาคม 2551

1463
ลองศึกษาการเพิ่ม WAN ที่ 3 ตามในเอกสารดูครับ

เด๋วจะมาเพิ่มอธิบายเพิ่มอีกที

1464
ไฟล์ dota.sh

ตรงค่า WAN1IP ก็ใส่เป็น IP จริงของ eth1 ได้เลย

เช่น

WAN1IP=61.19.25.130
WAN2IP=`ip addr show ppp102 |grep inet |cut -d " " -f 6`

เป็นต้น

1465
ไฟล์ tableroute.sh ให้เปลี่ยนในส่วนของ ppp101 เป็น eth1

เช่น

ยกตัวอย่างโดยการ Remark (ใช้ # นำหน้าของเดิม แสดงด้วยสีเหลือง) ใส่แถบสีส้ม สำหรับข้อความที่เพิ่มไปใหม่

# MARK INPUT PACKET
#iptables -t mangle -A PREROUTING -i ppp101 -j CONNMARK --set-mark 0x101
iptables -t mangle -A PREROUTING -i eth1 -j CONNMARK --set-mark 0x101
iptables -t mangle -A PREROUTING -i ppp102 -j CONNMARK --set-mark 0x102

# MARK OUTPUT PACKET
#iptables -t mangle -A POSTROUTING -o ppp101 -j CONNMARK --set-mark 0x101
iptables -t mangle -A POSTROUTING -o eth1 -j CONNMARK --set-mark 0x101
iptables -t mangle -A POSTROUTING -o ppp102 -j CONNMARK --set-mark 0x102

# MARK ADSL OUTPUT PACKET #
#iptables -t mangle -o ppp101 --insert FORWARD 1 -p tcp --tcp-flags SYN,RST SYN -m tcpmss --mss 1400:1536 -j TCPMSS --clamp-mss-to-pmtu
iptables -t mangle -o ppp102 --insert FORWARD 1 -p tcp --tcp-flags SYN,RST SYN -m tcpmss --mss 1400:1536 -j TCPMSS --clamp-mss-to-pmtu

# MAKE TABLE
ip route add table 101 192.168.200.0/24 dev eth0  proto kernel  scope link  src 192.168.200.1
#ip route add table 101 default dev ppp101
ip route add table 101 default via 61.19.25.129
ip route add table 102 192.168.200.0/24 dev eth0  proto kernel  scope link  src 192.168.200.1
ip route add table 102 default dev ppp102
ip route add default dev ppp102


ลองนำตัวอย่างไปประยุกต์ดูครับ

1466
ไฟล์ tablenat.sh และ 0nat

ให้เพิ่มการ nat เข้าไปใน eth ของ Leased Line ดังนี้

เช่น

#!/bin/bash

# This file is auto generate by xxxkung script

# Flush table nat
iptables -t nat -F

# MASQUERADE
iptables -t nat -A POSTROUTING -o ppp+ -j MASQUERADE
iptables -t nat -A POSTROUTING -o eth1 -j MASQUERADE

เป็นต้น

และก็ทำการ copy ไปเป็นไฟล์ 0nat ด้วย

cp /etc/init.d/tablenat.sh /etc/ppp/ip-up.d/0nat


1467
โดยไฟล์ interface

เดิม

# This file is auto generate by xxxkung script
# Loopback Interface
auto lo
iface lo inet loopback

# LAN Interface
auto eth0
iface eth0 inet static
     address 192.168.200.1
     netmask 255.255.255.0
     network 192.168.200.0
     broadcast 192.168.200.255

auto dsl-link1
iface dsl-link1 inet ppp
pre-up /sbin/ifconfig eth1 up
provider dsl-link1

auto eth1
iface eth1 inet manual


auto dsl-link2
iface dsl-link2 inet ppp
pre-up /sbin/ifconfig eth2 up
provider dsl-link2

auto eth2
iface eth2 inet manual

ให้แก้ไขส่วนของ eth1 หรือส่วนของ dsl-link1 ดังนี้

# This file is auto generate by xxxkung script
# Loopback Interface
auto lo
iface lo inet loopback

# LAN Interface
auto eth0
iface eth0 inet static
     address 192.168.200.1
     netmask 255.255.255.0
     network 192.168.200.0
     broadcast 192.168.200.255

# Leased Line Interface
auto eth1
iface eth1 inet static
     address 61.19.25.130
     netmask 255.255.255.248
     network 61.19.25.128
     broadcast 61.19.25.135


auto dsl-link2
iface dsl-link2 inet ppp
pre-up /sbin/ifconfig eth2 up
provider dsl-link2

auto eth2
iface eth2 inet manual

โดยกำหนด IP ของ Leased line ตามที่ ISP กำหนดมาให้

กรณีตัวอย่าง คือ

Router Leased Line IP 61.19.25.129
Server Ubuntu IP 61.19.25.130
Subnet mask เป็น 255.255.255.248  (ISP กำหนด IP จริงมาให้ 6 IP)

1468
ในกรณีที่ใช้กับ Leased Line นำมาวิ่งเกมส์นั้น

จะต้องทำการ รัน script config.sh ก่อนเพื่อให้ script สร้าง file config ขึ้นมาก่อน

แล้วทำการแก้ไขไฟล์

1. ไฟล์ /etc/network/interface
2. ไฟล์ /etc/init.d/tablenat.sh , /etc/ppp/ip-up.d/0nat
3. ไฟล์ /etc/init.d/tableroute.sh
4. ไฟล์ /etc/init.d/dota.sh


1469
น่าจะอัพเดทให้ เดือนละครั้งนะครับ

สำหรับ version ต่าง ๆ เก็บรวบรวมสิ่งที่ยังขาดตกอยู่ใส่เพิ่มเข้าไปให้สมบูรณ์

1470
จะอัพเดทเป็นบทความให้อ่านนะครับ

ยังขาดเหลืออะไรอยู่บ้าง จะได้รวบรวมใส่ไว้ใน Version ต่อไป

คาดว่านะอัพเดท เดือนละ Version พัฒนาไปเรื่อย ๆ

หน้า: 1 ... 96 97 [98] 99 100 ... 115