ndt-server

command module
v0.10.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 17, 2019 License: Apache-2.0 Imports: 21 Imported by: 0

README

GoDoc Build Status Coverage Status Go Report Card

ndt-server

This repository contains a ndt5 and ndt7 server written in Go. This code may compile under many systems, including macOS and Windows, but is specifically designed and tested for running on Linux 4.17+.

To run the server locally, generate local self signed certificates (key.pem and cert.pem) using bash and OpenSSL

./gen_local_test_certs.bash

build the docker container for ndt-server

docker build . -t ndt-server

prepare the runtime environment

install -d certs data
mv key.pem cert.pem certs

enable BBR (with which ndt7 works much better)

sudo modprobe tcp_bbr

and run the ndt-server binary container

docker run --network=bridge                \
           --publish 443:4443              \
           --volume `pwd`/certs:/certs:ro  \
           --volume `pwd`/data:/data       \
           --read-only                     \
           --user `id -u`:`id -g`          \
           --cap-drop=all                  \
           ndt-server                      \
           -cert /certs/cert.pem           \
           -key /certs/key.pem             \
           -datadir /data                  \
           -ndt7_addr :4443

Once you have done that, you should have a ndt5 server running on ports 3001 (legacy binary flavour), 3002 (WebSocket flavour), and 3010 (secure WebSocket flavour); a ndt7 server running on port 443 (over TLS and using the ndt7 WebSocket protocol); and Prometheus metrics available on port 9990.

Try accessing these URLs in your browser (for URLs using HTTPS, certs will appear invalid to your browser, but everything is safe because this is a test deployment, hence you should ignore this warning and continue):

Replace localhost with the IP of the server to access them externally.

Documentation

The Go Gopher

There is no documentation for this package.

Directories

Path Synopsis
Package bbr contains code required to read BBR variables of a net.Conn on which we're serving a WebSocket client.
Package bbr contains code required to read BBR variables of a net.Conn on which we're serving a WebSocket client.
cmd
ndt-client command
Package fdcache contains a mechanism to obtain the file descriptor bound to a websocket.Conn.
Package fdcache contains a mechanism to obtain the file descriptor bound to a websocket.Conn.
Package logging contains data structures useful to implement logging across ndt-server in a Docker friendly way.
Package logging contains data structures useful to implement logging across ndt-server in a Docker friendly way.
c2s
ndt
s2c
web100
Package web100 provides web100 variables (or a simulation thereof) to interested systems.
Package web100 provides web100 variables (or a simulation thereof) to interested systems.
ws
ndt7
download
Package download implements the ndt7/server downloader.
Package download implements the ndt7/server downloader.
download/measurer
Package measurer contains the downloader measurer
Package measurer contains the downloader measurer
download/receiver
Package receiver implements the counter-flow messages receiver.
Package receiver implements the counter-flow messages receiver.
download/sender
Package sender implements the download sender.
Package sender implements the download sender.
handler
Package handler implements the WebSocket handler for ndt7.
Package handler implements the WebSocket handler for ndt7.
listener
Package listener provides generic functions which extend the capabilities of the http package.
Package listener provides generic functions which extend the capabilities of the http package.
model
Package model contains the ndt7 data model
Package model contains the ndt7 data model
results
Package results contains server results
Package results contains server results
saver
Package saver contains the code for saving results.
Package saver contains the code for saving results.
spec
Package spec contains constants defined in the ndt7 specification.
Package spec contains constants defined in the ndt7 specification.
upload
Package upload implements the ndt7 upload
Package upload implements the ndt7 upload
Package platformx contains platform specific code
Package platformx contains platform specific code
Package tcpinfox helps to gather TCP_INFO statistics.
Package tcpinfox helps to gather TCP_INFO statistics.
Package version contains ndt-server version
Package version contains ndt-server version

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL