ip spoofing not working jmeter - jmeter

I am trying IP spoofing in JMeter HTTP requests but my public IP is going to the request, not the IP address which I have specified under advanced option in HTTP sampler. can anyone help me in this?
I am also sharing the screenshot of my test plan.
here
In my test plan my let's say my IP is x.x.x.x and the IP which I have configured for IP spoofing is: 192.168.23.12 as shown in the screenshot but request to the server is still going with my IP which is x.x.x.x.
Can anyone help me out in this?

As per HTTP Request sampler documentation
Source address field [Only for HTTP Request with HTTPClient implementation]
So change "Implementation" to HttpClient4 and it should start working as expected.
Also be aware that you need to have this IP address (or alias) defined in the underlying operating system.
See Using IP Spoofing to Simulate Requests from Different IP Addresses with JMeter article for more information and configuration instructions for different operating systems.

Please check the below test plan:-

Related

JMeter with 20000 threads and multi-home network

In the scenario where you're running a single Linux instance of jmeter with 20000 threads and 4 ip addresses, would jmeter (HttpClient4) use all ports in all 4 IP addresses for http connections, or is it restricted to one IP choosen by jmeter (In Linux machine) ?
Thanks
JMeter will stick to a single IP address by default, if you want to distribute the outgoing connections between all 4 IP addresses you will need to put them into a CSV file and use CSV Data Set Config to read it so each thread (virtual user) would choose a new source address on each iteration.
The source IP address can be set at "Advanced" tab of the HTTP Request sampler (or HTTP Request Defaults)
See Using IP Spoofing to Simulate Requests from Different IP Addresses with JMeter article for more information.

IP SPOOFING concept in Distributed load testing Jmeter

I am trying to invoke distributed load testing with jmeter (Which have 3 ips in it) and it is running in only one ip. Will other ips also run in the background or they won't even start?
If you have a Distributed JMeter Test architecture with 1 master and 3 slaves my expectation is that each JMeter slave has its own IP address so you should see requests coming from 3 different IPs to the system under test.
If you need to mimic more IP addresses - there is "Source address" section which lives under "Advanced" tab of the HTTP Request sampler where you can specify the desired outgoing IP address.
But be aware that the IP address (or its alias) must exist on the operating system level in order to be used at this field so you need to ensure that all source IP addresses you're going to use exist and are usable by JMeter.
Check out Using IP Spoofing to Simulate Requests from Different IP Addresses with JMeter for comprehensive information and example configurations

JMeter can I run it locally?

In my opinion, load tests should be performed from several different IP addresses simultaneously(because of restrictions on http). Am I right?
I will do load tests for:
Number of Threads (users): 2000
Ramp-Up Period (in seconds): 10
The load doesn't necessarily have to come from different IP addresses however depending on your application nature it might be required (for example application does explicit check of origin IP address or lives behind a load balancer with session stickiness based on IP addresses or whatever)
In this case you can perform IP spoofing so each request would come from the different IP address, you can configure source IP address under "Source address" input on the "Advanced" tab of the HTTP Request sampler
See Using IP Spoofing to Simulate Requests from Different IP Addresses with JMeter for more details.
Yes you can run JMeter locally, it can be run anywhere that has a Java Virtual Machine.
Another alternative if you are interested is Gatling http://gatling.io/
To perform load test in serveral different IP address use Jmeter remote test
control multiple, remote JMeter engines from a single JMeter client. By running JMeter remotely, you can replicate a test across many low-end computers and thus simulate a larger load on the server.

How to use multiple proxy with JMeter

I have a load balancer and I want to test the performance of the load balancer. I am using Apache JMeter to test the load balancer. I need to change my IP address so that the client IP is always different. My uni doesn't allow me to add multiple IP addresses (IP spoofing / IP alias).
So, the other option is to use a proxy server. Is there a way to use 2 or more proxy server in JMeter at one go? I can only specify one proxy server at a time at the moment.
Is there a way to turn it around?
You can use "Server name /IP" configuration in "HTTP Request" sampler. But those IPs should belong to same network. You cant set jmeter with different Geo locations.

jMeter source address not working

When source address field is empty, all runs fine. When I put in an IP, even if it is my actual IP, I get an error:
Response code: Non HTTP response code: java.net.SocketException
Response message: Non HTTP response message: Network is unreachable: connect
I run Windows... Also I have already tried all the Implementations.
There should be few pre-requisites met:
You need to have HTTPClient implementation (see HTTP Request sampler documentation)
Source address field[Only for HTTP Request with HTTPClient implementation]
In case of single IP address:
The IP address needs to be available in the underlying operating system, it may be either IP associated with NIC or an IP alias
Relevant Source address type needs to be specified, in case of single IP it should be IP/Hostname
See Using IP Spoofing to Simulate Requests from Different IP Addresses with JMeter guide for more detailed information on the domain.

Resources