Traceroute issue from a router running with software might get connection timed out message immediately as soon as the command is issued, even though the user is allowed to execute the traceroute command.
user@router> traceroute 8.8.8.8
traceroute to 8.8.8.8 (8.8.8.8), 30 hops max, 60 byte packets
connect: Connection timed out
user@router>
user@router> show cli authorization
Current user: 'user ' class 'test'
Permissions:
view -- Can view current values and statistics
Individual command authorization:
Allow regular expression: "show" "ssh" "cli.*" "set" "list" "file" "ping.*" "exit" "quit" "help" "traceroute.*"
Deny regular expression: none
Allow configuration regular expression: none
Deny configuration regular expression: none
user@router> show configuration system login class test
idle-timeout 5;
permissions view;
allow-commands-regexps [ traceroute.* help quit exit ping.* file list set cli.* ssh show ]; <<<< pls refer , traceroute is part of allowed command
user@router> show route 8.8.8.8
inet.0: 26 destinations, 27 routes (25 active, 0 holddown, 2 hidden)
+ = Active Route, - = Last Active, * = Both
0.0.0.0/0 *[Static/5] 3w6d 21:09:59
> to 10.85.183.193 via re0:mgmt-0.0
user@router> ping 8.8.8.8 <<<<< ping is successful
PING 8.8.8.8 (8.8.8.8) 56(84) bytes of data.
64 bytes from 8.8.8.8: icmp_seq=1 ttl=111 time=5.26 ms
64 bytes from 8.8.8.8: icmp_seq=2 ttl=111 time=5.28 ms
^C
--- 8.8.8.8 ping statistics ---
2 packets transmitted, 2 received, 0% packet loss, time 1001ms
rtt min/avg/max/mdev = 5.264/5.272/5.280/0.008 ms
CLI Out put from Non Working-Scenario
user@router> file list /dev/shm/smg_fibdv2_base detail
Jul 19 11:27:06
-rw-r----- 1 root root 256 Jun 14 17:55 /dev/shm/smg_fibdv2_base
total files: 1
Jul 19 11:27:09
<- After modifying the file permissions to 644
Jul 19 11:27:43
-rw-r--r-- 1 root root 256 Jun 14 17:55 /dev/shm/smg_fibdv2_base <<<<< File permission updated
user@router> traceroute 8.8.8.8 <<< traceroute started working
Jul 19 11:27:50
1 10.85.183.195 (10.85.183.195) 16.180 ms 16.026 ms 15.905 ms
2 10.85.128.129 (10.85.128.129) 0.786 ms 1.048 ms 0.973 ms^C
user@router> ping 8.8.8.8
Jul 19 11:30:10
64 bytes from 8.8.8.8: icmp_seq=1 ttl=111 time=5.32 ms
64 bytes from 8.8.8.8: icmp_seq=2 ttl=111 time=5.30 ms
rtt min/avg/max/mdev = 5.305/5.315/5.325/0.010 ms
Jul 19 11:30:16
Corrected the URL name