Create a Post
cancel
Showing results for 
Search instead for 
Did you mean: 
TomMor
Explorer

SmartConsole CLI

Hello Everyone!

I'm trying to export groups from my SmartConsole to CSV file.

I ran this script via expert mode and it worked correctly:

mgmt_cli -r true show-group name "My_Group" details-level full -f json | jq '.members[] | [.name, ."ipv4-address", .comments] |@csv'

But when I'm trying to run this script via SmartConsole CLI it's failing.

This is the SmartConsole CLI I'm trying to run:

show-group name "My_Group" details-level full -f json | jq '.members[] | [.name, ."ipv4-address", .comments] |@csv'

And this is the error:

Error: The parameters of show-group command should be provided in pairs (key and value). You have provided an odd number of parameters which suggests that you are probably missing a parameter.

Thank you.

 

 

0 Kudos
2 Replies
Bob_Zimmerman
Authority
Authority

The CLI in SmartConsole doesn't support pipes (incidentally, nor does clish). It feeds the full command you enter to something a little like this:

mgmt_cli -s session.txt %

With the full text you entered replacing the %.

0 Kudos
TomMor
Explorer

OK, so if the CLI in SmartConsole doesn't support pipes, there is any other way I can export groups via SmartConsole CLI?

0 Kudos

Leaderboard

Epsum factorial non deposit quid pro quo hic escorol.

Upcoming Events

    Tue 20 May 2025 @ 11:30 AM (PDT)

    Las Vegas: Check Point Hybrid Mesh

    Wed 21 May 2025 @ 11:30 AM (MST)

    Tempe, AZ: Check Point Hybrid Mesh

    Tue 03 Jun 2025 @ 06:00 PM (EDT)

    Montreal: CPX Recap

    Tue 10 Jun 2025 @ 06:00 PM (EDT)

    Quebec City: CPX Recap
    CheckMates Events