IP Library Granted Patent US 11,586,455
Granted Patent B2
US 11,586,455 · App. 16/281,984 · Granted Feb 21, 2023

Managing containers across multiple operating systems

Inventors: Raymond Strode, Jr. (Westford, MA); Alexander Larsson (Stockholm, SE); Matthias Clasen (Westford, MA); Debarshi Ray (Brno, CZ)
Assignee: Red Hat, Inc.
G06F9/4555G06F9/45512G06F9/45558G06F9/461H04L41/0806H04L41/0846G06F2009/45562G06F2009/45575
View Patent ↗
Loading inventors, assignments & file history…
Monitor This Case
Get email alerts when status or documents change.
Order Certified Copies
Most orders are placed with the USPTO same day — all within 24 business hours.
Order via The Patent Place →
Pre-filled with this patent's details
Quick Facts
Patent No.
US 11,586,455
App. No.
16/281,984
Granted
Feb 21, 2023
Kind
B2
Abstract

Aspects of the disclosure provide for mechanisms for managing containers across operating systems in a computer system. A method of the disclosure includes: running a first container corresponding to a first operating system, wherein the first container is created in view of a container image; receiving a user request to switch from the first operating system to a second operating system; in response to receiving the user request, switching, by a processing device, from the first container to a second container corresponding to the second operating system, wherein the second container is created in view of the container image, wherein switching from the first container to the second container comprises: configuring the second container in view of a plurality of configurations of the first container; and running the configured second container.

Claims (55)

1. A method comprising:

creating a first container that includes an installation of a first operating system, wherein the first container is created in view of a container image;

causing a first container management agent in the first container to run a user interface in the first container;

receiving, from the user interface running in the first container, a first command to switch from the first operating system to a second operating system; and

responsive to receiving the first command to switch from the first operating system to the second operating system:

creating, in view of the container image, a second container that includes an installation of the second operating system;

configuring the second container in view of one or more configurations of the first container; and

causing a second container management agent in the second container to run the user interface in the second container, wherein the second container management agent is configured to initiate execution in the second container of a second command received from the user interface in the second container.

2. The method of claim 1 , further comprising: responsive to creating the first container, associating a user identifier with the first container,

wherein the user interface enables a user identified by the user identifier to manage the first container and the second container in a single terminal.

3. The method of claim 1 , wherein the user interface comprises a command line interface that provides a prompt identifying a particular container in which the user interface is running.

4. The method of claim 1 , wherein the first container is associated with a user identifier, and configuring the second container comprises:

associating the user identifier with the second container

attaching a current working directory of the first container to the second container; and

importing a shell history associated with the first container to the second container, wherein the shell history specifies one or more commands that were executed in the first container.

5. The method of claim 1 , wherein the user interface comprises a shell, the first container management agent comprises a first shell script, and the second container management agent comprises a second shell script.

6. The method of claim 1 , wherein configuring the second container comprises:

importing a home directory related to the first container to the second container.

7. The method of claim 1 , wherein the first operating system is different than the second operating system.

8. The method of claim 1 , wherein the first command to switch to the second operating system comprises information identifying the second operating system.

9. A non-transitory machine-readable storage medium including instructions that, when accessed by a processing device, cause the processing device to:

create a first container that includes an installation of a first operating system, wherein the first container is created in view of a container image;

cause a first container management agent in the first container to run a user interface in the first container;

receive, from the user interface running in the first container, a first command to switch from the first operating system to a second operating system; and

responsive to receiving the first command to switch from the first operating system to the second operating system:

create, in view of the container image, a second container that includes an installation of the second operating system;

configure the second container in view of one or more configurations of the first container; and

cause a second container management agent in the second container to run the user interface in the second container, wherein the second container management agent is configured to initiate execution in the second container of a second command received from the user interface in the second container.

10. A system comprising:

a memory; and

a processing device operatively coupled to the memory, the processing device to:

create a first container that includes an installation of a first operating system, wherein the first container is created in view of a container image;

cause a first container management agent in the first container to run a user interface in the first container;

receive, from the user interface running in the first container, a first command to switch from the first operating system to a second operating system; and

responsive to receiving the first command to switch from the first operating system to the second operating system:

create, in view of the container image, a second container that includes an installation of the second operating system;

configure the second container in view of one or more configurations of the first container; and

cause a second container management agent in the second container to run the user interface in the second container, wherein the second container management agent is configured to initiate execution in the second container of a second command received from the user interface in the second container.

11. The system of claim 10 , wherein the processing device is further to:

associate a user identifier with the first container responsive to creating the first container, wherein the user interface enables a user identified by the user identifier to manage the first container and the second container in the same terminal.

12. The system of claim 10 , wherein the first operating system is different than the second operating system.

13. The system of claim 10 , wherein the processing device is further to:

stop an execution of the first container responsive to receiving the first command to switch from the first operating system to the second operating system.

14. The system of claim 13 , wherein the processing device is further to, in response to receiving a third command to fork the first container, create a third container in view of the first container, wherein the third container represents a copy of the first container.

15. The system of claim 10 , wherein the user interface comprises a command line interface that provides a prompt identifying a particular container in which the user interface is running.

16. The system of claim 10 , wherein the first container is associated with a user identifier, and to configure the second container in view of the one or more configurations of the first container, the processing device is further to:

associate the user identifier with the second container

attach a current working directory of the first container to the second container; and

import a shell history associated with the first container to the second container, wherein the shell history specifies one or more commands that were executed in the first container.

17. The non-transitory machine-readable storage medium of claim 9 , wherein the user interface comprises a command line interface that provides a prompt identifying a particular container in which the user interface is running.

18. The non-transitory machine-readable storage medium of claim 17 , wherein the instructions further cause the processing device to:

in response to receiving a second command to create a copy of the first container, create the second container in view of the first container, wherein the second command to create the copy of the first container comprises a request to fork the first container.

19. The non-transitory machine-readable storage medium of claim 18 , wherein, to create the second container in view of the first container, the processing device is further to create a copy of the first container.

20. The non-transitory machine-readable storage medium of claim 17 , wherein the processing device is further to: responsive to creating the first container, associate a user identifier with the first container,

wherein the user interface enables a user identified by the user identifier to manage the first container and the second container in the same terminal.

Assignments (1)
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded Feb 22, 2019
From: STRODE, RAYMOND; LARSSON, ALEXANDER; CLASEN, MATTHIAS; RAY, DEBARSHI
To: RED HAT, INC.
Reel/Frame 048406/0622 →
Continuity (1)
Related Publication 20200272488A1 · Aug 27, 2020