$|=1; $N_CONS = "/usr/bin/ncons"; open (CONS, "| $N_CONS"); sleep 5; print CONS "config execute test.cfg \n"; sleep 5; print CONS "config save \n"; sleep 5; print CONS "quit \n"; sleep 5; close (CONS);