Run Script on Discovery during ZTP+ process

  • 0
  • 2
  • Question
  • Updated 3 months ago
  • Answered
  • (Edited)
Dear all.

I have a question about running a script during ZTP+ process.

NetSight 8.0.4.54
EXOS 22.3.1.4 Patch 4

We want to deploy ZTP+ functionality. The overall process is working fine.
Devices are discovered. Firmware is updated and the devices are integrated automaticaly to the correct site in EMC.

What I want, is that a new device gets a special basic configuration after it is discovered.
In the settings for every site in the menu "Discovered Device Actions" you can add a script.

I can add the script, but it is not executed. I did not find some detailed information in any manual about this functionality.
So can anyone help me here to get this running!?

thanks and best regards
Alex






Photo of aloeffle

aloeffle

  • 980 Points 500 badge 2x thumb

Posted 1 year ago

  • 0
  • 2
Photo of Pala, Zdenek

Pala, Zdenek, Employee

  • 10,186 Points 10k badge 2x thumb
Hi,

save the script as JSON-RPC and you should be good.

Z.
Photo of aloeffle

aloeffle

  • 980 Points 500 badge 2x thumb
Hi Z.

thanks for your fast reply. I did so, but without success.
Can you please give me more details!?

I also checked the event log. It seems that the script is not executed at all. Neither CLI nore JSON-RPC.



regards
Alex
Photo of Grosjean, Stephane

Grosjean, Stephane, Employee

  • 13,676 Points 10k badge 2x thumb
Hi,

it should work with any script. How do you create your script? It needs to be valid.
Photo of aloeffle

aloeffle

  • 980 Points 500 badge 2x thumb
Hello Stephane.

thanks for your help

I create the script by
Administration ->Scripting -> Scripts -> Add ...

If I run this script manualy on a device, it is working.
To avoid script errors, I only configure a sysname in my test lab.

configure snmp sysname "ingolstadt"

regards
Alexander
(Edited)
Photo of Ali Aropaltio

Ali Aropaltio

  • 72 Points
Hi, 

I've encountered the same issue with 8.1.2.59 in a case with a customer. Here were my findings related to ZTP+ and Custom Scripts:

Troubleshooting: - Tested two different 8.1.2.59 versions with the same scenario: 
1. ZTP+ - device pre-registered -> scripts won't run 
2. ZTP+ - device not pre-registered -> scripts will run after configuration in discovered tab 

Switch 220-12p-10GE2, version 1.2.2.3

I've opened a GTAC case for this and let you know about the findings later on.

(Edited)
Photo of Ali Aropaltio

Ali Aropaltio

  • 72 Points
Tested today with 8.1.3.65 and the problem still presists.