返回列表 發帖

Cisco 2960 設定示範

no service pad- d+ X' w! F6 h% c
service timestamps debug datetime msec localtime show-timezone
4 s2 {: ?. C4 N6 m0 kservice timestamps log datetime localtime show-timezone; l8 J, @# d9 X" e' M
no service password-encryption
/ R% P- e6 p0 L; c" m!; d6 |0 Z9 K; e) h
hostname MY_SWITCH      [[[ Set switch hostname ]]]
1 |, P0 q4 ?6 U# P& w!
4 K; C2 G4 ]+ s; U; }% W# Eusername XXXXX secret 5 $1$i/aq$6gVcvlv2b7H6cLeDUGnhw0
. d2 A- O4 H8 p, uenable secret 5 $1$4KgT$eQ0xNzP8Q5lTdtLm/hFHJ1. L. W1 {  D4 a/ W' F* k6 w3 l
!- s* w) {& i" X: c0 H6 [# @
clock timezone HKT 8      [[[ Set Hong Kong Time Zone ]]]# l- A# ]& ?( i! J1 R
!
; _% X% y0 L5 o# u3 {; O. c: Rvtp mode transparent               [[[ VTP = Vlan trunking protocol ]]]  P, |% U6 \, B: `- m. K
!/ x( Y) E/ }6 r/ B+ p' |! \
spanning-tree mode pvst
4 n% L6 Z, l+ s  J6 G: \1 fno spanning-tree optimize bpdu transmission( a/ \, s0 R' Y5 S& _9 U
spanning-tree extend system-id  a! M4 \3 }& k7 g  s) F6 a
!
2 R9 L- r& B3 S+ W1 @' `3 q+ Iinterface FastEthernet0/1      [[[ Set access port in certain ports to allow certain Vlan ]]]
$ F& Q! {. N2 _$ p: F( B switchport mode access( i( w8 ]$ c+ Q0 w1 U
switchport access vlan 29 ~0 l2 h2 t3 v# J4 m; _
!. D+ q$ _) y9 J& [, ^' Z5 ^
interface FastEthernet0/2" h$ n/ N- T/ F. ]) M0 J' t9 i) g: [
switchport mode access8 Z: t+ u/ O8 @+ v! u2 ?! n4 D3 u: y
switchport access vlan 2! M/ r9 K& q7 }
!. ?* y3 y( g' ^4 \5 b% L- a  C6 I
interface FastEthernet0/33 n; G$ e% u) V5 y, p2 ^
switchport mode access
( @% @7 Q: q; x, A switchport access vlan 3
3 g; l6 @4 F9 F2 }: x0 M- _$ e!; V0 [4 o2 ]+ n8 Y, B6 x$ R; {
interface FastEthernet0/47 o+ _' e4 W8 I
switchport mode access. z  a! p0 h( y2 w$ w& j
switchport access vlan 3, {7 j3 M6 B4 {8 {7 ^4 K
!8 d  e$ X& i5 x7 s
interface FastEthernet0/5' ^' e7 d$ S- B1 P2 V0 k
switchport mode access
! G- Y% F8 f$ H switchport access vlan 2: g- f. W! A+ ]9 K' T* a! w+ n: S
!
1 ?7 O: z) B+ A! yinterface FastEthernet0/6( y1 i& F0 H/ n% y
switchport mode access% J. A5 t) Z! x! L) q# g+ m5 \# M
switchport access vlan 27 R# M  R# N( T. V* @. M
!
" H- G+ l5 b6 w3 C( m) Q+ ?interface FastEthernet0/7
7 ?/ H$ ?' z, Z9 d2 b, Vswitchport mode access4 s" o/ D" b' f3 J5 H" C
switchport access vlan 3
- W2 Q8 ^; X& W" V' P, d!9 v2 Q! k8 u' [* \
interface FastEthernet0/8- z% N8 z! t5 B& A  I5 f9 Y0 J
no ip address
! v: `' F7 F3 k' v! y  i!0 U* v* c. Z' k* r! I  H
interface FastEthernet0/9
4 x4 G* N- d/ w: q0 h" S; V, ^2 R' w no ip address
: _/ _. @, Q5 R!6 s; b. B% W7 W( P5 M* ^
interface FastEthernet0/10  x6 b  s# B# ~  g& H
no ip address
. p6 H: a$ e# O3 L8 t. `6 M!, I1 T) W$ K0 [# [+ W/ P) ^
interface FastEthernet0/11. |" D: v" R, Z* b; P
switchport mode access
7 Q3 ?( j+ z* F2 t8 y3 ^! Z+ y2 A switchport access vlan 3
4 R  F  {3 e( W8 |) {+ S!: V% z! r. K8 d5 r& P
interface FastEthernet0/12, I& ~, N0 n( J+ Y3 V
switchport mode access
5 V5 S0 e, |( M" e; I* T. { switchport access vlan 2/ Z: x! ~1 Y! t7 ^- B
!
1 n0 P) ~4 m, D3 @interface FastEthernet0/131 J' I* d8 b9 U/ U7 G
switchport mode access
# v0 h0 P4 S8 F switchport access vlan 3
% n' q( c& m: W5 i!
0 j  d0 A- B9 i  A& N7 Iinterface FastEthernet0/14
, }! q) v# g  g0 l, V/ c2 I, w! y no ip address; _9 W; X2 e) _# J
!
4 h. F3 a3 |: o% N) Minterface FastEthernet0/15* d2 k( w; R  O. {& P! x$ p- o
no ip address& u# J' z/ w/ \5 a7 ?8 j  s
!! Y5 C4 \( m* \# g0 u4 P
interface FastEthernet0/16
# R  T: M# |( [ no ip address2 O+ \* Q8 R+ x& N# K
!% Y( s) Q" q5 e' t1 u
interface FastEthernet0/17) @0 |6 S- M! V3 a
no ip address
$ R5 g8 A1 M* |+ h/ H!' u& y8 g3 Q( `
interface FastEthernet0/18+ t* Y2 l7 ]8 P. s$ K: o  W& X7 @  w
no ip address/ _: P1 z% ?5 i# r
!
% A5 _; E6 M$ b# ]' Pinterface FastEthernet0/19
/ M, \- ]% }* w8 Z9 i8 }9 P/ d no ip address3 ^; o( k" V+ x" H$ E. y
!& h/ N% ?  f7 H
interface FastEthernet0/20+ C; b$ h1 c5 F9 L0 j- L+ w: a) O
no ip address6 T  V# d& z: e5 e% J5 B, P
!- k; f' k' ]+ @1 g, u0 h9 @& o
interface FastEthernet0/21, D! {, k, M6 s+ d. d& Y
no ip address1 m, C1 B3 Y1 |+ Q* L- F$ q
!
9 ~2 o% N  N# z" h% N  ]interface FastEthernet0/225 ]) P+ |- w& E, Y
no ip address
" o" ?: [  M- k2 l6 u!$ D9 V8 \2 H& C7 X& |4 A9 d4 h) |
interface FastEthernet0/23
, w" l7 e6 `( y# w7 J) k) K( Y2 C no ip address1 t: i5 d% n1 M1 S( _
!
/ U2 m  j. U  O8 h. S7 Cinterface FastEthernet0/248 n, u+ n  P  ~3 `3 T
no ip address
$ S) _9 R( p; R8 j& w!4 w7 g. q8 ?4 U% B
interface GigabitEthernet0/1    [[[ Set trunk mode in uplink ports  ]]]
" b$ P4 }- e6 n* j! k3 } switchport mode trunk- o% Z+ }! i" C5 x7 A
!
/ \* }& t) }+ j* Finterface GigabitEthernet0/2) w' I+ }2 `$ m& W
switchport mode trunk
( h7 B) s; |- S8 {+ d! Q0 x$ B!; Q7 k0 b$ P( f3 X. U& ]+ l
interface Vlan1             [[[ Vlan 1 = native Vlan ]]]; l2 o1 v+ K1 e" L  V  m
ip address 172.18.25.203 255.255.255.0
& H2 n7 j* Q* x! E( A6 v* d, m6 a!) f3 f8 q( J# s0 ?- C
interface Vlan2/ }- E; }! ~% l! v' d; [
ip address 172.18.25.203 255.255.255.0
2 I0 A9 n  M3 h5 E/ i!
8 e" g* O/ y1 \2 A% V4 w$ `interface Vlan3
2 U# k, n4 w9 ]1 X; l ip address 172.18.25.203 255.255.255.0
0 o! i$ q8 U9 ?1 H. V!; r) q8 ]  d8 [! K
ip default-gateway 172.18.25.44        [[[ Set gateway IP address  ]]]]/ G* h1 U7 b( \1 L
!# u) |6 m& S' b$ L7 m5 H4 z' h" H
snmp-server community admin1234 RO
' E) W( k8 E' glogging 172.18.25.37     [[[ Set log server IP address ]]]
' x# W! w; @. O8 W* P1 k!4 W" }6 L3 N+ f1 t" Z  r% D1 r
line con 0
+ R) D! t8 ^* A4 f' w3 X* y password XXXXX: ?: [# V8 [) H% N
line vty 0 4
* d" P/ i: p/ n4 w4 _& Cline vty 5 15
+ ]8 ^5 L- c) J% ^!/ \' w9 I; f4 [' S7 n) I! V
ntp clock-period 17179912             [[[ NTP = network time protocol ]]]
( K' W: ?. B' ]& F- [ntp server 172.38.225.218! H5 N! k& V" C/ Q3 i: l/ K
end
Bill Tang     MSN:billtang@openplatform.com.hk
Openplatform Technology Co.,Ltd. 資訊坊科技有限公司  
無線工程施工、方案設計、無線產品、天饋材料、終端設備綜合供應商
Tel: 852-27491011  Fax: 852-81483532

返回列表