Configuration and Show Commands for Juniper
Basic Junos Router Show Commands & Configurations
Here are 10 essential Junos commands and configurations to help you get started with your Junos router.
1. Show System Information
To check the system status, hardware details, and software version of your Junos router:
show version
This will provide information like Junos version, router model, and uptime.
2. Show System Boot Process
To view the system boot history and details:
show system boot-messages
This shows any issues during boot, kernel messages, and overall boot status.
3. Show Interface Status
To view the status of all network interfaces:
show interfaces terse
This gives a concise overview of interface status (up/down), IP addresses, and other essential details.
4. Show Routing Table
To display the current routing table:
show route
This will list all active routes, including destination networks, next hops, and interface details.
5. Show Firewall Filters (Policies)
To view firewall filter (policies) applied to interfaces or zones:
show configuration firewall
This will display the configuration for firewall rules, including filters, policies, and interfaces.
6. Show System Memory Usage
To check the system’s memory usage and statistics:
show system resources
This provides memory, CPU, and system load information, helping to monitor resource consumption.
7. Show BGP Summary
If you’re using BGP, this command will show the status of BGP neighbors:
show bgp summary
This command shows BGP peer status, advertised routes, and other related statistics.
8. Show Log Messages
To display the system log messages for troubleshooting:
show log messages
This will display system logs, including events, errors, and warnings.
9. Show Configuration
To display the router’s active configuration:
show configuration
This will show the full configuration of the router. You can also use:
show configuration | display set
for a more compact, set-style output.
10. Show System Uptime
To view how long the system has been up and running:
show system uptime
This gives you the router’s uptime, including how long the system has been operational since the last reboot.
Basic Junos Router Configuration Commands
Here are some basic configuration commands you might use:
1. Configure Hostname
To set the router’s hostname:
set system host-name <hostname>
Example:
set system host-name Router1
2. Configure Interface IP Address
To assign an IP address to an interface:
set interfaces ge-0/0/0 unit 0 family inet address <ip-address>/<subnet-mask>
Example:
set interfaces ge-0/0/0 unit 0 family inet address 192.168.1.1/24
3. Configure Routing Protocol (OSPF)
To configure OSPF on an interface:
set protocols ospf area 0.0.0.0 interface ge-0/0/0.0
4. Set Default Gateway
To configure a default route (gateway):
set routing-options static route 0.0.0.0/0 next-hop <next-hop-ip>
Example:
set routing-options static route 0.0.0.0/0 next-hop 192.168.1.254
5. Commit Changes
To apply the changes you’ve made:
commit
Leave a Reply