-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Hi Miles,

> I have to move a whole host/sitegroup from one server to 
> another.  What is the best way to do it?  I'm guessing using 
> repligard, but I'm a little sketchy on how to setup the conf 
> files.  Also how do you get the correct blobs out for only 
> that sitegroup/host?  

Here is how I usually do stuff like that:
1.) edit repligard.conf on Server 1:
- - use repliard_withsg scheme
- - username and password have to belong to sg administrator (e.g. username: admin+sg)
- - uncomment <replicate all\>
- - save this as repligard_name_of_sitegroup.conf
2.) export using this config-file
repligard -c /path/to/repligard_name_of_sitegroup.conf -a -e /path/to/sg_dump.xml.gz
3.) On the 2. Server edit repligard.conf to use repligard_withsg scheme, keep system 
admin and his password as login!
4.) Import the xml.gz
repligard -a -i /path/to/transferred/sg_dump.xml.gz
5.) using mysql you will have to adjust the sitegroup table:
Mysql midgard;
Select * from sitegroup; // shows a sitegroup with empty name, realm and admin-group. 
Thats what we have to edit.
Update sitegroup set name='my_sg_name', realm='my_sg_name', 
admingroup='id_of_admin_group' where id='id_of_this_sg'; 
// You can find the admingroup either in aegir or mysql, as you please...
6.) adjust the server name:
Either in mysql (update host set name='new_name' where name='old_name';) or in aegir.
 

Possible Errors:
- - in my experience repligard may complain about 2 things when importing: 
- -- "can't understand sitegroups-field" means you didn't use the repligard_withsg 
scheme in your repligard.conf
- -- "failed to allocate sitegroup 'long-GUID-of-sitegroup' as a resource for blobs" 
is a little more weird.
AFAIK it means repligard has already a sg with prefix "/attachment" and the GUID of 
the attachments you try to import..
This sometimes happens to me when i transfer some SG to my home machine, edit it there 
and try to transfer it back.
I don't know what's the cause for this error, so if anyone out there could enlighten 
me? 


Have Fun,

Alex
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.4 (MingW32)

iD8DBQFAh9Ph6ByBlKPys/0RAqZiAKDih8ZnxurgHO/S+9h6fVL3cjhzbACeMKVD
JJ/umokBycjsr9e7xWQRw2o=
=5Oc1
-----END PGP SIGNATURE-----


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to