cancel
Showing results for 
Search instead for 
Did you mean: 
Create a Post
Marc_Lampo
Nickel

mgmt_cli - delete member from group ?

Jump to solution

at first glance, the R80 API documentatoin does not explain how to delete  a member from a group.  Anybody an idea ?

With dbedit, deleting an object, used in a group, implicitly removed the object from that group.

Trying to delete such an object, in R80.10, results in a warning I don't seem to be able to override.

So :

is there a way - via CLI - to remove a group member ?

or is there a way to delete an object with some "force" attribute in case it is used as member in some group ?

Thanks !

Marc

Tags (2)
0 Kudos
1 Solution

Accepted Solutions
Employee+
Employee+

Re: mgmt_cli - delete member from group ?

Jump to solution

You can use where-used and delete all references  .

I do not think that 'force' will be a good idea, you can create a scenario that you break the policy .

For groups, you can use 'remove'

groupsObject vCollection of group identifiers.
or
Object v
Parameter nameValueDescription
removestringRemoves from collection of values
or
List: string
or
string
or
List: string
0 Kudos
6 Replies
Admin
Admin

Re: mgmt_cli - delete member from group ?

Jump to solution

I believe the correct approach is to use the "set group" command specifying all members of the group BUT the one you want to delete.

Having a proper "delete from group" API call seems like a good suggestion for future releases.

0 Kudos
Marc_Lampo
Nickel

Re: mgmt_cli - delete member from group ?

Jump to solution

I'll give it a try - but the first script I'm moving from R77.30 to R80 put 312 members in a group.  If, on the next run, I have to delete one by entering the 311 that should remain ...

0 Kudos
Employee+
Employee+

Re: mgmt_cli - delete member from group ?

Jump to solution

try this post Smiley Happy

Adding members to a group 

Eric provided example for 'batch' option , with one CSV file and a few moments you be able to complete the task

set group --batch <csvfilename> --format json --ignore-errors true

0 Kudos
Employee+
Employee+

Re: mgmt_cli - delete member from group ?

Jump to solution

You can use where-used and delete all references  .

I do not think that 'force' will be a good idea, you can create a scenario that you break the policy .

For groups, you can use 'remove'

groupsObject vCollection of group identifiers.
or
Object v
Parameter nameValueDescription
removestringRemoves from collection of values
or
List: string
or
string
or
List: string
0 Kudos
Admin
Admin

Re: mgmt_cli - delete member from group ?

Jump to solution

Nice one... I didn't catch that the first time.

Marc_Lampo
Nickel

Re: mgmt_cli - delete member from group ?

Jump to solution

Thanks for your help !

Interestingly enough the on-line API documentation does not mention "remove" as possibility ...

And I already found that adding "ignore-warnings true" to the "mgmt_cli delete network ..." does the trick.