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.
相关推荐
wanhengidc25 分钟前
云手机 网络连接与持续性的表现如何
运维·服务器·科技·游戏·智能手机
小猿成长28 分钟前
Ubuntu搭建物联网平台(ThingsBoard)教程
linux·运维·ubuntu
代码不行的搬运工31 分钟前
RFC6811:BGP前缀源验证
运维·服务器·bgp网络
Archie_IT33 分钟前
openEuler 软件生态深度勘探:从六万软件包到多语言融合
linux·容器·性能测试·openeuler·多语言开发
tokepson2 小时前
香橙派AI Pro个人云平台 - 从零搭建全记录
linux·服务器·技术·记录
月亮!2 小时前
移动端测试重磅升级:跨平台自动化测试框架深度对比
运维·网络·人工智能·测试工具·容器·自动化·测试用例
fengyehongWorld2 小时前
Linux wget命令
linux
凯子坚持 c3 小时前
Docker 容器全生命周期管理与运维命令深度解析
运维·docker·php
fpcc3 小时前
跟我学C++中级篇——Linux系统信号分析
linux
楼田莉子3 小时前
基于Linux的个人制作的文件库+标准输出和标准错误
linux·c语言·c++·学习·vim