cmd = ("the linux command") cmd | getline dk; close(cmd)
dk stores the output of the command.
awk调用系统命令
原文:http://www.cnblogs.com/shalijiang/p/4604341.html