Commit Graph

1159 Commits

Author SHA1 Message Date
Robert Chacón
912099cf3d
Fix pertaining to https://github.com/LibreQoE/LibreQoS/issues/273
Ensure client is active before attempting to pull plan info
2023-02-27 16:57:30 -07:00
Robert Chacón
da42238332
Fix related to https://github.com/LibreQoE/LibreQoS/issues/273
Ensure client is active before attempting to pull plan info
2023-02-27 16:55:28 -07:00
Dave Taht
9b0313a942 build-rust to build_rust
Fixes: #276
2023-02-27 08:46:16 -08:00
Dave Taht
6671eb7c64 Updated copyrights to 2022-2023
Someday I hope something other than my amazing sed skills will be
of use in refactoring this project.
2023-02-25 15:46:32 -08:00
Herbert Wolverson
c73af2de89 Auto include a MOTD script to remind the user that they have installed LibreQoS and how to get to the web UI. 2023-02-24 18:55:44 +00:00
Herbert Wolverson
b98417282a Trim dependency list in .deb to not include development/build only dependencies, fix an oops with quoting an integer. 2023-02-24 18:19:25 +00:00
Herbert Wolverson
6eb9c80a3b Update Cargo.lock to latest versions 2023-02-24 17:41:51 +00:00
Herbert Wolverson
4ddf665e14 Fix name that should have been 2023-02-24 17:37:43 +00:00
Herbert Wolverson
2b8ed7ef1f Cleanup path error message (wasn't doing anything) from build_dpkg 2023-02-24 17:34:40 +00:00
Herbert Wolverson
1f5629a8c3 Tweak to previous commit: I didn't intend to filter out no-RTT
hosts from the top downloaders list, since they might be
non-TCP traffic.
2023-02-24 15:02:57 +00:00
Herbert Wolverson
6b82fd968e Fix RTT outliers
1) When calculating median latency, reject any entry that doesn't
   have at least 5 data points. From local testing, 5 appears
   to be the magic number (when combined with sampling time) that
   ignores the "idle" traffic from CPEs, routers and long-poll
   sessions on devices.

2) Filter out RTT 0 from best/worst reports.

3) Note that no data is discarded - it's just filtered for display.

This results in a much cleaner display of RTT times in the
reporting interface, giving a much better ability to "zero in"
on problem areas without being distracted by poor RTT - but
basically no traffic - hosts that are idle.
2023-02-24 14:53:47 +00:00
Herbert Wolverson
791ff97eef Update DPKG build script to use version numbering from date
to handle nightly or similar builds and always increase the
build number for upgrades.
2023-02-21 20:56:46 +00:00
Herbert Wolverson
3e9ff0c0f5 (Very alpha!) Add dpkg builder and initial configurator
* Adds a new Rust program, `lqos_setup`.
    * If no /etc/lqos.conf is found, prompts for interfaces and
      creates a dual-interface XDP bridge setup.
    * If no /opt/libreqos/src/ispConfig.py is found, prompts
      for bandwidth and creates one (using the interfaces also)
    * Same for ShapedDevices.csv and network.json
    * If no webusers are found, prompts to make one.
* Adds build_dbpkg.sh
    * Creates a new directory named `dist`
    * Builds the Rust components in a portable mode.
    * Creates a list of dependencies and DEBIAN directory
      with control and postinst files.
    * Handles PIP dependencies in postinst
    * Calls the new `lqos_setup` program for final
      configuration.
    * Sets up the daemons in systemd and enables them.

In very brief testing, I had a working XDP bridge with
1 fake user and a total bandwidth limit configured and
working after running:

dpkg -i 1.4-1.dpkg
apt -f install

Could still use some tweaking.
2023-02-21 20:26:34 +00:00
Robert Chacón
e74662631c
Merge pull request #269 from interduo/chmodx
improvement: add +x for lqTools.py
2023-02-19 00:36:36 -07:00
Jarosław Kłopotek - INTERDUO
71f75cc6c3 improvement: add +x for lqTools.py 2023-02-16 15:41:27 +01:00
Herbert Wolverson
da44d38888 Temporary: mark --updateonly as unavailable if OnAStick
The partial reload mechanism *really* doesn't work with OnAStick
configurations at present. There's a lot of work required to make
it function. In the meantime, warn the poor user that this
isn't going to work.

Affects ISSUE #129
2023-02-15 17:14:29 +00:00
Herbert Wolverson
e7d7429058 Fix partial reload in LibreQoS.py for NOT OnAStick mode
OnAStick mode is still broken for partial updates. The
`addDeviceIPsToFilter` function was referencing circuit
information (the class_id) that wasn't present in the
partially reloaded data.

Changed shell call to call `add_ip_mapping` which accesses
the bus directly, saving a shell call.

Part of ISSUE #239 - does not fix it for "on a stick"
configurations.
2023-02-15 17:04:29 +00:00
Herbert Wolverson
54d9fa99a5 Improve error messaged when parsing IPs for iphash_to_cpu/Python
Display the offending string as well as the general "Class id must
be in the format (major):(minor), e.g. 1:12.

May help with diagnosing #239 (since "Error: Class id..." is the
only visible error message.
2023-02-15 15:24:11 +00:00
Herbert Wolverson
f8f438e8d7 Add Python Version Check to Python Scripts
ISSUE #204 : Running on versions prior to 3.10 will fail, due to
the use of `match` statements. Other parts of the script assume
a recent Python also, and the system as a whole expects a recent
version of Ubuntu.

`pythonCheck.py` polls `sys.version_info` to detect the in-use
version of Python. If the version is prior to 3.10, it bails out
with the message "LibreQoS requires Python 3.10 or greater".

This should help with outdated OS detection in general.
2023-02-15 15:00:53 +00:00
Herbert Wolverson
85caa6be19 Stop using unicode extended characters in lqtop
Remove the up and down arrows that render strangely in fonts
that don't support full unicode graphics. Add text UP/DOWN
headings instead.

FIXES #266
2023-02-15 14:41:41 +00:00
Herbert Wolverson
088f608614 #229 - Run cargo fmt to format everything. 2023-02-14 22:06:57 +00:00
Herbert Wolverson
6fe97e97b6 an atomic compare_exchange. 2023-02-14 21:36:16 +00:00
Herbert Wolverson
dcb0ae8444 Add an additional NUM_CPUS atomic to store the actual size. CPU
utilization is updated in a lock-free array of atomics. Another
lock removed (and another unmeasurably small gain)
2023-02-14 21:27:37 +00:00
Herbert Wolverson
c0f83dbc51 Replace MEMORY_USED RwLock'd array with a pair of atomic u64s,
for a non-noticeable performance improvement.
2023-02-14 21:01:10 +00:00
Herbert Wolverson
8f7293760c Just directly initialize the atomic bool. 2023-02-14 20:41:43 +00:00
Herbert Wolverson
27c079f9cf Add lqusers.toml to .gitignore after it was renamed. 2023-02-14 20:41:38 +00:00
Herbert Wolverson
c096226665 ISSUE #229 - Change "reload required" from a lock with a bool inside
to a proper atomic bool, for a completely unnoticable performance
improvement.
2023-02-14 20:37:09 +00:00
Herbert Wolverson
1da10d7a23 Add bin/lqusers to the gitignore file. 2023-02-14 20:37:02 +00:00
Dave Taht
a58ce5cd0b Finished conversion to lqusers from webusers
Note that you will need to regenerate the webusers.toml file
after this.

Part of my motivation for this is that this file is not strictly
for governing web permissions in the future.
2023-02-09 15:26:27 +00:00
Dave Taht
8ba5aed14e lqusers: change name of web admin tool from webusers to lqusers
lqusers is consistent with the prefix used elsewhere in LibreQos.

Something one character shorter than that came to mind, but
I resisted.
2023-02-09 15:21:02 +00:00
Herbert Wolverson
51c369b9b5 Update dependencies. 2023-02-09 14:36:47 +00:00
Herbert Wolverson
32a75bde0f ISSUE #258 - Specifically ignore [idForCircuitsWithoutParentNodes] in queueingStrucutre.json 2023-02-09 14:15:56 +00:00
Herbert Wolverson
11644dd1f1 #258 - Unrecognized node in queueingStructure.json generates a warning and continues rather than aborting hard. This makes it a lot more tolerant of anything changing. 2023-02-09 14:15:06 +00:00
Herbert Wolverson
787344e8f4 Fix typo I noticed in #258 - incorrect file name referenced in error message. 2023-02-09 14:14:28 +00:00
Dave Taht
b1f2bfb053 fix Spelling error in example
Fixes: https://github.com/LibreQoE/LibreQoS/issues/262
2023-02-09 11:51:33 +00:00
Robert Chacón
fa8d67c554
Fix https://github.com/LibreQoE/LibreQoS/issues/252 2023-02-08 20:48:05 -07:00
Dave Taht
04f1f4c2cb webusers: correct usage message 2023-02-09 02:44:39 +00:00
Dave Taht
79db32ff99 Proper spelling and quoting 2023-02-08 19:52:28 +00:00
Dave Täht
679c5e9a3a
Merge pull request #260 from interduo/patch-28
improvement: add tuning of performance governor
2023-02-08 11:50:56 -08:00
Dave Taht
71988e6046 Updated copyright message: It is 2023 now
At least it was when last I looked
2023-02-08 15:56:09 +00:00
Interduo
1904fb4690
improvement: add tuning of performance governor 2023-02-08 16:22:56 +01:00
Herbert "TheBracket
2ae80f9fc3
Merge pull request #259 from trendal/main
login page enter key action
2023-02-08 06:40:21 -08:00
Trendal Toews
2ff6284a6b login page enter key action 2023-02-08 06:56:31 +00:00
Robert Chacón
46457878a0
Fix https://github.com/LibreQoE/LibreQoS/pull/257 2023-02-07 06:38:20 -07:00
Robert Chacón
20567736d7
Update TESTING-1.4.md 2023-02-07 06:29:04 -07:00
Robert Chacón
4caf9712cf
Fix https://github.com/LibreQoE/LibreQoS/issues/252 2023-02-07 06:24:49 -07:00
Dave Täht
f89e2d5847
Merge pull request #251 from interduo/patch-26
improvement: make systemd unit services managing by one command and n…
2023-02-07 04:52:47 -08:00
Robert Chacón
ff40478eee
Fix https://github.com/LibreQoE/LibreQoS/issues/255 2023-02-06 19:44:48 -07:00
Robert Chacón
dee2c465be
Fix https://github.com/LibreQoE/LibreQoS/issues/253 2023-02-06 19:22:51 -07:00
Robert Chacón
2811148ffb
Merge pull request #256 from LibreQoE/fixGraphing324
Fix #254
2023-02-06 18:46:18 -07:00