[CRIU] [PATCH 29/32] tools: cpt2 -- Add writing of per-task images
Cyrill Gorcunov
gorcunov at openvz.org
Mon Apr 1 06:59:15 EDT 2013
On Mon, Apr 01, 2013 at 02:31:11PM +0400, Pavel Emelyanov wrote:
> > +
> > + ret = write_task_netdev(ctx, t);
> > + if (ret) {
> > + pr_err("Failed writing netdev for task %d\n",
> > + t->ti.cpt_pid);
> > + goto out;
> > + }
> > +
> > + ret = write_task_ifaddr(ctx, t);
> > + if (ret) {
> > + pr_err("Failed writing ifaddr for task %d\n",
> > + t->ti.cpt_pid);
> > + goto out;
> > + }
> > +
> > + ret = write_task_route(ctx, t);
> > + if (ret) {
> > + pr_err("Failed writing route for task %d\n",
> > + t->ti.cpt_pid);
> > + goto out;
> > + }
>
> When have netdevs, ifaddrs and routes become per-task information?
int dump_net_ns(int pid, struct cr_fdset *fds)
{
int ret;
ret = switch_ns(pid, &net_ns_desc, NULL);
if (!ret)
ret = dump_links(fds);
if (!ret)
ret = dump_ifaddr(fds);
if (!ret)
ret = dump_route(fds);
return ret;
}
as far as I understand we dump info for task which has own ns.
More information about the CRIU
mailing list