open(my $fh2, ">&", $fh) or die "Can't dup filehandle: $!";