All of lore.kernel.org
 help / color / mirror / Atom feed
* Testing Linux-CR -- Some Documentation
@ 2011-05-13  5:09 Raghu D K
       [not found] ` <BANLkTimjvdKGr_ZKpoozV5JzdbJeSE7PEA-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
  0 siblings, 1 reply; 8+ messages in thread
From: Raghu D K @ 2011-05-13  5:09 UTC (permalink / raw)
  To: containers-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA

Hello All,

Further to some checking out the sources ( linux-cr, user-cr and
test-cr ), I was able to make some progress after reading the
"linux/Documentation/checkpoint".
I just wanted to summarize the steps I did for reaching what I see. I
have a Ubuntu 10.10 64-bit machine ( however I have installed only a
32-bit ) Ubuntu version.

Checking out Source Code:

1. $ mkdir test-linux-cr
2. $ git clone git://www.linux-cr.org/pub/git/linux-cr
3. $ git clone git://www.linux-cr.org/pub/git/user-cr
4. $ git clone git://www.linux-cr.org/pub/git/tests-cr

I am behind a firewall so I had to configure my proxy setting since
GIT server port "9418" was not open, this is well documented in the
community. However for completeness.

Setting Proxy:

$ apt-get install socat

Create a file "gitproxy.sh" and give it execute permission.

#!/bin/bash
_proxy=<your proxy ip>
_proxyport=<your port>

exec socat STDIO PROXY:$_proxy:$1:$2,proxyport=$_proxyport

Edit ".bashrc" or ".profile" file and add

$ export GIT_PROXY_COMMAND=$(HOME)/gitproxy.sh

Compiling and Building Linux Kernel:

1. Since I have a Ubuntu 10.10 running, I used the kernel
configuration file "config-2.6.35-28-generic" from "/boot" folder

$ cp /boot/config-2.6.35-28-generic ~test-linux-cr/linux-cr/.config

Ensure the following tokens are enabled in the ".config" file.
CONFIG_CHECKPOINT_SUPPORT=y
CONFIG_SYSVIPC_CHECKPOINT=y
CONFIG_CHECKPOINT=y
CONFIG_NETNS_CHECKPOINT=y
CONFIG_CHECKPOINT_DEBUG=y
CONFIG_CGROUPS=y
CONFIG_CGROUP_FREEZER=y
CONFIG_NAMESPACES=y
CONFIG_CGROUP_NS=y
CONFIG_UTS_NS=y
CONFIG_IPC_NS=y
CONFIG_USER_NS=y
CONFIG_PID_NS=y
CONFIG_NET_NS=y
CONFIG_FREEZER=y

$ sudo fakeroot make-kpkg --intrd --append-to-version=-cr kernel_image
kernel_headers

On a successful build we'll have two ".deb" packages for "kernel" and
"headers" and they can be installed with

$ sudo dpkg -i linux-image-2.6.37-cr.Custom_i386.deb
$ sudo dpkg -i linux-headers-2.6.37-cr.Custom_i386.deb

On the Ubuntu 10.10 the GRUB2 is automatically updated when the
package is successfully installed. Reboot and you are in
"Checkpoint/Reset" capable kernel :-)

Building "user-cr" and "tests-cr":
$ cd ~/test-linux-cr/user-cr
$ cd scripts
$ bash ./extract-headers.sh --kernel-src=< path to Linux kernel>
$ cd ..
$ make all

$ cd ~/test-linux-cr/tests-cr
$ bash ./rewrite-cr-header.sh --- This will create a "cr.h" header
file with appropriate macro defines for "__NR_checkpoint" and
"__NR_restart"
$ make all
$ cd simple
$ ./ckpt
$ cat /tmp/cr-test.out
Invoking checkpoint syscall... PASSED.
ret = 1

$ restart < /tmp/out
Invoking checkpoint syscall... PASSED.
ret = 0

However I was not able to run the test scripts ( runall.sh ) as it
gave some errors. Also analyzing the "out" file using "ckptinfo"
results in EOF error.
Any additional help on this is appreciated.

Warm Regards,
Raghu

^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2011-05-18 13:42 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-05-13  5:09 Testing Linux-CR -- Some Documentation Raghu D K
     [not found] ` <BANLkTimjvdKGr_ZKpoozV5JzdbJeSE7PEA-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2011-05-13 11:42   ` Serge E. Hallyn
     [not found]     ` <20110513114245.GA4121-7LNsyQBKDXoIagZqoN9o3w@public.gmane.org>
2011-05-13 14:07       ` Brian Haley
     [not found]         ` <4DCD3B3E.1040704-VXdhtT5mjnY@public.gmane.org>
2011-05-13 14:51           ` Serge Hallyn
     [not found]             ` <20110513145140.GA23848-7LNsyQBKDXoIagZqoN9o3w@public.gmane.org>
2011-05-16 10:34               ` Raghu D K
     [not found]                 ` <BANLkTimSFKU8ibjSpQqQ4vHSFoptJorPFQ-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2011-05-16 13:27                   ` Serge E. Hallyn
     [not found]                     ` <20110516132734.GA26650-7LNsyQBKDXoIagZqoN9o3w@public.gmane.org>
2011-05-18  7:09                       ` Raghu D K
     [not found]                         ` <BANLkTinQhntbVEvNUmdtFQvr04imEvxm9w-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2011-05-18 13:42                           ` Serge Hallyn

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.