1

I have been testing HTTP request for the URL: www.google.com and getting unknown host error in jmeter.

HTTP REQUEST PAGE[![][1]

Farhana Naaz Ansari
  • 7,524
  • 26
  • 65
  • 105
Durairaj s
  • 193
  • 3
  • 13

2 Answers2

1

The error means that JMeter cannot resolve the IP address of google.com website. Most probably this is due to your network settings, i.e. your machine uses a corporate proxy in order to access the Internet.

Contact your network administrator in order to obtain the required proxy settings (hostname, port, username and password) and configure JMeter to use the proxy server to access external resources, i.e. launch it as:

jmeter -H your_proxy_host -P your_proxy_port -u your_proxy_username -a your_proxy_password

Apart from the above:

  1. Don't load test public resources without explicit permission of their owner as your actions might be considered as DoS attack and your IP address might become blacklisted. So use something from your Intranet instead of Google, this way you will kill 2 birds with one stone:

    • you will not need to configure proxy
    • your actions will be clear from the law perspective

    if you don't have anything you can test in your Intranet you can consider using special websites like blazedemo.com or newtours.demoaut.com

  2. According to JMeter Best Practices you should always be using the latest available JMeter version so consider upgrading to JMeter 5.0 (or whatever is the current version available at JMeter Downloads page)

Dmitri T
  • 159,985
  • 5
  • 83
  • 133
1

It is easy to make such mistakes when you congfigurate HTTP Request in the JMeter UI.

Suppose now you want to test this URL: https://www.your_host.com/your_path/, you should split this URL into different parts and put them into corresponding JMeter's fields repectively.

  • Protocol[http]: https (red marker)
  • Server Name or IP: www.your_host.com (blue marker)
  • Path: /your_path (yellow marker)

NOTE: DONT put your complete URL in the "Server Name or IP". enter image description here

Ivan Xue
  • 879
  • 6
  • 9