select(STDERR);$|=1;select(STDOUT);$|=1; # autoflush $cmd = 'perl b.pl 2>&1'; system($cmd);