Create a Post
cancel
Showing results for 
Search instead for 
Did you mean: 
andersplarsson
Contributor

Trying to add network objects from bulk-file /CSV

Hi,

 

Im trying to create Network-objects from CLi in management with this command:

 

>mgmt_cli add network --batch @storage-host/anders/GenesysCloudNW.csv

get this error message: 

" MGMT9000 code: "generic_err_missing_required_parameters"
message: "Missing parameter: [name]"

 

syntax in csv-file looks like this:

name,ip-adress,subnet-mask
GenesysCloud1,108.128.0.0,255.248.0.0
GenesysCloud3,34.240.0.0,255.248.0.0
GenesysCloud4,34.248.0.0,255.248.0.0
GenesysCloud2,3.248.0.0,255.248.0.0
GenesysCloud5,52.208.0.0,255.248.0.0
GenesysCloud6,52.48.0.0,255.252.0.0
GenesysCloud7,63.32.0.0,255.252.0.0

......

 

What is missing?  The name(s) is right there!?!?!?

 

Regards,

Anders

0 Kudos
7 Replies
Alex-
Leader Leader
Leader

You're likely confusing hosts and networks in your syntax. Give a quick look at sk113078.

0 Kudos
andersplarsson
Contributor

I´m sorry I do not see it, this is the syntax from the SK:

 

"#mgmt_cli add network --batch networks.csv" 

 

my syntax: "mgmt_cli add network --batch @storage-host/anders/GenesysCloudNW.csv"

 

Do I have to copy the file to the MGM-blade for this to work?

 

/Anders

0 Kudos
PhoneBoy
Admin
Admin

Try putting quotes around the items in Line 1.
You may have to do it for other lines in the CSV as well.

0 Kudos
Maarten_Sjouw
Champion
Champion

Are you sure it can get to the file, try to give it the explicit path to the file.

Regards, Maarten
0 Kudos
the_rock
Legend
Legend

Message me offline, I can help you with this. I actually had case with TAC on this back in December. I will see if I can find the email on how we did it and email you tomorrow.

Andy

0 Kudos
andersplarsson
Contributor

Faulty syntax in file I guess. This is how it should look like "name,subnet,subnet-mask"  but creating the file in vi instead. Still working on this batch halted with some duplicates and wrong subnet-mask. Still working on it 

---------------------------------------------
Time: [08:26:38] 9/3/2021
---------------------------------------------
"Publish operation" in progress (10%)


---------------------------------------------
Time: [08:26:49] 9/3/2021
---------------------------------------------
"Publish operation" in progress (10%)

0 Kudos
andersplarsson
Contributor

It finally worked. Thank you all for the input. 

---------------------------------------------
Time: [08:41:05] 9/3/2021
---------------------------------------------
"Publish operation" succeeded (100%)

0 Kudos

Leaderboard

Epsum factorial non deposit quid pro quo hic escorol.

Upcoming Events

    CheckMates Events