提问: 当我尝试在虚拟机中安装一个新的Linux时,虚拟机不能启动且报了下面这个错误:”unsupported configuration: hda-duplex not supported in this QEMU binary.”(“不支持的配置:hda-duplex在此QEMU文件中不支持。”) 我该如何修复?
$ sudo ip addr add 10.0.0.1/24 broadcast 10.0.0.255 dev eth1
$ sudo ip addr add 10.0.0.2/24 broadcast 10.0.0.255 dev eth1
$ sudo ip addr add 10.0.0.3/24 broadcast 10.0.0.255 dev eth1
function forEach(array, action) {
for (var i = 0; i < array.length; i++) {
action(array[i]); //apply action to every element of the arra.
}
}
function reduce(combine, base, array) {
forEach(array, function (element) {
base = combine(base, element); // and here we apply function passed as ‘combine’ parameter to ‘base’ and ‘element’
});
return base;
}
function add(a, b) { // btw, this is how you define a function in JavaScript
return a + b;
}
function sum(numbers) {
return reduce(add, 0, numbers);
}
答:灰名单(LCTT译注:介于白名单和黑名单之间)是一种用于拦截垃圾邮件的技术。一个 MTA 使用灰名单时就会“暂时拒绝”未被识别的发送者发来的所有邮件。如果邮件是正当合理的,发起者会在一段时间后重新发送,然后这份邮件就能被接收。(LCTT译注:灰名单基于这样一个事实,就是大多数的垃圾邮件服务器和僵尸网络的邮件只发送一次,而会忽略要求它们在一定的时间间隔后再次发送的请求。)
avi@tecmint:~$ /bin/pwd --version
pwd (GNU coreutils) 8.23
Copyright (C) 2014 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later .
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.
Written by Jim Meyering.
$ machine create -d virtualbox dev
[info] Downloading boot2docker...
[info] Creating SSH key...
[info] Creating VirtualBox VM...
[info] Starting VirtualBox VM...
[info] Waiting for VM to start...
[info] "dev" has been created and is now the active host. Docker commands will now run against that host.
$ machine ls
NAME ACTIVE DRIVER STATE URL
dev * virtualbox Running tcp://192.168.99.100:2375
$ export DOCKER_HOST=`machine url` DOCKER_AUTH=identity
$ docker run busybox echo hello world
Unable to find image 'busybox' locally
Pulling repository busybox
e72ac664f4f0: Download complete
511136ea3c5a: Download complete
df7546f9f060: Download complete
e433a6c5b276: Download complete
hello world
$ machine create -d digitalocean --digitalocean-access-token=... staging
[info] Creating SSH key...
[info] Creating Digital Ocean droplet...
[info] Waiting for SSH...
[info] "staging" has been created and is now the active host. Docker commands will now run against that host.
$ machine ls
NAME ACTIVE DRIVER STATE URL
dev virtualbox Running tcp://192.168.99.108:2376
staging * digitalocean Running tcp://104.236.37.134:2376
Machine做事也很聪明,很符合Docker公司的做事风格,他们号称自己架构很好,方便第三方集成。所以Machine现在只支持有限的几个平台(VirtualBox、 Digital Ocean、Microsoft Azure),其它平台的兼容留给那些爱Docker的第三方厂商以及开发者去做吧。所以接下来一定会有很多的厂商跟进,比如国内阿里云之类的,他们根据官方的接口开发个Driver即可加入Machine的能力。