VLANIF配置

news2025/1/11 4:53:23

目录

实验原理:

案例:

设备配置

用ping验证不同vlan之间实现相互通信


实验原理:

VLANIF接口是一种第三层的逻辑接口,用于在第三层实现不同VLAN 之间的通信。

每个VALN有一个VLANIF接口,并通过该接口在网络层转发 VLAN通信。由于每个VLAN是一个广播域,每个 VLAN 可以被看作是一个 IP 网段,因此可以把 VLANIF 接口当作该VLAN的网关,通过在VLANIF 接口上配置IP地址,并允许其基于IP地址进行第三层分组转发,就可以实现VLAN之间在第三层上的互相通信。 

案例:

设备配置

 

LSW1的配置 

<Huawei>sys
Enter system view, return user view with Ctrl+Z.
[Huawei]sysname LSW1
[LSW1]vlan batch 10 30
Info: This operation may take a few seconds. Please wait for a moment...done.
[LSW1]
Sep 17 2023 11:07:12-08:00 LSW1 DS/4/DATASYNC_CFGCHANGE:OID 1.3.6.1.4.1.2011.5.2
5.191.3.1 configurations have been changed. The current change number is 5, the 
change loop count is 0, and the maximum number of records is 4095.
[LSW1]undo info-center enable
Info: Information center is disabled.
[LSW1]port-group pvlan10
[LSW1-port-group-pvlan10]group-member g0/0/9 to g0/0/12
[LSW1-port-group-pvlan10]port link-type access
[LSW1-GigabitEthernet0/0/9]port link-type access
[LSW1-GigabitEthernet0/0/10]port link-type access
[LSW1-GigabitEthernet0/0/11]port link-type access
[LSW1-GigabitEthernet0/0/12]port link-type access
[LSW1-port-group-pvlan10]port default vlan 10
[LSW1-GigabitEthernet0/0/9]port default vlan 10
[LSW1-GigabitEthernet0/0/10]port default vlan 10
[LSW1-GigabitEthernet0/0/11]port default vlan 10
[LSW1-GigabitEthernet0/0/12]port default vlan 10
[LSW1-port-group-pvlan10]q
[LSW1]port-group pvlan30
[LSW1-port-group-pvlan30]group-member g0/0/13 to g0/0/16
[LSW1-port-group-pvlan30]port link-type access
[LSW1-GigabitEthernet0/0/13]port link-type access
[LSW1-GigabitEthernet0/0/14]port link-type access
[LSW1-GigabitEthernet0/0/15]port link-type access
[LSW1-GigabitEthernet0/0/16]port link-type access
[LSW1-port-group-pvlan30]port default vlan 30
[LSW1-GigabitEthernet0/0/13]port default vlan 30
[LSW1-GigabitEthernet0/0/14]port default vlan 30
[LSW1-GigabitEthernet0/0/15]port default vlan 30
[LSW1-GigabitEthernet0/0/16]port default vlan 30
[LSW1-port-group-pvlan30]qu
[LSW1]interface g0/0/24
[LSW1-GigabitEthernet0/0/24]port link-type trunk
[LSW1-GigabitEthernet0/0/24]port trunk allow-pass vlan 10 30
[LSW1-GigabitEthernet0/0/24]qu
[LSW1]display vlan
The total number of vlans is : 3
--------------------------------------------------------------------------------
U: Up;         D: Down;         TG: Tagged;         UT: Untagged;
MP: Vlan-mapping;               ST: Vlan-stacking;
#: ProtocolTransparent-vlan;    *: Management-vlan;
--------------------------------------------------------------------------------

VID  Type    Ports                                                          
--------------------------------------------------------------------------------
1    common  UT:GE0/0/1(D)      GE0/0/2(D)      GE0/0/3(D)      GE0/0/4(D)      
                GE0/0/5(D)      GE0/0/6(D)      GE0/0/7(D)      GE0/0/8(D)      
                GE0/0/17(D)     GE0/0/18(D)     GE0/0/19(D)     GE0/0/20(D)     
                GE0/0/21(D)     GE0/0/22(D)     GE0/0/23(D)     GE0/0/24(U)     

10   common  UT:GE0/0/9(U)      GE0/0/10(D)     GE0/0/11(D)     GE0/0/12(D)     

             TG:GE0/0/24(U)                                                     

30   common  UT:GE0/0/13(U)     GE0/0/14(D)     GE0/0/15(D)     GE0/0/16(D)     

             TG:GE0/0/24(U)                                                     


VID  Status  Property      MAC-LRN Statistics Description      
--------------------------------------------------------------------------------

1    enable  default       enable  disable    VLAN 0001                         
10   enable  default       enable  disable    VLAN 0010                         
30   enable  default       enable  disable    VLAN 0030                         
[LSW1]display IP routing-table
Route Flags: R - relay, D - download to fib
------------------------------------------------------------------------------
Routing Tables: Public
         Destinations : 2        Routes : 2        

Destination/Mask    Proto   Pre  Cost      Flags NextHop         Interface

      127.0.0.0/8   Direct  0    0           D   127.0.0.1       InLoopBack0
      127.0.0.1/32  Direct  0    0           D   127.0.0.1       InLoopBack0

 LSW2也是相同的配置 

<Huawei>sys
Enter system view, return user view with Ctrl+Z.
[Huawei]sysname LSW2
[LSW2]
Sep 17 2023 11:14:23-08:00 LSW2 DS/4/DATASYNC_CFGCHANGE:OID 1.3.6.1.4.1.2011.5.2
5.191.3.1 configurations have been changed. The current change number is 4, the 
change loop count is 0, and the maximum number of records is 4095.
[LSW2]undo info-center enable
Info: Information center is disabled.
[LSW2]vlan batch 10 30
Info: This operation may take a few seconds. Please wait for a moment...done.
[LSW2]port-group pvlan10
[LSW2-port-group-pvlan10]group-member g0/0/9 to g0/0/12
[LSW2-port-group-pvlan10]port link-type access
[LSW2-GigabitEthernet0/0/9]port link-type access
[LSW2-GigabitEthernet0/0/10]port link-type access
[LSW2-GigabitEthernet0/0/11]port link-type access
[LSW2-GigabitEthernet0/0/12]port link-type access
[LSW2-port-group-pvlan10]port default vlan 10
[LSW2-GigabitEthernet0/0/9]port default vlan 10
[LSW2-GigabitEthernet0/0/10]port default vlan 10
[LSW2-GigabitEthernet0/0/11]port default vlan 10
[LSW2-GigabitEthernet0/0/12]port default vlan 10
[LSW2-port-group-pvlan10]qu
[LSW2]port-group pvlan30
[LSW2-port-group-pvlan30]group-member g0/0/13 to g0/0/16
[LSW2-port-group-pvlan30]port link-type access
[LSW2-GigabitEthernet0/0/13]port link-type access
[LSW2-GigabitEthernet0/0/14]port link-type access
[LSW2-GigabitEthernet0/0/15]port link-type access
[LSW2-GigabitEthernet0/0/16]port link-type access
[LSW2-port-group-pvlan30]port default vlan 30
[LSW2-GigabitEthernet0/0/13]port default vlan 30
[LSW2-GigabitEthernet0/0/14]port default vlan 30
[LSW2-GigabitEthernet0/0/15]port default vlan 30
[LSW2-GigabitEthernet0/0/16]port default vlan 30
[LSW2-port-group-pvlan30]qu
[LSW2]interface g0/0/24
[LSW2-GigabitEthernet0/0/24]port link-type trunk
[LSW2-GigabitEthernet0/0/24]port trunk allow-pass vlan 10 30
[LSW2-GigabitEthernet0/0/24]qu
[LSW2]display vlan
The total number of vlans is : 3
--------------------------------------------------------------------------------
U: Up;         D: Down;         TG: Tagged;         UT: Untagged;
MP: Vlan-mapping;               ST: Vlan-stacking;
#: ProtocolTransparent-vlan;    *: Management-vlan;
--------------------------------------------------------------------------------

VID  Type    Ports                                                          
--------------------------------------------------------------------------------
1    common  UT:GE0/0/1(D)      GE0/0/2(D)      GE0/0/3(D)      GE0/0/4(D)      
                GE0/0/5(D)      GE0/0/6(D)      GE0/0/7(D)      GE0/0/8(D)      
                GE0/0/17(D)     GE0/0/18(D)     GE0/0/19(D)     GE0/0/20(D)     
                GE0/0/21(D)     GE0/0/22(D)     GE0/0/23(D)     GE0/0/24(U)     

10   common  UT:GE0/0/9(U)      GE0/0/10(D)     GE0/0/11(D)     GE0/0/12(D)     
             TG:GE0/0/24(U)                                                     

30   common  UT:GE0/0/13(U)     GE0/0/14(D)     GE0/0/15(D)     GE0/0/16(D)     

             TG:GE0/0/24(U)                                                     


VID  Status  Property      MAC-LRN Statistics Description      
--------------------------------------------------------------------------------

1    enable  default       enable  disable    VLAN 0001                         
10   enable  default       enable  disable    VLAN 0010                         
30   enable  default       enable  disable    VLAN 0030                         
[LSW2]display IP routing-table
Route Flags: R - relay, D - download to fib
------------------------------------------------------------------------------
Routing Tables: Public
         Destinations : 2        Routes : 2        

Destination/Mask    Proto   Pre  Cost      Flags NextHop         Interface

      127.0.0.0/8   Direct  0    0           D   127.0.0.1       InLoopBack0
      127.0.0.1/32  Direct  0    0           D   127.0.0.1       InLoopBack0

[LSW2]

 在PC-10-1命令窗口中输入以下命令,测试是否能与PC-10-2和PC-30-2通信


PC>ping 192.168.10.12

Ping 192.168.10.12: 32 data bytes, Press Ctrl_C to break
From 192.168.10.12: bytes=32 seq=1 ttl=128 time=78 ms
From 192.168.10.12: bytes=32 seq=2 ttl=128 time=93 ms
From 192.168.10.12: bytes=32 seq=3 ttl=128 time=125 ms
From 192.168.10.12: bytes=32 seq=4 ttl=128 time=94 ms
From 192.168.10.12: bytes=32 seq=5 ttl=128 time=110 ms

--- 192.168.10.12 ping statistics ---
  5 packet(s) transmitted
  5 packet(s) received
  0.00% packet loss
  round-trip min/avg/max = 78/100/125 ms

PC>ping 192.168.30.12

Ping 192.168.30.12: 32 data bytes, Press Ctrl_C to break
From 192.168.10.11: Destination host unreachable
From 192.168.10.11: Destination host unreachable
From 192.168.10.11: Destination host unreachable
From 192.168.10.11: Destination host unreachable
From 192.168.10.11: Destination host unreachable

--- 192.168.10.1 ping statistics ---
  5 packet(s) transmitted
  0 packet(s) received
  100.00% packet loss

 在PC-30-1命令窗口中输入以下命令,测试是否能与PC-30-2和PC-10-2通信


PC>ping 192.168.30.12

Ping 192.168.30.12: 32 data bytes, Press Ctrl_C to break
From 192.168.30.12: bytes=32 seq=1 ttl=128 time=47 ms
From 192.168.30.12: bytes=32 seq=2 ttl=128 time=78 ms
From 192.168.30.12: bytes=32 seq=3 ttl=128 time=78 ms
From 192.168.30.12: bytes=32 seq=4 ttl=128 time=62 ms
From 192.168.30.12: bytes=32 seq=5 ttl=128 time=109 ms

--- 192.168.30.12 ping statistics ---
  5 packet(s) transmitted
  5 packet(s) received
  0.00% packet loss
  round-trip min/avg/max = 47/74/109 ms

PC>ping 192.168.10.12

Ping 192.168.10.12: 32 data bytes, Press Ctrl_C to break
From 192.168.30.11: Destination host unreachable
From 192.168.30.11: Destination host unreachable
From 192.168.30.11: Destination host unreachable
From 192.168.30.11: Destination host unreachable
From 192.168.30.11: Destination host unreachable

--- 192.168.30.1 ping statistics ---
  5 packet(s) transmitted
  0 packet(s) received
  100.00% packet loss

可以看到,在同一vlan的PC可以互相ping通,不在同一PC不能ping通 

在交换机LSW1或在LSW2上配置VLANIF都可以,这里选择LSW1

#配置到vlan 10的vlanif接口的ip地址
[LSW1]interface vlanif 10
[LSW1-Vlanif10]ip address 192.168.10.1 24
[LSW1-Vlanif10]qu
#配置到vlan 30的vlanif接口的ip地址
[LSW1]interface vlanif 30
[LSW1-Vlanif30]ip address 192.168.30.1 24
[LSW1-Vlanif30]qu
#查看所有端口的状态
[LSW1]display interface brief
PHY: Physical
*down: administratively down
(l): loopback
(s): spoofing
(b): BFD down
(e): ETHOAM down
(dl): DLDP down
(d): Dampening Suppressed
InUti/OutUti: input utility/output utility
Interface                   PHY   Protocol InUti OutUti   inErrors  outErrors
GigabitEthernet0/0/1        down  down        0%     0%          0          0
GigabitEthernet0/0/2        down  down        0%     0%          0          0
GigabitEthernet0/0/3        down  down        0%     0%          0          0
GigabitEthernet0/0/4        down  down        0%     0%          0          0
GigabitEthernet0/0/5        down  down        0%     0%          0          0
GigabitEthernet0/0/6        down  down        0%     0%          0          0
GigabitEthernet0/0/7        down  down        0%     0%          0          0
GigabitEthernet0/0/8        down  down        0%     0%          0          0
GigabitEthernet0/0/9        up    up          0%     0%          0          0
GigabitEthernet0/0/10       down  down        0%     0%          0          0
GigabitEthernet0/0/11       down  down        0%     0%          0          0
GigabitEthernet0/0/12       down  down        0%     0%          0          0
GigabitEthernet0/0/13       up    up          0%     0%          0          0
GigabitEthernet0/0/14       down  down        0%     0%          0          0
GigabitEthernet0/0/15       down  down        0%     0%          0          0
GigabitEthernet0/0/16       down  down        0%     0%          0          0
GigabitEthernet0/0/17       down  down        0%     0%          0          0
GigabitEthernet0/0/18       down  down        0%     0%          0          0
GigabitEthernet0/0/19       down  down        0%     0%          0          0
GigabitEthernet0/0/20       down  down        0%     0%          0          0
GigabitEthernet0/0/21       down  down        0%     0%          0          0
GigabitEthernet0/0/22       down  down        0%     0%          0          0
GigabitEthernet0/0/23       down  down        0%     0%          0          0
GigabitEthernet0/0/24       up    up          0%     0%          0          0

#查看所有端口的ip信息  
[LSW1]display ip interface brief
*down: administratively down
^down: standby
(l): loopback
(s): spoofing
The number of interface that is UP in Physical is 4
The number of interface that is DOWN in Physical is 1
The number of interface that is UP in Protocol is 3
The number of interface that is DOWN in Protocol is 2

Interface                         IP Address/Mask      Physical   Protocol  
MEth0/0/1                         unassigned           down       down      
NULL0                             unassigned           up         up(s)     
Vlanif1                           unassigned           up         down      
Vlanif10                          192.168.10.1/24      up         up        
Vlanif30                          192.168.30.1/24      up         up 

#查看vlanif接口ip配置
[LSW1]display IP interface vlanif 10
Vlanif10 current state : UP 
Line protocol current state : UP
The Maximum Transmit Unit : 1500 bytes
input packets : 0, bytes : 0, multicasts : 0
output packets : 0, bytes : 0, multicasts : 0
Directed-broadcast packets:
 received packets:            0, sent packets:            0 
 forwarded packets:           0, dropped packets:           0 
Internet Address is 192.168.10.1/24 
Broadcast address : 192.168.10.255
TTL being 1 packet number:         0
TTL invalid packet number:         0
ICMP packet input number:          0
  Echo reply:                      0
  Unreachable:                     0
  Source quench:                   0
  Routing redirect:                0
  Echo request:                    0
  Router advert:                   0
  Router solicit:                  0
  Time exceed:                     0
  IP header bad:                   0
  Timestamp request:               0
  Timestamp reply:                 0


[LSW1]display IP interface vlanif 30
Vlanif30 current state : UP 
Line protocol current state : UP
The Maximum Transmit Unit : 1500 bytes
input packets : 0, bytes : 0, multicasts : 0
output packets : 0, bytes : 0, multicasts : 0
Directed-broadcast packets:
 received packets:            0, sent packets:            0 
 forwarded packets:           0, dropped packets:           0 
Internet Address is 192.168.30.1/24 
Broadcast address : 192.168.30.255
TTL being 1 packet number:         0
TTL invalid packet number:         0
ICMP packet input number:          0
  Echo reply:                      0
  Unreachable:                     0
  Source quench:                   0
  Routing redirect:                0
  Echo request:                    0
  Router advert:                   0
  Router solicit:                  0
  Time exceed:                     0
  IP header bad:                   0
  Timestamp request:               0
  Timestamp reply:                 0

#查看交换机ip路由表
[LSW1]display IP routing-table
Route Flags: R - relay, D - download to fib
------------------------------------------------------------------------------
Routing Tables: Public
         Destinations : 6        Routes : 6        

Destination/Mask    Proto   Pre  Cost      Flags NextHop         Interface

      127.0.0.0/8   Direct  0    0           D   127.0.0.1       InLoopBack0
      127.0.0.1/32  Direct  0    0           D   127.0.0.1       InLoopBack0
   192.168.10.0/24  Direct  0    0           D   192.168.10.1    Vlanif10
   192.168.10.1/32  Direct  0    0           D   127.0.0.1       Vlanif10
   192.168.30.0/24  Direct  0    0           D   192.168.30.1    Vlanif30
   192.168.30.1/32  Direct  0    0           D   127.0.0.1       Vlanif30

[LSW1]
用ping验证不同vlan之间实现相互通信

此时,在PC-10-1命令窗口中输入以下命令,测试是否能与PC-10-2和PC-30-2通信

通过tracert 192.168.30.12可以看出

192.168.10.11---->192.168.10.1---->192.168.30.12

PC>ping 192.168.10.12

Ping 192.168.10.12: 32 data bytes, Press Ctrl_C to break
From 192.168.10.12: bytes=32 seq=1 ttl=128 time=78 ms
From 192.168.10.12: bytes=32 seq=2 ttl=128 time=94 ms
From 192.168.10.12: bytes=32 seq=3 ttl=128 time=78 ms
From 192.168.10.12: bytes=32 seq=4 ttl=128 time=62 ms
From 192.168.10.12: bytes=32 seq=5 ttl=128 time=62 ms

--- 192.168.10.12 ping statistics ---
  5 packet(s) transmitted
  5 packet(s) received
  0.00% packet loss
  round-trip min/avg/max = 62/74/94 ms

PC>ping 192.168.30.12

Ping 192.168.30.12: 32 data bytes, Press Ctrl_C to break
From 192.168.30.12: bytes=32 seq=1 ttl=127 time=125 ms
From 192.168.30.12: bytes=32 seq=2 ttl=127 time=63 ms
From 192.168.30.12: bytes=32 seq=3 ttl=127 time=62 ms
From 192.168.30.12: bytes=32 seq=4 ttl=127 time=62 ms
From 192.168.30.12: bytes=32 seq=5 ttl=127 time=94 ms

--- 192.168.30.12 ping statistics ---
  5 packet(s) transmitted
  5 packet(s) received
  0.00% packet loss
  round-trip min/avg/max = 62/81/125 ms

PC>tracert 192.168.30.12

traceroute to 192.168.30.12, 8 hops max
(ICMP), press Ctrl+C to stop
 1  192.168.10.1   31 ms  32 ms  31 ms
 2  192.168.30.12   94 ms  78 ms  94 ms

在PC-30-1命令窗口中输入以下命令,测试是否能与PC-10-2和PC-30-2通信

通过tracert 192.168.10.12可以看出

192.168.30.11---->192.168.30.1---->192.168.10.12

PC>ping 192.168.30.12

Ping 192.168.30.12: 32 data bytes, Press Ctrl_C to break
From 192.168.30.12: bytes=32 seq=1 ttl=128 time=63 ms
From 192.168.30.12: bytes=32 seq=2 ttl=128 time=63 ms
From 192.168.30.12: bytes=32 seq=3 ttl=128 time=79 ms
From 192.168.30.12: bytes=32 seq=4 ttl=128 time=62 ms
From 192.168.30.12: bytes=32 seq=5 ttl=128 time=93 ms

--- 192.168.30.12 ping statistics ---
  5 packet(s) transmitted
  5 packet(s) received
  0.00% packet loss
  round-trip min/avg/max = 62/72/93 ms

PC>ping 192.168.10.12

Ping 192.168.10.12: 32 data bytes, Press Ctrl_C to break
From 192.168.10.12: bytes=32 seq=1 ttl=127 time=125 ms
From 192.168.10.12: bytes=32 seq=2 ttl=127 time=94 ms
From 192.168.10.12: bytes=32 seq=3 ttl=127 time=78 ms
From 192.168.10.12: bytes=32 seq=4 ttl=127 time=93 ms
From 192.168.10.12: bytes=32 seq=5 ttl=127 time=78 ms

--- 192.168.10.12 ping statistics ---
  5 packet(s) transmitted
  5 packet(s) received
  0.00% packet loss
  round-trip min/avg/max = 78/93/125 ms

PC>tracert 192.168.10.12

traceroute to 192.168.10.12, 8 hops max
(ICMP), press Ctrl+C to stop
 1  192.168.30.1   32 ms  15 ms  31 ms
 2  192.168.10.12   79 ms  78 ms  78 ms

佬们可以到移步到下篇看看:单臂路由的配置

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

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

相关文章

【操作系统笔记】缓存一致性

CPU 核心之间数据如何传播 高速缓存中的值被修改了&#xff0c;那么怎么同步到内存中呢&#xff1f; ① 写直达&#xff08;Write-Through&#xff09;② 写回&#xff08;Write-Back&#xff09; 写直达&#xff08;Write-Through&#xff09; 简单&#xff0c;但是很慢&am…

《Kubernetes部署篇:Ubuntu20.04基于containerd二进制部署K8S 1.25.14集群(多主多从)》

一、架构图 如下图所示&#xff1a; 二、部署说明 2.1、部署流程 1、系统环境初始化&#xff0c;主要包括 主机名设置、主机hosts解析、关闭防火墙、关闭swap分区、修改系统参数、时间时区同步、修改内核参数、启用ipvs模式。 2、使用一键生成K8S集群证书工具创建证书文件。…

vue页面嵌入飞书网页组件,用于在类似ERP,OA等系统中展示在线文档

先展示最终效果(就是在vue页面中,内嵌了一块ifream页面): 1. 注册进入飞书开放平台,地址为: 飞书开放平台 2.进入开放平台后,选择--创建企业自建应用--创建网页应用,然后在主页面记住该应用的appId和appSecret参数,后面要用 3.然后注意一点的是,因为后面的授权等逻辑我们一般…

Android设计支持库

本文所有的代码均存于 https://github.com/MADMAX110/BitsandPizzas 设计支持库&#xff08;Design Support Library&#xff09;是 Google 在 2015 年的 I/O 大会上发布的全新 Material Design 支持库&#xff0c;在这个 support 库里面主要包含了 8 个新的 Material Design …

clickhouse简单安装部署

目录 前言(来源于官方文档)&#xff1a; 一.下载并上传 1.下载地址&#xff1a;点我跳转下载 2.上传至Linux 二.解压和配置 1.解压顺序 注意&#xff1a;必须按照以下顺序解压&#xff0c;并且每解压一个都要执行该解压后文件的install/doinst.sh文件 解压步骤&#xff…

antd-design-vue Table组件全局配置(分页器...)

描述&#xff1a;该框架许多默认配置好像还不支持&#xff0c;一般都是挨个使用挨个配置。我的项目中也遇到了类似的情况&#xff0c;但是当需求发生变化时&#xff0c;代码所有的组件使用则都需要修改&#xff0c;这种方式真的很不礼貌。 《我为了一口醋包了顿饺子》 需求是将…

MQ - 19 安全_限流方案的设计

文章目录 导图Pre概述集群中的数据加密加密算法分类消息队列限流机制思考单机限流全局限流全局限流还是单机限流?对哪些资源和维度进行限流发生限流后怎么处理消息队列全局限流设计单机限流方案全局限流方案消息队列的服务降级配置 Broker 的 CPU 或内存的使用率额度配置磁盘保…

C语言每日一题(5):求两个数二进制中不同位的个数

文章主题&#xff1a;求两个数二进制中不同位的个数&#x1f525;所属专栏&#xff1a;C语言每日一题&#x1f4d7;作者简介&#xff1a;每天不定时更新C语言的小白一枚&#xff0c;记录分享自己每天的所思所想&#x1f604;&#x1f3b6;个人主页&#xff1a;[₽]的个人主页&a…

BOA服务器移植

BOA服务器移植 1、源码下载 http://www.boa.org/ News! (last updated 23 February 2005) Latest Released Version (0.94.13) here (signature here) --- 下载地址1.1 boa简介&#xff1a; 其可执行代码只有大约60KB左右&#xff0c;Boa是一个单任务的HTTP服务器&#xff…

MyBatisPlus(五)配置表名前缀:table-prefix

说明 数据库中的表名&#xff0c;和项目中的实体类名&#xff0c;并不符合默认对应规则。所有表都有同样的前缀&#xff0c;而实体类名是和表名去掉前缀后的部分对应的。 解决方案 配置全局表名前缀&#xff0c;使实体类名对应的表名&#xff0c;自动加上一段前缀。 限制 …

JSON 串和 Java 对象的相互转换

JSON 串和 Java 对象的相互转换 以 json 格式的数据进行前后端交互 前端发送请求时&#xff0c;如果是复杂的数据就会以 json 提交给后端&#xff1b; 而后端如果需要响应一些复杂的数据时&#xff0c;也需要以 json 格式将数据响应回给浏览器 为达到以上目的就需要重点学习…

基于微信小程序的美术馆预约平台设计与实现(源码+lw+部署文档+讲解等)

前言 &#x1f497;博主介绍&#xff1a;✌全网粉丝10W,CSDN特邀作者、博客专家、CSDN新星计划导师、全栈领域优质创作者&#xff0c;博客之星、掘金/华为云/阿里云/InfoQ等平台优质作者、专注于Java、小程序技术领域和毕业项目实战✌&#x1f497; &#x1f447;&#x1f3fb;…

Linux_9_网络协议和管理

目录 1网络基础1.1 网络概念1.2常见的网络物理组件1.3网络应用程序1.3.1各种网络应用1.3.2应用程序对网络的要求 1.4网络的特征1.4.1速度(带宽)1.4.2网络拓扑 1.5网络1.5.1网络准和分层1.5.2开放系统互联OSI1.5.3网络的通信过程1.5.3.1数据封装和数据解封1.5.3.2协议数据单元PD…

基于SSM的四六级报名与成绩查询系统的设计与实现

末尾获取源码 开发语言&#xff1a;Java Java开发工具&#xff1a;JDK1.8 后端框架&#xff1a;SSM 前端&#xff1a;采用JSP技术开发 数据库&#xff1a;MySQL5.7和Navicat管理工具结合 服务器&#xff1a;Tomcat8.5 开发软件&#xff1a;IDEA / Eclipse 是否Maven项目&#x…

机器学习 day36(纯度)

熵 这些例子的纯度和熵如图所示&#xff0c;且左侧为熵函数图熵函数是判断某组数据是否纯度高的指标 熵函数公式如上图&#xff0c;底数为2仅为了使函数峰值为1&#xff0c;且设定0log(0)为0&#xff0c;但log(0)为无穷大

【Java 基础篇】Java实现文件搜索详解

文件搜索是计算机应用中的一个常见任务&#xff0c;它允许用户查找特定文件或目录&#xff0c;以便更轻松地管理文件系统中的内容。在Java中&#xff0c;您可以使用各种方法来实现文件搜索。本文将详细介绍如何使用Java编写文件搜索功能&#xff0c;以及一些相关的内容。 文件…

【数据结构】图的应用:最小生成树;最短路径;有向无环图描述表达式;拓扑排序;逆拓扑排序;关键路径

目录 1、最小生成树 1.1 概念 1.2 普利姆算法&#xff08;Prim&#xff09; 1.3 克鲁斯卡尔算法&#xff08;Kruskal&#xff09; 2、最短路径 2.1 迪杰斯特拉算法&#xff08;Dijkstra&#xff09; 2.2 弗洛伊德算法&#xff08;Floyd&#xff09; 2.3 BFS算法&…

windows主机和vmware ubuntu18.04虚拟机ping通

windows主机 网线连接电脑&#xff0c;读取当前windows的相关信息 powershell 更改IP地址指令 New-NetIPAddress -InterfaceIndex 23 -IPAddress 192.168.0.105 -PrefixLength 24 -DefaultGateway 192.168.0.1 虚拟机 虚拟机需要管理员权限打开 选择桥接方式 IPV4地址改成同…

求生之路2专用服务器搭建对抗模式,药抗模式,特殊模式Ubuntu系统另附上游戏代码以及控制台代码

求生之路2专用服务器搭建对抗模式,药抗模式,特殊模式Ubuntu系统另附上游戏代码以及控制台代码 大家好我是艾西&#xff0c;熟悉Left 4 Dead 2求生之路2这游戏的小伙伴都知道这个游戏分为以下几种模式&#xff1a; 对抗模式&#xff1a;在对抗模式下&#xff0c;玩家需要掌握一…

小白的入门二叉树(C语言实现)

前言&#xff1a; 二叉树属于数据结构的一个重要组成部分&#xff0c;很多小白可能被其复杂的外表所吓退&#xff0c;但我要告诉你的是“世上无难事&#xff0c;只怕有心人”&#xff0c;我将认真的对待这篇博客&#xff0c;我相信只要大家敢于思考&#xff0c;肯定会有所收获…