BGP实验--联邦

news2024/11/26 2:36:02

 

1,AS1存在两个环回,一个地址为192.168.1.0/24 该地址不嫩在任何协议中宣告
   AS3中存在两个环回,一个地址为192.168.2.0/24该地址不能再任何协议中宣告,最终要求这两个环回可用互相通讯
   AS1中的另一个环回为10.0.0.0 24,AS3中的另一个环回为11.0.0.0/24
2,整个AS2的IP地址为172.16.0.0/16,请合理划分
3,AS间的骨干链路IP地址随意指定
4,使用BGP协议让整个网络所有设备的环回可以互相访问
5,减少路由条目数量,避免环路出现

配置路由 

R1

Interface                         IP Address/Mask      Physical   Protocol  
GigabitEthernet0/0/0              12.0.0.1/24          up         up        
GigabitEthernet0/0/1              unassigned           down       down      
GigabitEthernet0/0/2              unassigned           down       down      
LoopBack0                         10.0.0.1/24          up         up(s)     
LoopBack1                         192.168.1.1/24       up         up(s)     
NULL0                             unassigned           up         up(s)     

R2

Interface                         IP Address/Mask      Physical   Protocol  
GigabitEthernet0/0/0              172.16.0.1/30        up         up        
GigabitEthernet0/0/1              12.0.0.2/24          up         up        
GigabitEthernet0/0/2              172.16.0.22/30       up         up        
LoopBack0                         172.16.2.1/24        up         up(s)     
NULL0                             unassigned           up         up(s)     

R3

Interface                         IP Address/Mask      Physical   Protocol  
GigabitEthernet0/0/0              172.16.0.5/30        up         up        
GigabitEthernet0/0/1              172.16.0.2/30        up         up        
GigabitEthernet0/0/2              unassigned           down       down      
LoopBack0                         172.16.3.1/24        up         up(s)     
NULL0                             unassigned           up         up(s)  

R4

Interface                         IP Address/Mask      Physical   Protocol  
GigabitEthernet0/0/0              172.16.0.9/30        up         up        
GigabitEthernet0/0/1              172.16.0.6/30        up         up        
GigabitEthernet0/0/2              unassigned           down       down      
LoopBack0                         172.16.4.1/24        up         up(s)     
NULL0                             unassigned           up         up(s)

R5

Interface                         IP Address/Mask      Physical   Protocol  
GigabitEthernet0/0/0              172.16.0.21/30       up         up        
GigabitEthernet0/0/1              172.16.0.18/30       up         up        
GigabitEthernet0/0/2              unassigned           down       down      
LoopBack0                         172.16.5.1/24        up         up(s)     
NULL0                             unassigned           up         up(s)     


R6

Interface                         IP Address/Mask      Physical   Protocol  
GigabitEthernet0/0/0              172.16.0.17/30       up         up        
GigabitEthernet0/0/1              172.16.0.14/30       up         up        
GigabitEthernet0/0/2              unassigned           down       down      
LoopBack0                         172.16.6.1/24        up         up(s)     
NULL0                             unassigned           up         up(s)     


R7

Interface                         IP Address/Mask      Physical   Protocol  
GigabitEthernet0/0/0              172.16.0.13/30       up         up        
GigabitEthernet0/0/1              78.0.0.1/24          up         up        
GigabitEthernet0/0/2              172.16.0.10/30       up         up        
LoopBack0                         172.16.7.1/24        up         up(s)     
NULL0                             unassigned           up         up(s)     


R8


Interface                         IP Address/Mask      Physical   Protocol  
GigabitEthernet0/0/0              78.0.0.2/24          up         up        
GigabitEthernet0/0/1              unassigned           down       down      
GigabitEthernet0/0/2              unassigned           down       down      
LoopBack0                         11.0.0.1/24          up         up(s)     
LoopBack1                         192.168.2.1/24       up         up(s)     
NULL0                             unassigned           up         up(s)     

再内部网络(R2-R7)中运行IGP协议--ospf

R2
[r2]ospf 1 ro	
[r2]ospf 1 router-id 2.2.2.2
[r2-ospf-1]area 0
[r2-ospf-1-area-0.0.0.0]net	
[r2-ospf-1-area-0.0.0.0]network 172.16.0.0 0.0.255.255
[r2]dis ospf p b

	 OSPF Process 1 with Router ID 2.2.2.2
		  Peer Statistic Information
 ----------------------------------------------------------------------------
 Area Id          Interface                        Neighbor id      State    
 0.0.0.0          GigabitEthernet0/0/0             3.3.3.3          Full        
 0.0.0.0          GigabitEthernet0/0/2             5.5.5.5          Full        
 ----------------------------------------------------------------------------



R3
[r3-LoopBack0]q
[r3]ospf 1 ro	
[r3]ospf 1 router-id 3.3.3.3
[r3-ospf-1]net	
[r3-ospf-1]area 0
[r3-ospf-1-area-0.0.0.0]net	
[r3-ospf-1-area-0.0.0.0]network 172.16.0.0 0.0.255.255
[r3]dis ospf p b

	 OSPF Process 1 with Router ID 3.3.3.3
		  Peer Statistic Information
 ----------------------------------------------------------------------------
 Area Id          Interface                        Neighbor id      State    
 0.0.0.0          GigabitEthernet0/0/0             4.4.4.4          Full        
 0.0.0.0          GigabitEthernet0/0/1             2.2.2.2          Full        
 ----------------------------------------------------------------------------
[r3]


R4
[r4-ospf-1-area-0.0.0.0]dis this
[V200R003C00]
#
 area 0.0.0.0 
  network 172.16.0.0 0.0.255.255 
#
return
[r4-ospf-1-area-0.0.0.0]dis ospf p b

	 OSPF Process 1 with Router ID 4.4.4.4
		  Peer Statistic Information
 ----------------------------------------------------------------------------
 Area Id          Interface                        Neighbor id      State    
 0.0.0.0          GigabitEthernet0/0/0             7.7.7.7          Full        
 0.0.0.0          GigabitEthernet0/0/1             3.3.3.3          Full        
 ----------------------------------------------------------------------------


R5
[r5]ospf 1 ro	
[r5]ospf 1 router-id 5.5.5.5
[r5-ospf-1]AREA 0
[r5-ospf-1-area-0.0.0.0]net	
[r5-ospf-1-area-0.0.0.0]network 172.16.0.0 0.0.255.255
[r5-ospf-1-area-0.0.0.0]dis ospf p b

	 OSPF Process 1 with Router ID 5.5.5.5
		  Peer Statistic Information
 ----------------------------------------------------------------------------
 Area Id          Interface                        Neighbor id      State    
 0.0.0.0          GigabitEthernet0/0/0             2.2.2.2          Full        
 0.0.0.0          GigabitEthernet0/0/1             6.6.6.6          Full        
 ----------------------------------------------------------------------------



R6
[r6]ospf 1 ro	
[r6]ospf 1 router-id 6.6.6.6
[r6-ospf-1]area 0
[r6-ospf-1-area-0.0.0.0]net	
[r6-ospf-1-area-0.0.0.0]network 172.16.0.0 0.0.255.255
[r6-ospf-1-area-0.0.0.0]dis ospf p b

	 OSPF Process 1 with Router ID 6.6.6.6
		  Peer Statistic Information
 ----------------------------------------------------------------------------
 Area Id          Interface                        Neighbor id      State    
 0.0.0.0          GigabitEthernet0/0/0             5.5.5.5          Full        
 0.0.0.0          GigabitEthernet0/0/1             7.7.7.7          Full        
 ----------------------------------------------------------------------------


R7
[r7]ospf 1 ro	
[r7]ospf 1 router-id 7.7.7.7
[r7-ospf-1]area 0
[r7-ospf-1-area-0.0.0.0]net	
[r7-ospf-1-area-0.0.0.0]network 172.16.0.0 0.0.255.255
[r7-ospf-1-area-0.0.0.0]dis ospf p b

	 OSPF Process 1 with Router ID 7.7.7.7
		  Peer Statistic Information
 ----------------------------------------------------------------------------
 Area Id          Interface                        Neighbor id      State    
 0.0.0.0          GigabitEthernet0/0/0             6.6.6.6          Full        
 0.0.0.0          GigabitEthernet0/0/2             4.4.4.4          Full        
 ----------------------------------------------------------------------------

进行BGP配置,并进行建邻操作

R1
[r1-bgp]ro	
[r1-bgp]router-id 1.1.1.1
[r1-bgp]peer 12.0.0.2 as	
[r1-bgp]peer 12.0.0.2 as-number 2
[r1-bgp]dis this
[V200R003C00]
#
bgp 1
 router-id 1.1.1.1
 peer 12.0.0.2 as-number 2 
 #
 ipv4-family unicast
  undo synchronization
  peer 12.0.0.2 enable
#
return
[r1-bgp]



R2
[r2-bgp]ro	
[r2-bgp]router-id 2.2.2.2
[r2-bgp]con	
[r2-bgp]confederation id 2
[r2-bgp]peer 12.0.0.1 as	
[r2-bgp]peer 12.0.0.1 as-number 1
[r2-bgp]peer 172.16.3.1 as	
[r2-bgp]peer 172.16.3.1 as-path-filter
[r2-bgp]peer 172.16.3.1 as-number 64512
[r2-bgp]peer 172.16.3.1 connect-interface lo	
[r2-bgp]peer 172.16.3.1 connect-interface LoopBack 0
[r2-bgp]dis this
[V200R003C00]
#
bgp 64512
 router-id 2.2.2.2
 confederation id 2
 peer 12.0.0.1 as-number 1 
 peer 172.16.3.1 as-number 64512 
 peer 172.16.3.1 connect-interface LoopBack0
 #
 ipv4-family unicast
  undo synchronization
  peer 12.0.0.1 enable
  peer 172.16.3.1 enable
#
return



R3
[r3-bgp]con	
[r3-bgp]confederation id 2
[r3-bgp]ro	
[r3-bgp]router-id 3.3.3.3
[r3-bgp]peer 172.16.2.1 as-nu	
[r3-bgp]peer 172.16.2.1 as-number 64512
[r3-bgp]peer 172.16.2.1 con	
[r3-bgp]peer 172.16.2.1 connect-interface lo 0
[r3-bgp]peer 172.16.4.1 as-	
[r3-bgp]peer 172.16.4.1 as-number 64512
[r3-bgp]peer 172.16.4.1 co	
[r3-bgp]peer 172.16.4.1 connect-interface lo 0
[r3-bgp]dis this
[V200R003C00]
#
bgp 64512
 router-id 3.3.3.3
 confederation id 2
 peer 172.16.2.1 as-number 64512 
 peer 172.16.2.1 connect-interface LoopBack0
 peer 172.16.4.1 as-number 64512 
 peer 172.16.4.1 connect-interface LoopBack0
 #
 ipv4-family unicast
  undo synchronization
  peer 172.16.2.1 enable
  peer 172.16.4.1 enable
#
return



R4
[r4-bgp]con	
[r4-bgp]confederation id 2
[r4-bgp]ro	
[r4-bgp]router-id 4.4.4.4
[r4-bgp]peer 172.16.3.1 as	
[r4-bgp]peer 172.16.3.1 as-number 64512
[r4-bgp]peer 172.16.3.1 con	
[r4-bgp]peer 172.16.3.1 connect-interface lo 0
[r4-bgp]dis this
[V200R003C00]
#
bgp 64512
 router-id 4.4.4.4
 confederation id 2
 peer 172.16.3.1 as-number 64512 
 peer 172.16.3.1 connect-interface LoopBack0
 #
 ipv4-family unicast
  undo synchronization
  peer 172.16.3.1 enable
#
return



R5
[r5-bgp]con	
[r5-bgp]confederation id 2
[r5-bgp]ro	
[r5-bgp]router-id 5.5.5.5
[r5-bgp]peer 172.16.6.1 as	
[r5-bgp]peer 172.16.6.1 as-number 64513
[r5-bgp]peer 172.16.6.1 con	
[r5-bgp]peer 172.16.6.1 connect-interface lo 0
[r5-bgp]dis this
[V200R003C00]
#
bgp 64513
 router-id 5.5.5.5
 confederation id 2
 peer 172.16.6.1 as-number 64513 
 peer 172.16.6.1 connect-interface LoopBack0
 #
 ipv4-family unicast
  undo synchronization
  peer 172.16.6.1 enable
#
return


R6
[r6-bgp]con	
[r6-bgp]confederation id 2
[r6-bgp]ro	
[r6-bgp]router-id 6.6.6.6
[r6-bgp]peer 172.16.5.1 as	
[r6-bgp]peer 172.16.5.1 as-number 64513
[r6-bgp]peer 172.16.5.1 co	
[r6-bgp]peer 172.16.5.1 connect-interface lo 0
[r6-bgp]peer 172.16.7.1 as	
[r6-bgp]peer 172.16.7.1 as-number 64513
[r6-bgp]peer 172.16.7.1 con	
[r6-bgp]peer 172.16.7.1 connect-interface lo 0
[r6-bgp]dis this
[V200R003C00]
#
bgp 64513
 router-id 6.6.6.6
 confederation id 2
 peer 172.16.5.1 as-number 64513 
 peer 172.16.5.1 connect-interface LoopBack0
 peer 172.16.7.1 as-number 64513 
 peer 172.16.7.1 connect-interface LoopBack0
 #
 ipv4-family unicast
  undo synchronization
  peer 172.16.5.1 enable
  peer 172.16.7.1 enable
#
return



R7
[r7-bgp]con	
[r7-bgp]confederation id 2
[r7-bgp]ro	
[r7-bgp]router-id 7.7.7.7
[r7-bgp]peer 78.0.0.2 as	
[r7-bgp]peer 78.0.0.2 as-number 3
[r7-bgp]peer 172.16.6.1 as	
[r7-bgp]peer 172.16.6.1 as-path-filter
[r7-bgp]peer 172.16.6.1 co	
[r7-bgp]peer 172.16.6.1 connect-interface lo 0
Error: The peer session does not exist.
[r7-bgp]peer 172.16.6.1 connect-interface lo 	
[r7-bgp]peer 172.16.6.1 connect-interface LoopBack 0
Error: The peer session does not exist.
[r7-bgp]dis this
[V200R003C00]
#
bgp 64513
 router-id 7.7.7.7
 confederation id 2
 peer 78.0.0.2 as-number 3 
 #
 ipv4-family unicast
  undo synchronization
  peer 78.0.0.2 enable
#
return
[r7-bgp]peer 172.16.6.1 as	
[r7-bgp]peer 172.16.6.1 as-number 64513
[r7-bgp]peer 172.16.6.1 co	
[r7-bgp]peer 172.16.6.1 connect-interface lo 0
[r7-bgp]dis this
[V200R003C00]
#
bgp 64513
 router-id 7.7.7.7
 confederation id 2
 peer 78.0.0.2 as-number 3 
 peer 172.16.6.1 as-number 64513 
 peer 172.16.6.1 connect-interface LoopBack0
 #
 ipv4-family unicast
  undo synchronization
  peer 78.0.0.2 enable
  peer 172.16.6.1 enable
#
return


R8
[r8-bgp]ro	
[r8-bgp]route-select
[r8-bgp]router-id 8.8.8.8
[r8-bgp]peer 78.0.0.1 as	
[r8-bgp]peer 78.0.0.1 as-number 2
[r8-bgp]dis this
[V200R003C00]
#
bgp 3
 router-id 8.8.8.8
 peer 78.0.0.1 as-number 2 
 #
 ipv4-family unicast
  undo synchronization
  peer 78.0.0.1 enable
#
return



再AS2内部进行AS联邦配置

[r2-bgp]confederation peer-as 64513
[r2-bgp]peer 172.16.5.1 as-number 64513
[r2-bgp]peer 172.16.5.1 connect-interface lo 0
[r2-bgp]peer 172.16.5.1 ebgp-max-hop 



[r4-bgp]confederation peer-as 64513
[r4-bgp]peer 172.16.7.1 as-number 64513
[r4-bgp]peer 172.16.7.1 connect-interface LoopBack 0
[r4-bgp]peer 172.16.7.1 ebgp-max-hop 



[r5-bgp]confederation peer-as 64512
[r5-bgp]peer 172.16.2.1 as-number 64512
[r5-bgp]peer 172.16.2.1 connect-interface lo 0
[r5-bgp]peer 172.16.2.1 ebgp-max-hop




[r7-bgp]confederation peer-as 64512
[r7-bgp]peer 172.16.4.1 as-number 64512
[r7-bgp]peer 172.16.4.1 connect-interface LoopBack 0
[r7-bgp]peer 172.16.4.1 ebgp-max-hop

查看建邻是否成功

[r2-bgp]dis bgp peer 

 BGP local router ID : 2.2.2.2
 Local AS number : 64512
 Total number of peers : 3		  Peers in established state : 3

  Peer            V          AS  MsgRcvd  MsgSent  OutQ  Up/Down       State Pre
fRcv

  12.0.0.1        4           1       27       27     0 00:25:39 Established    
   0
  172.16.3.1      4       64512       25       26     0 00:23:42 Established    
   0
  172.16.5.1      4       64513        6       10     0 00:05:00 Established    
   0
[r2-bgp]



[r7-bgp]dis bgp peer

 BGP local router ID : 7.7.7.7
 Local AS number : 64513
 Total number of peers : 3		  Peers in established state : 3

  Peer            V          AS  MsgRcvd  MsgSent  OutQ  Up/Down       State Pre
fRcv

  78.0.0.2        4           3       18       19     0 00:16:39 Established    
   0
  172.16.4.1      4       64512        5        5     0 00:03:19 Established    
   0
  172.16.6.1      4       64513       19       19     0 00:17:12 Established    
   0
[r7-bgp]
宣告10.0.0.0/24和11.0.0.0/24网段,以及修改在R2和R7上传输给AS 2内部的对等体的下一跳属性,并指定为自己与对等体的连接地址
[r1-bgp]network 10.0.0.0 24


[r8-bgp]network 11.0.0.0 24


[r2-bgp]peer 172.16.3.1 next-hop-local
[r2-bgp]peer 172.16.5.1 next-hop-local


[r7-bgp]peer 172.16.4.1 next-hop-local
[r7-bgp]peer 172.16.6.1 next-hop-local

指定R3和R6为路由反射器,并将R2和R7分别定为R3和R6的客户

[r3-bgp]peer 172.16.2.1 reflect-client 

[r6-bgp]peer 172.16.7.1 reflect-client 


[r4-bgp]dis bgp routing-table 

 BGP Local router ID is 4.4.4.4 
 Status codes: * - valid, > - best, d - damped,
               h - history,  i - internal, s - suppressed, S - Stale
               Origin : i - IGP, e - EGP, ? - incomplete


 Total Number of Routes: 3
      Network            NextHop        MED        LocPrf    PrefVal Path/Ogn

 *>i  10.0.0.0/24        172.16.2.1      0          100        0      1i
 *>i  11.0.0.0/24        172.16.7.1      0          100        0      (64513) 3i
 * i                     172.16.7.1      0          100        0      (64513) 3i
[r4-bgp]



[r5-bgp]dis bgp routing-table 

 BGP Local router ID is 5.5.5.5 
 Status codes: * - valid, > - best, d - damped,
               h - history,  i - internal, s - suppressed, S - Stale
               Origin : i - IGP, e - EGP, ? - incomplete


 Total Number of Routes: 2
      Network            NextHop        MED        LocPrf    PrefVal Path/Ogn

 *>i  10.0.0.0/24        172.16.2.1      0          100        0      (64512) 1i
 *>i  11.0.0.0/24        172.16.7.1      0          100        0      3i
[r5-bgp]

对AS 2区域内的路由进行聚合,并配置空接口

[r2]ip route-static 172.16.0.0 16 nu 0

[r7]ip route-static 172.16.0.0 16 NULL 0

[r7-bgp]network 172.16.0.0 16

[r2-bgp]network 172.16.0.0 16

再R2和R7上宣告其他AS区域的网段,使得全网可达

[r2-bgp]network 12.0.0.0 24

[r7-bgp]network 78.0.0.0 24

[r1-bgp]dis ip ro protocol bgp
Route Flags: R - relay, D - download to fib
------------------------------------------------------------------------------
Public routing table : BGP
         Destinations : 3        Routes : 3        

BGP routing table status : <Active>
         Destinations : 3        Routes : 3

Destination/Mask    Proto   Pre  Cost      Flags NextHop         Interface

       11.0.0.0/24  EBGP    255  0           D   12.0.0.2        GigabitEthernet
0/0/0
       78.0.0.0/24  EBGP    255  0           D   12.0.0.2        GigabitEthernet
0/0/0
     172.16.0.0/16  EBGP    255  0           D   12.0.0.2        GigabitEthernet
0/0/0

BGP routing table status : <Inactive>
         Destinations : 0        Routes : 0

[r1-bgp]


[r8-bgp]dis ip ro p bgp
Route Flags: R - relay, D - download to fib
------------------------------------------------------------------------------
Public routing table : BGP
         Destinations : 3        Routes : 3        

BGP routing table status : <Active>
         Destinations : 3        Routes : 3

Destination/Mask    Proto   Pre  Cost      Flags NextHop         Interface

       10.0.0.0/24  EBGP    255  0           D   78.0.0.1        GigabitEthernet
0/0/0
       12.0.0.0/24  EBGP    255  0           D   78.0.0.1        GigabitEthernet
0/0/0
     172.16.0.0/16  EBGP    255  0           D   78.0.0.1        GigabitEthernet
0/0/0

BGP routing table status : <Inactive>
         Destinations : 0        Routes : 0

[r8-bgp]

为R1和R2的环回L1建立隧道,使得不宣告路由也可达

R1:[r1-Tunnel0/0/0]dis this
[V200R003C00]
#
interface Tunnel0/0/0
 ip address 18.0.0.1 255.255.255.0 
 tunnel-protocol gre
 source 10.0.0.1
 destination 11.0.0.1
#
return

R8:
[r8-Tunnel0/0/0]dis this
[V200R003C00]
#
interface Tunnel0/0/0
 ip address 18.0.0.2 255.255.255.0 
 tunnel-protocol gre
 source 11.0.0.1
 destination 10.0.0.1
#
return

[r1-Tunnel0/0/0]ping -a 18.0.0.1 18.0.0.2
  PING 18.0.0.2: 56  data bytes, press CTRL_C to break
    Reply from 18.0.0.2: bytes=56 Sequence=1 ttl=255 time=90 ms
    Reply from 18.0.0.2: bytes=56 Sequence=2 ttl=255 time=40 ms
    Reply from 18.0.0.2: bytes=56 Sequence=3 ttl=255 time=50 ms
    Reply from 18.0.0.2: bytes=56 Sequence=4 ttl=255 time=40 ms
    Reply from 18.0.0.2: bytes=56 Sequence=5 ttl=255 time=60 ms

  --- 18.0.0.2 ping statistics ---
    5 packet(s) transmitted
    5 packet(s) received
    0.00% packet loss
    round-trip min/avg/max = 40/56/90 ms

R1:
[r1]ip route-static 192.168.2.0 24 18.0.0.2----在R1上配置静态指向隧道对端的入口地址

R8:
[r8]ip route-static 192.168.1.0 24 18.0.0.1----在R8上配置静态指向隧道对端的入口地址



[r1]ping -a 192.168.1.1 192.168.2.1
  PING 192.168.2.1: 56  data bytes, press CTRL_C to break
    Reply from 192.168.2.1: bytes=56 Sequence=1 ttl=255 time=70 ms
    Reply from 192.168.2.1: bytes=56 Sequence=2 ttl=255 time=50 ms
    Reply from 192.168.2.1: bytes=56 Sequence=3 ttl=255 time=50 ms
    Reply from 192.168.2.1: bytes=56 Sequence=4 ttl=255 time=50 ms
    Reply from 192.168.2.1: bytes=56 Sequence=5 ttl=255 time=60 ms

  --- 192.168.2.1 ping statistics ---
    5 packet(s) transmitted
    5 packet(s) received
    0.00% packet loss
    round-trip min/avg/max = 50/56/70 ms

本文来自互联网用户投稿,该文观点仅代表作者本人,不代表本站立场。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如若转载,请注明出处:http://www.coloradmin.cn/o/764824.html

如若内容造成侵权/违法违规/事实不符,请联系多彩编程网进行投诉反馈,一经查实,立即删除!

相关文章

在 Linux 系统上下载 Android SDK

使用ubuntu系统进行车机开发&#xff0c;今天开始配置环境&#xff0c;首先是下载android studio&#xff0c;然后下载android sdk&#xff0c;这里需要注意的是linux系统不能使用windows系统下的Android sdk&#xff0c;亲测会出现各种问题。 常规思路&#xff0c;下载sdk&am…

【前端知识】JavaScript——<script>的8个属性

【前端知识】JavaScript——<script>的8个属性 <script>元素的8个属性&#xff1a; 属性释义async表示应该立即开始下载脚本&#xff0c;但不能阻止其他页面动作&#xff0c;比如下载资源或等待其他脚本加载。只对外部脚本文件有效。charset使用 src 属性指定的代…

力扣 134. 加油站

题目来源&#xff1a;https://leetcode.cn/problems/gas-station/description/ C题解1&#xff1a; 感觉也属于暴力&#xff0c;有一点点简化。在汽油获得总量小于消耗总量时直接返回-1&#xff0c;对于出发的加油站编号&#xff0c;其当前站的汽油净获得量一定大于等于0&#…

【严重】Grafana Azure AD环境身份认证绕过漏洞

漏洞描述 Grafana 是一个跨平台、开源的数据可视化网络应用平台。Azure AD 是由微软提供的一种云身份验证和访问管理服务。 在 Azure AD 中&#xff0c;多个用户可以拥有相同的电子邮件地址。攻击者可以创建一个与目标 Grafana 账户相同的电子邮件地址的恶意帐户&#xff0c;并…

Java IO流的使用

IO流概述 Java.io 包几乎包含了所有操作输入、输出需要的类。所有这些流类代表了输入源和输出目标。一个流可以理解为一个数据的序列。输入流表示从一个源读取数据&#xff0c;输出流表示向一个目标写数据。 Java.io 包中的流支持很多种格式&#xff0c;比如&#xff1a;基本…

SQLite数据库介绍以及安装

SQLite简介 轻量化&#xff0c;易用的嵌入式数据库&#xff0c;用于设备端的数据管理&#xff0c;可以理解成单点的数据库。传统服务器型数据 库用于管理多端设备&#xff0c;更加复杂 SQLite是一个无服务器的数据库&#xff0c;是自包含的。这也称为嵌入式数据库&#xff0c…

栈--C语言实现数据结构

本期带大家一起用C语言实现栈&#x1f308;&#x1f308;&#x1f308; 一、栈的概念&#x1f30e; 栈是一种常见的数据结构&#xff0c;它遵循后进先出&#xff08;Last In, First Out&#xff09;的原则。可以将其类比为现实生活中的一摞书或者一叠盘子。 栈由一个连续的内…

前端:运用html+css+js模仿京东上商品图片区域放大特效

前端:运用htmlcssjs模仿京东上商品图片区域放大特效 1. 前言2. 前端界面3. js实现鼠标移入效果4. 实现代码 1. 前言 最近在网页端浏览京东上的商品时&#xff0c;觉得上面的那张gif图片上实现的特效不错&#xff0c;于是自己打算使用htmlcssjs技术来实现一下上述特效效果&#…

【Ceph】Ceph集群应用详解

Ceph集群应用详解 1. 资源池Pool管理1.1 查看Pool集群信息的三种方式1.2 删除Pool资源池 2.创建CephFS文件系统MDS接口2.1 创建cephfs2.2 基于内核的客户端挂载2.3 基于fuse工具方式的客户端挂载 3.创建Ceph块存储系统RBD接口3.1 删除镜像3.2 还原镜像3.3 在线扩容3.4 回滚镜像…

flutter开发实战-卡片翻转动画效果Transform+IndexedStack+rotateAnimation

flutter开发实战-实现卡片翻转动画效果 之前开发中遇到了商品卡片翻转&#xff0c;商品正面是商品图片、商品名称&#xff1b;背面是商品价格&#xff0c;需要做卡片翻转动画。 动画实现即&#xff1a;在一段时间内&#xff0c;快速地多次改变UI外观&#xff1b;由于人眼会产生…

Ext JS中定义和使用类Ext JS风格的html 按钮

Ext JS 的按钮样式如下: 按钮的背景色默认为应用的主色调或是灰色系, 也可以通过样式设置按钮的背景色, 详细可以参考: Ext JS 如何设置工具栏按钮和一般按钮保持统一样式 但是, 在实际开发的场景中有可能某些按钮是不能通过Ext JS的Button 类进行创建的, 但是页面效果…

第三章:内存管理——C++的内存管理方式

系列文章目录 文章目录 系列文章目录前言C/C内存分布C语言中动态内存管理方式面试题 C内存管理模式new/delete操作内置类型new和delete操作自定义类型 operator new与operator delete函数new和delete的实现原理内置类型自定义类型 定位new表达式(placement-new)常见面试题mallo…

JDBC 驱动程序类型

什么是JDBC驱动程序&#xff1f; JDBC驱动程序在JDBC API中实现了已定义的接口&#xff0c;用于与数据库服务器进行交互。 例如&#xff0c;使用JDBC驱动程序&#xff0c;您可以通过发送SQL或数据库命令&#xff0c;然后使用Java接收结果来打开数据库连接并与其进行交互。 J…

el-date-picker 宽度溢出浏览器问题

原文链接&#xff1a; el-date-picker 宽度溢出浏览器问题 问题由来 <el-date-picker v-model"Time" type"datetimerange"range-separator"至"start-placeholder"年/月/日 时:分:秒"end-placeholder"年/月/日 时:分:秒"…

通过迁移加速计划迁移到亚马逊云科技

公司出于许多不同的原因迁移到云。也许他们需要关闭一个老化的数据中心。或者&#xff0c;他们正在寻找太昂贵或太难在内部构建和维护的新功能。无论出于何种原因&#xff0c;在开始规划迁移之前&#xff0c;他们还有另一个问题需要回答&#xff1a;哪种云服务适合他们的需求&a…

基于互一致性学习的半监督医学图像分割

文章目录 Mutual Consistency Learning for Semi-supervised Medical Image Segmentation摘要本文方法实验结果 Mutual Consistency Learning for Semi-supervised Medical Image Segmentation 摘要 提出了一种新的互一致性网络(MC-Net)来有效地利用未标记数据进行半监督医学…

修复git diff正文中文乱码

Linux git diff正文中文乱码 在命令行下输入以下命令&#xff1a; $ git config --global core.quotepath false # 显示 status 编码 $ git config --global gui.encoding utf-8 # 图形界面编码 $ git config --global i18n.commit.encoding utf-8 # …

安装linux子系统时,出现的问题

目录 一、事故原因&#xff1a;适配linux子系统问题 二、事故问题&#xff1a;wsl版本问题 一、事故原因&#xff1a;适配linux子系统问题 事故全文&#xff1a; Installing, this may take a few minutes... WslRegisterDistribution failed with error: 0x8007019e Err…

springboot sentinel 安装 整合 样例-分布式/微服务流量控制

sentinel控制台安装 下载地址&#xff1a;https://github.com/alibaba/Sentinel/releases 本次版本&#xff1a;1.8.6 后台启动&#xff1a; nohup java -Dserver.port7080 -Dcsp.sentinel.dashboard.serverlocalhost:7080 -Dproject.namesentinel-dashboard -jar sentinel-…

基于文本内容的垃圾短信识别实战

1、实战的背景与目标 背景&#xff1a; 垃圾短信形式日益多变&#xff0c;相关报告可以在下面网站查看 360互联网安全中心&#xff08;http://zt.360.cn/report/&#xff09; 目标&#xff1a; 基于短信文本内容&#xff0c;建立识别模型&#xff0c;准确地识别出垃圾短信…