On Wed, September 30, 2015 09:33, James B. Byrne wrote:
If I log into a host via ssh from my workstation then I can enter this:
shutdown -r +90&
and log out. The shutdown command will continue in effect and will activae 90 minutes later.
However, if I do this instead:
ssh -t host.domain.tld 'shutdown -r +90&'
then the shutdown command does not remain in effect. Why is this so and is there some way to achieve this?
Why is it that after beating my brains out and finally asking for help the answer appears? I have to close the stdxxx files before putting shutdown into the background.
This seems to work:
ssh host.domain.tld 'shutdown -r +90 > /var/log/shutdown_$(date +%Y%m%dT%H%M).log 2>&1 <&- &'