juniper srx經常使用操做

 

一、建立高級管理員:shell

如今咱們建立一個管理員Admin,操做權限爲Super的管理員用戶,並配置密碼。
首先咱們創建一個操做權限“super”,設置爲idel-timeout 15,具備全部操做權限。
命令行配置以下:
set system login class super idle-timeout 15
set system login class super permissions all服務器


set system login user febayadmin class super
set system login user febayadmin authentication  plain-text-password
 session

 

二、過濾公網IP:併發

其中a.a.a.a/32爲你要限制的IP地址
set firewall filter admin-ip term 1 from source-address 183.16.3.83/32
set firewall filter admin-ip term 1 from destination-address   0.0.0.0/0
set firewall filter admin-ip term 1 then disable log
set firewall filter admin-ip term 3 then accept
最後在接口加上過濾條件
set inter ge-0/0/0 unit 0 fam inet filter input admin-ipapp

 

三、經常使用操命令:ssh

show log messages  #顯示系統日誌
clear log messages
 #清除系統日誌
show configuration groups junos-defaults applications  #查看系統默認服務機端口
show configuration applications          #查看自定義的服務及端口
show arp 查看ARP 表
show log messages 查看系統日誌
show interface terse 查看全部接口運行狀態
show interface ge-x/y/z detail 查看接口運行細節信息
monitor interface ge-x/y/z 動態統計接口數據包轉發信息
monitor traffic interface ge-x/y/z 動態報文抓取(Tcpdump,相似ScreenOS snoop
命令)
show security flow session summary 查看當前防火牆併發會話數
show security flow session 查看當前防火牆具體併發會話
clear security flow session all 清除當前session
show security alg status 檢查全局ALG 開啓狀況
Show system software 查看當前軟件版本號
show system uptime 查看系統啓動時間
Show chassis haredware 查看硬件板卡及序列號
show chassis environment 查看硬件板卡當前狀態
show chassis routing-engine 查看主控板(RE)資源使用及狀態
show route 查看路由表ide

request system reboot 重啓設備oop

 

四、基於目的地址池的端口映射:spa

set security zones security-zone trust address-book address server182 192.168.100.182/32
#創建元素
#服務22端口系統自帶。因此不須要新建
set security nat destination pool 182 address 192.168.100.182/32
set security nat destination pool 182 address port 22
set security nat destination rule-set 1 from zone untrust   
set security nat destination rule-set 1 rule 182 match source-address 0.0.0.0/0
set security nat destination rule-set 1 rule 182 match destination-address 113.106.95.114/32
set security nat destination rule-set 1 rule 182 match destination-port 222
set security nat destination rule-set 1 rule 182 then destination-nat pool 182
#NAT命令行


set security policies from-zone untrust to-zone trust policy untrust-to-trust match source-address any
set security policies from-zone untrust to-zone trust policy untrust-to-trust match destination-address server182
set security policies from-zone untrust to-zone trust policy untrust-to-trust match application junos-ssh
set security policies from-zone untrust to-zone trust policy untrust-to-trust then permit
#策略
set security nat proxy-arp interface ge-0/0/0.0 address 113.106.95.114/32
#代理公網IP到接口IP
 

 四、命令行將策略移動到頂端

insert security policies from-zone trust to-zone untrust policy s251-jc(要移動的策略) before policy trust-to-untrust(當前頂端的策略名)

查看目前的策略及排名:查看策略的相關命令

五、備份juniper srx配置:進入配置模式:

#save srx65020120406  (備份到srx設備的內存)

還原:load update srx65020120406

刪除已備份到srx設備的相關文件:退回到用戶模式,

start shell,進入到普通權限模式,提示符號:%      想進入root模式,運行su - root

進入到管理模式下,提示符:root@%  即unix命令模式,經過find命令找到須要的問題件,在rm **(文件名)便可

 

備份到ftp服務器:

save ftp://user:pw@x.x.x.x/filename.txt
 

從ftp服務器還原:

load update  ftp://user:pw@x.x.x.x/filename.txt 

相關文章
相關標籤/搜索