OS : Ubuntu 18.04 LTS
rc.local ÆÄÀÏ»ý¼º
$ sudo cat >> /etc/rc.local <<EOF
#!/bin/bash
exit 0
EOF
½ÇÇà ±ÇÇѺο©
$ sudo chmod +x /etc/rc.local
ÆÄÀÏ ³»¿ë Ãß°¡
$ cat /lib/systemd/system/rc-local.service
...........................
[Service]
Type=forking
ExecStart=/etc/rc.local start
TimeoutSec=0
RemainAfterExit=yes
GuessMainPID=no
[Install]
WantedBy=multi-user.target
rc-local ¼ºñ½º È°¼ºÈ
$ sudo systemctl enable rc-local.service
Created symlink /etc/systemd/system/multi-user.target.wants/rc-local.service -> /lib/systemd/system/rc-local.service.
$ sudo systemctl start rc-local.service
$ sudo systemctl status rc-local.service
¡Ü rc-local.service - /etc/rc.local Compatibility
Loaded: loaded (/lib/systemd/system/rc-local.service; enabled; vendor preset: enabled)
Drop-In: /lib/systemd/system/rc-local.service.d
¦¦¦¡debian.conf
Active: active (exited) since Mon 2018-10-22 13:49:01 KST; 1 day 2h ago
Docs: man:systemd-rc-local-generator(8)
Tasks: 0 (limit: 4915)
CGroup: /system.slice/rc-local.service
Oct 22 13:48:57 ssd-osd-210-220 systemd[1]: Starting /etc/rc.local Compatibility...
Oct 22 13:49:01 ssd-osd-210-220 systemd[1]: Started /etc/rc.local Compatibility.