CN114500573B - Storage volume mounting method, device, equipment and storage medium - Google Patents

Storage volume mounting method, device, equipment and storage medium Download PDF

Info

Publication number
CN114500573B
CN114500573B CN202111598345.8A CN202111598345A CN114500573B CN 114500573 B CN114500573 B CN 114500573B CN 202111598345 A CN202111598345 A CN 202111598345A CN 114500573 B CN114500573 B CN 114500573B
Authority
CN
China
Prior art keywords
storage
container
mounting
target
address
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202111598345.8A
Other languages
Chinese (zh)
Other versions
CN114500573A (en
Inventor
朱廷祥
李光辉
余斌
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Tianyi Cloud Technology Co Ltd
Original Assignee
Tianyi Cloud Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Tianyi Cloud Technology Co Ltd filed Critical Tianyi Cloud Technology Co Ltd
Priority to CN202111598345.8A priority Critical patent/CN114500573B/en
Publication of CN114500573A publication Critical patent/CN114500573A/en
Application granted granted Critical
Publication of CN114500573B publication Critical patent/CN114500573B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/10Protocols in which an application is distributed across nodes in the network
    • H04L67/1097Protocols in which an application is distributed across nodes in the network for distributed storage of data in networks, e.g. transport arrangements for network file system [NFS], storage area networks [SAN] or network attached storage [NAS]
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L63/00Network architectures or network communication protocols for network security
    • H04L63/08Network architectures or network communication protocols for network security for authentication of entities
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/10Protocols in which an application is distributed across nodes in the network

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Computer Hardware Design (AREA)
  • Computer Security & Cryptography (AREA)
  • Computing Systems (AREA)
  • General Engineering & Computer Science (AREA)
  • Data Exchanges In Wide-Area Networks (AREA)

Abstract

The invention discloses a storage volume mounting method, a device, equipment and a storage medium, wherein the method comprises the following steps: receiving a request message of a mounting storage volume sent by a target container; modifying the destination address of the mounting storage volume request message according to the storage service address to obtain a modified mounting storage volume request message, and transmitting the modified mounting storage volume request message to a target storage node; receiving a response message of the mounting storage volume returned by the target storage node, wherein the mounting authentication response message is used for indicating whether the request of the mounting storage volume is passed; and modifying the destination address of the mounting storage volume response message according to the container interconnection address to obtain a modified mounting storage volume response message, and transmitting the modified mounting storage volume response message to the target container. Therefore, the invention realizes that the storage volume is directly mounted on the container under the scene that the tenant network and the underlying distributed storage network cannot be communicated, and improves the reliability and safety of the mounting of the storage volume.

Description

Storage volume mounting method, device, equipment and storage medium
Technical Field
The present invention relates to the field of information technologies, and in particular, to a storage volume mounting method, device, equipment, and storage medium.
Background
In a cloud computing scenario, a distributed storage is often adopted to provide storage resources, and a typical network architecture of the distributed storage comprises a management network, a storage service network and a storage back-end network, wherein the storage service network provides storage service capability outwards, and a host machine of the cloud resources mounts storage volumes through the storage network to bear virtual machine resources. The container cloud is carried on an Infrastructure as a service (IaaS) cloud resource basis.
The container is further packaged on the basis of virtualization, and the creation and maintenance of the container are greatly simplified from file system, network interconnection to process isolation and the like. Making application container engine (Docker) technology more lightweight and faster than virtual machine technology.
In an actual network architecture, a container (i.e., a Virtual Machine (VM)) and a Virtual Machine (VM)) are in the same network plane, belonging to a tenant service network. As shown in fig. 1, the service network (i.e. Overlay network) and the storage service network are two separate network planes, and for service security design, the container network cannot be in network interworking with the storage service network, and the container cannot directly mount storage volumes provided by distributed storage as a persistence scheme of data.
Disclosure of Invention
In view of this, the embodiments of the present invention provide a storage volume mounting method, apparatus, device, and storage medium, so as to solve the problem that a container cannot directly mount a storage volume provided by distributed storage as a persistence scheme of data.
According to a first aspect, an embodiment of the present invention provides a storage volume mounting method, where the method is used on a first device that performs storage volume mounting, where the first device is configured with a container storage gateway, where the container storage gateway includes a container interconnection address and a storage service address, where the container interconnection address is used for information interaction between the container storage gateway and a target container in a tenant network, and the storage service address is used for information interaction between the container storage gateway and a target storage node in a distributed storage network;
The method comprises the following steps:
receiving a request message of mounting storage volume sent by the target container;
Modifying the destination address of the mounting storage volume request message according to the storage service address to obtain a modified mounting storage volume request message, and sending the modified mounting storage volume request message to the target storage node;
Receiving a mount storage volume response message returned by the target storage node, wherein the mount authentication response message is used for indicating whether a request of the mount storage volume is passed;
And modifying the destination address of the mount storage volume response message according to the container interconnection address to obtain a modified mount storage volume response message, and sending the modified mount storage volume response message to the target container.
With reference to the first aspect, in a first implementation manner of the first aspect, the first device is a virtual machine or a physical machine.
With reference to the first aspect, in a second implementation manner of the first aspect, a core switch is included between the container storage gateway and the target container;
The container interconnection address is specifically used for information interaction between the container storage gateway and the target container through the core switch;
The information interaction between the container storage gateway and the target container is container service network traffic, and the container service network traffic is terminated at the container storage gateway;
The container interconnection address is configured when the target container mounts a disk.
With reference to the first aspect, in a third implementation manner of the first aspect, for the tenant network, the storage service address is invisible;
And the information interaction between the container storage gateway and each storage node in the distributed storage network is distributed storage flow.
With reference to the first aspect, in a fourth implementation manner of the first aspect, the number of container storage gateways is two, and the two container storage gateways form a dual HA cluster.
With reference to the first aspect, the second implementation manner of the first aspect, the third implementation manner of the first aspect, or the fourth implementation manner of the first aspect, in a fifth implementation manner of the first aspect, before the receiving the mount storage volume request packet sent by the target container, the method further includes:
receiving a mounting authentication request message sent by the target container;
modifying the destination address of the mounting authentication request message according to the storage service address to obtain a modified mounting authentication request message, and sending the modified mounting authentication request message to the target storage node;
Receiving a mount authentication response message returned by the target storage node, wherein the mount authentication response message is used for indicating whether a mount authentication request is passed or not;
And modifying the destination address of the mounting authentication response message according to the container interconnection address to obtain a modified mounting authentication response message, and sending the modified mounting authentication response message to the target container.
With reference to the first aspect, the second implementation manner of the first aspect, the third implementation manner of the first aspect, or the fourth implementation manner of the first aspect, in a sixth implementation manner of the first aspect, the configuration container storage gateway includes:
After the modified mount storage volume response message is sent to the target container, the method further includes:
receiving a storage data request message sent by the target container;
Modifying the destination address of the storage data request message according to the storage service address to obtain a modified storage data request message, and sending the modified storage data request message to the target storage node;
receiving a storage data response message returned by the target storage node, wherein the storage data response message is used for indicating whether a storage data request is passed;
And modifying the destination address of the storage data response message according to the container interconnection address to obtain a modified storage data response message, and sending the modified storage data response message to the target container.
According to a second aspect, an embodiment of the present invention provides a storage volume mounting apparatus, where the apparatus is configured to perform storage volume mounting on a first device, where the first device is configured with a container storage gateway, where the container storage gateway includes a container interconnection address and a storage service address, where the container interconnection address is used for information interaction between the container storage gateway and a target container in a tenant network, and where the storage service address is used for information interaction between the container storage gateway and a target storage node in a distributed storage network;
the device comprises:
the first receiving module is used for receiving a request message of the mounted storage volume sent by the target container;
the first sending module is used for modifying the destination address of the mounting storage volume request message according to the storage service address to obtain a modified mounting storage volume request message, and sending the modified mounting storage volume request message to the target storage node;
The second receiving module is used for receiving a mount storage volume response message returned by the target storage node, wherein the mount authentication response message is used for indicating whether a request of the mount storage volume is passed;
and the second sending module is used for modifying the destination address of the mounting storage volume response message according to the container interconnection address to obtain a modified mounting storage volume response message, and sending the modified mounting storage volume response message to the target container.
With reference to the second aspect, in a first implementation manner of the second aspect, the first device is a virtual machine or a physical machine.
With reference to the second aspect, in a second implementation manner of the second aspect, a core switch is included between the container storage gateway and the target container;
The container interconnection address is specifically used for information interaction between the container storage gateway and the target container through the core switch;
The information interaction between the container storage gateway and the target container is container service network traffic, and the container service network traffic is terminated at the container storage gateway;
The container interconnection address is configured when the target container mounts a disk.
With reference to the second aspect, in a third implementation manner of the second aspect, for the tenant network, the storage service address is in an invisible state;
The information interaction between the container storage gateway and the target storage node is distributed storage flow.
With reference to the second aspect, in a fourth implementation manner of the second aspect, the number of container storage gateways is two, and the two container storage gateways form a dual HA cluster.
With reference to the second aspect or the second implementation manner of the second aspect or the third implementation manner of the second aspect or the fourth implementation manner of the second aspect, in a fifth implementation manner of the second aspect, the storage volume mounting device may further include:
the third receiving module is used for receiving the mounting authentication request message sent by the target container;
the third sending module is used for modifying the destination address of the mounting authentication request message by the storage service address to obtain a modified mounting authentication request message, and sending the modified mounting authentication request message to the target storage node;
the fourth receiving module is used for receiving a mount authentication response message returned by the target storage node, wherein the mount authentication response message is used for indicating whether the mount authentication request is passed or not;
And the fourth sending module is used for modifying the destination address of the mounting authentication response message according to the container interconnection address to obtain a modified mounting authentication response message, and sending the modified mounting authentication response message to the target container.
With reference to the second aspect or the second implementation manner of the second aspect or the third implementation manner of the second aspect or the fourth implementation manner of the second aspect, in a sixth implementation manner of the second aspect, the storage volume mounting device may further include:
a fifth receiving module, configured to receive a storage data request packet sent by the target container;
a fifth sending module, configured to modify a destination address of the storage data request packet according to the storage service address, obtain a modified storage data request packet, and send the modified storage data request packet to the target storage node;
The sixth receiving module is used for receiving a storage data response message returned by the target storage node, wherein the storage data response message is used for indicating whether a storage data request is passed or not;
And a sixth sending module, configured to modify the destination address of the storage data response message according to the container interconnection address, obtain a modified storage data response message, and send the modified storage data response message to the target container.
According to a third aspect, an embodiment of the present invention provides an electronic device, including: the storage volume mounting method comprises a memory and a processor, wherein the memory and the processor are in communication connection, computer instructions are stored in the memory, and the processor executes the computer instructions, so that the storage volume mounting method in the first aspect or any implementation manner of the first aspect is executed.
According to a fourth aspect, an embodiment of the present invention provides a computer readable storage medium storing computer instructions for causing a computer to perform the storage volume mounting method according to the first aspect or any implementation manner of the first aspect.
Drawings
The features and advantages of the present invention will be more clearly understood by reference to the accompanying drawings, which are illustrative and should not be construed as limiting the invention in any way, in which:
fig. 1 shows a network architecture diagram.
Fig. 2 shows a method schematic diagram of a storage volume mounting method.
Fig. 3 shows an application scenario diagram of a storage volume mounting method.
Fig. 4 shows an information interaction diagram of a storage volume mounting method.
Fig. 5 shows a schematic structure of a storage volume mounting device.
Fig. 6 shows a schematic structural diagram of an electronic device.
Detailed Description
For the purpose of making the objects, technical solutions and advantages of the embodiments of the present invention more apparent, the technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings in the embodiments of the present invention, and it is apparent that the described embodiments are some embodiments of the present invention, but not all embodiments of the present invention. All other embodiments, which can be made by those skilled in the art based on the embodiments of the invention without making any inventive effort, are intended to fall within the scope of the invention.
FIG. 2 illustrates a method flow diagram of a storage volume mounting method that may be used on a first device performing storage volume mounting, the first device configured with a container storage gateway including a container interconnect address for information interaction between the container storage gateway and a target container in a tenant network and a storage service address for information interaction between the container storage gateway and a target storage node in a distributed storage network; wherein, optionally, the first device may be a virtual machine or a physical machine; as shown in fig. 2, the storage volume mounting method may include:
Step 201, receiving a request message of the mounted storage volume sent by the target container.
Step 202, modifying the destination address of the mount storage volume request message according to the storage service address to obtain a modified mount storage volume request message, and sending the modified mount storage volume request message to the target storage node.
Step 203, the receiving target storage node returns a mount storage volume response message, where the mount authentication response message is used to indicate whether to pass the mount storage volume request.
And 204, modifying the destination address of the mount storage volume response message according to the container interconnection address to obtain a modified mount storage volume response message, and sending the modified mount storage volume response message to the target container.
Specifically, when configuring the container storage gateway, the container storage gateway may be deployed through a virtual machine or a physical machine, and the storage service address and the container interconnection address are respectively configured. Wherein the storage service address and the container interconnect address are two internet protocol (Internet Protocol, IP) addresses of the container storage gateway.
Such as: as shown in fig. 3, two container storage gateways are deployed, where each container storage gateway may perform information interaction with each container in the tenant network through a container interconnection address, and may also perform information interaction with each storage node in the distributed storage network through a storage service address.
The Top of Rank (ToR) in fig. 3 is an architectural design of the data center, like the End of Row (EoR) and the Middle of Row (MoR). The server access switch corresponds to the core aggregation switch.
In addition, high performance may be supported through a data plane Development Kit (DATA PLANE Development Kit, DPDK) when deploying the container storage gateway through a virtual machine or physical machine. The DPDK is used for a function library and a driving set for fast data packet processing, so that the data processing performance and throughput can be greatly improved, and the working efficiency of a data plane application program can be improved. If the container storage gateway link storage requires higher performance, DPDK techniques can be used to achieve high bandwidth throughput.
Because the target container cannot directly communicate with the target storage node, the target container and the target storage node are safely isolated, and the storage volume between the target container and the target storage node can be mounted through the container storage gateway.
The container storage gateway comprises a container interconnection address and a storage service address, so that the direct mounting of the storage volume to the container in the tenant can be realized through an Nginx reverse proxy mechanism. Wherein, nginx is a high performance reverse proxy architecture with stability, rich functionality, simple configuration files and low system resource consumption characteristics. The container storage gateway is based on the Nginx technology, and after installation and deployment, the storage service cluster IP of the back-end agent can be configured for use.
The distributed storage network only communicates securely with the storage traffic address of the container storage gateway, which the tenant network cannot perceive and know. The container in the tenant network communicates with the container interconnect address of the container storage gateway. The deployment mode of the container storage gateway can be virtualized deployment or physical machine deployment, so that a general and safe direct container mounting storage technology is realized, namely, direct container mounting storage volume in a tenant is realized.
In the embodiment of the application, the container storage gateway is configured, the container storage gateway comprises a container interconnection address and a storage service address, and the storage volume between the target container and the target storage node is mounted through the container storage gateway, so that the safe mounting of the storage volume of the container is realized by adding the container storage gateway under the condition of not changing a service network and storing the existing architecture, thereby realizing the direct mounting of the storage volume of the container under the condition that a tenant network (overlay network) and a distributed storage network (namely, an underlying storage network) cannot be communicated, and improving the reliability and the safety of the mounting of the storage volume.
In an alternative embodiment, a core switch is included between the container storage gateway and the target container; the container interconnection address is specifically used for information interaction between the container storage gateway and the target container through the core switch.
Specifically, as shown in fig. 3, a service core switch is included, where the container interconnect address may be used for information interaction between the container storage gateway and the target container through the service core switch. In addition, a service connection for interfacing with the background distributed storage is configured at the container storage gateway.
In the embodiment of the application, the container storage gateway can interact information with the target container through the core switch, so that the reliability of the storage volume mounting is improved.
In an alternative embodiment, the information interaction between the container storage gateway and the target container is container traffic network traffic, which terminates at the container storage gateway; the container interconnect address is configured when the target container mounts the disk.
Specifically, the container service network traffic may refer to the service network connection traffic in fig. 3, as shown in fig. 3, where the container interconnection address is filled when the container mounts the disk, the service network connection traffic is terminated at the container storage gateway, and the back-end traffic is interacted by the container storage gateway and the storage node.
In the embodiment of the application, the container interconnection address is configured when the target container mounts the disk, and the container service network flow is terminated at the container storage gateway, so that the security of mounting the storage volume is ensured.
In an alternative embodiment, the traffic address is stored in an invisible state for the tenant network.
In particular, the storage business address may be configured by an administrator plan, invisible to the tenant.
In the embodiment of the application, the storage service address is invisible to the tenant, so that the safety of the storage volume mounting is ensured.
In an alternative embodiment, the information interaction between the container storage gateway and the storage nodes in the distributed storage network is distributed storage traffic.
Specifically, the distributed storage traffic may refer to storage network connection traffic in fig. 3, where, as shown in fig. 3, the container interconnection address is filled when the container mounts the disk, the service network connection traffic is terminated at the container storage gateway, and the storage network connection traffic is interacted by the container storage gateway and the storage node.
In the embodiment of the application, the distributed storage flow is the information interaction between the container storage gateway and each storage node in the distributed storage network, thereby ensuring the safety of the storage volume mounting.
In an alternative embodiment, before performing step 201, the following implementation procedure may be further included, but is not limited to:
(1) Receiving a mounting authentication request message sent by a target container;
(2) Modifying the destination address of the mounting authentication request message according to the storage service address to obtain a modified mounting authentication request message, and transmitting the modified mounting authentication request message to a target storage node;
(3) Receiving a mounting authentication response message returned by the target storage node, wherein the mounting authentication response message is used for indicating whether a mounting authentication request is passed or not;
(4) And modifying the destination address of the mounting authentication response message according to the container interconnection address to obtain a modified mounting authentication response message, and transmitting the modified mounting authentication response message to the target container.
In the embodiment of the application, the container storage gateway can start an authentication mechanism to ensure that the trusted container is linked with the storage, thereby improving the safety and reliability of the storage volume mounting.
In an alternative embodiment, after performing step 204, the following implementation process may be further included, but is not limited to:
(1) Receiving a storage data request message sent by a target container;
(2) Modifying the destination address of the storage data request message according to the storage service address to obtain a modified storage data request message, and transmitting the modified storage data request message to a target storage node;
(3) Receiving a storage data response message returned by the target storage node, wherein the storage data response message is used for indicating whether a storage data request is passed;
(4) And modifying the destination address of the storage data response message according to the container interconnection address to obtain a modified storage data response message, and transmitting the modified storage data response message to the target container.
In an alternative embodiment, the first device is configured with two container storage gateways that form a dual machine (Highly Available, HA) cluster.
In the embodiment of the application, two container storage gateways can be deployed and form an HA cluster to ensure high reliability of service, thereby further improving the reliability of storage volume mounting.
The implementation of the above-described storage volume mounting is described below by way of a specific example, as shown in fig. 4.
4-1, The container Client (Docker Client) sends a mount authentication request to the container storage gateway (Docker Storage gateway).
4-2, The container storage gateway (Docker Storage gateway) performs load sharing and forwards the load sharing to the back-end mount authentication request.
4-3, The management process (Storage Target) returns whether the mount request passes.
The mounting authentication request is an authentication mechanism, so that the validity of a user using storage is guaranteed, and if the mounting request does not pass, the subsequent step of mounting the storage volume is not continuously executed.
4-4, The container storage gateway (Docker Storage gateway) records the mapping relation between the access request and the back-end conversion request, and sends a first response message (i.e. a mount authentication response message) to the container Client (Docker Client).
The first reply message (src ip=gw EIP, dst ip=docker IP) is a reply message of the container storage gateway to the mount authentication request, src ip=gw EIP is a source IP address of the reply message is a container interconnection address of the gateway, and dst ip=docker IP is a container address of the request.
4-5, The container Client (Docker Client) sends a mount storage volume request to the container storage gateway (Docker Storage gateway).
4-6, According to the IP and port mapping relation, modifying the IP address and port address of the message, and sending a request message to a management process (Storage Target).
The destination address of the request of the container mount Storage volume is the address and the service port (public) of the container Storage gateway, and the nginx proxy of the Storage gateway can modify the destination address and the destination service port of the request message into the actual address and the service port (invisible to the container side) of the back-end distributed Storage Target.
4-7, The management process (Storage Target) forwards the Storage response message.
4-8, The container Client (Docker Client) queries the mapping relation table, and forwards the response, namely, sends a second response message (namely, a mount storage volume response message) to the container Client (Docker Client).
In the second reply message (src ip=gw IP, src port=gw), the source address of the reply Storage mount request message of the container Storage gateway is the container interconnection address of the gateway, and the source port is a service port that is externally disclosed by the gateway, instead of the address and service port of the distributed Storage Target (which are invisible to the container side).
4-9, A container Client (Docker Client) stores data with a data storage process (object storage daemon, OSD) through a container storage gateway (Docker Storage gateway).
It should be noted that, OSD in fig. 4 is a data service of Ceph distributed storage, and is responsible for the processes of landing of service data, monitoring of data state, recovering of data state, migration and recovery of data, and the like. And the monitoring device is responsible for reading and writing data of the Ceph cluster and reporting the monitored OSD state to the Monitor. In the invention, the method is responsible for responding to the data request of the storage gateway and returning the storage data.
Both the OSD and the management process (Storage Target) of fig. 4 run on the Storage node of fig. 3, namely: the Storage nodes in fig. 3 are multiple servers stored in a distributed manner, and a management process (Storage Target) and a data Storage process (OSD) are simultaneously located on the distributed Storage nodes.
As can be seen from the above embodiments, the technical effects that can be achieved by the present invention may include:
(1) The safety of container mounting and storage is improved: through the container storage gateway scheme, the distributed storage device only communicates with the storage service address of the container storage gateway, the container service network cannot perceive and know the address, and the container interconnection address of the gateway communicate. The container gateway only opens a specific port (configurable) for container linking, further enhancing security. The container gateway may open an authentication mechanism to ensure that trusted containers are storage linked.
(2) High performance and high reliability: the container gateway supports DPDK capability to improve memory mounting performance and HA architecture to improve reliability.
(3) The HA technology is used for guaranteeing high reliability.
(4) The authentication technology is used for guaranteeing the safety.
Fig. 5 shows a schematic structure of a storage volume mounting device. The storage volume mounting apparatus may be used on a first device executing storage volume mounting, the first device being configured with a container storage gateway, the container storage gateway including a container interconnection address and a storage service address, the container interconnection address being used for information interaction between the container storage gateway and a target container in a tenant network, and the storage service address being used for information interaction between the container storage gateway and a target storage node in a distributed storage network. As shown in fig. 5, the storage volume mounting apparatus may include:
A first receiving module 51, configured to receive a mount storage volume request packet sent by the target container;
A first sending module 52, configured to modify a destination address of the mount storage volume request packet according to the storage service address, obtain a modified mount storage volume request packet, and send the modified mount storage volume request packet to the target storage node;
a second receiving module 53, configured to receive a mount storage volume reply packet returned by the target storage node, where the mount authentication reply packet is used to indicate whether to pass a mount storage volume request;
And the second sending module 54 is configured to modify the destination address of the mount storage volume reply message according to the container interconnection address, obtain a modified mount storage volume reply message, and send the modified mount storage volume reply message to the target container.
In one possible implementation, the first device is a virtual machine or a physical machine.
In one possible implementation, a core switch is included between the container storage gateway and the target container;
The container interconnection address is specifically used for information interaction between the container storage gateway and the target container through the core switch;
The information interaction between the container storage gateway and the target container is container service network traffic, and the container service network traffic is terminated at the container storage gateway;
The container interconnection address is configured when the target container mounts a disk.
In one possible implementation, the stored service address is in an invisible state for the tenant network;
The information interaction between the container storage gateway and the target storage node is distributed storage flow.
In one possible implementation, the number of container storage gateways is two, and the two container storage gateways form a dual HA cluster.
In one possible implementation manner, the storage volume mounting device may further include:
the third receiving module is used for receiving the mounting authentication request message sent by the target container;
the third sending module is used for modifying the destination address of the mounting authentication request message by the storage service address to obtain a modified mounting authentication request message, and sending the modified mounting authentication request message to the target storage node;
the fourth receiving module is used for receiving a mount authentication response message returned by the target storage node, wherein the mount authentication response message is used for indicating whether the mount authentication request is passed or not;
And the fourth sending module is used for modifying the destination address of the mounting authentication response message according to the container interconnection address to obtain a modified mounting authentication response message, and sending the modified mounting authentication response message to the target container.
In one possible implementation manner, the storage volume mounting device may further include:
a fifth receiving module, configured to receive a storage data request packet sent by the target container;
a fifth sending module, configured to modify a destination address of the storage data request packet according to the storage service address, obtain a modified storage data request packet, and send the modified storage data request packet to the target storage node;
The sixth receiving module is used for receiving a storage data response message returned by the target storage node, wherein the storage data response message is used for indicating whether a storage data request is passed or not;
And a sixth sending module, configured to modify the destination address of the storage data response message according to the container interconnection address, obtain a modified storage data response message, and send the modified storage data response message to the target container.
It should be noted that, the storage volume mounting device provided by the embodiment of the present application can implement all the method steps implemented by the method embodiment and achieve the same technical effects, and the same parts and beneficial effects as those of the method embodiment in the embodiment are not described in detail herein.
Fig. 6 shows a schematic structural diagram of an electronic device. As shown in fig. 6, the electronic device may include: processor 610, communication interface (Communications Interface) 620, memory 630, and communication bus 640, wherein processor 610, communication interface 620, memory 630 communicate with each other via communication bus 640. The processor 610 may invoke logic instructions in the memory 630 to perform a storage volume mounting method, the electronic device configured with a container storage gateway including a container interconnect address for information interaction between the container storage gateway and a target container in a tenant network and a storage business address for information interaction between the container storage gateway and a target storage node in a distributed storage network; the method comprises the following steps:
receiving a request message of mounting storage volume sent by the target container;
Modifying the destination address of the mounting storage volume request message according to the storage service address to obtain a modified mounting storage volume request message, and sending the modified mounting storage volume request message to the target storage node;
Receiving a mount storage volume response message returned by the target storage node, wherein the mount authentication response message is used for indicating whether a request of the mount storage volume is passed;
And modifying the destination address of the mount storage volume response message according to the container interconnection address to obtain a modified mount storage volume response message, and sending the modified mount storage volume response message to the target container.
Further, the logic instructions in the memory 630 may be implemented in the form of software functional units and stored in a computer-readable storage medium when sold or used as a stand-alone product. Based on this understanding, the technical solution of the present invention may be embodied essentially or in a part contributing to the prior art or in a part of the technical solution in the form of a software product stored in a storage medium, comprising several instructions for causing a computer device (which may be a personal computer, a server, a network device, etc.) to perform all or part of the steps of the method of the embodiments of the present invention. And the aforementioned storage medium includes: a usb disk, a removable hard disk, a Read-Only Memory (ROM), a random access Memory (RAM, random Access Memory), a magnetic disk, or an optical disk, or other various media capable of storing program codes.
In another aspect, the present invention also provides a computer program product comprising a computer program stored on a non-transitory computer readable storage medium, the computer program comprising program instructions which, when executed by a computer, are capable of performing a storage volume mounting method provided by the above methods, the method comprising:
receiving a request message of mounting storage volume sent by the target container;
Modifying the destination address of the mounting storage volume request message according to the storage service address to obtain a modified mounting storage volume request message, and sending the modified mounting storage volume request message to the target storage node;
Receiving a mount storage volume response message returned by the target storage node, wherein the mount authentication response message is used for indicating whether a request of the mount storage volume is passed;
And modifying the destination address of the mount storage volume response message according to the container interconnection address to obtain a modified mount storage volume response message, and sending the modified mount storage volume response message to the target container.
In yet another aspect, the present invention also provides a non-transitory computer readable storage medium having stored thereon a computer program which, when executed by a processor, is implemented to perform the storage volume mounting methods provided above, the method comprising:
receiving a request message of mounting storage volume sent by the target container;
Modifying the destination address of the mounting storage volume request message according to the storage service address to obtain a modified mounting storage volume request message, and sending the modified mounting storage volume request message to the target storage node;
Receiving a mount storage volume response message returned by the target storage node, wherein the mount authentication response message is used for indicating whether a request of the mount storage volume is passed;
And modifying the destination address of the mount storage volume response message according to the container interconnection address to obtain a modified mount storage volume response message, and sending the modified mount storage volume response message to the target container.
The apparatus embodiments described above are merely illustrative, wherein elements illustrated as separate elements may or may not be physically separate, and elements shown as elements may or may not be physical elements, may be located in one place, or may be distributed over a plurality of network elements. Some or all of the modules may be selected according to actual needs to achieve the purpose of the solution of this embodiment. Those of ordinary skill in the art will understand and implement the present invention without undue burden.
From the above description of the embodiments, it will be apparent to those skilled in the art that the embodiments may be implemented by means of software plus necessary general hardware platforms, or of course may be implemented by means of hardware. Based on such understanding, the foregoing technical solutions may be embodied essentially or in part in the form of a software product, which may be stored in a computer-readable storage medium, such as a ROM/RAM, a magnetic disk, an optical disk, etc., including several instructions to cause a computer device (which may be a personal computer, a server, or a network device, etc.) to perform the various embodiments or methods of some parts of the embodiments.
Finally, it should be noted that: the above embodiments are only for illustrating the technical solution of the present invention, and are not limiting; although the invention has been described in detail with reference to the foregoing embodiments, it will be understood by those of ordinary skill in the art that: the technical scheme described in the foregoing embodiments can be modified or some technical features thereof can be replaced by equivalents; such modifications and substitutions do not depart from the spirit and scope of the technical solutions of the embodiments of the present invention.

Claims (9)

1. A storage volume mounting method, characterized in that the method is used for executing a first device for mounting a storage volume, the first device is configured with a container storage gateway, the container storage gateway comprises a container interconnection address and a storage service address, the container interconnection address is used for information interaction between the container storage gateway and a target container in a tenant network, and the storage service address is used for information interaction between the container storage gateway and a target storage node in a distributed storage network;
The method comprises the following steps:
receiving a request message of mounting storage volume sent by the target container;
Modifying the destination address of the mounting storage volume request message according to the storage service address to obtain a modified mounting storage volume request message, and sending the modified mounting storage volume request message to the target storage node;
receiving a mount storage volume response message returned by the target storage node, wherein the mount storage volume response message is used for indicating whether a request of mounting a storage volume is passed;
Modifying the destination address of the mount storage volume response message according to the container interconnection address to obtain a modified mount storage volume response message, and sending the modified mount storage volume response message to the target container;
wherein a core switch is included between the container storage gateway and the target container;
The container interconnection address is specifically used for information interaction between the container storage gateway and the target container through the core switch;
The information interaction between the container storage gateway and the target container is container service network traffic, and the container service network traffic is terminated at the container storage gateway;
The container interconnection address is configured when the target container mounts a disk.
2. The method of claim 1, wherein the first device is a virtual machine or a physical machine.
3. The method of claim 1, wherein the stored traffic address is in an invisible state for the tenant network;
The information interaction between the container storage gateway and the target storage node is distributed storage flow.
4. The method of claim 1, wherein the number of container storage gateways is two, the two container storage gateways comprising a dual HA cluster.
5. The method according to any one of claims 1 to 4, further comprising, before receiving the mount storage volume request message sent by the target container:
receiving a mounting authentication request message sent by the target container;
modifying the destination address of the mounting authentication request message according to the storage service address to obtain a modified mounting authentication request message, and sending the modified mounting authentication request message to the target storage node;
Receiving a mount authentication response message returned by the target storage node, wherein the mount authentication response message is used for indicating whether a mount authentication request is passed or not;
And modifying the destination address of the mounting authentication response message according to the container interconnection address to obtain a modified mounting authentication response message, and sending the modified mounting authentication response message to the target container.
6. The method according to any one of claims 1 to 4, wherein after the sending the modified mount storage volume reply message to the target container, further comprising:
receiving a storage data request message sent by the target container;
Modifying the destination address of the storage data request message according to the storage service address to obtain a modified storage data request message, and sending the modified storage data request message to the target storage node;
receiving a storage data response message returned by the target storage node, wherein the storage data response message is used for indicating whether a storage data request is passed;
And modifying the destination address of the storage data response message according to the container interconnection address to obtain a modified storage data response message, and sending the modified storage data response message to the target container.
7. A storage volume mounting apparatus, wherein the apparatus is configured to execute storage volume mounting on a first device, the first device is configured with a container storage gateway, the container storage gateway includes a container interconnection address and a storage service address, the container interconnection address is used for information interaction between the container storage gateway and a target container in a tenant network, and the storage service address is used for information interaction between the container storage gateway and a target storage node in a distributed storage network;
the device comprises:
the first receiving module is used for receiving a request message of the mounted storage volume sent by the target container;
the first sending module is used for modifying the destination address of the mounting storage volume request message according to the storage service address to obtain a modified mounting storage volume request message, and sending the modified mounting storage volume request message to the target storage node;
The second receiving module is used for receiving a mounting storage volume response message returned by the target storage node, wherein the mounting storage volume response message is used for indicating whether a request of mounting storage volume is passed;
The second sending module is used for modifying the destination address of the mount storage volume response message according to the container interconnection address to obtain a modified mount storage volume response message, and sending the modified mount storage volume response message to the target container;
wherein a core switch is included between the container storage gateway and the target container;
The container interconnection address is specifically used for information interaction between the container storage gateway and the target container through the core switch;
The information interaction between the container storage gateway and the target container is container service network traffic, and the container service network traffic is terminated at the container storage gateway;
The container interconnection address is configured when the target container mounts a disk.
8. An electronic device, comprising: a memory and a processor, the memory and the processor being communicatively connected to each other, the memory having stored therein computer instructions, the processor executing the computer instructions to perform the storage volume mounting method of any of claims 1 to 6.
9. A computer-readable storage medium storing computer instructions for causing the computer to perform the storage volume mounting method of any one of claims 1 to 6.
CN202111598345.8A 2021-12-24 2021-12-24 Storage volume mounting method, device, equipment and storage medium Active CN114500573B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202111598345.8A CN114500573B (en) 2021-12-24 2021-12-24 Storage volume mounting method, device, equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202111598345.8A CN114500573B (en) 2021-12-24 2021-12-24 Storage volume mounting method, device, equipment and storage medium

Publications (2)

Publication Number Publication Date
CN114500573A CN114500573A (en) 2022-05-13
CN114500573B true CN114500573B (en) 2024-04-26

Family

ID=81496220

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202111598345.8A Active CN114500573B (en) 2021-12-24 2021-12-24 Storage volume mounting method, device, equipment and storage medium

Country Status (1)

Country Link
CN (1) CN114500573B (en)

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103748545A (en) * 2011-08-26 2014-04-23 威睿公司 Data storage system and data storage control method
AU2015264961A1 (en) * 2010-03-31 2015-12-24 Security First Corp. Systems and Methods for Securing Data
CN108681434A (en) * 2018-05-24 2018-10-19 中科边缘智慧信息科技(苏州)有限公司 A kind of container persistent storage hanging method
CN109918359A (en) * 2019-01-18 2019-06-21 华南理工大学 Database service persistence method and system based on swarm
CN111913665A (en) * 2020-07-30 2020-11-10 星辰天合(北京)数据科技有限公司 Mounting method and device of storage volume and electronic equipment
CN112799588A (en) * 2020-12-31 2021-05-14 杭州朗澈科技有限公司 Data storage method for loading container cluster application data by using external storage

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US9052995B2 (en) * 2013-04-26 2015-06-09 Netapp, Inc. Systems and methods providing mount catalogs for rapid volume mount

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
AU2015264961A1 (en) * 2010-03-31 2015-12-24 Security First Corp. Systems and Methods for Securing Data
CN103748545A (en) * 2011-08-26 2014-04-23 威睿公司 Data storage system and data storage control method
CN108681434A (en) * 2018-05-24 2018-10-19 中科边缘智慧信息科技(苏州)有限公司 A kind of container persistent storage hanging method
CN109918359A (en) * 2019-01-18 2019-06-21 华南理工大学 Database service persistence method and system based on swarm
CN111913665A (en) * 2020-07-30 2020-11-10 星辰天合(北京)数据科技有限公司 Mounting method and device of storage volume and electronic equipment
CN112799588A (en) * 2020-12-31 2021-05-14 杭州朗澈科技有限公司 Data storage method for loading container cluster application data by using external storage

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
容器网络Calico基本原理和模拟;朱娟;赵兆;;信息与电脑(理论版);20191225(24);全文 *

Also Published As

Publication number Publication date
CN114500573A (en) 2022-05-13

Similar Documents

Publication Publication Date Title
US9137175B2 (en) High performance ethernet networking utilizing existing fibre channel fabric HBA technology
EP3353997B1 (en) Technologies for offloading data object replication and service function chain management
US10567308B1 (en) Virtual machine virtual fabric login system
US8073966B2 (en) Virtual interface
CN101924693B (en) Method and system for migrating processes between virtual machines
US9880870B1 (en) Live migration of virtual machines using packet duplication
US11960430B2 (en) Remote mapping method, apparatus and device for computing resources, and storage medium
US9935901B2 (en) System and method of enabling a multi-chassis virtual switch for virtual server network provisioning
CN110113441A (en) Realize computer equipment, the system and method for load balancing
US8711864B1 (en) System and method for supporting fibre channel over ethernet communication
US20080195756A1 (en) Method and system to access a service utilizing a virtual communications device
CN113326228A (en) Message forwarding method, device and equipment based on remote direct data storage
CN106657180B (en) Information transmission method and device for cloud service, terminal equipment and system
CN107463339B (en) NAS storage system
WO2014086193A1 (en) Data flow affinity for heterogenous virtual machines
WO2017185992A1 (en) Method and apparatus for transmitting request message
CN117616736A (en) Routing application control and data plane traffic supporting native cloud applications
CN109120556B (en) A kind of method and system of cloud host access object storage server
CN114500573B (en) Storage volume mounting method, device, equipment and storage medium
KR20170102717A (en) Micro server based on fabric network
CN110795209B (en) Control method and device
KR20150032085A (en) Method for processing huge data and constructing high performance nfv system
US11422845B2 (en) Native cloud live traffic migration to counter suspected harmful traffic
Dietz et al. Slipstream: Automatic interprocess communication optimization
US20240250892A1 (en) Routing network traffic for hosts and containers with redundant network interfaces

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant