wiki:Soledad/MigrazioneNuovoServer

Migrazione dei dati su un nuovo server

#!/bin/sh

CMD=scp -r
DEST=$1

# vecchio server                # nuovo server
$CMD /var/www/fuss-data-conf/*  $DEST:/var/www/fuss-data-conf/
$CMD /root/.ssh/*               $DEST:/root/.ssh/
$CMD /etc/ssl/certs/*           $DEST:/etc/ssl/certs/

# se sono custom...
$CMD /etc/squid/squid.conf      $DEST:/etc/squid/
$CMD /etc/samba/*               $DEST:/etc/samba/
$CMD /etc/init.d/firewall.sh    $DEST:/etc/init.d/
$CMD /etc/clusters              $DEST:/etc/

# LDAP
ssh $DEST "/etc/init.d/slapd stop && rm /var/lib/ldap/*"
slapcat | ssh $DEST "cat | slapadd"
ssh $DEST "/etc/init.d/slapd start"

# HOME

rsync -avzr /home/* $DEST:/home/

Last modified 11 years ago Last modified on Oct 18, 2006, 5:51:06 PM