echo '[Unit]
Description=/etc/rc.local Compatibility
[Service]
Type=oneshot
ExecStart=/etc/rc.local
TimeoutSec=0
StandardInput=tty
RemainAfterExit=yes
[Install]
WantedBy=
multi-user.target' | sudo tee /etc/systemd/system/rc-local.service
sudo chmod 644 /etc/systemd/system/rc-local.service
sudo chmod +x /etc/rc.local
sudo systemctl daemon-reload
sudo systemctl enable rc-local
sudo systemctl status rc-local.service