{"id":50385150,"url":"https://github.com/stackhpc/kernel_packages","last_synced_at":"2026-05-30T14:31:02.965Z","repository":{"id":54961189,"uuid":"331005406","full_name":"stackhpc/kernel_packages","owner":"stackhpc","description":"Manage CentOS kernel and packages depending on kernel version","archived":false,"fork":false,"pushed_at":"2021-02-04T20:16:47.000Z","size":40,"stargazers_count":1,"open_issues_count":1,"forks_count":0,"subscribers_count":5,"default_branch":"main","last_synced_at":"2024-04-14T22:50:20.848Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/stackhpc.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2021-01-19T14:23:26.000Z","updated_at":"2021-05-04T16:37:25.000Z","dependencies_parsed_at":"2022-08-14T07:30:56.686Z","dependency_job_id":null,"html_url":"https://github.com/stackhpc/kernel_packages","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/stackhpc/kernel_packages","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/stackhpc%2Fkernel_packages","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/stackhpc%2Fkernel_packages/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/stackhpc%2Fkernel_packages/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/stackhpc%2Fkernel_packages/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/stackhpc","download_url":"https://codeload.github.com/stackhpc/kernel_packages/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/stackhpc%2Fkernel_packages/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":33696681,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-26T15:22:16.424Z","status":"online","status_checked_at":"2026-05-30T02:00:06.278Z","response_time":92,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2026-05-30T14:31:02.873Z","updated_at":"2026-05-30T14:31:02.959Z","avatar_url":"https://github.com/stackhpc.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"Role Name\n=========\n\nManage `kernel` and `kernel-*` packages which depend on kernel version.\n\nThere are two problems which mean that it can be hard to install packages like `kernel-headers` properly: Firstly the kernel can change unexpectedly on reboot as (by default) CentOS installs updated `kernel` packages when available. Secondly the main CentOS repos only contain the latest versions of packages, which means `yum`/`dnf` may not be able to find `kernel-*` packages which match the running kernel.\n\nThis role fixes this by:\n- Ensuring the selected kernel version is installed, running and set as the default on boot.\n- Disabling updates to `kernel*` packages.\n- Installing `kernel-*` packages matching the selected kernel from either the normal or CentOS Vault (archive) repos as necessary.\n\nNote that outdated kernels and other packages may have security issues or contain bugs. However some applications such as lustre servers may require specific kernel versions.\n\nRequirements\n------------\nA CentOS 7.8 - 8.3 (inclusive) x86_84 system. This role must be run with `become` and `gather_facts`.\n\nRole Variables\n--------------\n- `kernel_version`: Optional. Either a specific, full kernel version as listed below or `{{ ansible_kernel }}` (default) to use the currently-running kernel.\n   **NB:** In the default case the running kernel must still be in the list below.\n- `kernel_pkgs`: Optional. A list of packages depending on a specific kernel version. Default is empty list.\n- `kernel_pkgs_state`: Optional. Either `present` (default) or `absent` to control `kernel_pkgs` install state.\n\nKernel Versions\n---------------\nThe following kernel versions may be used for `kernel_version`, depending on the running CentOS release:\n- CentOS 8.3 (2011):\n  - 4.18.0-240.1.1.el8_3.x86_64 (used by cloud image `CentOS-8-GenericCloud-8.3.2011-20201204.2.x86_64.qcow2`)\n  - 4.18.0-240.10.1.el8_3.x86_64\n  - 4.18.0-240.el8.x86_64\n  - Any later kernels provided in the main CentOS repos.\n\n- Centos 8.2 (2004):\n  - 4.18.0-193.1.2.el8_2.x86_64\n  - 4.18.0-193.6.3.el8_2.x86_64 (used by cloud image `CentOS-8-GenericCloud-8.2.2004-20200611.2.x86_64.qcow2`)\n  - 4.18.0-193.14.2.el8_2.x86_64\n  - 4.18.0-193.19.1.el8_2.x86_64\n  - 4.18.0-193.28.1.el8_2.x86_64\n  - 4.18.0-193.el8.x86_64\n\n- Centos 8.1 (1911):\n  - 4.18.0-147.0.3.el8_1.x86_64\n  - 4.18.0-147.3.1.el8_1.x86_64 (used by cloud image `CentOS-8-GenericCloud-8.1.1911-20200113.3.x86_64.qcow2`)\n  - 4.18.0-147.5.1.el8_1.x86_64\n  - 4.18.0-147.8.1.el8_1.x86_64\n  - 4.18.0-147.el8.x86_64\n\n- Centos 8.0 (1905):\n  - 4.18.0-80.1.2.el8_0.x86_64\n  - 4.18.0-80.4.2.el8_0.x86_64\n  - 4.18.0-80.7.1.el8_0.x86_64\n  - 4.18.0-80.7.2.el8_0.x86_64\n  - 4.18.0-80.11.1.el8_0.x86_64\n  - 4.18.0-80.11.2.el8_0.x86_64\n  - 4.18.0-80.el8.x86_64\n\n- Centos 7.9 (2009):\n  - 3.10.0-1160.el7.x86_64 (used by cloud image CentOS-7-x86_64-GenericCloud-2009.qcow2)\n  - Any later kernels provided in the main CentOS repos.\n\n- Centos 7.8 (2003):\n  - 3.10.0-1127.el7.x86_64 (used by cloud image CentOS-7-x86_64-GenericCloud-2003.qcow2)\n\nDependencies\n------------\n\nNone.\n\nExample Playbook\n----------------\n\nTo install a `4.18.0-147.0.3` (for CentOS 8.1) kernel plus matching `kernel-headers` and `kernel-devel` packages:\n\n    - hosts: servers\n      become: yes\n      tasks:\n        - import_role:\n            name: kernel_packages\n            vars:\n              kernel_version: \"4.18.0-147.0.3.el8_1.x86_64\"\n              kernel_pkgs:\n                - kernel-headers\n                - kernel-devel\n\n\nLicense\n-------\n\nApache 2.0\n\nAuthor Information\n------------------\n\nSteve Brasier steveb@stackhpc.com\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fstackhpc%2Fkernel_packages","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fstackhpc%2Fkernel_packages","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fstackhpc%2Fkernel_packages/lists"}