kurtʮһѧϰͬ²½¼Æ»®(Èþ¡¢Â·ÓÉÆ÷ÅäÖûù´¡)
root> configure //ͨ¹ýconfigureÃüÁî½øÈëÅäÖÃģʽ
Entering configuration mode
[edit]
root#
root# ? //ÅäÖÃģʽÏÂËùʹÓÃ
Possible completions:
<[Enter]> Execute this command
activate Remove the inactive tag from a statement
annotate Annotate the statement with a comment
commit Commit current set of changes
copy Copy a statement
deactivate Add the inactive tag to a statement
delete Delete a data element
edit Edit a sub-element
exit Exit from this level
help Provide help information
insert Insert a new ordered data element
load Load configuration from ASCII file
quit Quit from this level
rename Rename a statement
replace Replace character string in configuration
rollback Roll back to previous committed configuration
run Run an operational-mode command
save Save configuration to ASCII file
set Set a parameter
show Show a parameter
status Show users currently editing configuration
top Exit to top level of configuration
up Exit one level of configuration
wildcard Wildcard operations
[edit]
root# set ? //ÅäÖÃÃüÁîËùÄÜÅäÖõÄÄÚÈÝ
Possible completions:
> access Network access configuration
> accounting-options Accounting data configuration
> applications Define applications by protocol characteristics
+ apply-groups Groups from which to inherit configuration data
> chassis Chassis configuration
> class-of-service Class-of-service configuration
> event-options Event processing configuration
> firewall Define a firewall configuration
> forwarding-options Configure options to control packet forwarding
> groups Configuration groups
> interfaces Interface configuration
> logical-routers Logical routers
> policy-options Routing policy option configuration
> protocols Routing protocol configuration
> routing-instances Routing instance configuration
> routing-options Protocol-independent routing option configuration
> services Service PIC applications settings
> snmp Simple Network Management Protocol configuration
> system System parameters
[edit]
root# set system ?
Possible completions:
> accounting System accounting configuration
+ 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
+ authentication-order Order in which authentication methods are invoked
> backup-router IPv4 router to use while booting
> commit Configuration commit management
compress-configuration-files Compress the router configuration files
default-address-selection Use system address for locally originated traffic
> diag-port-authentication Authentication for the diagnostic port
domain-name Domain name for this router
+ domain-search List of domain names to search
host-name Hostname for this router
> inet6-backup-router IPv6 router to use while booting
> internet-options Tunable options for Internet operation
> location Location of the system, in various forms
> login Names, login classes, and passwords for users
max-configurations-on-flash Number of configuration files stored on flash
mirror-flash-on-disk Mirror contents of the flash drive onto hard drive
> name-server DNS name servers
no-compress-configuration-files Don't compress the router configuration files
no-multicast-echo Disable ICMP echo on multicast addresses
no-redirects Disable ICMP redirects
no-saved-core-context Don't save context information for core files
> ntp Network Time Protocol services
> pic-console-authentication Authentication for the console port on PICs
> ports Craft interface RS-232 ports
> processes Process control
> radius-options RADIUS options
> radius-server RADIUS server configuration
> root-authentication Authentication information for the root login
saved-core-context Save context information for core files
saved-core-files Number of saved core files per executable (1..64)
> scripts Scripting mechanisms
> services System services
> static-host-mapping Static hostname database mapping
> syslog System logging facility
> tacplus-options TACACS+ options
> tacplus-server TACACS+ server configuration
time-zone Time zone name or POSIX-compliant time zone string
[edit]
root# set system host-name Juniperbbs-Kurt-M7i //ÅäÖ÷ÓÉÆ÷Ãû
root# set system root-authentication plain-text-password //ÅäÖÃrootÓû§ÃÜÂë
New password: //ÅäÖÃÃÜÂëkurt
error: minimum password length is 6 //ÌáʾÃÜÂë×î¶ÌΪ6¸ö×Öĸ
error: require change of case, digits or punctuation
[edit]
root# set system root-authentication plain-text-password
New password:
Retype new password:
root# set system login user kurt class ? //ÅäÖÃÓû§kurt
Possible completions:
<class> Login class
operator permissions [ clear network reset trace view ] //²Ù×÷ģʽ
read-only permissions [ view ] //Ö»¶Áģʽ
super-user permissions [ all ] //¹ÜÀíԱģʽ
unauthorized permissions [ none ] //δÊÚȨ
[edit]
root#set system login user kurt class super-user authentication plain-text-password //ÅäÖ󬼶Óû§kurt²¢ÉèÖÃÃÜÂë
New password:
Retype new password:
root#set system login user kurt class super-user full-name juniperbbs-kurt //ÅäÖÃkurtµÄÈ«Ãû
root#set system login user kurt class super-user uid 1000 //ÅäÖÃkurtµÄID
[edit]
root# commit //Ö´ÐÐÅäÖã¬ÈçË«RE£¬ÐèҪʹÓÃcommit synchronizeÃüÁî
commit complete //ÃüÁî³É¹¦
root@Juniperbbs-Kurt-M7i# show
## Last changed: 2007-10-01 06:38:27 UTC
version 8.3R1.5;
system {
host-name Juniperbbs-Kurt-M7i;
authentication-order password;
root-authentication {
encrypted-password "$1$o0PsQdUy$rAc28GdeomAxO13Cxzap.1"; ## SECRET-DATA
}
login {
user kurt {
full-name juniperbbs-kurt;
uid 1000;
class super-user;
authentication {
encrypted-password "$1$4iVGvaSm$0J8bcDkqiEVixYsL99l.V1"; ## SECRET-DATA
}
}
}
syslog {
user * {
any emergency;
}
file messages {
any notice;
authorization info;
}
file interactive-commands {
interactive-commands any;
}
}
}
root@Juniperbbs-Kurt-M7i# set system time-zone Asia/Shanghai //ÅäÖÃÊ±Çø
ʹÓÃshowÃüÁî¿É¿´µ½Ê±¼ä¸ÄΪ## Last changed: 2007-10-01 14:42:33 CST
ºÃÁË£¬Ê¹ÓÃ×Ô¼ºµÄÕË»§µÇ½ÁË
login: kurt
Password:
--- JUNOS 8.3R1.5 built 2007-04-13 22:23:02 UTC
kurt@Juniperbbs-Kurt-M7i>
kurt@Juniperbbs-Kurt-M7i# set system services telnet //ÅäÖÃtelnetÐÒé
kurt@Juniperbbs-Kurt-M7i# set system services ftp
//ÅäÖÃftpÐÒ飬ͨ¹ýÕâÁ½¸öÐÒ飬ÔÙ¼ÓÉÏΪ¶Ë¿ÚÅäÉϺÏÊʵÄIPµØÖ·£¬ÎÒÃǾͿÉÒÔÔ¶³Ì¿ØÖÆÂ·ÓÉÆ÷ÁË
kurt@Juniperbbs-Kurt-M7i# set system syslog file messages archive size 2m files 10
//ÉèÖÃSYSLogÎļþÈÝÁ¿ºÍÊýÁ¿¡£
kurt@Juniperbbs-Kurt-M7i# set system syslog file messages any info
//ÉèÖÃÎļþÐÅÏ¢
kurt@Juniperbbs-Kurt-M7i# set system syslog user * any emergency
//ÕâÌõºÍÉÏÌõ¾ßÌå¸ÉʲôµÄ²»ÊÇÌ«Çå³þ,ÕâÌõºÃÏñÊÇÉèÖÃÎļþµÄ·ÃÎÊÓû§È¨ÏÞ
kurt@Juniperbbs-Kurt-M7i# set chassis alarm management-ethernet link-down ignore
//¹Ø±ÕÍø¹Ülink-down¸æ¾¯£¬±¾ÏµÍ³Î´´ø
°´ÕÕ´óèǰ±²Â߼·ÓÉÆ÷ÅäÖõÄÎĵµ£¬¾ßÌåÅäÖÃÈçÏÂ
root@Juniperbbs-Kurt-M7i# show
## Last changed: 2007-10-01 18:29:04 CST
version 8.3R1.5;
system {
host-name Juniperbbs-Kurt-M7i;
time-zone Asia/Shanghai;
authentication-order password;
root-authentication {
encrypted-password "$1$s2DjtpA5$igH5IA8QSqoEVCE3lmiSa."; ## SECRET-DATA
}
login {
user kurt {
full-name juniperbbs-kurt;
uid 1000;
class super-user;
authentication {
encrypted-password "$1$4iVGvaSm$0J8bcDkqiEVixYsL99l.V1"; ## SECRET-DATA
}
}
}
services {
ftp;
telnet;
}
syslog {
user * {
any emergency;
}
file messages {
any info;
authorization info;
archive size 2m files 10;
}
file interactive-commands {
interactive-commands any;
}
}
compress-configuration-files;
}
logical-routers {
r1 {
interfaces {
fe-1/3/0 {
unit 12 {
vlan-id 12;
family inet {
address 10.100.12.1/30;
}
family mpls;
}
unit 13 {
vlan-id 13;
family inet {
address 10.100.13.1/30;
}
family mpls;
}
unit 33 {
vlan-id 33;
family inet {
address 192.168.12.1/24;
}
}
}
lo0 {
unit 12 {
family inet {
address 202.202.10.1/32;
}
}
}
}
}
r2 {
interfaces {
fe-1/3/1 {
unit 12 {
vlan-id 12;
family inet {
address 10.100.12.2/30;
}
family mpls;
}
unit 14 {
vlan-id 14;
family inet {
address 10.100.14.2/30;
}
family mpls;
}
unit 44 {
vlan-id 44;
family inet {
address 192.168.14.1/24;
}
}
}
lo0 {
unit 22 {
family inet {
address 202.202.10.2/32;
}
}
}
}
}
r3 {
interfaces {
fe-1/3/0 {
unit 14 {
vlan-id 14;
family inet {
address 10.100.14.1/30;
}
family mpls;
}
unit 15 {
vlan-id 15;
family inet {
address 10.100.15.1/30;
}
family mpls;
}
unit 55 {
vlan-id 55;
family inet {
address 192.168.15.1/24;
}
}
}
lo0 {
unit 44 {
family inet {
address 202.202.10.3/32;
}
}
}
}
}
r4 {
interfaces {
fe-1/3/1 {
unit 13 {
vlan-id 13;
family inet {
address 10.100.13.2/30;
}
family mpls;
}
unit 15 {
vlan-id 15;
family inet {
address 10.100.15.2/30;
}
family mpls;
}
unit 33 {
vlan-id 33;
family inet {
address 192.168.13.1/24;
}
}
}
lo0 {
unit 55 {
family inet {
address 202.202.10.4/32;
}
}
}
}
}
}
chassis {
alarm {
management-ethernet {
link-down ignore;
}
}
}
interfaces {
fe-1/3/0 {
vlan-tagging;
}
fe-1/3/1 {
vlan-tagging;
}
}
¹²ÅäÖÃ4̨·ÓÉÆ÷£¬°´ÕÕR1-R2-R3-R4-R1µÄ¼òµ¥ÍØÆË£¬ÔÙδÅäÖþßÌåÐÒéǰ£¬Ö»ÄÜpingͨÏàÁڵķÓÉÆ÷
root@Juniperbbs-Kurt-M7i> ping 10.100.14.1 logical-router r2
PING 10.100.14.1 (10.100.14.1): 56 data bytes
64 bytes from 10.100.14.1: icmp_seq=0 ttl=64 time=1.884 ms
64 bytes from 10.100.14.1: icmp_seq=1 ttl=64 time=0.873 ms
^C
--- 10.100.14.1 ping statistics ---
2 packets transmitted, 2 packets received, 0% packet loss
round-trip min/avg/max/stddev = 0.873/1.378/1.884/0.506 ms
root@Juniperbbs-Kurt-M7i> ping 10.100.14.1 logical-router r3
PING 10.100.14.1 (10.100.14.1): 56 data bytes
64 bytes from 10.100.14.1: icmp_seq=0 ttl=64 time=0.165 ms
64 bytes from 10.100.14.1: icmp_seq=1 ttl=64 time=0.155 ms
^C
--- 10.100.14.1 ping statistics ---
2 packets transmitted, 2 packets received, 0% packet loss
round-trip min/avg/max/stddev = 0.155/0.160/0.165/0.005 ms
root@Juniperbbs-Kurt-M7i> ping 10.100.14.1 logical-router r4
PING 10.100.14.1 (10.100.14.1): 56 data bytes
ping: sendto: No route to host
ping: sendto: No route to host
^C
--- 10.100.14.1 ping statistics ---
2 packets transmitted, 0 packets received, 100% packet loss
root@Juniperbbs-Kurt-M7i> ping 10.100.14.1 logical-router r1
PING 10.100.14.1 (10.100.14.1): 56 data bytes
ping: sendto: No route to host
ping: sendto: No route to host
ping: ^Csendto: No route to host
--- 10.100.14.1 ping statistics ---
3 packets transmitted, 0 packets received, 100% packet loss
½ñÌìÏȵ½Õ⣬ϣÍû´ó¼ÒÄܻظ´±¾Ìù£¬²¢ÌṩÏà¹ØÅäÖã¬ÈÃÎÒÃǹ²Í¬½ø²½£¡Ð»Ð»
ËÑË÷¸ü¶àÏà¹ØÖ÷ÌâµÄÌû×Ó:
ѧϰ ʵÑé