Home  >  Article  >  Operation and Maintenance  >  What is uuid in linux

What is uuid in linux

WBOY
WBOYOriginal
2022-03-15 16:35:477228browse

In Linux, uuid is a universal unique identification code. Uuid is a standard for software construction. The purpose is to allow all elements used in a distributed system to have unique identification information, so that there is no need to specify identification information through a central control terminal.

What is uuid in linux

#The operating environment of this tutorial: linux7.3 system, Dell G3 computer.

What is uuid in Linux

1 Introduction

UUID means Universal Unique Identifier (Universally Unique Identifier), which is a software construct The standard is also part of the field of Distributed Computing Environment (DCE) used by the Open Software Foundation (OSF).

2 Function

The purpose of UUID is to allow all elements in the distributed system to have unique identification information without going through the central control end To specify identification information. This way, everyone can create UUIDs that don't conflict with anyone else's. In this case, there is no need to consider the duplication of names when creating the database. The most widely used UUID at present is Microsoft's Globally Unique Identifiers (GUIDs), while other important applications include Linux ext2/ext3 file system, LUKS encrypted partition, GNOME, KDE, Mac OS X, etc.

3 Composition

UUID refers to a number generated on one machine, which is guaranteed to be unique to all machines in the same time and space. Usually the platform will provide a generated API. Calculated according to standards set by the Open Software Foundation (OSF), using the Ethernet card address, nanosecond time, chip ID code and many possible numbers

UUID is a combination of the following parts:

(1) The current date and time. The first part of the UUID is related to the time. If you generate a UUID after a few seconds, the first part is different and the rest are the same.

(2) Clock sequence.

(3) Globally unique IEEE machine identification number. If there is a network card, it is obtained from the MAC address of the network card. If there is no network card, it is obtained by other means.

The only drawback of UUID is that the generated result string will be relatively long. The most commonly used UUID standard is Microsoft's GUID (Globals Unique Identifiers). In ColdFusion, you can use the CreateUUID() function to easily generate a UUID. Its format is: xxxxxxxx-xxxx- xxxx-xxxxxxxxxxxxxxxx (8-4-4-16), where each x is one in the range of 0-9 or a-f Hexadecimal number. The standard UUID format is: xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx (8-4-4-4-12). You can download the CreateGUID() UDF from cflib for conversion.

4 Application

The benefits of using UUID can be reflected in distributed software systems (such as: DCE/RPC, COM, CORBA), which can ensure The identification generated by each node will not be repeated, and with the development of integration technologies such as WEB services, the advantages of UUID will become more obvious. Depending on the specific mechanism used, UUIDs need to be guaranteed to be not only different from each other, but at least very different from any other universally unique identifier generated before 3400 AD.

Universally unique identifiers can also be used to point to most possible objects. Microsoft and other software companies favor the use of globally unique identifiers (GUIDs), a type of universally unique identifier that can be used to point to building block objects and other software components. The first universally unique identifier was created in Network Computer Systems (NCS) and subsequently became a component of the Open Software Foundation's (OSF) Distributed Computing Environment (DCE).

Related recommendations: "Linux Video Tutorial"

The above is the detailed content of What is uuid in linux. For more information, please follow other related articles on the PHP Chinese website!

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn