Git Product home page Git Product logo

crusader's People

Contributors

richb-hanover avatar zoxc avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

crusader's Issues

How to debug time out issue?

I have no issues running Crusader within the home network, with both IPv4 and IPv6).
For example, the following is the run log with IPv6.

But now I would like to test over the internet. But it crashed due to time out issues.

Crusader version: v0.0.10-testing

Server: Ubuntu 22.04 Proxmox PVE 8.0 LxC container (Intel N100 mini PC connected to Asus RT-AX86U router 2.5G LAN port), port forward done in the Asus router.

Client: Windows 11 x84 using wireless (Acer Windows 11 laptop with Intel AX201 WiFi 6 adapter, connected to another wireless router over another home network). I have tried Linux client as well and the problem is the same.

Example run log for Windows 11 x64.

PS C:\work\speedtest\crusader-x86_64-pc-windows-msvc> .\crusader.exe test xxxxxxxxx.asuscomm.com
Connected to server 219.75.xxx.xxx:35481
Latency to server 3.61 ms
thread 'thread 'thread 'thread 'thread 'tokio-runtime-workerthread 'thread 'thread 'tokio-runtime-workertokio-runtime-workertokio-runtime-workertokio-runtime-worker' panicked at tokio-runtime-workertokio-runtime-workertokio-runtime-worker' panicked at ' panicked at ' panicked at ' panicked at crusader-lib\src\test.rs' panicked at ' panicked at ' panicked at crusader-lib\src\test.rscrusader-lib\src\test.rs:crusader-lib\src\test.rscrusader-lib\src\test.rs:crusader-lib\src\test.rs::crusader-lib\src\test.rs:crusader-lib\src\test.rs947::947947947947947:947::::::22:22222222:
:
:
22947:
22unable to bind TCP socket: Os { code: 10060, kind: TimedOut, message: "A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond." }:

unable to bind TCP socket: Os { code: 10060, kind: TimedOut, message: "A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond." }stack backtrace:
:unable to bind TCP socket: Os { code: 10060, kind: TimedOut, message: "A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond." }:
unable to bind TCP socket: Os { code: 10060, kind: TimedOut, message: "A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond." }unable to bind TCP socket: Os { code: 10060, kind: TimedOut, message: "A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond." }:

22
unable to bind TCP socket: Os { code: 10060, kind: TimedOut, message: "A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond." }

unable to bind TCP socket: Os { code: 10060, kind: TimedOut, message: "A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond." }:


unable to bind TCP socket: Os { code: 10060, kind: TimedOut, message: "A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond." }
   0:     0x7ff775dfec83 - <unknown>
   1:     0x7ff775e19eed - <unknown>
   2:     0x7ff775dfb7d1 - <unknown>
   3:     0x7ff775dfea8a - <unknown>
   4:     0x7ff775e00b79 - <unknown>
   5:     0x7ff775e0083b - <unknown>
   6:     0x7ff775e01064 - <unknown>
   7:     0x7ff775e00f35 - <unknown>
   8:     0x7ff775dff319 - <unknown>
   9:     0x7ff775e00c44 - <unknown>
  10:     0x7ff775e42277 - <unknown>
  11:     0x7ff775e42733 - <unknown>
  12:     0x7ff775d15d99 - <unknown>
  13:     0x7ff775d4781f - <unknown>
  14:     0x7ff775da0531 - <unknown>
  15:     0x7ff775d9faee - <unknown>
  16:     0x7ff775d9f169 - <unknown>
  17:     0x7ff775d9b6ed - <unknown>
  18:     0x7ff775da3941 - <unknown>
  19:     0x7ff775d95adb - <unknown>
  20:     0x7ff775d8eaef - <unknown>
  21:     0x7ff775d8ef75 - <unknown>
  22:     0x7ff775e0592c - <unknown>
  23:     0x7ffa67cb257d - BaseThreadInitThunk
  24:     0x7ffa698aaa58 - RtlUserThreadStart

Build fail against unstable crusader lib

sudo apt update && sudo apt upgrade -y
sudo apt install build-essential -y
sudo apt install cargo -y
sudo snap install rustup --classic
sudo rustup toolchain install nightly
sudo rustup run nightly rustc --version
sudo rustup default nightly
sudo rustup update
git clone https://github.com/Zoxc/crusader.git
cd /home/xxxx/crusader/src
sudo cargo build --release```

# Followed the guidelines and use a nightly build of rust; from the 'note' message below.  Any guidance please.

Compiling crusader-lib v0.0.9 (/home/xxxx/crusader/src/crusader-lib)
error[E0658]: use of unstable library feature 'bool_to_option'
  --> crusader-lib/src/serve.rs:236:73
   |
236 | ...                   (client.ip == ip_to_ipv6_mapped(addr.ip())).then_some(client)
   |                                                                   ^^^^^^^^^
   |
   = note: see issue #80967 <https://github.com/rust-lang/rust/issues/80967> for more information

error[E0658]: use of unstable library feature 'bool_to_option'
  --> crusader-lib/src/serve.rs:498:64
   |
498 |                     (ip_to_ipv6_mapped(src.ip()) == client.ip).then_some((client, ping))
   |                                                                ^^^^^^^^^
   |
   = note: see issue #80967 <https://github.com/rust-lang/rust/issues/80967> for more information

For more information about this error, try `rustc --explain E0658`.
error: could not compile `crusader-lib` due to 2 previous errors
warning: build failed, waiting for other jobs to finish...

Tweaks to logging

Using crusader 0.0.10 on macOS, I see the following log messages when I run the server:

Server running...
Serving 192.168.253.110:60233, version 3
Serving complete for 192.168.253.110:60233
Serving 192.168.253.110:60337, version 3
Serving complete for 192.168.253.110:60337

A couple requests:

  1. Add a date/time on each line so that people can disambiguate any tests they performed
  2. In the Server running... message, it would be good to display the version number (e.g. Server 0.0.10 running...)
  3. It might be useful to include the same info in the client CLI version
  4. And also in the logs output by the crusader-gui

Many thanks!

How are latencies in Up- and Downlink measured?

First of all, a big thanks for this great software, which works really nice!

In the graphs, the latency for Up and Down is shown.
I'm wondering how this is done considering that client and server are usually different machines with unsynchronized clocks?

How to get rid of the warning message about Load termination timed out.?

Sometimes I will get the following warning, when testing wireless.

Warning: Load termination timed out. There may be residual untracked traffic in the background.

Just wondering if this is a real issue or not. If it is a real issue, how do I debug and get rid of the warning? Thanks.
Crusader version: v0.0.10-testing
Local wireless test: Asus RT-AX86U (no QoS settings enabled)
Server -- Proxmox PVE 8.0 LxC container (Ubuntu 22.04), connected to RT-AX86U 2.5G LAN port
Client -- Acer Windows 11 machine (2021 model) , Intel AX201 WiFi 6 adapter.

PS C:\work\speedtest\crusader-x86_64-pc-windows-msvc> .\crusader.exe test 192.168.50.12
Connected to server 192.168.50.12:35481
Latency to server 1.93 ms
Testing download...
Testing upload...
Testing both download and upload...
Warning: Load termination timed out. There may be residual untracked traffic in the background.
Writing data...
Saved raw data as data 2024.03.25 08-01-18.crr
Saved plot as plot 2024.03.25 08-01-18.png

PS C:\work\speedtest\crusader-x86_64-pc-windows-msvc> .\crusader.exe test 192.168.50.12
Connected to server 192.168.50.12:35481
Latency to server 1.60 ms
Testing download...
Testing upload...
Testing both download and upload...
Warning: Load termination timed out. There may be residual untracked traffic in the background.
Writing data...
Saved raw data as data 2024.03.25 08-02-09.crr
Saved plot as plot 2024.03.25 08-02-09.png

2F8euCz
dOuTjqs

Warn if no server running

I got the following error message when I ran the client without a server running at the other end.

A simple "No server seems to be running at <ip-address>" would suffice

?134 release % ./crusader test 192.168.253.128
thread 'main' panicked at 'called `Result::unwrap()` on an `Err` value: Os { code: 61, kind: ConnectionRefused, message: "Connection refused" }', crusader-lib/src/test.rs:1304:10
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
zsh: abort      ./crusader test 192.168.253.128

Docker build

I made a docker build script so one can do a quick deploy on a server for easier testing.
Dockerfile.txt
one flaw with this as is, the cargo build script wants to build gui side also and I didn't see how to tell it to not without a manual edit.
as such I included a cargo update line so if someone edits the build list it builds without throwing errors.

Feature proposal

Maybe the run time of the test could be made configurable? Often tests of longer durations like 0.5-10 minutes (so considerably longer than the typical 10-20 seconds for online speedtests) can be quite revealing and show e.g. things that cyclically affect throughput or latency (like an WiFi AP's channel scans say every 10 seconds).

What is crusader's "version"?

I was trying to replicate the IPv6 crash in #9, and wasn't sure about which commit I was using for my tests. So I set about to re-run my test, and wasn't sure which version I had.

I started looking around the repo (latest is commit a89abd2) and found these files that might have the correct "version" for Crusader:

  • README - currently shows 0.0.9
  • android/Cargo.toml - currently shows 0.1.0
  • src/crusader/Cargo.toml - currently shows 0.0.9
  • src/crusader-gui/Cargo.toml - currently shows 0.1.0
  • src/crusader-gui-lib/Cargo.toml - currently shows 0.1.0
  • src/crusader-lib/Cargo.toml - currently shows 0.0.10

Which should be regarded as "the correct version" for crusader? A unified version number policy would also address part of #13.

Many thanks.

Support specifying plot title

Thank you for this awesome tool!

Would it be possible to support specifying a plot title? Primary use case being to easily differentiate between changes in wireless or router settings between test runs. Sure we can use different file names, but if we upload results to something like the OpenWRT forums, the filename is effectively lost and the exact settings used aren't communicated on the actual graph.

This feature would match flent's current capability as well.

Comparing Crusader plots to Flent

[Not really a crusader bug report]

In #6 (comment), @dtaht wrote:

And see how weird the up+down test is? What's the link?

Dave: Could you explain what you're seeing in this plot? What do you see there? What did you expect?

Also: And I just created the second plot. Any surprises there? Many thanks.

From #6
image

From richb-hanover test
plot 2024 01 11 07-58-58

which rus version is required

I just tried to update to the newest version:

bash-3.2$ git pull
remote: Enumerating objects: 250, done.
remote: Counting objects: 100% (250/250), done.
remote: Compressing objects: 100% (134/134), done.
remote: Total 250 (delta 177), reused 180 (delta 107), pack-reused 0
Receiving objects: 100% (250/250), 446.88 KiB | 16.55 MiB/s, done.
Resolving deltas: 100% (177/177), completed with 15 local objects.
From https://github.com/Zoxc/crusader
   c2b50ad..bba1768  master     -> origin/master
 * [new branch]      test       -> origin/test
 * [new tag]         v0.0.7-testing -> v0.0.7-testing
Updating c2b50ad..bba1768
Fast-forward
 android/Cargo.lock                                        |  22 +++---
 android/Cargo.toml                                        |   3 +-
 android/app/src/main/java/zoxc/crusader/MainActivity.java |  12 ++--
 android/src/lib.rs                                        |   2 +-
 data/v0.crr                                               | Bin 0 -> 171552 bytes
 data/v1.crr                                               | Bin 0 -> 119261 bytes
 data/v2.crr                                               | Bin 0 -> 325182 bytes
 src/Cargo.lock                                            |  28 ++++----
 src/crusader-gui-lib/src/lib.rs                           |  78 ++++++++++++++------
 src/crusader-lib/Cargo.toml                               |   3 +-
 src/crusader-lib/src/file_format.rs                       |  23 +++---
 src/crusader-lib/src/plot.rs                              | 124 +++++++++++++++++++-------------
 src/crusader-lib/src/protocol.rs                          |  26 +++++--
 src/crusader-lib/src/serve.rs                             | 496 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++-------------------------------------
 src/crusader-lib/src/test.rs                              | 346 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++-------------------
 src/crusader/Cargo.toml                                   |   2 +-
 16 files changed, 830 insertions(+), 335 deletions(-)
 create mode 100644 data/v0.crr
 create mode 100644 data/v1.crr
 create mode 100644 data/v2.crr
Press any key to continue...

bash-3.2$ cargo build --release
    Updating git repository `https://github.com/Zoxc/winit`
    Updating crates.io index
    Updating git repository `https://github.com/Zoxc/egui.git`
  Downloaded socket2 v0.4.6
  Downloaded 1 crate (44.5 KB) in 0.56s
   Compiling socket2 v0.4.6
   Compiling emath v0.19.0 (https://github.com/Zoxc/egui.git?branch=crusader#1bd048c7)
   Compiling winit v0.27.2 (https://github.com/Zoxc/winit?branch=crusader#75c0ae47)
   Compiling tokio v1.20.1
   Compiling epaint v0.19.0 (https://github.com/Zoxc/egui.git?branch=crusader#1bd048c7)
   Compiling glutin v0.29.1
   Compiling egui v0.19.0 (https://github.com/Zoxc/egui.git?branch=crusader#1bd048c7)
   Compiling egui_glow v0.19.0 (https://github.com/Zoxc/egui.git?branch=crusader#1bd048c7)
   Compiling egui-winit v0.19.0 (https://github.com/Zoxc/egui.git?branch=crusader#1bd048c7)
   Compiling eframe v0.19.0 (https://github.com/Zoxc/egui.git?branch=crusader#1bd048c7)
   Compiling tokio-util v0.7.3
   Compiling crusader-lib v0.0.7 (/Users/Shared/space/data_local/moeller/PRIVATE/samba/privat/MOEWE/techno_kram/CODE/crusader/src/crusader-lib)
error[E0658]: use of unstable library feature 'bool_to_option'
   --> crusader-lib/src/serve.rs:199:73
    |
199 | ...                   (client.ip == ip_to_ipv6_mapped(addr.ip())).then_some(client)
    |                                                                   ^^^^^^^^^
    |
    = note: see issue #80967 <https://github.com/rust-lang/rust/issues/80967> for more information

error[E0658]: use of unstable library feature 'bool_to_option'
   --> crusader-lib/src/serve.rs:421:64
    |
421 |                     (ip_to_ipv6_mapped(src.ip()) == client.ip).then_some((client, ping))
    |                                                                ^^^^^^^^^
    |
    = note: see issue #80967 <https://github.com/rust-lang/rust/issues/80967> for more information

For more information about this error, try `rustc --explain E0658`.
error: could not compile `crusader-lib` due to 2 previous errors
warning: build failed, waiting for other jobs to finish...
macbook:~ user$ rustc --version
rustc 1.61.0 (fe5b13d68 2022-05-18)

Crash with ipv6

oot@lqos:~# crusader test --stream-stagger 5 --streams 2 --load-duration 10 fd77::2
Connected to server [fd77::2]:35481
thread 'main' panicked at 'called Result::unwrap() on an Err value: "Unable to measure latency to server"', crusader-lib/src/test.rs:1304:10
stack backtrace:
0: 0x7fdf8f501ddd -
1: 0x7fdf8f53bc0c -
2: 0x7fdf8f4fc771 -
3: 0x7fdf8f503335 -
4: 0x7fdf8f503056 -
5: 0x7fdf8f5038c6 -
6: 0x7fdf8f5037b7 -
7: 0x7fdf8f502294 -
8: 0x7fdf8f5034e9 -
9: 0x7fdf8f388103 -
10: 0x7fdf8f3881f3 -
11: 0x7fdf8f3e6c8a -
12: 0x7fdf8f38e850 -
13: 0x7fdf8f392c63 -
Aborted (core dumped)

automated build?

very happy to see this progressing? Any chance at an automated build for those that cannot compile?

thread 'tokio-runtime-worker' panicked at 'unable to udp ping:

Running crusader test <host> on macOS 12.6.1 laptop on Wi-Fi to small odroid running crusader serve on Ethernet with Ubuntu 20.04.05. I got the following error messages the very first three times I ran it after compiling it (on macOS).

√ release % ./crusader test 192.168.253.128
Connected to server 192.168.253.128:35481
Latency to server 2.69 ms
Testing download...
Testing upload...
thread 'tokio-runtime-worker' panicked at 'unable to udp ping: Os { code: 55, kind: Uncategorized, message: "No buffer space available" }', crusader-lib/src/test.rs:1232:32
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
zsh: abort      ./crusader test 192.168.253.128
?134 release % ./crusader test 192.168.253.128
Connected to server 192.168.253.128:35481
Latency to server 2.62 ms
Testing download...
Testing upload...
Testing both download and upload...
thread 'tokio-runtime-worker' panicked at 'unable to udp ping: Os { code: 55, kind: Uncategorized, message: "No buffer space available" }', crusader-lib/src/test.rs:1232:32
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
zsh: abort      ./crusader test 192.168.253.128
?134 release % ./crusader test 192.168.253.128
Connected to server 192.168.253.128:35481
Latency to server 2.63 ms
Testing download...
Testing upload...
Testing both download and upload...
Writing data...
Saved raw data as data 2022.12.06 21-00-02.crr
Saved plot as plot 2022.12.06 21-00-02.png
√ release %

Server said...

llladmin@odroid:~/Documents/src/crusader/src/target/release$ ./crusader serve
Server running...
Serving 192.168.253.116:50773, version 3
Error from client 192.168.253.116:50773: Connection reset by peer (os error 104)
Serving 192.168.253.116:50859, version 3
Error from client 192.168.253.116:50859: Connection reset by peer (os error 104)
Serving 192.168.253.116:50929, version 3
Serving complete for 192.168.253.116:50929
^CServer aborting...

Plot (from third run) Not sure if this is good or bad...

plot 2022 12 06 21-00-02

crusader server issue under OpenWRT

It seems to me crusader server can timeout easily after being idle, unlike iperf3.

Is this a known behavior? If yes, how do I workaround the behavior?

FYI, so far I have only run the server from Linux side (Debian 12 LxC container or OpenWRT 23.5).

pilot error on macos 12.6.3?

trying the current crusader (just pulled and compiled) on macosx 12.6.3 (intel) against the same version server on ubuntu22 (intel) results in the following issue on the client side:

bash-3.2$ RUST_BACKTRACE=full ./src/target/release/crusader test 192.168.42.201
thread 'main' panicked at 'called `Result::unwrap()` on an `Err` value: Os { code: 61, kind: ConnectionRefused, message: "Connection refused" }', crusader-lib/src/test.rs:1304:10
stack backtrace:
   0:        0x104364994 - __mh_execute_header
   1:        0x10438008b - __mh_execute_header
   2:        0x10435f208 - __mh_execute_header
   3:        0x104365ebd - __mh_execute_header
   4:        0x104365c14 - __mh_execute_header
   5:        0x1043663f8 - __mh_execute_header
   6:        0x104366333 - __mh_execute_header
   7:        0x104364e17 - __mh_execute_header
   8:        0x10436600a - __mh_execute_header
   9:        0x104394663 - __mh_execute_header
  10:        0x104394755 - __mh_execute_header
  11:        0x1042700fe - __mh_execute_header
  12:        0x1041eaa54 - __mh_execute_header
  13:        0x1041ef446 - __mh_execute_header
Abort trap: 6

the GUI reports error 61 as well, local testing on the client side against a locally started server (from within the GUI) seems to work.

I am pretty sure this is a simple "pilot's error" on my side, but I am at a loss what I am doing wrong here. Any help would be appreciated.

[Feature] web browser/wasm version

I know rust allows for wasm builds I wonder if it would be possible to allow for a web browser version of this
the end result allowing for a quick deploy on a local server and not have to worry about client side having anything but access to a modern web browser.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.