rr-pppoe-server startup script issues
Nobody has claimed this yet.
- Dominant language
- Makefile
- Stars
- 4.6k
- Forks
- 4k
- Avg merge
- 3d 12h
- Merged PRs (30d)
- 134
Description
Hello, I think this is the correct place for this, but please close the issue and send me to appropriate repo if it's not.
I have found several bugs that involve the startup script for the rr-pppoe-server package.
The file in question is the /etc/init.d/pppoe-server script.
- Obvious typo on line 51
[ -n "$firstremoteip" ] && append OPTIONS "-R $firstremoteip"
[ -n "maxsessions" ] && append OPTIONS "-N $maxsessions" # <-- the test is missing the $ variable
[ -n "optionsfile" ] && append OPTIONS "-O $optionsfile" # <-- same here
[ "$randomsession" = "1" ] && append OPTIONS "-r"
- behaviour mismatch with
luci-app-rp-pppoe-server: the UI removes the randomsession value from the/etc/config/pppoefile when the randomize sessions checkbox is unchecked. However, the default value of missing attribute in the startup script is 1, meaning that it's effectively not possible to not randomize.
config_get_bool randomsession "$cfg" randomsession 1
To aggravate this matter (only a bit), the attribute value that the app uses is randomsessions (plural).
- the final bug which is UI related is that the dropdown for interface lists devices as well as interfaces. As a result, this line will silently fail the entire script if a device is selected instead of an interface.
- while we're at it, I think a call to
logger -t pppoe-servershould be added in the startup script for hygiene.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with net/rp-pppoe/files/pppoe-server.init, especially the config reads around lines 30 and 51 and the interface handling around line 42. Compare those settings and failure behavior with luci-app-rp-pppoe-server; done means the reported script and UI mismatches are resolved and startup logging is addressed.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- shell
- Domain
- frontend, operating-systems
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100