博客园 :: 首页 :: 博问 :: 闪存 :: 新随笔 :: 联系 :: 订阅 订阅 :: 管理 ::
  730 随笔 :: 0 文章 :: 323 评论 :: 347万 阅读
< 2025年3月 >
23 24 25 26 27 28 1
2 3 4 5 6 7 8
9 10 11 12 13 14 15
16 17 18 19 20 21 22
23 24 25 26 27 28 29
30 31 1 2 3 4 5

查看所有任务状态: supervisorctl status

# supervisorctl status
nginx                           RUNNING   pid 18752, uptime 22:59:40
redis                            RUNNING   pid 14542, uptime 45 days, 19:18:08

第一列是服务名;
第二列是运行状态,RUNNING表示运行中,FATAL 表示运行失败,STARTING表示正在启动,STOPED表示任务已停止; 
第三/四列是进程号,最后是任务已经运行的时间。

查看单个任务状态: supervisorctl status 服务名

# supervisorctl status nginx
nginx                      RUNNING   pid 26073, uptime 1 day, 23:12:10

启动任务:supervisorctl start 服务名

# supervisorctl stop nginx
nginx: stopped
#supervisorctl status nginx
nginx                      STOPPED   Jan 05 01:59 PM

停止任务:supervisorctl stop 服务名

# supervisorctl start nginx
nginx: started
# supervisorctl status nginx
nginx                      RUNNING   pid 32207, uptime 0:00:05

重启任务:supervisorctl restart 服务名

# supervisorctl restart nginx
nginx: stopped
nginx: started
# supervisorctl status nginx
nginx                      RUNNING   pid 4952, uptime 0:00:03

其他命令:
supervisorctl help:帮助命令
supervisorctl update :配置文件修改后可以使用该命令加载新的配置
supervisorctl reload: 重新启动配置中的所有程序

posted on   Likwo  阅读(160)  评论(0编辑  收藏  举报
编辑推荐:
· 10年+ .NET Coder 心语,封装的思维:从隐藏、稳定开始理解其本质意义
· .NET Core 中如何实现缓存的预热?
· 从 HTTP 原因短语缺失研究 HTTP/2 和 HTTP/3 的设计差异
· AI与.NET技术实操系列:向量存储与相似性搜索在 .NET 中的实现
· 基于Microsoft.Extensions.AI核心库实现RAG应用
阅读排行:
· 10年+ .NET Coder 心语 ── 封装的思维:从隐藏、稳定开始理解其本质意义
· 地球OL攻略 —— 某应届生求职总结
· 提示词工程——AI应用必不可少的技术
· Open-Sora 2.0 重磅开源!
· 周边上新:园子的第一款马克杯温暖上架
点击右上角即可分享
微信分享提示