debian 9、10开启rc.local 您所在的位置:网站首页 口腔溃疡有什么症状或感觉 debian 9、10开启rc.local

debian 9、10开启rc.local

2024-05-09 04:21| 来源: 网络整理| 查看: 265

新建vi /etc/rc.local内容2行:

#!/bin/sh -e exit 0

chmod u+x /etc/rc.local

开机启动

root@debian10:~# systemctl enable rc.local 这一步不成功,实际上这一步也不影响reboot后,rc.local的开机启动 The unit files have no installation config (WantedBy=, RequiredBy=, Also=, Alias= settings in the [Install] section, and DefaultInstance= for template units). This means they are not meant to be enabled using systemctl. Possible reasons for having this kind of units are: • A unit may be statically enabled by being symlinked from another unit's .wants/ or .requires/ directory. • A unit's purpose may be to act as a helper for some other unit which has a requirement dependency on it. • A unit may be started when needed via activation (socket, path, timer, D-Bus, udev, scripted systemctl call, ...). • In case of template units, the unit is meant to be enabled with some instance name specified

reboot后,rc.local正常开机启动

实际上rc.local.servie和rc-local.service是一个服务



【本文地址】

公司简介

联系我们

今日新闻

    推荐新闻

      专题文章
        CopyRight 2018-2019 实验室设备网 版权所有