#查看邻居
show ip bgp neighbors <peer-ip>
#拒收默认路由规则
ip prefix-list DEFAULT-ROUTE-v4 seq 5 deny 0.0.0.0/0
ipv6 prefix-list DEFAULT-ROUTE-v6 seq 5 deny ::/0
#刷新收取路由
clear ip bgp <peer-ip> soft in
#查看BGP连接状态
show ip bgp summary
show bgp ipv6 unicast summary
#筛选配置内容
show running-config | section router bgp
#查看bgp邻居
show bgp ipv6 unicast neighbors <peer-ipv6>
show bgp ipv4 unicast neighbors <peer-ipv4>
#查看网卡状态信息
show ip interface brief
#查看宣告路由表
show bgp ipv6 unicast neighbors <peer-ipv6> advertised-routes
show bgp ipv4 unicast neighbors <peer-ipv4> advertised-routes
router bgp 65000
no bgp enforce-first-as #关闭拒收一个as非peer as的路由
neighbor <peer-ipv4> default-originate #BGP发送默认路由
帮人配置个思科路踩到个坑:翻了半天文档才发现ASR默认开启了 bgp enforce-first-as,导致路由表里首个 AS 不是peer AS 的前缀都在Local Policy Denied Prefixes里面。
router bgp 65536
no bgp enforce-first-as
IX在发送交换路由的时候把自身AS过滤掉了,导致无法收表。
之前也用了chatgpt寻找答案,关键点也提到了IX在as-path过滤掉了自生AS,但是仍然没有正确解决思路都没提到,反而一直让route-map的规则里面找配置问题和重新配置BGP Session。
在运行的命令下按Ctrl+Z可以暂停进程运行
fg #恢复到前台继续运行
jobs # 查看后台任务
fg %1 # 恢复 jobs 列表里的 1 号任务
bg #后台继续运行(不挂起)
bg %1 #默认恢复最后一个挂起的任务
disown -h %1 #挂起后转后台长期运行
reptyr接管pid
apt install reptyr -y # Debian/Ubuntu
yum install reptyr -y # CentOS/RHEL
reptyr 12345 #12345是pid进程
这样可以把一个长期运行需要观察输出的进程丢进screen\tmux里面挂机运行了