0

Im trying to have my bash script simply run a bunch of aws s3 sync commands at the same time and not do them one by one. It appears that it is only doing one of them at a time instead of doing them all at once. My config is setup so I can run 10+ aws s3 sync at a time. If I ran all the aws commands manually, they will all run and start their uploads. Im not sure why this isn't working...

#!/bin/bash
aws s3 sync /usr/local/backup1/latestbackup/ s3://abucket/backup1/
aws s3 sync /usr/local/backup2/latestbackup/ s3://abucket/backup2/
aws s3 sync /usr/local/backup3/latestbackup/ s3://abucket/backup3/

Why is it not spawning them all at once?

Thanks for any help!

saleetzo
  • 580

1 Answers1

1

Oops! I was able to fix this by just adding & at the end of each of the lines.

saleetzo
  • 580