Hi Hugh,
> Can I re-run the import and "merge" the admin users in, or will I have to
> remove and re-add the site? I kinda need to merge, 'cos they've had a
> bunch of mail come in since the sites came back up, which they'd obviously
> lose if I re-imported the whole thing.
Although cmuImport supports "merging", the method it uses for that is somewhat
obscure and will not get you the results you are looking for.
My advice would be to delete the sites in question and do the import again.
Sure, it blows to loose the mail, but OTOH the sooner you get everything up
and running normally, the better.
If it's more than just a few sites, then the procedure below may be useful, as
it automates the deletion and re-import of multiple sites:
Do a "yum install 5100R-shell-tools" to make sure that you have
the "shell-tools" installed. You'll need them for the procedure I outline
below and some versions of BlueQuartz may not have the shell-tools installed
by default.
Create a textfile with the names of the sites in question. One domain name per
line. Example:
----------------------------------------------------------------------------------------------------
www.domain1.com
www.domain2.com
mail.domain3.co.uk
----------------------------------------------------------------------------------------------------
Name it sitelist.txt and then create the following Perl script. The name of
the script is not important:
----------------------------------------------------------------------------------------------------
#!/usr/bin/perl
# Change these settings:
$ip = "127.0.0.1"; # Change it!
$path_to_cmudump = "/home/import/data/"; # Change it!
# Program start:
open( PWFILE, "sitelist.txt") || die "Cannot open sitelist.txt";
while ( <PWFILE>) {
chop;
($site) = split /\//;
print $site . "\n";
system("/usr/sbin/cdelvsite --fqdn $site");
system ("cmuImport -i $ip -n $site -d $path_to_cmudump");
}
close (PWFILE);
----------------------------------------------------------------------------------------------------
Be sure to change the two lines in the script to reflect the IP you want to
import onto and to fix the location where your CMU dump is located.
Then run that script. It will go through sitelist.txt and for each line it
finds there it will delete the site from the server first (with
the "/usr/sbin/cdelvsite" command from the shell-tools) and will then
re-import that site from your CMU-Dump.
Be sure to apply the cmu.xml fix that I wrote about earlier to remove the
SiteAdmin capability from all users.
> I hate days like this!
I can imagine. :o(
--
With best regards,
Michael Stauber
http://www.solarspeed.net