while (my ($mac, $bp) = each %mactobp) { $mactobp {$mac} = $bptoifIndex {$bp} if exists $bptoifIndex {$bp} }