GS1920-24HPv2 - Turn on & off PoE on ports by SNMP

IanCH
IanCH Posts: 2
First Comment Friend Collector

I have a APC BackUPS Pro UPS which powers a server, a PoE switch (GS1920-24HPv2), and a RaspPi running NUT (Network UPS Tools) to monitor the UPS.

When power goes off the NUT gracefully shuts the server down.

All is good.

However I'd like to get some more life from the UPS and I was thinking that when the power fails I could get the NUT to somehow tell the PoE switch to continue being a switch but turn off the PoE to the CCTV Cameras.

I tried to turn off the PoE on port17 using the below

snmpset -v2c -c public 192.168.1.1 1.3.6.1.2.1.105.1.1.1.3.17 i 2

But I get the following error

Error in packet.
Reason: notWritable (That object does not support modification)
Failed object: iso.3.6.1.2.1.105.1.1.1.3.17

Questions

  1. Can I not do this with SNMP?
  2. Is that the wrong OID?
  3. Is there another way I could do this?

Many thanks in advance

Accepted Solution

All Replies

  • Zyxel_Melen
    Zyxel_Melen Posts: 2,295  Zyxel Employee
    Zyxel Certified Network Engineer Level 1 - Switch Zyxel Certified Network Administrator - Switch Zyxel Certified Network Administrator - Nebula Zyxel Certified Sales Associate
    edited May 30 Answer ✓

    Hi @IanCH,

    I can turn on/off the PoE by the same O.I.D.

    Please help to check if you enable the SNMP function on the Service Access Control page (Path: Menu > Security > Access Control > Service Access Control)

  • IanCH
    IanCH Posts: 2
    First Comment Friend Collector

    Hi @Zyxel_Melen

    Thank you so much for the screen shots.

    Thanks to those I saw my mistake. I had the wrong OID

    I was doing the below for port 17

    snmpset -v2c -c public 192.168.1.1 1.3.6.1.2.1.105.1.1.1.3.17 i 2

    and should of been doing the below

    snmpset -v2c -c public 192.168.1.1 1.3.6.1.2.1.105.1.1.1.3.1.17 i 2

    The OID being 1.3.6.1.2.1.105.1.1.1.3.1.portNo

    Regards