Giter VIP home page Giter VIP logo

hcontainer-tutorial's Introduction

More information can be found on the Wiki

H-Container -- A project to migrate containers among heterogeneous-ISA machines

H-Container enables containerized applications, natively compiled for a specific ISA, to runtime migrate (similar to VM migration) across compute nodes featuring CPUs of different ISAs, such as ARM and x86. H-Container takes a natively compiled binary (for Linux) and transforms it into a natively compiled set of binaries, one per ISA. Once a binary is started and checkpointed on a machine, it can be restarted on a machine with a different ISA. Thus, enabling runtime migration of applications (note that live-migration is also supported). H-Container supports not just single applications but also entire containers.

H-Container fully integrates with Docker. However, at least at the time of writing, Docker supports container checkpoint/restart (with CRIU) on a single machine only, checkpoint/restart among different (heterogeneous-ISA) machines is completely manual. This repository provides the tools and instructions to enable Docker container migration.

Content

This repository includes tools and instructions (refer to the Wiki) to test H-Container container migration with and without Docker, on yuor own machine (embedded board, laptop, desktop, server), as well as in the cloud (AWS). The following content is included:

config.sh 					 				
popcorn.sh
docker-popcorn-notify.sh
scripts/
	- builder.sh
	- check.sh
	- dump.sh
	- recode.sh
	- restore.sh						
helloworld/ 					
	- Dockerfile 				
	- popcorn-hello 			
	- popcorn-hello_aarch64		
	- popcorn-hello_x86-64	
redis/
	- Dockerfile
	- redis-server
	- redis-server_aarch64
	- redis-server_x86-64
nginx-bin/
	- Dockerfile
	- popcorn-nginx
	- popcorn-nginx_aarch64
	- popcorn-nginx_x86-64
nginx/ # nginx configuration dir, including log and default webpage
       # host machine may already have it if it had install nginx before, 
       # Nginx running inside Docker need map this configuration in host machine.
live-migration/ # criu live migration test script
non-docker-migration/ # H-container normal migration script 

Getting Started with H-Container

H-Containers enables container migration (checkpoint/restart and live-migation), with and without Docker, among any pair of machines (of any ISA, including ARM and x86), running Linux, with identical kernel Cgroup configuration. Note that AWS provides kernel images for different ISAs with the same kernel Cgroup configuration.

The github Wiki includes instructions to setup several examples on AWS. The same examples works on bare-metal, and on QEMU, with and without Docker.

Examples

This repository includes the following examples:

  • Hello World Docker, migration from ARM to x86
  • Redis Server Dokcer, migration from x86 to ARM
  • Nginx Server Docker, migration from x86 to ARM

hcontainer-tutorial's People

Contributors

123toorc avatar abarbala avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

hcontainer-tutorial's Issues

How to get the demo's results?

I used the tools provided by you and migrated redis according to the operation in the video, but I used redis to set the key to random and the value to 123456, but after the migration, I got nil for get random.
The environment I use is the same as in the video, the system in aws, and the mirroring and configuration are the same. My local arm64 virtual machine and x86-64 virtual machine have the same result. I don't know what went wrong, can you help me, thank you

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.