返回列表 發帖

Cisco 2960 設定示範

no service pad
) j0 B: h5 S3 I6 i# s: ?service timestamps debug datetime msec localtime show-timezone
4 N/ ?8 p2 e& r- K  Wservice timestamps log datetime localtime show-timezone
6 z, H( _6 {0 i1 }# t. Yno service password-encryption1 A( ]6 F/ w7 P' F
!9 j7 |& ?# |) f) R
hostname MY_SWITCH      [[[ Set switch hostname ]]], i+ c% W' j  m/ t: Z7 o
!. e& J! U" l7 w- ^" R$ Y9 C4 E
username XXXXX secret 5 $1$i/aq$6gVcvlv2b7H6cLeDUGnhw0
; _; `9 Z- o3 W9 g5 Jenable secret 5 $1$4KgT$eQ0xNzP8Q5lTdtLm/hFHJ1, s  s) y" F" I+ `4 W3 z' k
!. `9 E( J0 a1 U
clock timezone HKT 8      [[[ Set Hong Kong Time Zone ]]], u3 ^- a% e0 f% S! [2 z6 B' G, w+ X
!
9 x; X5 f1 h8 a1 E$ Pvtp mode transparent               [[[ VTP = Vlan trunking protocol ]]]
. D7 O- }$ `$ A!
: F* n/ x1 S$ T4 vspanning-tree mode pvst; O7 O  W0 Q4 F
no spanning-tree optimize bpdu transmission
! V- \) ?7 `1 {0 Z4 p; Jspanning-tree extend system-id
& B1 u( ~# y9 M! F!
1 l5 s6 v7 R, {* z9 o) o$ t8 Minterface FastEthernet0/1      [[[ Set access port in certain ports to allow certain Vlan ]]]& [+ S3 C9 n; e) d# s7 T
switchport mode access
  k) Q: p5 f$ k  N switchport access vlan 2# {9 l' G5 m: Z/ q. t$ ]
!9 V# b( u+ K8 t3 P
interface FastEthernet0/2
& ~4 M% ~. Y+ ^" eswitchport mode access* x  ^* b5 b5 k! v+ J) ?
switchport access vlan 2
% h9 E0 h4 g9 L) @. h# H8 [!
) z% e; x& b2 a) ^interface FastEthernet0/3
) |& D$ M6 {1 j, D! D" b" Yswitchport mode access, k7 a7 Q* s3 p/ W9 `1 D
switchport access vlan 3
3 P" M& K  [- o6 s& Q+ S!. E) e, d, A1 t4 B8 v# H
interface FastEthernet0/4
: I! V3 W; ]5 ]; j9 B5 Aswitchport mode access  M4 l3 b# p+ I
switchport access vlan 3
( [7 t: b- J+ Q% ^# Q!- {! N1 d$ n8 J/ x5 P% l: I( j
interface FastEthernet0/5
; r- G+ O# f  T- oswitchport mode access
) t7 M" F) j1 l/ o4 } switchport access vlan 2" b/ C! H( X; }. H6 B9 V
!' g3 y! @: |8 X
interface FastEthernet0/6
0 K( a: f1 b  y9 J  m& W0 Zswitchport mode access* E1 ?. L6 P. T* j* A, ]
switchport access vlan 2' V7 W, H* A0 o4 t5 C
!
" s; T! s1 n7 A' j* v) x: x6 F4 binterface FastEthernet0/7+ S* M4 h: z% o
switchport mode access
/ q5 X4 I* e6 S: D7 e switchport access vlan 3
' J: M* [& Y1 Z9 Z# s' E!
8 w( W/ `. M2 q2 V4 e% hinterface FastEthernet0/8
3 G1 D: Y2 t7 B! m# W' ^; ? no ip address
0 Q: T/ M0 ^2 R8 P* V* E& f!. F1 L2 b7 B5 e, G7 t
interface FastEthernet0/9* r2 n2 ?" j9 N
no ip address
$ ?% E- R9 k% R  ^! G!3 _9 [9 ^9 H( r
interface FastEthernet0/10
2 S  T6 i+ R* M! V  ] no ip address% @/ ]" l: P! Q  {3 F
!
% O6 T0 I% w( L+ J$ p! jinterface FastEthernet0/11
9 P- U: y: p! m! Bswitchport mode access8 H/ o/ F3 m+ l+ U% e: q3 ?* n
switchport access vlan 3
- T. B4 f$ K; y3 U4 E!
1 Q- f8 }- n. dinterface FastEthernet0/127 D' a0 X- Y: ^
switchport mode access
7 e5 e# R5 f: d' B+ } switchport access vlan 2
! i* h2 c1 l7 T: ?$ J, f6 K0 Y; _!
- s4 s% N: m' q# Tinterface FastEthernet0/139 }# m9 k1 p" c% c
switchport mode access
* v. v( x/ ~. E( u; F0 M" A3 ~ switchport access vlan 31 S" W" `1 N: A, e' X  K
!
9 T% v  H: K/ e! E, t7 D, g% qinterface FastEthernet0/14
: M# B- i! K/ q2 ~5 P$ |- \ no ip address
4 K1 ~. ~- q, Z2 G$ \! J/ f!% G$ ^4 i, B5 i0 s; _
interface FastEthernet0/15  L! v# i3 Y3 a  _. g
no ip address
% ?* G! ^, {1 H2 C$ e2 _* }!, y! K- a' Z4 z& d1 w
interface FastEthernet0/166 z* \/ T4 b5 j1 g$ r
no ip address0 e2 d8 h# L% T, I6 o9 J
!
# G+ v) Q; j9 D3 k1 R& R5 Pinterface FastEthernet0/17
8 Z2 w- R7 a$ z; M8 V3 I8 ~5 M no ip address
3 ^6 [* T' F. _& p% r, l; [* O!- {. E' w; w: A$ x9 M: z9 C  W
interface FastEthernet0/18
7 K# P3 I- e' t4 {% F no ip address
& D: e( H, P- c& ~!7 H$ u1 L4 I# H3 T. L8 Z4 |
interface FastEthernet0/19" O9 o1 L0 s$ N2 G$ [
no ip address; o! z6 ]/ T" Z$ O. l! W
!, g' b! y9 ^4 d1 ?: f$ O
interface FastEthernet0/20" X: i2 X% N) v3 b: \! L
no ip address' s9 g4 N$ j* e/ L+ f
!
9 X/ t6 m' {7 S9 B1 {' C$ I' g# ainterface FastEthernet0/21
6 p! t9 G' w; e: Z( I no ip address+ z1 h" _. H0 J0 P* A9 n" @3 o
!3 `$ B9 m. B% p( m4 E
interface FastEthernet0/22: D1 l0 f  i3 b
no ip address
5 f+ b5 ~2 }4 T; }0 g!
4 w* }2 r; y! a; ?+ U& E. `interface FastEthernet0/23' H9 M$ x4 Q9 I2 c7 ?; ?$ }
no ip address
" E8 u& Y8 A: [, L) j, J1 \!. x4 Z# J8 T3 ~% T6 X* ]4 ?
interface FastEthernet0/24
! }2 L: U9 i& j/ {( f- Q no ip address
# a) t. N0 @' T!
* e% y* M- B2 e1 linterface GigabitEthernet0/1    [[[ Set trunk mode in uplink ports  ]]]
! Y+ [! ^6 H' I$ K  r switchport mode trunk
* \  y7 N( h+ D) Q+ U& _2 w!$ y) Z7 @/ i: X+ ]# ~, D
interface GigabitEthernet0/2
; U3 D% X* M* a) v2 h switchport mode trunk
3 T+ N( o7 y4 e5 k& b!
; O' q% B0 l+ z) a( R  D. linterface Vlan1             [[[ Vlan 1 = native Vlan ]]], M6 S# Z, w4 F' q( q5 E
ip address 172.18.25.203 255.255.255.0
; ~+ E7 g( W0 N& M! ^9 Y; b!
; a* N) b+ D+ q) S- Z, }# Rinterface Vlan2: a. Z' Y2 d/ P( g; j/ y  K
ip address 172.18.25.203 255.255.255.01 r4 ~5 w8 v) a0 ?. T
!
1 b  I) z8 ], V1 Tinterface Vlan3
! ^" j; F$ x6 V# K8 |; U4 L ip address 172.18.25.203 255.255.255.0
. y1 o0 {. N9 ~5 r8 {!# B; E8 z% h" g# A0 ?( v
ip default-gateway 172.18.25.44        [[[ Set gateway IP address  ]]]]& ^% v$ T1 x' s: z2 }2 L. E7 {0 H
!6 v6 G- H- \4 I/ k
snmp-server community admin1234 RO
$ a! @: U& P! k: Qlogging 172.18.25.37     [[[ Set log server IP address ]]]
. a: U3 G1 S( T! V( O) {!
5 C) P9 d6 n, \4 \2 f& s9 d/ J& K, }0 \line con 0
' h7 c# q5 c3 N8 r/ n" Y- s) Z password XXXXX+ ]. O. E) |# c# ^/ s% }/ W  j
line vty 0 4# g' X" c+ ^' X# W- Y
line vty 5 15
6 s" z" x  R5 ?( _. }- ]2 G!
/ r/ T- |0 m- u+ Q- |! G9 g7 g% |ntp clock-period 17179912             [[[ NTP = network time protocol ]]]
+ E0 _& E/ c" \( {/ b# zntp server 172.38.225.218( F, i$ }* e/ q
end
Bill Tang     MSN:billtang@openplatform.com.hk
Openplatform Technology Co.,Ltd. 資訊坊科技有限公司  
無線工程施工、方案設計、無線產品、天饋材料、終端設備綜合供應商
Tel: 852-27491011  Fax: 852-81483532

返回列表