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.
相关推荐
Y1rong3 分钟前
linux之网络
linux
寄存器漫游者20 分钟前
Linux 软件编程 - IO 编程
linux·运维·spring
charlotte1024102423 分钟前
高并发:关于在等待学校教务系统选课时的碎碎念
java·运维·网络
_别来无恙_37 分钟前
TFTP的使用Linux
linux·服务器
gaize121340 分钟前
Moltbot(Clawdbot) 专属轻量服务器
运维·服务器
Zaralike1 小时前
Linux 服务器网络不通排查 SOP(标准操作流程)
linux·服务器·网络
getapi1 小时前
注塑件的费用构成
linux·服务器·ubuntu
鸽芷咕2 小时前
DrissionPage 成 CANN 仓库爆款自动化工具:背后原因何在?
运维·python·自动化·cann
池央2 小时前
CANN 算子生态的深度演进:稀疏计算支持与 PyPTO 范式的抽象层级
运维·人工智能·信号处理
Maynor9962 小时前
OpenClaw 玩家必备:用 AI 自动追踪社区最新动态
java·服务器·人工智能