http://crd.lbl.gov/departments/computer-science/CLaSS/research/BLCR/
% tar zxf blcr-0.8.4.tar.gz
% cd blcr-0.8.4
% mkdir builddir
% cd builddir
% ../configure --enable-debug --enable-libcr-tracing
--enable-kernel-tracing --enable-cr-info
--enable-init-script
% make
% make install (root权限)
2. 验证安装
% lsmod | grep blcr (验证BLCR内核模块加载是否成功)
blcr 47508 0
blcr_imports 7808 1 blcr
如果没有出现上述结果,单独加载BLCR模块blcr_imports.ko和blcr.ko
% (模块所在路径).../insmod blcr_import.ko
% (模块所在路径).../insmod blcr.ko
3. 验证环境
% cr_checkpoint --help (验证BLCR环境)
如果提示错误需手动设置环境(仅在当前窗口中有效):(bash)
PREFIX为BLCR安装路径,默认为:/usr/local
$ PATH=$PATH:PREFIX/bin
$ MANPATH=$MANPATH:PREFIX/man
$ LD_LIBRARY_PATH=$LD_LIBRARY_PATH:PREFIX/lib:PREFIX/lib64
$ export PATH MANPATH LD_LIBRARY_PATH
可永久设置shell的环境变量,修改文件 /etc/bash.bashrc后重启系统:
# set Environment Variables for BLCR
export PATH="$PATH:/usr/local/bin"
export MANPATH="$MANPATH:/usr/local/man"
export LD_LIBRARY_PATH="$LD_LIBRARY_PATH:/usr/local/lib"
4. 功能测试
% gcc -o test test.c -LBLCR_LIBDIR -lcr
% ./test
% cr_checkpoint --term PID (设置检查点后终止进程)
% cr_restart context.PID (恢复运行)注:在另一个terminal终端运行