立即注册 登录
51学通信技术论坛 返回首页

爱卫生的个人空间 http://www.51xuetongxin.com/bbs/?2 [收藏] [复制] [分享] [RSS]

日志

Junos一些非常有用的命令

已有 842 次阅读2012-2-6 15:00 |个人分类:Juniper|

1 为某条命令加上描述信息。
aviva@router1# set area  0.0.0.0 interface fe-0/0/0
aviva@router1# annotate area  0.0.0.0 "backbone routers"
 
2 查看commit的时间,并为commit加上描述。非常方便做割接的时候查看时间点。
aviva@router1# commit comment "turned on telnet"
To track down what changed in the configuration and when, you can review the comments:
 aviva@router1> show system commit
 0   2005-03-31 20:26:16 UTC by aviva via cli
     turned on telnet
 1   2005-03-31 11:12:28 UTC by aviva via cli
     set host gildor facility-override local4
 
3 用show | compare命令可以比较与刚才的配置相比,到底做了哪些改变。
 
4 提交命令生效,需提交两遍,如果第二遍不提交,则在固定时间内默认10分钟自动回退。
   aviva@router1#   commit confirmed 1
 commit confirmed will be automatically rolled back in 1 minutes unless confirmed
 commit complete
To make the provisional activation permanent, issue the following command:
 [edit]
 aviva@router1# commit
 Broadcast Message from root@router1
         (no tty) at 15:05 PDT…
 Commit was not confirmed; automatic rollback complete.
 
5 存一份好的紧急配置用于回退用,而不用记rollback的回退号。
 aviva@router1> request system configuration rescue save
 aviva@router1# rollback rescue
 [edit]
 aviva@router1# commit
 commit complete
 aviva@router1> file list /config
 /config:
 juniper.conf.1.gz
 juniper.conf.2.gz
 juniper.conf.3.gz
 juniper.conf.gz
 rescue.conf.gz
 
6 在M系列上保存系统的镜像和版本文件。
 aviva@router1> request system snapshot
 Copying '/' to '/altroot' .. (this may take a few minutes)
 Copying '/config' to '/altconfig' .. (this may take a few minutes)
 The following filesystems were archived: / /config
       M系列上,ad0是cf卡。ad1是硬盘。
 
7 从备份的文件系统中恢复。
 First, reboot the router from the alternate boot media to which you saved the snapshot. On M-series and T-series routers, this is the hard disk:
aviva@RouterA> request system software reboot media disk
Then, retake the snapshot to copy the filesystem to the media from which you didn't boot:
aviva@router1>  request system snapshot
 
8 request support information | save support-file是一个命令合集,可以收集很多router的状态信息提交给tac

路过

鸡蛋

鲜花

握手

雷人

评论 (0 个评论)

facelist doodle 涂鸦板

您需要登录后才可以评论 登录 | 立即注册

站长邮箱|Archiver|51学通信 ( 粤ICP备11025688 )

GMT+8, 2024-5-25 16:09 , Processed in 0.019078 second(s), 15 queries .

Powered by Discuz! X2

© 2001-2011 Comsenz Inc.

回顶部