Jon Posted July 2, 2011 Share Posted July 2, 2011 I would like to test my database search page which has 3 options that I pass using GET i.e. exact phrase, each word and exclude words. Can anyone tell me how I can do this with Apachebench. Entering the url doesn't work. Link to comment Share on other sites More sharing options...
Jon Posted July 2, 2011 Author Share Posted July 2, 2011 I would like to test my database search page which has 3 options that I pass using GET i.e. exact phrase, each word and exclude words. Can anyone tell me how I can do this with Apachebench. Entering the url doesn't work. With a bit of trial and error I have found the answer which I have put below for anyone else who may have this question. The answer is to use the -C cookie option. This example submits 200 requests. I searched for the word "moore" using the exact phrase field (ep is exact phrase) and the other two parameters ew and ex were not used. For testing on your own server the normal URL following the http:// might be: localhost/search.php?ep=moore&ew=&ex=&submit=Start+Search!&submitted=TRUE The Apachebench command is: ab -n 200 -C "ep=moore; ew=; ex=; submit=Start+Search!; submitted=TRUE;" http://localhost/search.php Link to comment Share on other sites More sharing options...
Recommended Posts