testdevelocidad.jpg

Si dispones de un servidor y quieres hacer un test de velocidad desde éste, ya sea porque notas que las descargas de las webs que aloja no lo hacen a la velocidad que deben, o simplemente te apetece hacerlo para comprobarlo, tu herramienta ideal esspeedtest-cli.

Esta herramienta utiliza los tests de la web speedtest.net, aunque sin necesidad de disponer de una interfaz gráfica o Flash para ejecutarlo, algo que no es habitual tener en un servidor web.

Instalación

El procedimiento de instalación en Ubuntu Server y Ubuntu Desktop o derivados es muy sencillo, y se compone de dos pasos.

El primero es instalar python-pip que nos permitirá manejar e instalar paquetes de software escritos en Python, para lo cual utilizaremos esta instrucción:

sudo apt-get install python-pip

Como segundo y último paso simplemente debemos ejecutar la siguiente orden para completar el proceso:

sudo pip install speedtest-cli

Cómo usarlo

Una ve instalado bastará con ejecutarlo:

speedtest-cli

El resultado será algo similar a esto donde aparecerá la IP pública de vuestra máquina o red:

angel@server:~$ speedtest-cli
 Retrieving speedtest.net configuration...
 Retrieving speedtest.net server list...
 Testing from Mi proveedor (1.1.1.1)...
 Selecting best server based on latency...
 Hosted by Vodafone PT (Porto) [127.37 km]: 90.425 ms
 Testing download speed........................................
 Download: 2.54 Mbits/s
 Testing upload speed..................................................
 Upload: 0.53 Mbits/s

Si queremos personalizar el test, como por ejemplo generar una imagen del test para compartir el resultado, o ver la lista de los servidores disponibles para hacer el test y seleccionarlo para ello, podemos comprobar las diferentes opciones de configuración con:

speedtest-cli -h
usage: speedtest-cli [-h] [--bytes] [--share] [--simple] [--list]
                     [--server SERVER] [--mini MINI] [--source SOURCE]
                     [--version]

Command line interface for testing internet bandwidth using speedtest.net.
--------------------------------------------------------------------------

https://github.com/sivel/speedtest-cli

optional arguments:
  -h, --help       show this help message and exit
  --bytes          Display values in bytes instead of bits. Does not affect
                   the image generated by --share
  --share          Generate and provide a URL to the speedtest.net share
                   results image
  --simple         Suppress verbose output, only show basic information
  --list           Display a list of speedtest.net servers sorted by distance
  --server SERVER  Specify a server ID to test against
  --mini MINI      URL of the Speedtest Mini server
  --source SOURCE  Source IP address to bind to
  --version        Show the version number and exit

Por si no lo habías tenido en cuenta, puedes utilizar esta herramienta tanto en un servidor con Ubuntu, Debian, Red Hat o CentOS como en el equipo de casa o la oficina, lo que te permitirá hacer test de una forma rápida y sencilla.

 

Fuente: nosinmiubuntu

¿Quién está en línea?

Hay 42051 invitados y ningún miembro en línea