In this post, How to benchmark a website with the Siege command line. Use Siege command to benchmark a Website.
siege command support both the HTTP/1.0 and 1.1 protocols, GET an POST ...
Requirements
- Running instance of Ubuntu Server.
- A user with sudo privileges.
- A Website to test.
Install Siege
Login Ubuntu server, Open a terminal to install Siege.
sudo apt-get install siege -y
After install, You need enable logging.
sudo nano /etc/siege/siegercBefore
#logfile = $(HOME)/var/log/siege.logAfter change
logfile = $(HOME)/var/log/siege.log
Save and close the file.
How to perform a test.
Example, we run a 5-minute and concurrent user load is 100.
siege https://SERVER -c 100 -t 5m
Where SERVER is the IP address or domain website for test.
The output terminal as below:
If you want to save log. You need run command below:
siege https://SERVER -c 100 -t 5m -l
How to test multiple site
You need test numerous sites at once. You need create a file with list a website.
nano ~/huuphan-sites.txt
Add domain or IP address for test
www.example.orgsave and close the file.
192.168.3.7
Run command as below:
siege -f ~/huuphan-sites.txt
Thanks for reading Siege command to benchmark a Website My blog Zimbra Mail Server,linux,bash script,centos,linux command I hope this is useful.