Re: [Vserver] Cloning a vserver

From: Mehdi Bennani <joeytriviano_at_gmail.com>
Date: Tue 27 Jun 2006 - 09:18:57 BST
Message-ID: <4a1c34ee0606270118t72c022d9r5da350bac73e576f@mail.gmail.com>

Hi,

Have you changed the context number in /etc/vservers/new/context ?

As I had lots of trouble changing config stuff when copying, I have a
personal way for copy/duplicate:

-make a new vserver skeleton named "new" with right ip, context, etc that
way:
vserver [name] build -m skeleton --hostname [hostname] --interface
eth0:[ip] --context [context number]

-Copy old to new:
cp -a /vservers/old/* /vservers/new/

-make the dummy interface in /etc/vservers/new/interfaces to have 127.0.0.1

-change config files in /vservers/new/etc/ to fit new ip and hostname

These steps can be handled by scripts...

I am making a report about vserver (in french, with details about
installation and management) and should be able to put it online soon, I'll
let the list know.

Salutations,

Mehdi Bennani

2006/6/27, Odile Bénassy <odile.benassy@jm.u-psud.fr>:
> Hello,
>
> I hope not to disturb with a low-level question, I still hope will be
> useful to others.
>
> I'm very happy with my vservers in general, I must say, and the users
> too, of course.
>
> I want to copy a vserver into a second one, because the second one will
> run the same software.
>
> So I had an IP .xxx and a name "old"
>
> And I want a new IP .yyy and a new name "new"
>
> 1) I copied all the /vservers/old to /vservers/new
>
> 2) I copied all the /etc/vservers/old to /etc/vservers/new and also
> /etc/vservers/old.conf to /etc/vservers/new.conf
>
> 3) I went into /etc/vservers/new.conf, into /etc/vservers/new, into
> /vservers/new/etc and change there every string .xxx into .yyy, and
> "old" into "new"
>
> 4) I fixed the /etc/vservers/new symlink
>
> Now both vservers can start and stop. I can ping both IPs.
>
> But if I enter "new" I am in "old".
>
> What do I have left behind?
>
> --
> Odile Bénassy, ingénieure informaticienne
> Service de la Recherche et des Études Doctorales
> Faculté Jean Monnet, Université Paris Sud 11
> 54 bd Desgranges, 92331 Sceaux Cedex
> Tél : +33 (0)1 40 91 18 77 - Fax : +33 (0)1 40 91 18 56
>
> _______________________________________________
> Vserver mailing list
> Vserver@list.linux-vserver.org
> http://list.linux-vserver.org/mailman/listinfo/vserver
>

_______________________________________________
Vserver mailing list
Vserver@list.linux-vserver.org
http://list.linux-vserver.org/mailman/listinfo/vserver
Received on Tue Jun 27 09:19:31 2006

[Next/Previous Months] [Main vserver Project Homepage] [Howto Subscribe/Unsubscribe] [Paul Sladen's vserver stuff]
Generated on Tue 27 Jun 2006 - 09:19:35 BST by hypermail 2.1.8