linux后台启动命令

后台启动:nohup bin/hive --service metastore >> logs/metastore.log 2>&1 &
Linux shell中2>&1的含义解释 (全网最全,看完就懂)
Shell 输入/输出重定向

nohup:

  1. nohup stands for "no hang up". It allows a command to continue running even after the user who issued the command logs out or closes the terminal.

    When a command is prefixed with nohup, it ensures that the command is immune to hangups (i.e., disconnections from the controlling terminal).

    &:

  2. The & (ampersand) operator is used to run a command in the background. It allows the user to continue using the terminal while the command is running.

    When a command is followed by &, it runs asynchronously in the background, and the user can continue issuing other commands in the same terminal session.

  • nohup ensures that a command keeps running even after the terminal is closed, while & runs a command in the background, allowing the user to continue using the terminal for other tasks. However, without nohup, background processes started with & will terminate if the terminal is closed.
相关推荐
ego.iblacat2 分钟前
Nginx 性能优化与深度监控
运维·nginx·性能优化
爱丽_6 分钟前
TCP 三次握手与四次挥手
服务器·网络·tcp/ip
智能工业品检测-奇妙智能18 分钟前
金属矿山安全智能AI视觉识别
服务器·人工智能·安全·openclaw·奇妙智能
bukeyiwanshui19 分钟前
【无标题】
linux·运维·服务器
疯狂吧小飞牛20 分钟前
Linux 多网卡同网段配置冲突问题
linux·运维·服务器
-ONLY-¥38 分钟前
Nginx性能优化与监控全攻略
linux
物联网全栈工程猪38 分钟前
CAN 总线传输策略设计:基于 CAN ID 优先级竞争与本节点低优先级事件让步
运维·服务器·网络
J超会运40 分钟前
OpenEuler系统Nginx性能优化全攻略
运维·nginx·性能优化
wang2455981991 小时前
Redis基础——1、Linux下安装Redis(超详细)
linux·数据库·redis
Solar20251 小时前
企业数据API对接选型指南:技术架构、评估标准与行业实践
大数据·运维·人工智能·架构·云计算