# phpman > man > snmpset(1)

> **TLDR:** Set a value using the SNMP protocol.
>
- Set a value:
  `snmpset -v {{version}} -c {{community}} {{ip_address}} {{oid}} {{value_type}} {{value}}`
- Display help:
  `snmpset {{-h|--help}}`

*Source: tldr-pages*

---

[SNMPSET(1)](https://www.chedong.com/phpMan.php/man/SNMPSET/1/markdown)                                    Net-SNMP                                    [SNMPSET(1)](https://www.chedong.com/phpMan.php/man/SNMPSET/1/markdown)



## NAME
       snmpset - communicates with a network entity using SNMP SET requests

## SYNOPSIS
       **snmpset** [COMMON OPTIONS] AGENT OID TYPE VALUE [OID TYPE VALUE]...

## DESCRIPTION
       **snmpset** is an SNMP application that uses the SNMP SET request to set information on a network
       entity.  One or more object identifiers (OIDs) must be given  as  arguments  on  the  command
       line.   A  type  and  a value to be set must accompany each object identifier.  Each variable
       name is given in the format specified in [_variables(5)](https://www.chedong.com/phpMan.php/man/variables/5/markdown)_.

       The _TYPE_ is a single character, one of:
              **i**  INTEGER
              **u**  UNSIGNED
              **s**  STRING
              **x**  HEX STRING
              **d**  DECIMAL STRING
              **n**  NULLOBJ
              **o**  OBJID
              **t**  TIMETICKS
              **a**  IPADDRESS
              **b**  BITS
       Most of these will use the obvious corresponding ASN.1 type.  's', 'x', 'd' and 'b'  are  all
       different  ways  of  specifying an OCTET STRING value, and the 'u' unsigned type is also used
       for handling Gauge32 values.

       If you have the proper MIB file loaded, you can, in most cases, replace the type with an  '='
       sign.  For  an  object of type OCTET STRING this will assume a string like the 's' type nota‐
       tion. For other types it will do "The Right Thing".

       For example:

       snmpset -c private -v 1 test-hub system.sysContact.0 s <dpz@noc.rutgers.edu>  ip.ipforwarding.0
       = 2

       will set the variables sysContact.0 and ipForwarding.0:

       system.sysContact.0 = STRING: "<dpz@noc.rutgers.edu>"
       ip.ipForwarding.0 = INTEGER: [not-forwarding(2)](https://www.chedong.com/phpMan.php/man/not-forwarding/2/markdown)

       If the network entity has an error processing the request packet, an error packet will be re‐
       turned and a message will be shown, helping to pinpoint in what  way  the  request  was  mal‐
       formed.

## OPTIONS
       **snmpset**  takes the common options described in the [_snmpcmd(1)](https://www.chedong.com/phpMan.php/man/snmpcmd/1/markdown)_ manual page.  Note that **snmpset**
       REQUIRES  an argument specifying the agent to query and at least one  set  of  OID/type/value
       arguments, as described in there.

## SEE ALSO
       [snmpcmd(1)](https://www.chedong.com/phpMan.php/man/snmpcmd/1/markdown), [variables(5)](https://www.chedong.com/phpMan.php/man/variables/5/markdown).



V5.9.1                                       19 Jun 2003                                  [SNMPSET(1)](https://www.chedong.com/phpMan.php/man/SNMPSET/1/markdown)
