You are on page 1of 9

TÀI LIỆU QUẢN TRỊ VẬN HÀNH SWITCH EX SERIES

1. Các đặc điểm cơ bản của JUNOS

 JUNOS có 3 mode, đó là :
a. Shell : Cho phép thực hiện các lệnh linux về hệ thống
b. Operation : Cho phép giám sát, vận hành, thực hiện một số thao tác về
chassis
c. Configure : Cho phép thay đổi cấu hình của thiết bị.
 Mode shell : được xác định bởi dấu (%)
% pwd
/cf/var/home/admin2
% ls
%

 Mode Operation : được xác định bởi dấu (>)


root@SWITCH-2300> request ?
Possible completions:
chassis Perform chassis-specific operations
dhcp Perform DHCP operations
dhcpv6 Perform DHCPv6 operations
interface Perform interface tasks
l2circuit-switchover Perform l2circuit switchover
lacp Request LACP actions
message Send text message to other users
mpls Perform Multiprotocol Label Switching operations
multicast Perform multicast operations
network-access Request network-access related information
pim Perform PIM operations
pppoe Perform PPPoE specific operations
routing-engine Log in to Routing Engine
security Request security operation

 Mode Configure : được xác định bởi dấu (#) và [edit]


[edit]
root@SWITCH-2300> set system ?
Possible completions:
> accounting System accounting configuration
allow-6pe-traceroute Allow IPv4-mapped v6 address in tag icmp6 TTL expired
packet
allow-v4mapped-packets Allow processing for packets with V4 mapped address
+ apply-groups Groups from which to inherit configuration data
+ apply-groups-except Don't inherit configuration data from these groups
> archival System archival management
> arp ARP settings
+ authentication-order Order in which authentication methods are invoked
> auto-configuration
 Để di chuyển giữa các mode trong JUNOS
o Từ mode Shell vào mode Operation : gõ cli
o Từ mode Operation vào mode Configure : gõ configure
o Từ mode Configure trở về mode Operation : gõ exit
o Từ mode Operation trở về mode Shell : gõ exit hoặc start shell
o Từ mode Configure trở về mode Shell : gõ run start shell

 File cấu hình của Junos có dạng phân cấp và kế thừa:


Tham_so_1 thamso_1.1;  level 1
Tham_so2 {  level 1
Tham_so_2.1 {  level 2
Tham_so_2.1.1;  level 3
Tham_so_2.1.2 {  level 3
Tham_so_2.1.2.1;  level 4
Tham_so_2.1.2.2;  level 4
}
}
}

Ví dụ :
version 11.4R9.4;
system {
host-name SWITCH-2300;
login {
user admin {
uid 2001;
class super-user;
authentication {
encrypted-password "$1$tGFjZhqg$mO6;
}
}

2. Một số cấu hình cơ bản trên JUNOS

 Cấu hình đặt tên thiết bị :


system {
host-name “TEN-THIET-BI”;

 Cấu hình bật dịch vụ telnet/ssh :


set system services ssh
set system services telnet

 Cấu hình vlan và đặt địa chỉ cho vlan :


set vlans pc vlan-id 5
set vlans pc l3-interface irb.5
set interfaces irb unit 5 family inet address 10.70.9.3/24
Trong đó pc là tên vlan, 5 là vlan id còn 10.70.9.3/24 là địa chỉ vlan mà
người quản trị muốn đặt.

 Cấu hình trunk port all vlan

set interfaces ge-0/0/0 unit 0 family ethernet-switching interface-mode trunk


set interfaces ge-0/0/0 unit 0 family ethernet-switching vlan members all

 Cấu hình gán vlan vào port access

set interfaces ge-0/0/1 unit 0 family ethernet-switching vlan members 10


 Khai báo thêm người người quản trị :
set system login user admin
set system login user admin class super-user
set system login user admin authentication plain-text password ( nhập password)

Trong đó admin là tên đăng nhập , và phần authentication là phần password


dành cho tên đăng nhập admin.

user pass hiện tại là :


user : admin
password: Juniper@123

Trong đó admin1 là tên đăng nhập , và phần authentication là phần


password dành cho tên đăng nhập admin1.

 Cấu hình cài đặt password khi thiết bị khởi động :

set system root-authentication plain-text password ( nhập password)


user pass hiện tại là :
user : root
pass : Juniper@123

 Cấu hình default gateway:

Set routing-options static route 0.0.0.0/0 next-hop 20.1.10.1


Trong đó 20.1.10.1 là default gateway.

 Cấu hình chống cấp dhcp ngược ( cấu hình vào switch mà client cắm vào)

set vlans (Tên vlan) forwarding-options dhcp-security group link overrides trusted
set vlans(Tên vlan) forwarding-options dhcp-security group link interface ge-0/0/0
Trong đó ge-0/0/0 là port duy nhất mà switch l2 lấy dhcp
 Tắt thiết bị bằng dòng lệnh :
request system reboot

3. Kiểm tra tình trạng hệ thống

 Show : hiện thị toàn bộ cấu hình switch

 show interfaces terse : hiện thị ngắn ngọn những trạng thái của cổng trên switch
 show vlan : hiện thị những vlan có trong switch
 show version :Hiện thị version hiện tại thiết bị đang chạy
 show chassis hardware detail :

Load lại file cấu hình đã lưu trên thiết bị ngoài


- Mở file cấu hình đã lưu trên laptop bằng notepad, copy toàn bộ nội
dung file vào clipboard.
- Trên EX2300, gõ load override terminal và paste nội dung file vào, ấn
Enter, ấn Control – D , commit.
[edit]
root@SWITCH-2300# load override terminal
[Type ^D at a new line to end input]

load complete

[edit]
root@SWITCH-2300# commit

You might also like