Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

In virtualization technology, the application of virtualization between different hierarchies

2025-01-15 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >

Share

Shulou(Shulou.com)06/02 Report--

Container technology and virtual machines will co-exist for a long time. Although the technical starting point of container technology is more lightweight and the deployment is fast, it shares the underlying kernel, so it has an inherent disadvantage in resource isolation with virtual machine mode, and will not be able to replace virtual machine mode for the time being. Although each virtual machine is a complete operating system, because of the need to allocate physical resources to it, when the number of virtual machines increases, the resources consumed by the operating system itself are bound to increase.

So containers can be used in conjunction with virtual machines, and this is the current mainstream practice:

After the emergence of virtualization technology, virtualization technology will add an additional layer of Hypervisor on top of the local operating system. Hypervisor is an intermediate software layer running between the physical server and the operating system, which can virtualize hardware resources, such as cpu, hard disk, memory resources and so on. We can then install the operating system based on the resources virtualized, which is called virtual machines.

Through the Hypervisor layer, we can create different virtual machines, and we can limit the physical resources of each virtual machine, and each virtual machine is separate and independent. For example, virtual machine A uses 2 cpu, 8 g memory and 100 g disk, while virtual machine B uses 4 cpu, 16 g memory and 300 g disk. And so on, so that you can maximize the utilization of physical resources.

In this way:

Multiple applications can be deployed on one physical machine, and each application can run independently in a virtual machine.

Virtualization technology

With the above ideas, we can re-recognize the virtualization technology that we are familiar with:

Virtual machine: a virtualization technology that exists between the hardware layer and the operating system layer.

By "forging" a hardware abstract interface, the virtual machine grafts an operating system and the layers above the operating system layer onto the hardware to achieve almost the same function as the real physical machine.

Advantages of virtualization technology:

Resource pool-the resources of one physical machine are allocated to different virtual machines

It's easy to expand-just add physical machines or virtual machines, because virtual machines can be replicated.

It's easy to cloud-Amazon AWS, Aliyun, Google Cloud, etc.

Now that virtualization technology is powerful, why do you need container technology? This involves the limitations of virtualization technology:

Each virtual machine is a complete operating system, so it needs to allocate physical resources. When the number of virtual machines increases, the resources consumed by the operating system itself are bound to increase.

Container: a virtualization technology that exists between the operating system layer and the function library layer.

The container puts the functions above the API abstraction layer and the function library layer on the operating system through the interface of the "forged" operating system. Take Docker as an example, it is an isolated container based on the Namespace and CGroup functions of the Linux operating system, simulating the function of the operating system. Because it is one layer higher than the virtual machine, it needs one less layer, so the container takes up less resources.

Containers can help us pack away the entire development environment and applications, and the packaged containers can be run in any environment, which can solve the problem of inconsistency between development and operation and maintenance environment, so:

The container solves the contradiction between development and operation and maintenance.

Building a bridge between development and operation and maintenance is the best solution to realize devops.

The above description only describes what the container has solved, but it does not specify what a container is. In fact, a few words can explain the container:

Standardized packaging of software and its dependent environment

Applications are isolated from each other

Share an OS Kernel

It can run on many mainstream operating systems.

JVM: a virtualization technology that exists between the library layer and the application.

Java virtual machine has cross-platform characteristics, and the so-called cross-platform feature is actually the work of virtualization. Our Java language calls the operating system function library, but the function libraries of different operating systems are different. JVM is to establish a virtualization layer, adapt to different operating systems through different versions, and provide a unified running environment for programs and developers. Through virtualization to achieve the now spectacular Java ecosystem and other languages based on JVM, such as Scala,Clojure,Kotlin and so on.

Almost all computers follow the same hierarchical structure: hardware layer > hardware abstraction layer > operating system layer > API abstraction layer > function library layer > application layer.

From this, we can know that in the virtualization technology, no matter the virtual machine, the container, or the cross-platform of JVM, it is only the virtualization application between different layers of computers. For a long time in the future, they will support each other according to the actual application scenarios.

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Servers

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report