惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

Cloudbric
Cloudbric
E
Exploit-DB.com RSS Feed
SecWiki News
SecWiki News
Forbes - Security
Forbes - Security
N
News | PayPal Newsroom
S
Security @ Cisco Blogs
Schneier on Security
Schneier on Security
V
V2EX - 技术
S
Secure Thoughts
W
WeLiveSecurity
Google DeepMind News
Google DeepMind News
C
CERT Recently Published Vulnerability Notes
NISL@THU
NISL@THU
S
Securelist
S
Security Archives - TechRepublic
Know Your Adversary
Know Your Adversary
V
Vulnerabilities – Threatpost
Security Latest
Security Latest
Recent Commits to openclaw:main
Recent Commits to openclaw:main
G
GRAHAM CLULEY
H
Hacker News: Front Page
Microsoft Azure Blog
Microsoft Azure Blog
I
Intezer
Google Online Security Blog
Google Online Security Blog
美团技术团队
阮一峰的网络日志
阮一峰的网络日志
T
The Exploit Database - CXSecurity.com
钛媒体:引领未来商业与生活新知
钛媒体:引领未来商业与生活新知
Webroot Blog
Webroot Blog
Jina AI
Jina AI
Engineering at Meta
Engineering at Meta
P
Proofpoint News Feed
The Cloudflare Blog
I
InfoQ
L
LangChain Blog
U
Unit 42
P
Proofpoint News Feed
S
Schneier on Security
S
Security Affairs
Y
Y Combinator Blog
T
Tenable Blog
N
News and Events Feed by Topic
MyScale Blog
MyScale Blog
量子位
Google DeepMind News
Google DeepMind News
Cyberwarzone
Cyberwarzone
博客园 - 聂微东
D
Darknet – Hacking Tools, Hacker News & Cyber Security
GbyAI
GbyAI
AWS News Blog
AWS News Blog

Kian Bradley’s Blog

Resurrecting a dead torrent tracker and finding 3 million peers Resurrecting a dead torrent tracker and finding 3 million peers Supporting modern https on Windows XP Supporting modern https on Windows XP Running rumprun for Xen in Ubuntu 16.04 Setting up NAT networking in Xen using virsh Setting up NAT networking in Xen using virsh Setting up Xen in Ubuntu 16.04 Setting up Xen in Ubuntu 16.04
Running rumprun for Xen in Ubuntu 16.04
Kian Bradley · 2016-08-26 · via Kian Bradley’s Blog

Running rumprun under Xen isn’t hard, but it’s less documented than running it under KVM. This page is similar to Rumprun’s guide to building rumprun unikernels with a few Xen-specific changes.

Build the rumprun platform

Install prerequisite xen headers and build tools:

sudo apt-get install build-essential libxen-dev

Clone their repo, cd, build:

git clone http://repo.rumpkernel.org/rumprun
cd rumprun
git submodule update --init
CC=cc ./build-rr.sh xen

Add binaries to PATH

You’ve now build rumprun and the binaries necessary for building, baking, running are located in rumprun/bin. You’ll want to these to your PATH variable for convenient access:

export PATH="${PATH}:$(pwd)/rumprun/bin"

You can also add this to your ~/.bashrc to make these changes permanent.

vim ~/.bashrc

Append the following, where [location of rumprun] represents the directory containing rumprun:

export PATH="$PATH:[location of rumprun]/rumprun/bin"

Building applications

Get some source code and use rumprun’s version of gcc to compile it. (Follow the rumprun tutorial for a more thorough explanation…)

Here, helloer.c is our source code and helloer-rumprun is the output binary.

x86_64-rumprun-netbsd-gcc -o helloer-rumprun helloer.c

Baking applications

I was going to make a joke here but I can’t think of anything clever right now. You need to bake it. That means running a command to add in all the kernel-y bits that makes rumprun ready for it.

Here, helloer-rumprun is the binary we just built and helloer-rumprun.bin is the the binary with the necessary rumprun pieces.

rumprun-bake xen_pv helloer-rumprun.bin helloer-rumprun

Running applications

Here’s the hard part. The rumprun command is a script that will create a Xen configuration file in /tmp and start up a Xen PV guest. For xen, it will look like this:

rumprun -S xen -id -g [Xen config options] -I [network interface] -W [more network options]

The -I and -W commands can be omitted if there is no need for networking. I have networking set up using a NAT, in which there exists a subnet local to the machine. Look at my article on Xen networking to see how I set up networking within rumprun.