Command Line Juniper

Download as doc, pdf, or txt
Download as doc, pdf, or txt
You are on page 1of 11

JUNIPER COMMAND LINE

Finding Interface on router with help of customer name :


ri007424@AHDBIAG1B> show interfaces descriptions | match sardar
ge-0/1/0.247 up up TO_SARDAR_VALLABHBHAI_OMBB200904143441621

{master}

Finding Interface on router with help of customer SO :


ri007424@AHDBIAG1B> show interfaces descriptions | match
OMBB200904143441621
ge-0/1/0.247 up up TO_SARDAR_VALLABHBHAI_OMBB200904143441621

ri007424@AHDBIAG1B> show configuration interfaces ge-0/1/0.247


description TO_SARDAR_VALLABHBHAI_OMBB200904143441621;
bandwidth 16m;
vlan-id 247;
family inet {
filter {
input Inbound-packet-filter-without-Ratelimit;
output Outbound-packet-filter-without-Ratelimit;
}
address 220.225.147.17/29 {
primary;
}
address 220.225.147.97/27;
}

ri007424@AHDBIAG1B> show interfaces ge-0/1/0.247


Logical interface ge-0/1/0.247 (Index 134) (SNMP ifIndex 174)
Description: TO_SARDAR_VALLABHBHAI_OMBB200904143441621
Flags: SNMP-Traps 0x4000 VLAN-Tag [ 0x8100.247 ] Encapsulation: ENET2
Bandwidth: 16mbps
Input packets : 2890984451
Output packets: 3288241321
Protocol inet, MTU: 4456
Flags: None
Addresses, Flags: Primary Is-Preferred Is-Primary
Destination: 220.225.147.16/29, Local: 220.225.147.17, Broadcast: 220.225.147.23
Addresses, Flags: Is-Preferred
Destination: 220.225.147.96/27, Local: 220.225.147.97, Broadcast: 220.225.147.127
18

Pinging WAN ip :
ri007424@AHDBIAG1B> ping 220.225.147.21 source 220.225.147.17 rapid count 50
PING 220.225.147.21 (220.225.147.21): 56 data bytes
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
--- 220.225.147.21 ping statistics ---
50 packets transmitted, 50 packets received, 0% packet loss
round-trip min/avg/max/stddev = 4.539/5.093/7.138/0.485 ms

Trace to yahoo.com [69.147.125.65]


ri007424@AHDBIAG1B> traceroute 69.147.125.65 source 124.124.19.234
traceroute to 69.147.125.65 (69.147.125.65) from 124.124.19.234, 30 hops max, 40 byte
packets
1 115.255.252.230 (115.255.252.230) 11.111 ms 8.779 ms 9.375 ms
2 62.216.147.97 (62.216.147.97) 7.487 ms 10.332 ms 7.803 ms
3 85.95.25.237 (85.95.25.237) 247.680 ms 249.353 ms 249.423 ms
MPLS Label=318816 CoS=0 TTL=1 S=1
4 85.95.25.193 (85.95.25.193) 256.864 ms 252.270 ms 249.349 ms
MPLS Label=312848 CoS=0 TTL=1 S=1
5 85.95.25.198 (85.95.25.198) 145.545 ms 146.382 ms 145.669 ms
MPLS Label=357056 CoS=0 TTL=1 S=1
6 62.216.128.62 (62.216.128.62) 248.328 ms 248.191 ms 252.192 ms
7 62.216.145.226 (62.216.145.226) 259.492 ms 247.766 ms 248.008 ms
8 216.115.101.131 (216.115.101.131) 289.075 ms 298.456 ms 288.708 ms
MPLS Label=421632 CoS=0 TTL=1 S=1
9 216.115.96.20 (216.115.96.20) 287.359 ms 287.701 ms 288.40 f5 ms
10 216.115.108.19 (216.115.108.19) 288.717 ms 216.115.108.23 (216.115.108.23)
311.556 ms 288.698 ms
11 66.196.112.201 (66.196.112.201) 289.138 ms 66.196.112.203 (66.196.112.203)
288.576 ms 66.196.112.201 (66.196.112.201) 288.480 ms
12 * * *
13 * * *
19

Monitoring BW utilization :
ri007424@AHDBIAG1B> monitor interface ge-0/1/0.247

AHDBIAG1B Seconds: 0 Time: 15:13:15


Delay: 0/0/0
Interface: ge-0/1/0.247, Enabled, Link is Up
Flags: SNMP-Traps 0x4000
AHDBIAG1B Seconds: 4 Time: 15:13:30
Delay: 0/0/0
Interface: ge-0/1/0.247, Enabled, Link is Up
Flags: SNMP-Traps 0x4000
Encapsulation: ENET2
VLAN-Tag [ 0x8100.247 ]
Local statistics: Current delta
Input bytes: 936250390 [372]
Output bytes: 145862482 [250]
Input packets: 13734643 [5]
Output packets: 2742645 [3]
Remote statistics:
Input bytes: 1540332516175 (17774912 bps) [12190384]
Output bytes: 3264953545930 (16226424 bps) [12918261]
Input packets: 2877546101 (2661 pps) [15697]
Output packets: 3285804249 (2380 pps) [14710]
Traffic statistics:
Input bytes: 1541268766565 [12190756]
Output bytes: 3265099408412 [12918511]
Input packets: 2891280744 [15702]
Output packets: 3288546894 [14713]
Protocol: inet, MTU: 4456
20
ri007424@AHDBIAG1B> show interfaces e1-1/2/0:16
Physical interface: e1-1/2/0:16, Enabled, Physical link is Up
Interface index: 222, SNMP ifIndex: 55
Link-level type: PPP, MTU: 1504, Clocking: Internal, Speed: E1, Loopback: None,
FCS: 16, Framing: Unframed,
Parent: cau4-1/2/0 Interface index 206
Device flags : Present Running
Interface flags: Point-To-Point SNMP-Traps Internal: 0x4000
Link flags : Keepalives
Keepalive settings: Interval 10 seconds, Up-count 1, Down-count 3
Keepalive: Input: 2385121 (00:00:02 ago), Output: 749016 (00:00:03 ago)
LCP state: Opened
NCP state: inet: Opened, inet6: Not-configured, iso: Not-configured, mpls: Not-
configured
CHAP state: Closed
PAP state: Closed
CoS queues : 4 supported, 4 maximum usable queues
Last flapped : 2010-07-10 08:56:32 IST (06:18:18 ago)
Input rate : 48 bps (0 pps)
Output rate : 48 bps (0 pps)
DS1 alarms : None
DS1 defects : None
SDH alarms : None
SDH defects : None

Logical interface e1-1/2/0:16.0 (Index 93) (SNMP ifIndex 143)


Description: TO_CHHOTALAL_OMBB200902142623867
Flags: Point-To-Point SNMP-Traps 0x4000 Encapsulation: PPP
Bandwidth: 512kbps
Protocol inet, MTU: 1500
Flags: None
Addresses, Flags: Is-Preferred Is-Primary
Destination: 220.225.63.152/30, Local: 220.225.63.154, Broadcast: 220.225.63.155
21
Interface Configuration :
ri007424@AHDBIAG1B> show configuration interfaces e1-1/2/0:16
e1-options {
framing unframed;
}
unit 0 {
description TO_CHHOTALAL_OMBB200902142623867;
bandwidth 512k;
family inet {
filter {
input 512K-1:1-inbound-packet-filter;
output 512K-1:1-outbound-packet-filter;
}
address 220.225.63.154/30;
}
}

How to check filter TCP/UDP ports:


ri007424@AHDBIAG1B> show configuration firewall family inet filter 512K-1:1-
inbound-packet-filter
term no-iana-spoofing-inbound {
from {
prefix-list {
iana-reserved;
}
}
then {
inactive: count spoof-inbound-iana;
discard;
term block-ms-portscans {
from {
protocol [ tcp udp ];
destination-port [ 137 138 139 445 5554 9996 1434 1720 5060 ];
}
then {
inactive: count msblast-counter;
discard;
}
}
term ratelimit {
then {
policer allow-full-512k;
forwarding-class best-effort;
accept;
22
Configuration for 1:4 customer :
ri007424@AHDBIAG1B> show configuration interfaces e1-1/2/0:53.0
description
TO_HARSHA_ENGINEERS_OMBB200909185805396_2M_1:4_VRF_LOGICAL-
ROUTER-2;
bandwidth 2m;
family inet {
filter {
input 2M-1:1-inbound-packet-filter;
output 2M-1:1-outbound-packet-filter;
}
address 220.225.63.46/30;
}

BGP
ri007424@AHDBIAG1B> show interfaces descriptions | match emti
ge-0/1/0.434 up up TO_EMTICI_OMBB201001268012397

BGP Summary/Status:
ri007424@AHDBIAG1B> show bgp summary | match 124.124.19.233
Table Tot Paths Act Paths Suppressed History Damp State Pending
124.124.19.233 45469 34960 32471 0 44 21:15:08 1/23/0
0/0/0
BGP ACTIVE state :
ri007424@AHDBIAG1B> show bgp summary | match 115.248.46.229
115.248.46.229 65532 194 184 0 19 6w1d23h Active
{master}
BGP ACTIVE Connect :
ri007424@AHDBIAG1B> show bgp summary | match 115.248.64.201
115.248.64.201 45916 84377 89533 0 12 20:06:55 Connect

BGP configuration:
ri007424@AHDBIAG1B> show configuration protocols bgp group EMTICI_45469
type external;
description PEER_TO_EMTICI;
local-address 124.124.19.234;
import EMTICI-IN;
export EMTICI-OUT;
peer-as 45469;
disable-4byte-as;
neighbor 124.124.19.233;
23
Route Receive from customer peer:
ri007424@AHDBIAG1B> show route receive-protocol bgp 124.124.19.233

inet.0: 341564 destinations, 682438 routes (341481 active, 2 holddown, 350 hidden)
Restart Complete
Prefix Nexthop MED Lclpref AS path
* 202.129.240.0/23 124.124.19.233 45469 I

inet.3: 55 destinations, 55 routes (55 active, 0 holddown, 0 hidden)


Restart Complete

ri007424@AHDBIAG1B> show bgp neighbor 124.124.19.233


Peer: 124.124.19.233+179 AS 45469 Local: 124.124.19.234+56147 AS 18101
Description: PEER_TO_EMTICI
Type: External State: Established Flags: <Sync>
Last State: OpenConfirm Last Event: RecvKeepAlive
Last Error: Hold Timer Expired Error
Export: [ EMTICI-OUT ] Import: [ EMTICI-IN ]
Options: <Preference LocalAddress GracefulRestart PeerAS Refresh>
Options: <4ByteAsDisabled>
Local Address: 124.124.19.234 Holdtime: 90 Preference: 170
Number of flaps: 44
Last flap event: HoldTime
Error: 'Hold Timer Expired Error' Sent: 25 Recv: 0
Peer ID: 111.93.65.14 Local ID: 220.224.151.238 Active Holdtime: 90
Keepalive Interval: 30 Peer index: 0
BFD: disabled, down
Local Interface: ge-0/1/0.434
NLRI for restart configured on peer: inet-unicast
NLRI advertised by peer: inet-unicast
NLRI for this session: inet-unicast
Peer supports Refresh capability (2)
Restart time configured on the peer: 120
Stale routes from peer are kept for: 300
Peer does not support Restart capability
Peer does not support 4 byte AS extension
Table inet.0 Bit: 1000d
RIB State: BGP restart is complete
Send state: in sync
Active prefixes: 1
Received prefixes: 23
Suppressed due to damping: 0
Advertised prefixes: 1
Last traffic (seconds): Received 24 Sent 12 Checked 7
24
Where to check configured customer pools:
ri007424@AHDBIAG1B> show configuration policy-options policy-statement EMTICI-
IN
term no-bogus {
from {
route-filter 220.224.0.0/14 orlonger;
route-filter 10.0.0.0/8 orlonger;
route-filter 169.254.0.0/16 orlonger;
route-filter 172.16.0.0/12 orlonger;
route-filter 192.0.2.0/24 orlonger;
route-filter 192.168.0.0/26 orlonger;
route-filter 223.255.255.0/24 orlonger;
route-filter 240.0.0.0/4 orlonger;
route-filter 0.0.0.0/0 through 0.0.0.0/32;
route-filter 224.0.0.0/3 orlonger;
}
then reject;
}
term receive_EMTICI {
from {
protocol bgp;
neighbor 124.124.19.233;
route-filter 202.129.240.0/23 upto /24;
}
then {
local-preference 600;
community set EMTICI;
community add EXT_AHDB_RIC;
community add FLAG_UK_EXP;
community add AHDB_EBGP_CUSTOMER;
community add ANNOUNCE_ALL;
accept;
}
25
Default ROUTING BGP:
ri007424@AHDBIAG1B> show route advertising-protocol bgp 124.124.19.233

inet.0: 341593 destinations, 682496 routes (341510 active, 2 holddown, 350 hidden)
Restart Complete
Prefix Nexthop MED Lclpref AS path
* 0.0.0.0/0 Self I

ri007424@AHDBIAG1B> show configuration policy-options policy-statement EMTICI-


OUT
term Advertise-default-route {
from {
protocol static;
route-filter 0.0.0.0/0 exact;
}
then accept;
}
term cleanup {
then reject;
}

Partial ROUTING BGP:


ri007424@DLHIIAG2B> show configuration policy-options policy-statement
METRO_RAIL-OUT
term advertise {
from {
protocol bgp;
as-path RIC-ROUTES;
}
then {
community delete ALL;
accept;
}
}
term network-block {
from {
route-filter 220.224.128.0/18 orlonger;
}
then reject;
}
term 18101 {
from {
protocol [ bgp static aggregate ];
route-filter 220.224.0.0/14 upto /24;
}
26
then {
community delete ALL;
accept;
}
}
term advertise_Reliance-Customer {
from {
protocol [ bgp aggregate static ];
community [ RIC-CUSTOMER R-CONNECT BRAS IDC ];
route-filter 0.0.0.0/0 upto /24;
}
then {
community delete ALL;
accept;
}
}
term IDC {
from {
protocol bgp;
route-filter 202.138.96.0/19 upto /24;
}
then {
community delete ALL;
accept;
}
}
term advertise-default-route {
from {
route-filter 0.0.0.0/0 exact;
}
then accept;
}
term cleanup {
then reject;
}
27

You might also like