-
Notifications
You must be signed in to change notification settings - Fork 230
Build error on Kernel 5.7.0 #49
Comments
I had a quick look and this seems to be the commit that broke it for security reasons |
ill try reverting this commit and retrying on my fork of rc git thx for the info |
I have the same problem, I am using a kernel system 5.3.0 on ubuntu bionic 18.04 LTS, this problem makes me unable to run anbox because ashmem and binder errors are built, can you help me? |
@ZeroLinux |
It seems like there have been a number of changes lately that are causing issues for the Anbox modules, not just this one |
Have you tried using the built-in "modules" in 5.7? In other words, rebuild kernel with (and don't forget to uninstall any Anbox modules (DKMS) package afterwards):
Note: In the above method, the "modules" are compiled in ( P.S. I am still on 5.6 because I encounter i915 GPU HANG bug in 5.7. |
@ipaucek4680 No I haven't tried building a kernel with the modules built in, I'm not sure where to find the patches needed to include them. |
I mean, the upstream kernel (including 5.7) already has "ashmem" and "binder", so no patch is needed. Have a look at the kernel source code and you will understand: If you have ever compiled the kernel in the past, you probably have to run |
So I compiled the kernel with those added config options and anbox now works perfectly on 5.7.2. |
Hi there!
|
@jedi2light |
|
Oh, i found |
And, unfortunately, it does not work :( |
@jedi2light |
On my system I needed to add an fstab entry to mount the |
Also run |
I used in-tree modules before (on Arch Linux) and an fstab entry was not needed. |
@TuxThePenguin0 @ipaucek4680
|
Can you share your fstab line? |
Oh, i found the solution at kernel doc
And finally its alive! |
So what exactly I have to do to get anbox running on arch with kernel 5.7.4? |
Not sure if this works on 5.7.4, but on 5.7.2 you should go through next steps:
You can use https://git.archlinux.org/svntogit/packages.git/tree/trunk?h=packages/linux to build your own kernel with modified config |
Also fixed Arch Linux wiki page for Anbox: https://wiki.archlinux.org/index.php/Anbox |
Is there a way I can verify that the linux kernel correctly built with the config values? (I'm still a newbie when it comes to building the kernel). I've tried this several times with 5.7.4 and 5.7.6-2 (using Manjaro's gitlab repository), and I'm not able to mount using binder. I modified both config and config.x86_64 in manjaro's repository.
|
I didn't specify any special name, I just replaced the kernel outright, so technically, yes. |
Okay, after doing some more research, I needed to enable the menuconfig option in the PKGBUILD for Liquorix, then set the correct flags there, and I even reached out to the developer of the kernel, and he's set to have it pre-packaged into the kernel on next release, so good stuff all around. |
https://techpatterns.com/forums/about2842.html |
Is this still a issue I don't really want to downgrade since the newest kernel adds new compresson type that sped up my boot times |
The modules are not needed anymore with 5.7 and later kernels. You just need to specify the build parameters in your kernel config. By the way, latest Manjaro kernel PKGBUILDs already included anbox-related parameters so you should be able to use it out-of-box on those kernels. EDIT: Not sure if there's a good way to ask dkms to build the modules only on kernels 5.6 or earlier, as those "bad status" dkms errors/warnings can be a bit annoying. |
How can this be an improvement, if the result is to have to rebuild the whole kernel instead of just modules? Or maybe I am missing something? |
The other option is to use the linux-zen kernel which is already compiled with the correct modules. |
how can I enable them? I've compiled the kernel a few times |
This is from Manjaro's official kernel PKGBUILD repo. This part contains the necessary build parameters for anbox-related modules and you can just append these lines to your existing config. |
If you read the commit message of the commit that unexported
This is basically exactly what Anbox is doing. It's a security improvement for the Linux kernel. Unfortunately it makes it very inconvenient for Anbox. |
Has anyone considered this workaround: lttng/lttng-modules@a657654 ? TL;DR: |
What a bunch of incompetent monkeys. Am I supposed to go install kernel 2.2 to use anbox? fuck off |
No you're supposed to either help maintain the project, find a workaround or build a kernel with the needed features built in anyway. |
The modules are now upstream and can be enabled from kernel configuration since 5.7.0 and this is no longer needed. Period.
It seems the topic is starting to derail into the concerns that people now have to make custom kernel build themselves to enable the modules, as the official kernel packages from their respective Linux distros may not have this enabled by default. Building a kernel can be difficult for some users, and may take very long if the user's CPU is weak. It may also disrupt regular package update routines as now one needs to manually build and install the kernel packages themselves instead of installing from official sources. Prior to the changes in 5.7.0, users can just update their systems and dkms will rebuild the modules afterwards, with no changes in usual update routines. Now this is no longer possible, if their distro does not ship kernels with this option enabled by default. It would be up to the kernel maintainers of the respective distros to decide whether or not they provide kernel variants with this enabled. |
Hello all, for all those who really need working kernel modules for anbox, you can try my dirty fixes in https://github.com/choff/anbox-modules that make ashmem and binder work again with later kernels. The most important change was to use KProbes to look up the address of kallsysms_lookup_name(), to be able to continue to use this function as before. Yes, I know it is dirty - hopefully it nevertheless helps one or the other person out there. The better solution is surely to contact the kernel maintainer of your Linux distro to enable ashmem and binder support in the kernel. So, this is just a solution if nothing else works. I have also opened a pull request (#76 ) for this - let's see if it will be integrated... Best regards, Christian |
At my side i needed to do:
ASHMEM=true if i use /dev/binderfs instead anbox doesn't seem to recognize binder then. but Anbox shows this error now while trying to start:
br |
Hello @SoulInfernoDE , thanks for sharing your solution, which also helped me to get past the issue that Anbox does not recognize Binder. Now I finally know that it is because binderfs wasn't mounted... The Anbox issue you reported seems like an OpenGL issue ("Failed to select EGL configuration") - maybe graphics drivers for hardware acceleration need to be installed? Also the stack trace comes from the OpenGL code in Anbox. Maybe it is worth to compile Anbox from source - then you get much better stack traces - at least if libunwind is installed. These better stack traces could then be used to create a bug report against Anbox. I finally got Anbox running yesterday evening with Binder and Ashmem support built into the kernel. Best regards, Christian |
For all looking for a quick fix, check @choff 's comment above. #49 (comment)
|
I just wanted to add that i needed to add a line to /etc/fstab to make /dev/binder permanent available to the system: |
Hi @choff DKMS make.log for anbox-binder-1 for kernel 5.13.0-kaisen1-amd64 (x86_64) |
Hello @0n1cOn3 , yes, I was also made aware of this issue by others. Please try the latest version of anbox-modules; it contains a (so far untested) fix for this issue. I would be happy if you could give it a try and give me feedback if it works or not. Best regards, Christian |
The kernel modules do not seem to install on kernel
5.7.0-rc2
Asmem:
Binder:
Any thoughts on?
The text was updated successfully, but these errors were encountered: