nohup java -jar materiallib.jar >temp.txt & 注:前提系统要装jdk,materiallb.jar是你的jar包名称,temp.txt是你输出的文件, &是防止后台运行。