LinuxCommandLibrary

gnmic-set

Set configuration value

TLDR

Set configuration value

$ gnmic set -a [router:57400] --update-path [/system/name] --update-value "[router1]"
copy
Delete configuration
$ gnmic set -a [router:57400] --delete [/interfaces/interface[name=eth1]]
copy
Set from file
$ gnmic set -a [router:57400] --update-path [/] --update-file [config.json]
copy
Replace configuration
$ gnmic set -a [router:57400] --replace-path [/interfaces] --replace-file [interfaces.json]
copy

SYNOPSIS

gnmic set [options]

DESCRIPTION

gnmic set modifies configuration on gNMI-enabled devices. It supports update (merge), replace, and delete operations on configuration data.
The command can set individual values or apply entire configuration files. It's used for network automation and configuration management.
gnmic set writes configuration to network devices via gNMI.

PARAMETERS

-a ADDRESS

Target address.
--update-path PATH
Path to update.
--update-value VALUE
Value to set.
--update-file FILE
Value from file.
--delete PATH
Path to delete.
--replace-path PATH
Path to replace.
--help
Display help information.

CAVEATS

Changes may require commit on some devices. Invalid config may be rejected. Test in lab first.

HISTORY

gnmic set is a subcommand of gnmic, the gNMI client created by Nokia.

SEE ALSO

gnmic(1), gnmic-get(1)

Copied to clipboard