I need to run some scripts that are located on my target servers. This must be done when I run the tests against my environment. These scripts are on my servers so I need to start them from the load Generators. Is it possible within NeoLoad?
NeoLoad allows to use custom code based on Javascript and JAVA code. This allows you to execute some commands on the Load generators.
By doing that, you could run script that will automatically connect to your target servers. This is an example of what could be done but of course it can be customized to suit your environment and your needs.
Create a NeoLoad Javascript in your script. This Javascript will launch a batch file located in the load generator hard drive.
This is the code example:
process=java.lang.Runtime.getRuntime().exec("d:\\NeoLoad\\Execute\\call_unix.bat");
“call_unix.bat” is the script located on your load generators.
Now this “call_unix.bat” can contain a simple SSH command to connect to a remote Unix server and to automatically launch a command. This batch could contain this:
D:\tools\Putty\plink.exe -l unix_username -pw unix_password Unix-IP-address /home/neoload/script/NeoLoad_calling.sh
Using “plink” you can connect using SSH, provide the credentials and run a specific command like “NeoLoad_calling.sh”.
For more information, see “NeoLoad Javascript API” under “Appendixes” section in NeoLoad documentation.