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.
相关推荐
咋的啥名都用不了呢~34 分钟前
Linux项目部署6(安装Elasticsearch)
linux
时间的拾荒人1 小时前
Docker 入门实战:从核心概念、安装配置到镜像操作与 Dockerfile 定制
运维·docker·容器·eureka
光电笑映1 小时前
TCP 为什么可靠?从三次握手、滑动窗口到拥塞控制全面拆解(上)
运维·服务器·网络·udp
飞奔的瓜牛1 小时前
Linux 下使用 OpenSSL 生成自签名证书完整指南
运维·服务器·nginx
无奈笑天下2 小时前
银河麒麟桌面上USB打印机无法打印问题标准处理流程
linux·运维·网络协议
Decay__2 小时前
附 - 02・SQLServer 分库分表与中间件 —— 原生分区表、横向分库实践与联邦查询
运维·数据库·sql·mysql·架构
15Moonlight2 小时前
Linux 网络(11):IO 多路转接(select /poll/epoll)
linux·网络
峥嵘life4 小时前
Android16 热点「网络共享」开关的设计与实现
服务器·网络·microsoft
wno7044 小时前
CentOS下FTP服务搭建
linux·运维·centos
mylove_北极甜虾4 小时前
jenkins-01Jenkins 架构与任务调度
运维·jenkins