use MCE::Shared; mce_open my $fh, ">", "/foo/bar.log" or die "open error: $!";