View StackScript Logs?
Thank You,
brendon
1 Reply
Save stdout and stderr
exec 6>&1
exec 5>&2
Redirect stdout and stderr to a file
exec > /root/StackScript.out
exec 2>&1
[….do_stuff….]
Restore stdout and stderr
exec 1>&6 6>&-
exec 2>&5 5>&-