Abstract:
A method and an apparatus for processing a data packet based on parallel protocol stack instances, where lower-layer protocol processing is performed, using a first protocol stack instance. An associated second protocol stack instance is determined using a target socket after the target socket that is needed to perform upper-layer protocol processing on the data packet is determined, and the upper-layer protocol processing is performed, using the target socket and the second protocol stack instance. The second protocol stack instance that performs the upper-layer protocol processing is determined using the target socket, and hence, a technical problem that protocol processing cannot be performed on a data packet because a protocol stack instance specified by an application (APP) conflicts with a protocol stack instance specified by a network adapter is resolved.
Abstract:
A method and device for processing an input/output (I/O) request in a network file system (NFS) includes sending, by a NFS server, a request for parsing the unidentifiable NFS FH to a centralized controller when a NFS file handle (NFS FH) in an I/O request cannot be identified, receiving, by the NFS server, a file identifier that corresponds to the unidentifiable NFS FH from the centralized controller according to the parsing request, where the file identifier is determined according to a pre-stored correspondence between NFS FHs and file identifiers, and processing, by the NFS server, the I/O request according to the file identifier.
Abstract:
A method and computing device for selecting a protocol stack for performing protocol processing on data is presented. The computing device is configured with a hypervisor for managing a first virtual machine. According to the method, when a socket creation instruction sent by the first virtual machine is received, a protocol stack instance is selected from the protocol stack instances provided by the computing device. Then, a socket is created in the selected protocol stack instance according to the socket creation instruction; and a creation result is transmitted to the first virtual machine. Therefore, in a virtualized environment, multiple virtual machines disposed in a same computing device can share a network protocol processing capability, and protocol stacks of the virtual machines achieve load balance.
Abstract:
A data processing apparatus and a data processing method are provided. The apparatus includes M protocol stacks and at least one distribution service module, and the M protocol stacks separately run on different logic cores of a processor and are configured to independently perform protocol processing on a data packet to be processed. The distribution service module receives an input data packet from a network interface and sends the data packet to one of the M protocol stacks for protocol processing, and receives data packets processed by the M protocol stacks and sends the data packets outwards through the network interface. The present disclosure implements a function of parallel protocol processing by multiple processes in user space of an operating system in a multi-core environment by using a parallel processing feature of a multi-core system, thereby reducing resource consumption caused by data packet copying.
Abstract:
A method and an apparatus for processing a data packet based on parallel protocol stack instances and the method includes determining a distribution policy of a data packet according to distribution policy information of a network adapter, determining a first protocol stack instance according to the distribution policy of the data packet, and creating a target socket in the first protocol stack instance such that when the data packet is distributed to the first protocol stack instance, the first protocol stack instance performs protocol processing on the data packet using the target socket. Hence, a case in which a protocol stack instance that is specified for the target socket by an application conflicts with a protocol stack instance specified by a network adapter is avoided, and a technical problem that protocol processing cannot be performed on the data packet is resolved.
Abstract:
A parameter inference method to solve a problem that precision of a Latent Dirichlet Allocation model is poor is provided. The method includes: calculating a Latent Dirichlet Allocation model according to a preset initial first hyperparameter, a preset initial second hyperparameter, a preset initial number of topics, a preset initial count matrix of documents and topics, and a preset initial count matrix of topics and words to obtain probability distributions; obtaining the number of topics, a first hyperparameter, and a second hyperparameter that maximize log likelihood functions of the probability distributions; and determining whether the number of topics, the first hyperparameter, and the second hyperparameter converge, and if not, putting the number of topics, the first hyperparameter, and the second hyperparameter into the Latent Dirichlet Allocation model until the optimal number of topics, an optimal first hyperparameter, and an optimal second hyperparameter that maximize the log likelihood functions of the probability distributions.
Abstract:
A method and computing device for selecting a protocol stack for performing protocol processing on data is presented. The computing device is configured with a hypervisor for managing a first virtual machine. According to the method, when a socket creation instruction sent by the first virtual machine is received, a protocol stack instance is selected from the protocol stack instances provided by the computing device. Then, a socket is created in the selected protocol stack instance according to the socket creation instruction; and a creation result is transmitted to the first virtual machine. Therefore, in a virtualized environment, multiple virtual machines disposed in a same computing device can share a network protocol processing capability, and protocol stacks of the virtual machines achieve load balance.
Abstract:
An address acquiring method includes receiving an address resolution request packet sent by a source host, where the address resolution request packet includes an Internet Protocol (IP) address of a destination host; determining another network virtualization edge (NVE) device, where the another NVE device stores a correspondence between the IP address of the destination host and a Media Access Control (MAC) address of the destination host and a correspondence between the IP address of the destination host and an IP address of a destination NVE device corresponding to the destination host; obtaining the MAC address of the destination host and the IP address of the destination NVE device corresponding to the destination host from the another NVE device according to the IP address of the destination host. The technical solutions provided in the present disclosure are intended to reduce processing pressure on a physical network.
Abstract:
A task processing method and virtual machine are disclosed. The method includes selecting an idle resource for a task; creating a global variable snapshot for a global variable; executing the task, in private memory space in the selected idle resource; after the execution of the task is complete, acquiring a new global variable snapshot corresponding to the global variable, and acquiring an updated global variable according to a local global variable snapshot and the new global variable snapshot; and determining whether a synchronization variable of a to-be-executed task in a task synchronization waiting queue includes the current updated global variable, and if the synchronization variable of the to-be-executed task in the task synchronization waiting queue includes the current updated global variable, putting the task into a task execution waiting queue.
Abstract:
Embodiments of the present invention disclose a data processing method including: sending global initial statistical information to each slave node; merging received local statistical information of each slave node, to obtain new global statistical information; if Gibbs sampling performed by a slave node has ended, calculating a probability distribution between a document and topic and a probability distribution between the topic and a word according to the new global statistical information; according to the probability distributions obtained through calculation, establishing a likelihood function of a text set, and maximizing the likelihood function, to obtain a new hLDA hyper-parameter; and if iteration of solving for an hLDA hyper-parameter has converged, and according to the new hLDA hyper-parameter, calculating and outputting the probability distribution between the document and topic and the probability distribution between the topic and word.