Skip to content
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

Custom kernel config management #1093

Open
mikhail-sakhnov opened this issue Oct 1, 2024 · 0 comments
Open

Custom kernel config management #1093

mikhail-sakhnov opened this issue Oct 1, 2024 · 0 comments
Labels
a/tech_debt Area: related to tech debt c/autoscaling/neonvm Component: autoscaling: NeonVM

Comments

@mikhail-sakhnov
Copy link
Contributor

Problem description / Motivation

Currently we store custom kernel config as one large text blob in the github https://github.com/neondatabase/autoscaling/blob/main/neonvm/hack/kernel/linux-config-6.1.92

With the #850 it is changed to two large text blobs: one config is for x86_64, another one is for aarch64.

While it works and provides us working kernel, it is hard to manage:

  • not clear which settings are customized comparing to the default kernel config for x86_64
  • not clear which of those custom settings should be also ported to the arm config during Epic: Support ARM AWS instances #850
  • (hypothesis): it is probably would be hard to update kernel to newer versions by the very same reasons as mentioned.

It would be great to store in the repo instead of the full config only the difference from the default one and use linux/scripts/kconfig/merge_config.sh from the kernel source tree.

Currently, difference with default x86_64 config (provided by make ARCH=x86_64 defconfig) is ~4k lines:

~/linux-6.1.92$ diff .config ~/autoscaling/neonvm/hack/kernel/linux-config-amd64-6.1.92 | wc -l
4083

Feature idea(s) / DoD

DoD: we have reliable way to manage kernel configuration for different architectures.

Implementation ideas

We should utilize them scripts and makefile targets in the linux kernel source tree, there are plenty of them to work with configuration management.

Option 1.

Store config only with those variables and values that are important for us, during build use make oldconfig or kconfig/merge_config.sh to merge our changes with default config.

@mikhail-sakhnov mikhail-sakhnov added a/tech_debt Area: related to tech debt c/autoscaling/neonvm Component: autoscaling: NeonVM labels Oct 1, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
a/tech_debt Area: related to tech debt c/autoscaling/neonvm Component: autoscaling: NeonVM
Projects
None yet
Development

No branches or pull requests

1 participant