Use lr_get_vuser_ip() function in the Vuser script
Note: This function is a part of function reference in LR 7.x but was undocumented in LR 6.5
Use the lr_get_vuser_ip() function within a lr_output_message() function in the vuser_init() section. This function will return the Vuser IP address as a C string. For example,
lr_output_message("Vuser IP -> %s", lr_get_vuser_ip());
This is advantageous because you can now use the Vusers output log of errors and its IP in conjunction with the Web server logs (which should list IP addresses) to track down errors faster and more accurately.
To have the IP address show in the Controller Vuser Status field, use the function
lr_vuser_status_message("Vuser IP -> %s", lr_get_vuser_ip());