I have a script built to log historical data into an Amazon Redshift instance. The script will likely need to run for a very long time, perhaps over 24 hours before it can run to completion.
I have tried ssh-ing into my EC2 instance and running the script from there, however the after a few hours I leave my laptop or shut the lid and the pipe is broken, stopping the script before it runs to completion.
How can I get a script running on my EC2, and then never have to worry about it stopping execution prematurely?
nohup yourshellcommandhere &
Will run in the background and not require you to have an interactive ssh session active.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With