본문 바로가기
IT스터디/벤더별 자료

주니퍼 스위치 - 자주 사용하는 Config 모음

by 천하무적 엔지니어 2021. 3. 9.

이번 시간에는 주니퍼 스위치에서 자주 사용하는 명령어에 대해서 알아보겠습니다. 주니퍼는 필드에서 생각보다 많이 사용되지 않고 , 엔지니어도 별로 없고 , 명령어도 다른 벤더들하고 틀려서 컨트롤하는 게 쉽지는 않은 장비예요. 명령어가 얼마나 다른지 한번 알아볼까요

 

 

 

1. 주니퍼 스위치 config 확인

 

초기 알람 램프 off))
junotec@jonotec> request system configuration rescue save
 
junotec@jonotec# set chassis alarm management-ethernet link-down ignore
 
*상태 확인 junotec@junotec# run show chassis lcd

root 설정))
junotec@junotec# set system root-authentication plain-text-password

사용자 생성)
junotec@junotec# set system login user admin class super-user authentication plain-text-password

Telnet  서비스 활성화))
junotec@junotec# set system services telnet

 

vlan 설정))
set interfaces vlan unit 0 family inet address 10.1.100.4/16  ==> unit 0 = default = vlan.0
( unit 10 = vlan 10 = vlan.10)
set vlans default l3-interface vlan.0
set vlans default vlan-id 1
set routing-options static route 0.0.0.0/0 next-hop 10.1.0.1
 

L3 port  설정))
a. L3 Port 설정을 위해 해당 포트에 L2 role을 제거
형식: delete interfaces interface-name unit 0 family ethernet-switching
(ex: ge-0/0/0)
 
root@junotec# delete interfaces ge-0/0/0 unit 0 family ethernet-switching
* EX Switch의 모든 port 는 최초 layer2 access port 임
 
b. L3 port 생성 및 IP 할당 ?
형식: set interface interface-name unit 0 family inet address ip-address
ex :  root@junotec# set interface ge-0/0/0 unit 0 family inet address 192.168.123.254/24
 
delete interfaces ge-0/0/22 unit 0 family ethernet-switching
delete interfaces ge-0/0/23 unit 0 family ethernet-switching
 
set interfaces ge-0/0/22 unit 0 family inet address
set interfaces ge-0/0/23 unit 0 family inet address

 

trunk 설정))
set interfaces ge-0/0/10 unit 0 family ethernet-switching port-mode trunk
set interfaces ge-0/0/10 unit 0 family ethernet-switching vlan members all
 
OR
    set interfaces ge-0/0/10 unit 0 family ethernet-switching port-mode trunk
    set vlans vlan1 interface ge-0/0/10.(ex: vlan15, vlan20)

 

라우팅))
junotec@junotec# set routing-options static route 0.0.0.0/0 next-hop 192.168.123.254 

시간 설정))
junotec@junotec> set date 201201271040
Fri Jan 27 10:40:00 KST 2012
 
junotec@junotec# set system time-zone Asia/Seoul
* NTP 서버 연동 시 128sec 이상의 시간 오차 발생 시 동기화 안됨

 

 

 

 

 


<확인 명령어>
 
config정보 확인))
junotec@junotec> show configure | display set
 
샤시정보))
junotec@junotec> show chassis routing-engine
 
junotec@junotec> show chassis hardware
 
시스템 리부팅))
junotec@jonotec> request system reboot
 
시스템파워 off))
junotec> request system power-off
 
시간설정 및 확인))
junotec@junotec# run show system uptime
 
변경내용 비교))
junotec@EX-Switch# show | compare
 
라우팅 테이블))
junotec@junotec# run show route

 

 

 
맥어드레스 테이블))
junotec@junotec# run show ethernet-switching table
 
arp 테이블))
junotec@junotec# run show arp
 
port 상태 확인))
junotec@junotec> show ethernet-switching interfaces
 
스패닝트리))
{master:0}
admin> show spanning-tree bridge brief
 
admin> show spanning-tree bridge detail
 
admin> show spanning-tree interface
* Default bridge-priority 32768

소프트웨어 업그레이드))
software upgrade)
# set system service ftp
# set system login user admin class super-user authentication plain-text-password
 
- ftp 스위치 ip 입력 후 등록한 ID/PW로 접속
(펌웨어가 있는 디렉터리로 이동)
 ex : C:\에 junos가 있을 경우
 cd c:\
 ftp “ip address” (“ “는 사용 안 함) ftp 접속
- bin
- hash
- put jinstall-ex-2200-10.4R5.5-domestic-signed. tgz/var/tmp/jinstall-ex-2200-10.4R5. 5-domestic-signed.tgz

리부팅
For Standalone device:
           root@EX-4200> request system reboot
           Reboot the system? [yes, no] (no) YES
 
 
software 동기화
root@junotec> request system snapshot media internal slice alternate
 Copying '/dev/da0s2a' to '/dev/da0 s1 a'.. (this may take a few minutes)
The following filesystems were archived: 

10G / 1G 세팅하기
tsline# set interface ge-0/0/7 unit 0 family ethernet-switching interface-mode access       
tsline# set interface ge-0/0/7 unit 0 family ethernet-switching vlan members vlan10

 

저의 글을 읽어 주셔서 감사합니다. 오늘도 즐거운 하루 보내세요.

반응형

댓글