--- swift-osg-ress-site-catalog.ORIG 2009-07-02 12:08:01.000000000 -0400 +++ swift-osg-ress-site-catalog 2009-07-02 12:13:56.000000000 -0400 @@ -60,7 +60,7 @@ if ($_ eq "") { if ($tmp{'GlueSiteName'} ne "") { my %copy = %tmp; - $ads{$tmp{'GlueSiteName'}} = \%copy; + $ads{$tmp{'GlueSiteName'} . "_" . $tmp{'GlueClusterUniqueID'}} = \%copy; undef %tmp; } } @@ -77,10 +77,10 @@ open(FH, ">$opt_out") or die("Unable to open $opt_out"); print FH "\n"; -foreach my $sitename (keys %ads) { - my $contact = $ads{$sitename}->{'GlueCEInfoContactString'}; +foreach my $siteid (sort keys %ads) { + my $contact = $ads{$siteid}->{'GlueCEInfoContactString'}; my $host = $contact; - $host =~ s/:.*//; + $host =~ s/[:\/].*//; my $jm = $contact; $jm =~ s/.*jobmanager-//; if ($jm eq "pbs") { @@ -95,10 +95,10 @@ elsif ($jm eq "condor") { $jm = "Condor"; } - my $workdir = $ads{$sitename}->{'GlueCEInfoDataDir'}; + my $workdir = $ads{$siteid}->{'GlueCEInfoDataDir'}; print FH "\n"; - print FH " \n"; - print FH " \n"; + print FH " \n"; + print FH " \n"; print FH " \n"; if ($opt_target eq "condorg") { print FH " \n"; @@ -111,7 +111,7 @@ else { print FH " \n"; } - print FH " $workdir/$lc_vo/tmp/$sitename\n"; + print FH " $workdir/$lc_vo/tmp/$host\n"; print FH " \n"; } print FH "\n\n";