没有合适的资源?快使用搜索试试~ 我知道了~
由于对可靠性的要求,例如不间断服务,容错能力等,虚拟机集群(VMC)的管理面临挑战。VMC的分布式快照是支持系统可靠性的一种有前途的方法,它允许数据中心的系统管理员从故障中恢复系统,并从中间状态而不是初始状态恢复执行。 但是,由于虚拟机(VM)技术的重量级性质,在VMC中运行的应用程序会遭受长时间的停机,并且快照期间的性能会下降。 此外,虚拟机之间快照完成时间的差异带来了TCP退回问题,从而导致两个通信虚拟机之间的网络中断。 本文提出了HotSnap,这是一种VMC快照方法,旨在使能够以毫秒级的系统停机时间和TCP退避持续时间拍摄热分布式快照。 HotSnap的核心是瞬态快照,它可以在短时间内保存最小的瞬时状态,而完整快照则可以在正常操作期间保存整个VM状态。 然后,我们设计快照协议以将各个VM快照协调为VMC的全局一致状态。 我们已经在QEMU / KVM上实现了HotSnap,并进行了一些实验以显示有效性和效率。 与基于实时迁移的分布式快照技术相比,它带来了数秒的系统停机时间和网络中断,而HotSnap仅需花费数十毫秒的时间。
资源推荐
资源详情
资源评论
HotSnap: A Hot Distributed Snapshot System for Virtual Machine Cluster
Lei Cui, Bo Li, Yangyang Zhang, Jianxin Li
Beihang University, Beijing, China
{cuilei, libo, zhangyy, lijx}@act.buaa.edu.cn
Abstract
The management of virtual machine cluster (VMC) is
challenging owing to the reliability requirements, such
as non-stop service, failure tolerance, etc. Distributed s-
napshot of VMC is one promising approach to support
system reliability, it allows the system administrators of
data centers to recover the system from failure, and re-
sume the execution from a intermediate state rather than
the initial state. However, due to the heavyweight na-
ture of virtual machine (VM) technology, application-
s running in the VMC suffer from long downtime and
performance degradation during snapshot. Besides, the
discrepancy of snapshot completion times among VMs
brings the TCP backoff problem, resulting in network in-
terruption between two communicating VMs. This paper
proposes HotSnap, a VMC snapshot approach designed
to enable taking hot distributed snapshot with millisec-
onds system downtime and TCP backoff duration. At the
core of HotSnap is transient snapshot that saves the min-
imum instantaneous state in a short time, and full snap-
shot which saves the entire VM state during normal oper-
ation. We then design the snapshot protocol to coordinate
the individual VM snapshots into the global consistent
state of VMC. We have implemented HotSnap on QE-
MU/KVM, and conduct several experiments to show the
effectiveness and efficiency. Compared to the live migra-
tion based distributed snapshot technique which brings
seconds of system downtime and network interruption,
HotSnap only incurs tens of milliseconds.
1 Introduction
With the increasing prevalence of cloud computing and
IaaS paradigm, more and more distributed application-
s and systems are migrating to and running on virtual-
ization platform. In virtualized environments, distribut-
ed applications are encapsulated into virtual machines,
which are connected into virtual machine cluster (VM-
C) and coordinated to complete the heavy tasks. For
example, Amazon EC2 [1] offers load balancing web
farm which can dynamically add or remove virtual ma-
chine (VM) nodes to maximize resource utilization; Cy-
berGuarder [22] encapsulates security services such as
IDS and firewalls into VMs, and deploys them over a
virtual network to provide virtual network security ser-
vice; Emulab [12] leverages VMC to implement on-
demand virtual environments for developing and testing
networked applications; the parallel applications, such as
map-reduce jobs, scientific computing, client-server sys-
tems can also run on the virtual machine cluster which
provides an isolated, scaled and closed running environ-
ment.
Distributed snapshot [13, 27, 19] is a critical technique
to improve system reliability for distributed applications
and systems. It saves the running state of the application-
s periodically during the failure-free execution. Upon a
failure, the system can resume the computation from a
recorded intermediate state rather than the initial state,
thereby reducing the amount of lost computation [15]. It
provides the system administrators the ability to recover
the system from failure owing to hardware errors, soft-
ware errors or other reasons.
Since the snapshot process is always carried out peri-
odically during normal execution, transparency is a key
feature when taking distributed snapshot. In other word-
s, the users or applications should be unaware of the
snapshot process, neither the snapshot implementation
scheme nor the performance impact. However, the tra-
ditional distributed systems either implement snapshot
in OS kernel [11], or modify the MPI library to sup-
port snapshot function [17, 24]. Besides, many systems
even leave the job to developers to implement snapshot
on the application level [3, 25]. These technologies re-
quire modification of OS code or recompilation of appli-
cations, thus violating the transparency from the view of
implementation schema.
The distributed snapshot of VMC seems to be an ef-
fective way to mitigate the transparency problem, since it
implements snapshot on virtual machine manager (VM-
M) layer which encapsulates the application’s running s-
tate and resources without modification to target applica-
tions or the OS. Many systems such as VNSnap [18] and
Emulab [12] have been proposed to create the distributed
snapshot for a closed network of VMs. However, these
methods still have obvious shortcomings.
First, the snapshot should be non-disruptive to the up-
per applications, however the state-of-the-art VM snap-
shot technologies, either adopt stop-and-copy method
(e.g., Xen and KVM) which causes the service are com-
pletely unavailable, or leverage live migration based
schema which also causes long and unpredictable down-
time owing to the final copy of dirty pages [26].
Second, the distributed snapshot should coordinate the
individual snapshots of VMs to maintain a global consis-
tent state. The global consistent state reflects the snap-
shot state in one virtual time epoch and regards causali-
ty, implying the VM before snapshot cannot receive the
packets send from the VM that has finished the snapshot
to keep the consistent state during distributed snapshot
(further explanations about global consistent state can be
referred in appendix A). However, due to the various VM
memory size, variety of workloads and parallel I/O oper-
ations to save the state, the snapshot start time, duration
time and completion time of different VMs are always
different, resulting in the TCP back-off issue [18], there-
by causing network interruption between the communi-
cating VMs. Figure 1 demonstrates one such case hap-
pened in TCP’s three-way handshake. Worse still, for
the master/slave style distributed applications, the mas-
ter always undertake heavier workloads so that cost more
time to finish the snapshot than the slaves, therefore, the
slaves which finish the snapshot ahead cannot commu-
nicate with the master until the master snapshot is over,
causing the whole system hung. As a result, the mas-
ter snapshot becomes the short-board during distributed
snapshot of master/slave systems.
Third, most distributed snapshot technologies adop-
t the coordinated snapshot protocol [13] to bring the
distributed applications into a consistent state. This re-
quires a coordinator to communicate snapshot-related
commands with other VMs during snapshot. In many
systems, the coordinator is setup in the customized mod-
ule such as VIOLIN switch in VNSnap [18] and XenBus
handler used in Emulab [12], thus lack of generality in
most virtualized environments.
To mitigate the problems above, we propose HotSnap,
a system capable of taking hot distributed snapshot that is
transparent to the upper applications. Once the snapshot
command is received, HotSnap first suspends the VM,
freezes the memory state and disk state, creates a tran-
sient snapshot of VM, and then resumes the VM. The
SYN_RCVD
TIME_OUT
snapshot
SYN
SYN_RCVD
SYN/ACK
VM1
VM2
snapshot
TIME_OUT
TCP state
SYN
SYN/ACK
VM1
VM2
Figure 1: A TCP handshake case during distributed s-
napshot. V M
2
first sends SYN to V M
1
to request a TCP
connection, at this moment V M
2
has not begin its snap-
shot; V M
1
receives this request, turn its own state into
SYN RCVD, and then sends SYN/ACK back to V M
2
.
We notice that now V M
1
has finished snapshot, and based
on the coordinated protocol, packets sent from VM
1
will
not be accepted by V M
2
until V M
2
has finished its own
snapshot. If VM
2
’s snapshot duration exceeds TCP time-
out, connection will fail.
transient snapshot only records the minimum instanta-
neous state, including CPU and device states, as well
as two bitmaps reserved for memory state and disk s-
tate, bringing only milliseconds of VM downtime, i.e.,
hot for upper applications. The full snapshot will be ac-
quired after resuming the VM, it saves the entire memory
state in a copy-on-write (COW) manner, and create the
disk snapshot in the redirect-on-write (ROW) schema;
the COW and ROW schemas enable creating the full s-
napshot without blocking the execution of VM, i.e., live
snapshot. Because the transient snapshot introduces on-
ly milliseconds of downtime, the discrepancy of down-
time among different VM snapshots will be minor, there-
by minimizing the TCP backoff duration.
HotSnap is completely implemented in VMM layer, it
requires no modification to Guest OS or applications, and
can work without other additional modules. The major
contributions of the work are summarized as follows:
1) We propose a VM snapshot approach combined of
transient snapshot and full snapshot. The approach com-
pletes snapshot transiently, enables all VMs finish their
snapshots almost at the same time, which greatly reduces
the TCP backoff duration caused by the discrepancy of
VMs’ snapshot completion times.
2) A classic coordinated non-blocking protocol is sim-
plified and tailored to create the distributed snapshot of
the VMC in our virtualized environment.
3) We implement HotSnap on QEMU/KVM platform
[20]. Comprehensive experiments are conducted to eval-
uate the performance of HotSnap, and the results prove
the correctness and effectiveness of our system.
The rest of the paper is organized as follows. The
next section provides an analysis of the traditional dis-
b) VNSnap distributed snapshot.
a) VNSnap distributed snapshot.
pre-snapshot
live-snapshot downtime post-snapshot
1
2
3
VM1 VM2 VM1 VM2
b) HotSnap distributed snapshot.a) VNSnap distributed snapshot.
pre-snapshot
live-snapshot suspended post-snapshot
Arrow1
Arrow2
Arrow3
VM1 VM2 VM1 VM2
SNAPSHOT
Figure 2: Comparison of VNSnap and HotSnap.
tributed snapshot and their problems. Section 3 intro-
duces the HotSnap method, describes the transient snap-
shot, full snapshot and coordinated protocol. Section
4 describes the implementation-specific details on QE-
MU/KVM platform. The experimental results are shown
in Section 5. Finally we present the previous work re-
lated to HotSnap in section 6 and conclude our work in
Section 7.
2 An Analysis of Distributed Snapshot
The distributed snapshot includes independent VM s-
napshot and the coordinated protocol. Stop-and-copy
schema is a simple way to create snapshot of individ-
ual VM, but this schema introduces long downtime of
Guest OS and the upper applications running inside the
VM, thus is impractical in many scenarios that deliver
services to users. The live snapshot technologies lever-
age pre-copy based migration to achieve live snapshot
by iteratively saving the dirty pages to the snapshot file
[12, 18]. In this section, we will analyze the live mi-
gration based distributed snapshot proposed in VNSnap
[18], and explain how it results in TCP backoff problem.
Figure 2(a) demonstrates the procedure of VNSnap
distributed snapshot. Although VNSnap exploits the VI-
OLIN [12] switch to execute the coordinated protocol,
we treat V M
1
as the coordinator for clarity. Upon dis-
tributed snapshot, the coordinator, i.e., V M
1
, will send
SNAPSHOT command to VM
2
, and then create the snap-
shot of V M
1
itself. VNSnap leverages live migration to
iteratively save the dirtied pages into stable storage or re-
served memory region until some requirements are satis-
fied, such as the amount of dirty pages are minor enough,
or the size cannot be further reduced even more iterations
are conducted. Then VNSnap suspends the VM, stores
the final dirty memory pages, saves other devices’ state
and creates the disk snapshot. After these steps, the snap-
shot of VM
1
is over and V M
1
is resumed. Upon receiving
the SNAPSHOT command from VM
1
, V M
2
follows the
same procedure as V M
1
to create its own snapshot. VN-
Snap drops the packets send from the post-snapshot VM
to pre-snapshot VM, to keep the global state consistent.
Take this tiny cluster which consists of two VMs as
an example, the distributed snapshot duration time is
from the start time of V M
1
snapshot to the end time of
V M
2
snapshot (suppose V M
2
finishes snapshot later than
V M
1
), the TCP backoff duration is from the start of V M
1
suspend to the end of V M
2
suspend. The packets re-
sult in TCP backoff fall into three categories: 1) V M
1
is suspended while V M
2
is in live-snapshot, the packets
send from V M
2
to V M
1
will not arrive, as Arrow
1
illus-
trates; 2) V M
1
finishes snapshot and then turns into post-
snapshot state, but V M
2
is before or during snapshot. In
this situation, packets send from V M
1
will be dropped to
keep the consistent state of distributed snapshot. Arrow
2
shows such a case. 3) V M
1
is in post-snapshot, but V M
2
is suspended, V M
2
cannot receive the packets send from
V M
1
, as Arrow
3
shows.
Based on the three types of packets, we can conclude
that two aspects affect the TCP backoff duration in dis-
剩余14页未读,继续阅读
资源评论
weixin_38682086
- 粉丝: 6
- 资源: 984
上传资源 快速赚钱
- 我的内容管理 展开
- 我的资源 快来上传第一个资源
- 我的收益 登录查看自己的收益
- 我的积分 登录查看自己的积分
- 我的C币 登录后查看C币余额
- 我的收藏
- 我的下载
- 下载帮助
最新资源
- apache-maven-3.6.1-bin.zip
- c593f5fc-d4a7-4b43-8ab2-51afc90f3f62
- IIR滤波器参数计算函数
- WPF树菜单拖拽功能,下级目录拖到上级目录,上级目录拖到下级目录.zip
- CDH6.3.2版本hive2.1.1修复HIVE-14706后的jar包
- 鸿蒙项目实战-天气项目(当前城市天气、温度、湿度,24h天气,未来七天天气预报,生活指数,城市选择等)
- Linux环境下oracle数据库服务器配置中文最新版本
- Linux操作系统中Oracle11g数据库安装步骤详细图解中文最新版本
- SMA中心接触件插合力量(插入力及分离力)仿真
- 变色龙记事本,有NPP功能,JSONview功能
资源上传下载、课程学习等过程中有任何疑问或建议,欢迎提出宝贵意见哦~我们会及时处理!
点击此处反馈
安全验证
文档复制为VIP权益,开通VIP直接复制
信息提交成功