magnific0 / wondershaper

Command-line utility for limiting an adapter's bandwidth
GNU General Public License v2.0
1.73k stars 261 forks source link

Loading config prints "[wondershaper]: command not found" #73

Closed mattiasb closed 3 years ago

mattiasb commented 3 years ago

With this configuration file (slightly modified from the default config in the repository):

[wondershaper]

# Adapter
IFACE="eno1"

# Download rate in Kbps
DSPEED="102400"

# Upload rate in Kbps
USPEED="51200"

### Separate items by whitespace:

#HIPRIODST=(IP1 IP2)
HIPRIODST=()

COMMONOPTIONS=()

# low priority OUTGOING traffic - you can leave this blank if you want
# low priority source netmasks
NOPRIOHOSTSRC=(80);

# low priority destination netmasks
NOPRIOHOSTDST=();

# low priority source ports
NOPRIOPORTSRC=();

# low priority destination ports
NOPRIOPORTDST=();

### EOF

… I get this output when running:

$ sudo wondershaper -p -a eno1
/etc/systemd/wondershaper.conf: line 1: [wondershaper]: command not found
mattiasb commented 3 years ago

I can probably fix this myself if you can point me in the right direction.

magnific0 commented 3 years ago

This is expected behaviour. It will process the file regardless. You can remove the section header [wondershaper] from the conf file. It's there because it also serves as the EnvironmentVariables conf file for systemd.