LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 07-17-2018, 06:38 AM   #1
aidylewis
LQ Newbie
 
Registered: Apr 2016
Posts: 25

Rep: Reputation: Disabled
GNU parallel aws cli


Hello,

I have a bash script and I just need to parallelise an aws cli command with X number of jobs.

$ seq 10 | parallel aws sqs send-message --queue-url "<queue-url>" --message-body "aws_sqs"

But I am being told my aws command is incorrect. Runs OK without parallel

Many Thanks

Aidy

Last edited by aidylewis; 07-17-2018 at 08:24 AM.
 
Old 07-18-2018, 12:01 AM   #2
scasey
LQ Veteran
 
Registered: Feb 2013
Location: Tucson, AZ, USA
Distribution: CentOS 7.9.2009
Posts: 5,764

Rep: Reputation: 2225Reputation: 2225Reputation: 2225Reputation: 2225Reputation: 2225Reputation: 2225Reputation: 2225Reputation: 2225Reputation: 2225Reputation: 2225Reputation: 2225
From man parallel
Code:
Synopsis

parallel [options] [command] -- [argument ...]
parallel [options] -- [command ...]
so there needs to be two hyphens (--) between either the command and its arguments or between parallel and the command.

Review the man page to figure out which applies. My guess would be the first one.
Code:
$ seq 10 | parallel aws -- sqs send-message --queue-url "<queue-url>" --message-body "aws_sqs"
 
Old 07-18-2018, 07:36 AM   #3
aidylewis
LQ Newbie
 
Registered: Apr 2016
Posts: 25

Original Poster
Rep: Reputation: Disabled
Both -- infixes, give aws unknown options. Does I need to operate on a list?
 
Old 07-18-2018, 08:11 AM   #4
scasey
LQ Veteran
 
Registered: Feb 2013
Location: Tucson, AZ, USA
Distribution: CentOS 7.9.2009
Posts: 5,764

Rep: Reputation: 2225Reputation: 2225Reputation: 2225Reputation: 2225Reputation: 2225Reputation: 2225Reputation: 2225Reputation: 2225Reputation: 2225Reputation: 2225Reputation: 2225
Here's a link to the man page

Maybe -n option...I don't know.
 
  


Reply

Tags
bash, gnu, parallel



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
LXer: Get more done at the Linux command line with GNU Parallel LXer Syndicated Linux News 0 05-11-2018 09:30 AM
LXer: Easy way to install AWS CLI on Linux LXer Syndicated Linux News 0 04-02-2018 08:03 AM
CentOS 7 w/KDE - Trying to get AWS CLI & Terraform installed buymycorp Linux - Newbie 2 03-19-2017 07:55 PM
[SOLVED] Executing a command in parallel | GNU parallel or xargs the_gripmaster AIX 3 05-08-2012 07:41 AM
Gnu make parallel problem Andrew Benton Programming 7 11-28-2010 09:56 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 08:43 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration