systemctl

本文介绍了如何使用systemd命令在Ubuntu系统中管理服务,包括启动、停止、重启、设置开机自启动等操作。

摘要生成于 C知道 ,由 DeepSeek-R1 满血版支持, 前往体验 >

许多linux的distributions都已经转投systemd了,而ubuntu自从15.04版本以后都使用了systemd.

只介绍常见常用的命令:
    打开服务:sudo systemctl start foobar
    关闭服务:sudo systemctl stop foobar
    重启服务:sudo systemctl restart foobar
    不中断正常功能下重新加载服务:sudo systemctl reload foobar
    设置服务的开机自启动:sudo systemctl enable foobar
    关闭服务的开机自启动:sudo systemctl disable foobar
    查看活跃的单元:systemctl list-units
    查看某个服务的状态:systemctl status foobar

转自:https://blog.youkuaiyun.com/qq_37993487/article/details/79868857

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值