-
-
Notifications
You must be signed in to change notification settings - Fork 505
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
DietPi-Software | WireGuard: Now available for install #2398
Conversation
🈴 Buster x86_64: Module build is skipped, since current kernel and headers from repo do not match:
This is a general issue, since in most cases we have the kernel installed via meta package, which is not updated via ordinary Second issue: After updating the kernel module, a reboot is required to apply it to the system, okay no big issue, since on interactive call, dietpi-software anyway triggers a reboot. @Fourdee 🈺 Okay
Partly resolved with: Fourdee@3ccd572
🈺 On RPi headers are no meta packages, thus don't need to be installed manually. But an issue occurs, if kernel was updated via
|
@Fourdee |
Appears NordVPN are looking into Wireguard: https://www.pr.com/press-release/769043
Originally, G_AGDUG is left for But yep, overall makes sense to |
@Fourdee I think this basically should stay as is now, mainly due to the dependency issues I regularly run into on Raspbian Buster: If some dependency is missing (which might as well occur on stable branch, theoretically), a forced (non-interactive) dist-upgrade leads to dependants being purged instead of upgrade being skipped. Perhaps there is a way to work around this via apt(-get) command arguments, so that manually installed dependants are never removed, but dependency upgrades skipped instead. As long as this is not the case, I think we should never force a For WireGuard this is not not required anymore with latest commits, since |
Whoopsie! 😄
Yep, good point 👍 |
Another issue when
Best we can do, I think, is implement If Okay at least on WireGuard install the way is now clear: notro/rpi-source#40 (comment) 🈺 Damn it's a python script... I'm not keen to install python just for workaround this issue. Hmm the more I think about it, the more I think we should remove any |
Thanks guys! I haven't tried it yet but I'm going to! PIA is also supposed to roll out support once it's audited |
+ DietPi-Config | Firmware update: On RPi give choice and do recommend to NOT use "rpi-update", but stay with APT firmware packages instead + DietPi-Config | Firmware update: Check firmware (via /lib/modules) before and after update attempt, to check if it actually changed, before setting reboot requirement + DietPi-Config | Minor coding
@Fourdee If left the choice to use One case where we used Do you agree? |
Yep agree 👍
Yep, |
DietPi confirms to be one of the best distro. |
@Fourdee or anyone with RPi free for testing
I am just thinking how to achieve this practically, since there are no older kernel packages available and no backports or buster repo. Perhaps only time will show, when users install WireGuard and next firmware packages are released 🤔. There is this RPi dac module that we build manually, when selected. I guess this needs to be redone after every kernel update currently, right? Same question is for Odroids. We have kernel packages in Meveric's repo, header packages are surely available as well. But would be good to know, if WireGuard kernel module rebuild is triggered automatically or one needs to do this manually. |
@garret Currently the install script will configure WireGuard to be the server and create matching client configurations to pass all network traffic through the VPN. It would be great to have some choices there:
We could either add a whiptail menu to allow user choice while install, and/or we add a dietpi.txt entry that allows choice (+ local machine domain/public IP + VPN port), to then have the install non-interactive, or we leave configuration to end user, by adding commented code parts to to the config file, to enable one of the above use cases. |
Yep, if the module is not built into the stock kernel, the only solution is to hold kernel packages, prevent any updates. Else, each kernel update would break compiled module. |
@Fourdee Or we try to automate this within G_AG*, if RPi + kernel update was detected. |
We could:
Save to file, and if that does not match at time of install, then we could prompt user to reinstall? But probably best to hold packages regardless. EDIT: Ah see you did something similar 👍
EDIT: Lets just hold packages. |
Many thanks 👍 Will merge, run tests and changes if required. |
@Fourdee |
# - If APT updates did not override "rpi-update" kernel version, headers might mismatch and WireGuard module missing | ||
if [[ $old_firmware == $(ls /lib/modules/) ]]; then | ||
G_WHIP_MSG 'Wireguard:\n\nKernel update detected, a reboot is required before Wireguard module can be built with latest kernel.\n\nOnce the system has rebooted, reselect Wireguard for installation to continue.' | ||
aSOFTWARE_INSTALL_STATE[$software_id]=0 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@Fourdee
Reboot not required here. The module will be build for all installed kernels, regardless of which one is active. So after reboot (which is done anyway after dietpi-software), WireGuard will work.
Also setting the packages on hold is contra-productive. WireGuard rebuilds the module automatically, when the kernel packages are updated due to some APT trigger, or did this not work on RPi (was the case on x86_64 at least)? So setting kernel packages on hold is required only for manually build modules.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reboot not required here. The module will be build for all installed kernels, regardless of which one is active. So after reboot (which is done anyway after dietpi-software), WireGuard will work.
Excellent, i'll make the change 👍
In this case, modprobe wireguard
will never fail.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
WireGuard rebuilds the module automatically, when the kernel packages are updated due to some APT trigger, or did this not work on RPi (was the case on x86_64 at least)?
Will need to verify this is case.
Does with Odroids
Further device support:
|
@Fourdee I am afraid it's for U1 actually, similar to |
Yep, unable to check as lack the device, and, no longer made. We only have 6 installs on survey, so I believe we can leave it for now. |
@Fourdee Meveric Jessie image available only, so makes sense that kernel version is frozen at 3.X: https://forum.odroid.com/viewtopic.php?f=79&t=17770 Jep, leave it out from support until someone asks for it and is willing verify kernel+header packages and do required tests. |
Status: WIP
qrencode -t ansiutf8 < /etc/wireguard/wg0-client.conf
NB: Currently only works on x86_64 and RPi's. Since kernel headers are required, we need to add those for other devices, before the WireGuard kernel module can be compiled.
Testing:
Reference: https://github.com/Fourdee/DietPi/issues/2052
Commit list/description: