logo
Free, unlimited AI code reviews that run on commit
git-lrc git-lrc GitHub Install Now We'd appreciate a star git-lrc - Free, unlimited AI code reviews that run on commit | Product Hunt git-lrc - Free, unlimited AI code reviews that run on commit | Product Hunt

px2_configure - deploy and configure Raritan PX2/PX3 power distribution units

Arguments

LIST
           Device list in CSV format.

       IPS Device IP addresses; use 'all' to run on all IPs in the CSV file.

       IP  Device IP address.

       OUTFILE
           Output file name.

       IMAGE
           Firmware image file.

       TZID
           Timezone ID as printed by the "print_timezones" command.

Commands

configureLISTIPS
           Configure some or all devices (network settings, unit name and SNMP settings).

           The  behavior  of  this  command is different depending on whether concrete IP addresses or the 'all'
           keyword is specified:

           • If IP addresses are specified the program will contact each device,  read  its  serial  number  and
             search  for  a matching entry in the device list. It will then change the device's network settings
             to the values from the device list. The initial IP addresses do not have to match the  values  from
             the device list, they might as well be dynamically assigned by a DHCP server.

           • If  the  'all'  keyword  is specified the IP addresses are taken from the device list. The devices'
             network settings are expected to be properly configured at this point, so the network configuration
             part will be skipped.

       verifyLISTIPS
           Verify device settings and SNMP access.

       identifyLISTIPS
           Identify some or all devices (show a distinctive string for two seconds in each unit's display).

       rebootLISTIPS
           Reboot some or all devices.

       fetch_fitnessLISTOUTFILEIPS
           Fetch fitness data from some or all devices and write them to a file in CSV format.

       updateLISTIMAGEIPS
           Device firmware update. The firmware image will be sequentially uploaded to  each  device,  then  all
           devices will be instructed to perform the firmware update in parallel.

       print_timezonesIP
           Print list of supported timezones with its IDs.

       set_timezoneLISTTZIDIPS
           Set the timezone of all devices.

Description

       PX2 deployment and configuration utility.

Device List Format

       The device list file contains a list of PX2 devices in CSV format. It could  e.g.  be  exported  from  an
       inventory spreadsheet. Each device line contains four or five fields, separated by commas:

       1. Unit serial number (exactly 10 characters)
       2. PDU name
       3. IP address with prefix length (e.g. 192.168.99.1/24)
       4. Gateway IP address
       5. Optional comment; the line is ignored if "ignore" is included here

       Lines with less than four fields are silently ignored. Likewise, lines that do not contain a valid serial
       number are disregarded.

Examples

px2_configureconfiguredevices.csv192.168.2.3
           Connect  to  the device at 192.168.2.3, read its serial number and look it up in the device list file
           named devices.csv. Configure the device's network, PDU name and SNMP settings.

       px2_configureverifydevices.csvall
           Verify the network settings, PDU name and SNMP access for all devices in the list file.

       px2_configureupdatedevices.csvpdu-px2-020106-26030.binall
           Update all devices to firmware version 2.1.6.

Name

       px2_configure - deploy and configure Raritan PX2/PX3 power distribution units

Requirements

       The following Perl modules are required to run this script:

       • Raritan PX2 RPC bindings (distributed along with this script)

       • libwww-perl <https://metacpan.org/release/libwww-perl>

       • LWP::Protocol::https <https://metacpan.org/release/LWP-Protocol-https>

       • JSON <https://metacpan.org/release/JSON>

       • JSON-RPC-Common <https://metacpan.org/release/JSON-RPC-Common>

       • perl-Error <https://metacpan.org/release/Error>

       • Test-Simple <https://metacpan.org/release/Test-Simple>

       Additionally, the verify command uses the snmpget utility to verify SNMP access.

perl v5.40.0                                       2024-11-17                                  px2_configure(1p)

Synopsis

       px2_configure COMMAND [ARGUMENTS]

See Also