From 3b170ec6088101957713a4aa7eaec272080629f2 Mon Sep 17 00:00:00 2001 From: Mayank <mayankchhabra9@gmail.com> Date: Fri, 3 Jul 2020 16:15:27 +0530 Subject: [PATCH] Log rc.local --- stage2/01-sys-tweaks/files/rc.local | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/stage2/01-sys-tweaks/files/rc.local b/stage2/01-sys-tweaks/files/rc.local index 2368717..8771ea1 100755 --- a/stage2/01-sys-tweaks/files/rc.local +++ b/stage2/01-sys-tweaks/files/rc.local @@ -11,6 +11,10 @@ # # By default this script does nothing. +exec 2> /tmp/rc.local.log # send stderr from rc.local to a log file +exec 1>&2 # send stdout to the same log file +set -x # tell sh to display commands before execution + # Print the IP address _IP=$(hostname -I) || true if [ "$_IP" ]; then