Tuesday, May 29, 2007

[Linux] setup jffnms แล้วจะ create postgresql database แล้ว error

แก้ไข
vi /var/lib/pgsql/data/pg_hba.conf
เพิ่ม
local all all trust
host all all 127.0.0.1 255.255.255.255 trust
แล้ว restart

Thursday, May 24, 2007

[Linux] Squid จะต้องการให้มีการ redirect url โดยดูจาก source ip

จะใช้ squid ทำตัวเป็น redirector โดยให้ดูจาก rule ที่กำหนด
#vi /etc/squid/squid.conf
url_rewrite_program /home/kitti/squid_redirect.pl
#vi /home/kitti/squid_redirect.pl

#!/usr/bin/perl
$|=1;

sub print_log
{
local($msg) = @_;
($sec,$min,$hour,$mday,$mon,$year,$wday,$yday,$isdst)=localtime(time);
$time=sprintf "%4d-%02d-%02d %02d:%02d:%02d",$year+1900,$mon+1,$mday,$hour,$min,$sec;
open(LOG,"+>>$log_file");
print LOG "$time : $msg";
close(LOG);
}

$rules_file = "/etc/squid/rules.conf";
$log_file = "/var/log/squid/redirect.log";
open (RULE,$rules_file);
&print_log("-- redirector start --\n");
while (<>) {
@X = split;
seek(RULE,0,0);
$url = $X[0];
($ip,$fqdn) = split(/\//,$X[1]);
$number=1;
$flag=0;
$line_no=0;
$go_url = $url;
while(){
chomp;
$line = $_;
if((!($line =~ /^[\#\;\t ]/))&&($line)){
($src_ip,$dst_url,$action,$redirect) = split(/[ |\t]+/,$line);
if(($url =~ /$redirect/)&&($ip =~ /$src_ip/)) {
$flag = 1;
$go_url = $url;
$action = "direct-to";
}elsif (($url =~ /$dst_url/)&&($ip =~ /$src_ip/)) {
$line_no = $number;
if($action eq 'bypass'){
$go_url = $url;
$flag = 1;
}elsif ($action eq 'redirect-to'){
$go_url = "302:$redirect";
$flag = 1;
}
}
}
$number++;
if($flag){ last; }
}
print "$go_url\n";
#&print_log("squid request: @X\n");
&print_log("ip:$ip, url:$url, rule:$line_no, action:$action, redirect:$go_url\n");

}
close(RULE);
&print_log("-- redirector exit-- \n");
exit(0);
#===============================================================

#vi /etc/squid/rules.conf
# description
;src-ip url action
1.1.1.1 www.domain1.com bypass
127.0.0.1 www.domain2.co.th bypass
.* www.domain3.com bypass
.* domain4.co.th bypass
.* .* redirect-to http://www.default-domain.co.th

Wednesday, May 16, 2007

[Linux] ใช้ firefox บน ubuntu แล้วเปิด Link ที่เป็น telnet:// ไม่ได้

อันเนื่องมาจากเปิด www.traceroute.org แล้วจะให้ firefox เรียก telnet ขึ้นมาให้เลย
1. ที่ address bar พิมพ์ about:config
2. click ขวา แล้วเลือก new->boolean
network.protocol-handler.external.telnet = true แล้ว Ok
3. click ขวาเพิ่มอีก new->string
network.protocol-handler.app.telnet = /usr/bin/firefox-telnet.sh
4. sudo vi /usr/bin/firefox-telnet.sh

#!/bin/bash
gnome-terminal -e "telnet ${1##telnet://}"

Wednesday, May 2, 2007

[CCIE] วันนี้มาคุยเรื่อง Cisco 7200 Simulator กัน

ขอขอบคุณ
http://www.ipflow.utc.fr/blog/
http://dynagen.org/
http://hacki.at/7200emu/

สำหรับคนที่ต้องการทำ lab ของinternetworkexpert iewb v4. โดยอุปกรณ์ของผมมีดังนี้
- Notebook DELL D620 Core2Duo 1.83 Ram 2G x 1 (OS Linux Ubuntu 7.04 ผมรู้สึกว่ามันเร็วกว่า XP)
- Catalyst 3750 x 4
- Catalyst 2950 x 1
- USB hub 4 port
- USB ethernet x 3 (เวลาไปซื้อเอาที่เป็น chipset realtek rtl8150 )น่ะครับแพงหน่อยประมาณ 500บาท ที่พันธ์ทิพย์ มันจะมียี้ห้อราคาถูกแนะนำว่าอย่าไปซื้อน่ะครับมันเห็นพร้อมกันไม่ได้มาก ที่จริงแล้วควรซื้อมาเท่ากับจำนวนของ router ที่ต่อออกไป switch 4 ตัวผมนับดูแล้วประมาณ 12 ตัวครับ แต่พอดีผมมี 2950 อยู่ก็เลยจะทำ trunk จาก DELL ไปหา 2950 แล้วต่อจาก 2950 ไปหา core switch ทั้ง 4 ตัวเพื่อประหยัด USB ethernet (แต่จะมี R6 ต่อไปหา core switchไม่ผ่าน 2950 ต้องใช้ usb ethernet ต่อกันตรงๆ เพราะว่าจะต้อง enable 802.1q ที่ R6 ด้วย)

จากตัว simulator มันค่อนข้างจะบริโภค CPU กับ RAM ครับ idea ของผมก็คือทุกอย่างที่ run อยู่จะต้องอยู่บน ram เพราะว่าเวลา access จะได้เร็วๆ และก็ใช้ idlepc, ghostios
ถ้าใครมี idea ดีก็บอกด้วยน่ะครับ
- สร้าง ramdisk 384M เพื่อที่จะได้ access ที่ ram จะได้เร็วๆกว่า harddisk (make_ramdisk.sh)
vi /boot/grub/menu.lst
kernel /boot/vmlinuz-2.6.20-15-lowlatency root=UUID=cd4fa939-5e2a-4450-82fb-45a11a435658 ro quiet splash verbose ramdisk_size=384000

แล้วก็ reboot

vi make_ramdisk.sh
#!/bin/sh

dd if=/dev/zero of=/dev/ram0 bs=1k count=384000
mke2fs -vm0 /dev/ram0 384000
mkdir -p /mnt/ramdisk
mount /dev/ram0 /mnt/ramdisk
mkdir -p /mnt/ramdisk/working
เวลา run script
$sudo ./make_ramdisk.sh

- สร้าง interface trunking ระหว่าง linux กับ 2950 (make_if_trunk.sh)
eth2 ทำเป็น mode promiscuous ด้วยไม่งั้นเดี๋ยวมีปัญหาเรื่องรับ packet multicast จุดนี้ผมงงอยู่หลายวัน พอ on ospf R1 กับ SW1 มันไม่ได้ทั้งๆที่เห็น multicast packet ออกจาก SW1 แล้ว ใช้ tcpdump มาจับ packet ดูก็ไม่เห็น ปรากฏว่า tcpdump มันไม่ทำตัวเป็น promisc ตั้งแต่ linux kernel 2.2+ จึงไม่เห็น multicast ที่เข้ามา แต่พอใช้ program ethereal มา sniff packet แล้วสามารถใช้ได้ในช่วงที่ sniff packet เหตุเพราะตัว linux เองมันก็จะ discard packet ที่ destination ไม่ใช่ตัวมันเอง เลยจึงจำเป็นต้องทำเป็น Mode สำส่อนเลย
#!/bin/sh
echo "Loading 802.1q module"
modprobe 8021q
ifconfig eth2 down
ifconfig eth3 down
ifconfig eth4 down
ifconfig eth2 promisc up
ifconfig eth3 promisc up
ifconfig eth4 promisc up
echo "Configuring VLAN_id to interface eth2"
vconfig add eth2 2
vconfig add eth2 3
vconfig add eth2 4
vconfig add eth2 5
vconfig add eth2 6
vconfig add eth2 7
vconfig add eth2 8
vconfig add eth2 9
vconfig add eth2 10
vconfig add eth2 11
echo "Creating interface for each vlans"
ifconfig eth2.2 promisc up
ifconfig eth2.3 promisc up
ifconfig eth2.4 promisc up
ifconfig eth2.5 promisc up
ifconfig eth2.6 promisc up
ifconfig eth2.7 promisc up
ifconfig eth2.8 promisc up
ifconfig eth2.9 promisc up
ifconfig eth2.10 promisc up
ifconfig eth2.11 promisc up

เวลา run script
$sudo ./make_if_trunk.sh

- ทำการ run process dynamips (start-dynamips.sh)
#!/bin/sh
cd /var/log/
sudo nice dynamips -H 3601 &
sudo nice dynamips -H 3602 &
sudo nice dynamips -H 3603 &
sudo nice dynamips -H 3604 &
sudo nice dynamips -H 3605 &
sudo nice dynamips -H 3606 &
sudo nice dynamips -H 3607 &
sudo nice dynamips -H 3608 &
sudo nice dynamips -H 3609 &
sudo nice dynamips -H 3610 &

เวลา run script
$sudo ./start-dynamips.sh

- script สำหรับ run dynagen (start-ccie-x.sh)
#!/bin/sh
cp -f /home/kitti/DATA/Dynamips/iewb4/working/c3600_R[1-6]_nvram /mnt/ramdisk/working/
sudo -u kitti /usr/local/dynagen/dynagen /home/kitti/DATA/Dynamips/iewb4/config/ccie-x.net
echo "Sync data..please wait...."
cp -f /mnt/ramdisk/working/* /home/kitti/DATA/Dynamips/iewb4/working/

เวลา run script
$sudo ./start-ccie-x.sh

- config file ของ dynagen (ccie-x.net)

#------------------------------------------
#Begin Dynagen config file
autostart = False
ghostios = true
sparsemem = true
mmap = false

###############################################################################
#
# Internetwork Expert Routing & Switching topology Version 4.0 mappings for dynamips/dynagen
# by: Brian McGahan, CCIE #8593
# bmcgahan@internetworkexpert.com
#
# For more information:
# Dynamips: http://www.ipflow.utc.fr/index.php/Cisco_7200_Simulator
# Dynagen: http://dyna-gen.sourceforge.net/
# Hacki's Forum: http://hacki.at/7200emu/index.php
# Internetwork Expert's Forum: http://forum.internetworkexpert.com
#
###############################################################################

##################################################
#
# Define global router parameters for instance 1
#
##################################################


[localhost:3601]
udp = 11000

workingdir = /mnt/ramdisk/working

[[3640]]
#
# Specify 3640 IOS image on Windows here:
image = /home/kitti/DATA/Dynamips/iewb4/images/c3640-jk9o3s-m.123-21.bin

ram = 73
disk0 = 0
disk1 = 0

[[Router R1]]
model = 3640
console = 2001
slot0 = NM-1FE-TX
slot1 = NM-4T
F0/0 = NIO_gen_eth:eth2.11
S1/0 = FRSW 1
idlepc = 0x6046e3ec


##################################################
#
# Define global router parameters for instance 2
#
##################################################


[localhost:3602]
udp = 12000

workingdir = /mnt/ramdisk/working
[[3640]]
#
# Specify 3640 IOS image on Windows here:
image = /home/kitti/DATA/Dynamips/iewb4/images/c3640-jk9o3s-m.123-21.bin

ram = 73
disk0 = 0
disk1 = 0

[[Router R2]]
model = 3640
console = 2002
slot0 = NM-1FE-TX
slot1 = NM-4T
F0/0 = NIO_gen_eth:eth2.2
S1/0 = FRSW 2
idlepc = 0x6046e3ec


##################################################
#
# Define global router parameters for instance 3
#
##################################################


[localhost:3603]
udp = 13000

workingdir = /mnt/ramdisk/working
[[3640]]
#
# Specify 3640 IOS image on Windows here:
image = /home/kitti/DATA/Dynamips/iewb4/images/c3640-jk9o3s-m.123-21.bin

ram = 73
disk0 = 0
disk1 = 0

[[Router R3]]
model = 3640
console = 2003
slot0 = NM-4E
slot1 = NM-4T
S1/0 = FRSW 3
S1/1 = FRSW 13
S1/2 = R1 S1/1
S1/3 = R2 S1/1
E0/0 = NIO_gen_eth:eth2.3
E0/1 = NIO_gen_eth:eth2.4
idlepc = 0x6046e3ec


##################################################
#
# Define global router parameters for instance 4
#
##################################################


[localhost:3604]
udp = 14000

workingdir = /mnt/ramdisk/working
[[3640]]
#
# Specify 3640 IOS image on Windows here:
image = /home/kitti/DATA/Dynamips/iewb4/images/c3640-jk9o3s-m.123-21.bin

ram = 73
disk0 = 0
disk1 = 0

[[Router R4]]
model = 3640
console = 2004
slot0 = NM-4E
slot1 = NM-4T
E0/0 = NIO_gen_eth:eth2.5
E0/1 = NIO_gen_eth:eth2.6
S1/0 = FRSW 4
S1/1 = R5 S1/1
idlepc = 0x6046e3ec


##################################################
#
# Define global router parameters for instance 5
#
##################################################


[localhost:3605]
udp = 15000

workingdir = /mnt/ramdisk/working
[[3640]]
#
# Specify 3640 IOS image on Windows here:
image = /home/kitti/DATA/Dynamips/iewb4/images/c3640-jk9o3s-m.123-21.bin

ram = 73
disk0 = 0
disk1 = 0

[[Router R5]]
model = 3640
console = 2005
slot0 = NM-4E
slot1 = NM-4T
E0/0 = NIO_gen_eth:eth2.7
E0/1 = NIO_gen_eth:eth2.8
S1/0 = FRSW 5
idlepc = 0x6046e3ec


##################################################
#
# Define global router parameters for instance 6
#
##################################################


[localhost:3606]
udp = 16000

workingdir = /mnt/ramdisk/working
[[3640]]
#
# Specify 3640 IOS image on Windows here:
image = /home/kitti/DATA/Dynamips/iewb4/images/c3640-jk9o3s-m.123-21.bin

ram = 73
disk0 = 0
disk1 = 0

[[Router R6]]
model = 3640
console = 2006
slot0 = NM-4E
slot1 = NM-4T
E0/0 = NIO_gen_eth:eth3
E0/1 = NIO_gen_eth:eth4
S1/0 = FRSW 6
idlepc = 0x6046e3ec


##################################################
#
# Define global router parameters for instance 11
#
##################################################


[localhost:3607]
udp = 17000

workingdir = /mnt/ramdisk/working
[[3640]]
#
# Specify 3640 IOS image on Windows here:
image = /home/kitti/DATA/Dynamips/iewb4/images/c3640-jk9o3s-m.123-21.bin

ram = 73
disk0 = 0
disk1 = 0

[[Router BB1]]
model = 3640
console = 2007
slot1 = NM-4T
S1/0 = BB3 S1/0
S1/1 = FRSW 21
cnfg = /home/kitti/DATA/Dynamips/iewb4/working/BB1.initial.config.txt
idlepc = 0x6046e3ec



##################################################
#
# Define global router parameters for instance 12
#
##################################################


[localhost:3608]
udp = 18000

workingdir = /mnt/ramdisk/working
[[3640]]
#
# Specify 3640 IOS image on Windows here:
image = /home/kitti/DATA/Dynamips/iewb4/images/c3640-jk9o3s-m.123-21.bin

ram = 73
disk0 = 0
disk1 = 0

[[Router BB2]]
model = 3640
console = 2008
slot0 = NM-4E
E0/0 = NIO_gen_eth:eth2.9
cnfg = /home/kitti/DATA/Dynamips/iewb4/working/BB2.initial.config.txt
idlepc = 0x6046e3ec



##################################################
#
# Define global router parameters for instance 13
#
##################################################


[localhost:3609]
udp = 19000

workingdir = /mnt/ramdisk/working
[[3640]]
#
# Specify 3640 IOS image on Windows here:
image = /home/kitti/DATA/Dynamips/iewb4/images/c3640-jk9o3s-m.123-21.bin

ram = 73
disk0 = 0
disk1 = 0

[[Router BB3]]
model = 3640
console = 2009
slot0 = NM-4E
slot1 = NM-4T
E0/0 = NIO_gen_eth:eth2.10
E0/3 = NIO_gen_eth:eth0
cnfg = /home/kitti/DATA/Dynamips/iewb4/working/BB3.initial.config.txt
idlepc = 0x6046e3ec


##################################################
#
# Define Frame-relay parameter
#
##################################################

[[FRSW FRSW]]

# R1 to FRSW
1:102 = 2:201
1:103 = 3:301
1:113 = 13:311
1:104 = 4:401
1:105 = 5:501

# R2 to FRSW
2:203 = 3:302
2:213 = 13:312
2:204 = 4:402
2:205 = 5:502

# R3 to FRSW
3:304 = 4:403
3:305 = 5:503
13:314 = 4:413
13:315 = 5:513

# R4 to FRSW
4:405 = 5:504

# R6 to FRSW
6:51 = 21:51
6:100 = 21:100
6:101 = 21:101
6:201 = 21:201
6:301 = 21:301
6:401 = 21:401

#End Dynagen config file
#------------------------------------------

- สุดท้ายก็ IOS ของ router ที่จะใช้ครับ

Wednesday, April 25, 2007

[Linux] config vlan trunking ต่อเข้ากับ Cisco catalyst2950

มาเริ่มทำเลยดีกว่า (อ้างอิง Ubuntu linux 7.04)
$sudo apt-get install vlan
ทำการ load module 802.1q
$sudo modprobe 8021q
ทำการ add tag 2 กับ physical interface eth2
$sudo vconfig add eth2 2
ทำการ create logical insterface eth2.2
$sudo ifconfig eth2.2 192.168.2.2 netmask 255.255.255.0 up

-- Switch Cisco catalyst2950
interface f0/1
des ## connect to linux box eth2 ##
no shut
switchport mode trunk

interface f0/2
switchport mode access
switchport access vlan 2
no shut

Monday, April 23, 2007

[Linux] ต้องการ install ผ่าน network โดย boot ผ่าน PXE

เรื่องมีอยู่ว่าผมจะ install CentOS แต่ Download มาเป็น DVD แต่ว่าตัว server ดันไม่มี dvd drive เลยต้องลำบากหาวิธีที่จะ install เห็นมี install ผ่าน network โดยให้ server มัน boot ผ่าน PXE แล้ว install ผ่าน http (ไม่รู้ว่างานนี้ทำเวอร์เกินไปหรือเปล่า?)
ต้องมี
Notebook ผมเก็บตัว installer ต้อง enable service ดังนี้
interface eth0
$sudo ifconfig eth0 10.10.10.1 netmask 255.255.255.0 up

Web server (lighttpd)
$sudo apt-get install lighttpd
$sudo /etc/init.d/lighttpd start

download image ของ CentOS ชื่อ /tmp/CentOS-5.0-i386-bin-DVD.iso
$sudo mkdir -p /var/www/installer
$sudo mount -t iso9660 -o loop /tmp/CentOS-5.0-i386-bin-DVD.iso /var/www/installer

DHCP Service
$sudo apt-get install dhcpd3-server
$sudo vi /etc/dhcp3/dhcpd.conf
ddns-update-style none;
subnet 10.10.10.0 netmask 255.255.255.0 {
range 10.10.10.100 10.10.10.200;
option routers 10.10.10.1;
filename="pxeboot/pxelinux.0";
}
$sudo /etc/init.d/dhcp3-server start

PXE Service
$sudo apt-get install pxe
$sudo /etc/init.d/pxe start

SYSLINUX
$sudo apt-get install syslinux

TFTP Service
$sudo apt-get install atftpd
$sudo mkdir -p /tftpboot/pxeboot
$sudo mkdir -p /tftpboot/pxeboot/CentOS_5.0_i386
$sudo cp /var/www/installer/images/pxeboot/vmlinuz /tftpboot/pxeboot/CentOS_5.0_i386
$sudo cp /var/www/installer/images/pxeboot/initrd.img /tftpboot/pxeboot/CentOS_5.0_i386
$sudo cp /usr/lib/syslinux/pxelinux.0 /tftpboot/pxeboot/ <-- file นี้เอามาจาก syslinux พอดีเครื่องผมใช้ ubuntu
$sudo mkdir -p /tftpboot/pxeboot/pxelinux.cfg

# config file สำหรับเลือก boot แยกแต่ล่ะ mac address หรือค่า default
$sudo vi /tftpboot/pxeboot/pxelinux.cfg/00-E0-4C-03-1D-08 <--- mac address ของ server
หรือ
$sudo vi /tftpboot/pxeboot/pxelinux.cfg/default

default CentOS_5.0_i386
timeout 10
prompt 1
display display.msg
label CentOS_5.0_i386
kernel CentOS_50_i386/vmlinuz
append initrd=CentOS_50_i386/initrd.img
หรือถ้ามี script kickstart
# append initrd=CentOS_50_i386/initrd.img ks=http://10.10.10.1/installer/anaconda.cfg
$sudo vi /tftpboot/pxeboot/display.msg
Linux installer via PXE boot:
CentOS_5.0_i386

$sudo chown -R nobody:nobody /tftpboot
$sudo /etc/init.d/atftpd start

ตอนนี้จัดเตรียมตัว install ไว้แล้ว
จากนั้นก็เอา server มาต่อ สาย lan แล้วให้ boot จาก lan card โดยให้ set ที่ bios
status มันก็จะ request DHCP แล้วก็จะได้ ip กลับไป
Linux installer via PXE boot:
CentOS_5.0_i386
boot:
ให้พิมพ์ดังนี้
boot: CentOS_5.0_i386 แล้ว enter
มันก็จะ boot แล้วเข้าสู่กระบวนการ install แล้วให้เราเลือก source ที่จะใช้ ผมเลือกใช้ http
มันจะถาม ip ของ web server และ directory
ip or name server: 10.10.10.1
directory: /installer/
แล้ว OK

Friday, April 20, 2007

[Cisco] ทำ frame-relay traffic shaping

from: h**p://www.cisco.com/warp/public/125/traffic_shaping_6151.html
interface Serial0/0
no ip address
encapsulation frame-relay
no fair-queue
frame-relay traffic-shaping
!
interface Serial0/0.1 point-to-point
ip address 10.1.1.2 255.255.255.0
frame-relay interface-dlci 16
frame-relay class cisco
!
map-class frame-relay cisco
frame-relay cir 64000
frame-relay mincir 32000
frame-relay adaptive-shaping becn
frame-relay bc 8000

อ้างจากรูป













เพื่อเข้าใจง่ายขึ้นเรื่อง CIR,Bc,Be
CIR = Commit Information Rate
Bc = Burst commit คือใน 1 Tc จะสามารถส่ง data ได้กี่บิต
Be = Burst excess
AR = Access Rate
Tc = Time interval (default 125ms)
Bc = CIR * Tc (หรือ Bc = CIR/8 กรณีที่ Tc ค่า default 125ms)
Be = (AR-CIR) * Tc

Friday, April 13, 2007

[FreeBSD] พอ install OS แล้วผมก็เตรียมพร้อมสำหรับโหลดบิต

ต้องทำให้เครื่อง pentium3 แรงๆเพื่อจะได้โหลดบิต (ทำแบบมั่วๆ search ใน google เรื่อง optimize, tunning บ้างมารวมๆกัน)

Thursday, April 12, 2007

[FreeBSD] ต้องการ compile Kernel ใหม่แต่ตอน Install เราไม่ได้เลือกให้ลง src

#/usr/sbin/sysinstall
- configure -> Distributions -> src -> All -> Ok -> FTP or CD/DVD
เมื่อเสร็จแล้ว
/usr/src/sys/i386/conf

Monday, April 9, 2007

[MySQL] ใช้ command line แก้ไข column size

กันลืม ใช้บ่อยมากเวลาแก้ไข column size

ALTER TABLE foo MODIFY column FOO ...

I would just use TEXT or TINYTEXT but if you wanted
only 1000 chars, you would use VARCHAR(1000);

บทเรียนจากพระพยอมเรื่องซื้อที่ดิน

ผมดูข่าวของพระพยอมแล้วทำให้รู้อะไรบางอย่างว่า เวลาคุณไปซื้อกล้วยทอด แล้วคุณท้องเสีย จะเอาผิดใครไม่ได้ เพราะว่าคุณไม่ได้ถามแม่ค้าว่า น้ำมันค้างมานานหรือยัง กล้วยเสียหรือเปล่า แป้งมันที่มาทอดได้คุณภาพ อย. หรือเปล่า ไม้จิ้มเนี่ยล้างสะอาดแล้วใช่ไหม.......ประเทศไทย

Thursday, April 5, 2007

[Cisco] จะ enable portchannel บน sup กับ module อื่น

ผมจะ enable portchannel บน interface ที่อยู่บน sup กับ interface GiE ที่ module อื่นปรากฏว่าพอผม add port ที่อยู่บน sup เข้าไปเกิด error
Apr 5 08:53:31: %EC-SP-5-CANNOT_BUNDLE2: Gi6/1 is not compatible with Gi1/11 and will be suspended (qos-card types of Gi6/1 do not match Gi1/11)

แก้ปัญหาโดย
conf t
interface port-channel 5
no mls qos channel-consistency
end
wr
ก็จะสามารถ bundle เข้าไปได้ครับ

Monday, April 2, 2007

[Troubleshoot] ตรวจสอบว่า server เปิด port หรือเปล่า?

ผมมีปัญหาอยู่ว่าใช้งาน www ว่าเปิดใช้งานได้หรือเปล่า?
ผมจึง test ไปที่ port 80
#telnet www.google.co.th 80
GET / HTTP/1.0
Host: www.google.co.th

HTTP/1.0 200 OK
Cache-Control: private
Content-Type: text/html; charset=windows-874
Set-Cookie: PREF=ID=5b1649e656f8f15d:TM=1175486984:LM=1175486984:S=N34yIfvZSGMzc36h; expires=Sun, 17-Jan-2038 19:14:07 GMT; path=/; domain=.google.co.th
Server: GWS/2.1
Date: Mon, 02 Apr 2007 04:09:44 GMT
Connection: Close
<----- DATA ------>