当前位置:网站首页>nohup 命令使用
nohup 命令使用
2022-06-12 15:33:00 【毕业即失业吗】
nohup 命令使用
运行jar包 长期运行并保存日志到spring.log
nohup java -jar spring.jar >temp.log &
错误提示nohup: 忽略输入重定向错误到标准输出端
修改命令为:
nohup java -jar spring.jar >temp.log 2>&1 &
说明:输入输出重定向
定义:为了更高效的处理数据,需要把多个Linux命令适当的组合在一起,使其协同工作,要做到这一点,就必须搞明白命令的输入重定向与输出重定向的原理。
输入重定向:是指把文件导入到命令中;
输出重定向:指把原本要输出到屏幕的数据信息写入到指定文件中。又分为标准输出重定向和错误输出重定向。
下表为输出重定向中用到的符号及其作用
命令>文件 将标准输出重定向到一个文件中(清空原有文件的数据)
命令>>文件 将标准输出重定向到一个文件中(追加到原有内容的后面)
命令2>文件 将错误输出重定向到一个文件中(清空原有文件的数据)
命令2>>文件 将错误输出重定向到一个文件中(追加到原有内容的后面)
&>或2>&1 将标准输出与错误输出共同写入到文件中
边栏推荐
- Idea大全(转载)
- MySQL开发注意事项(阿里巴巴开发手册)
- PTA:自测-1 打印沙漏 (20分)
- Microservice fault tolerance
- Module yaml error: Unexpected key in data: static_ context [line 9 col 3]
- 任务 水果炸汁机 0611
- Some useful websites
- [jvm learning] parental delegation mechanism and PC register (program counter)
- Error 1105: message:\“raft entry is too large
- Increase the maximum number of MySQL connections
猜你喜欢

Understanding of Odom coordinate system

Multi thread knowledge induction

Use of multithreading

SOA Architecture

IGMP报文(TCP/IP详解卷1/卷2)

【光源实用案例】 UV-LED固化创新,让产线变得更丝滑

Classic case of solidity - Smart games

How to set public IP access on the H3C gr5200 router

RARP总结(TCP/IP详解卷1/2)

Servlet connects to database to realize user login function
随机推荐
C语言 分割bin文件程序
TS 22.011
Leetcode daily question - fair candy bar exchange
IGMP报文(TCP/IP详解卷1/卷2)
Deepin20.6 RTX3080 安裝顯卡驅動510.60.02、CUDA11.6、PyTorch1.11
[jvm learning] local method stack and heap
學習是一件逆人性的事情(成為高手的內功心法)
Find the number of cells (connectivity map, wide search, deep search)
The process of generating strong association rules from frequent itemsets
idea 拉取分支代码
Golang collaboration scheduling (I): Collaboration Status
[LDA] basic knowledge notes - mainly AE and VAE
[untitled]
安装rhel 7/8 (红帽)虚拟机(转载)
使用CSDN-markdown编辑器
Servlet连接数据库实现用户登录功能
Singleton mode instance
Introduction to resttemplate
作業提交說明 上傳作業到網盤中
Understanding of Odom coordinate system