siege is a HTTP benchmark tool, which I have already used in the past to run a HTTP stress-test on a web-application.
While stress-testing a local Nginx and the application behind it, I ran into a cryptic error:
root@webserver:~# siege -b --concurrent=100 -H "Host: app.example.com" https://localhost:443 -t 60S
[error] socket: unable to connect sock.c:282: Connection refused
[error] socket: unable to connect sock.c:282: Connection refused
[error] socket: unable to connect sock.c:282: Connection refused
[...]
{ "transactions": 0,
"availability": 0.00,
"elapsed_time": 0.15,
"data_transferred": 0.00,
"response_time": 0.00,
"transaction_rate": 0.00,
"throughput": 0.00,
"concurrency": 0.00,
"successful_transactions": 0,
"failed_transactions": 1123,
"longest_transaction": 0.00,
"shortest_transaction": 0.00
}
The reason for the error is not really shown, but "socket" is a hint. A comment in issue #176 on the siege GitHub repository confirms the hint: The error only happens when using localhost as address. When using the lo IP instead (127.0.0.1), siege does its benchmark as expected:
root@webserver:~# siege -b --concurrent=100 -H "Host: app.example.com" https://127.0.0.1:443 -t 60S
{ "transactions": 115,
"availability": 3.03,
"elapsed_time": 4.83,
"data_transferred": 67.66,
"response_time": 2.72,
"transaction_rate": 23.81,
"throughput": 14.01,
"concurrency": 64.79,
"successful_transactions": 100,
"failed_transactions": 3685,
"longest_transaction": 3.37,
"shortest_transaction": 0.01
}
No comments yet.
AWS Android Ansible Apache Apple Atlassian BSD Backup Bash Bluecoat CMS Chef Cloud Coding Consul Containers CouchDB DB DNS Database Databases Docker ELK Elasticsearch Filebeat FreeBSD Galera Git GlusterFS Grafana Graphics HAProxy HTML Hacks Hardware Icinga Influx Internet Java KVM Kibana Kodi Kubernetes LVM LXC Linux Logstash Mac Macintosh Mail MariaDB Minio MongoDB Monitoring Multimedia MySQL NFS Nagios Network Nginx OSSEC OTRS Office OpenSearch PGSQL PHP Perl Personal PostgreSQL Postgres PowerDNS Proxmox Proxy Python Rancher Rant Redis Roundcube SSL Samba Seafile Security Shell SmartOS Solaris Surveillance Systemd TLS Tomcat Ubuntu Unix VMWare VMware Varnish Virtualization Windows Wireless Wordpress Wyse ZFS Zoneminder