Как установить ядро linux manjaro

Manjaro Kernels

Содержание

As the name would imply, as with the kernel of a seed, the Linux kernel is the core of a Linux operating system. Every other element of a Linux-based operating system is built around the kernel, which acts as an interface between your computer’s hardware and the applications that run on it. As hardware and software applications become more complex and sophisticated, so do the kernels to fully utilise them. As such, Linux kernels are continually under development, with new revisions and versions being regularly released. Further information on the very latest developments in kernel technology can be found at The Linux Kernel Archives

The first Linux kernel was originally developed by Linus Torvalds, the creator of Linux. It is now an open-source project containing millions of lines of code generated by thousands of programmers. However, Linus Torvalds still has the final authority on their development and release.

Manjaro Settings Manager offers an easy way to add and remove kernel (including the necessary kernel modules).

New kernels can be installed by pressing the «Install» button. All necessary kernel modules will be installed automatically with a new kernel as well.

Please consider the «Recommended» tag when choosing a kernel. LTS means Long Term Support, which is safest for most users. «What should I be aware of if I’m not on an LTS kernel?»

The newest installed Kernel will be booted by default, but to run other kernels that are installed, see Selecting Kernels section below.

Instead of using the Manjaro Settings Manager GUI to identify, choose, add, and remove kernels everything can be achieved from a terminal as well.

Identifying the Kernel Being Used

This terminal command will give your system’s kernel information:

The above command not only shows which kernel is being used, it also lists any other kernels that are also installed, as shown in the following example Terminal output:

As seen in the above example, Manjaro is running kernel 5.0.17-1-MANJARO. The information given here is not arbitrary; each part of the kernel name identifies something about that kernel:

  • The 5 indicates the version
  • The 0 indicates the major revision
  • The 17 indicates the minor revision
  • The 1 indicates the revision of the Manjaro package
  • MANJARO indicates the specific distribution it is used for

Adding New Kernels

Manjaro not only supports the use of multiple kernels (selectable from the boot screen), but allows easy access to the very latest bleeding edge kernels as well. This is undertaken through use of Manjaro’s own MHWD-kernel (Manjaro Hard-Ware Detection) command. The syntax of the command is as follows:

When listing a new kernel to be installed in the command, it is not necessary to write the entire version number. For example, any version of Kernel 4.19 can be listed simply as ‘linux419’, and any version of Kernel 4.14 can be listed as ‘linux414’, and so on.

The optional rmc (remove current) component is of vital importance. Using this will result in your existing kernel being deleted upon the installation of the new kernel. Otherwise, if it is not used, then the existing kernel will be kept, and will be selectable alongside the new kernel at the boot screen. It is recommended — especially if updating to the latest bleeding edge kernel — to keep your old one, even if only for a short time afterwards. This the safer option, and the old kernel can be easily removed when satisfied with the stability and functionality of the new one.

As an example, once the terminal is opened, the following command will install a new kernel (4.19) without deleting the existing kernel currently being used:

Otherwise, the following command will install a new kernel (5.10) to replace the existing kernel, which will be deleted:

Either way, Manjaro will automatically configure the new kernel for you, ready for immediate use. Once completed, close the terminal and re-boot the system for the change to take effect.

Removing Kernels

Where multiple kernels are present on your system, pacman can be used to remove them in the terminal. It may be necessary to delete a total of three elements of the kernel in total to completely remove it:

  1. The kernel itself
  2. The kernel’s headers
  3. The kernel’s extra modules
Читайте также:  Assassins creed 2 что делать если ошибка

Whether or not the headers and extra modules must be deleted depends on whether or not they have been installed.

1. To remove a kernel use the following syntax: sudo mhwd-kernel -r linux[version]

Here is an example for removing kernel 5.0.17-1

2. To delete a kernel’s headers, the syntax is:

For example, to delete the headers of kernel version 5.0.x from the system, the following command would be entered:

3. To delete a kernel’s extra modules, the syntax is:

For example, to delete the extra modules of kernel version 5.0.x from the system, the following command would be entered:

4. To delete all elements of a kernel at the same time — where they are all present on your system — the syntax is:

For example, to completely remove all elements of kernel version 5.0.x, the following command would be entered:

Please note however, that attempting to delete multiple elements at once if they are not present on your system will result in an error message before the operation itself is aborted. It is also worthwhile noting if Manjaro is being run in a virtual machine (e.g. Oracle Virtualbox), you may not be able to delete certain kernels if they contain elements important to the virtualisation process itself.

Don’t forget the mhwd-kernel -h command

As with most Linux commands that can be entered into the Terminal, typing the command followed by either -h or —help will print out the usage & available options to the Terminal for your reference. Here is the output of the mhwd-kernel -h command:

Источник

Как установить ядро linux manjaro

Одним из преимуществ Manjaro Linux является возможность одновременно использовать и устанавливать несколько версий ядра Linux. Переключение между различными версиями Linux на лету — это отличный способ убедиться, что ваши устройства всегда работают наилучшим образом. Manjaro Linux отлично справляется с взятием Arch Linux и упрощением его для обычных пользователей. Он часто строит звездные инструменты GUI вокруг сложного решения командной строки. Перестановка ядра ничем не отличается. Если пользователи хотят обновить (или даже понизить версию) до любой версии Linux, самый простой способ — переключить ядра в Majaro — использовать инструмент с графическим интерфейсом. Вот как это работает.

Начните с нажатия клавиши Windows на клавиатуре, чтобы открыть меню Manjaro. Внутри окна поиска найдите «Менеджер настроек Manjaro» и запустите его.

Примечание. Если вы используете версию Manjaro Linux для сообщества, а не традиционную версию, просмотрите настройки и запустите «Диспетчер настроек Manjaro».

Внутри диспетчера настроек есть несколько вариантов на выбор. Забудьте об остальных параметрах, так как единственное, что имеет значение в этом руководстве, это «Ядро». Нажмите на значок пингвина, чтобы открыть инструмент управления ядром GUI.

Переключение ядер через графический интерфейс

У инструмента управления ядром Manjaro есть много разных ядер Linux на выбор; как новые, так и устаревшие. По состоянию на январь 2018 года на нем установлена ​​последняя стабильная версия Linux (версия 4.14).

Для большинства пользователей версия 4.14 идеальна. Однако, если вы опытный пользователь и хотите получить от своего ПК Manjaro Linux немного больше, у вас есть возможность установить нестабильное ядро. Кроме того, если ваши устройства работают лучше со старыми ядрами, эта опция также доступна.

Обновление ядер в Манджаро

Чтобы установить нестабильное ядро, найдите любой выпуск с «.r» после него и нажмите кнопку «Установить». Например, чтобы запустить последнюю версию кандидата для Linux версии 4.15, нажмите кнопку «Установить» после «Linux 4.15.r180118.gdd».

Понижение ядра в Манджаро

Вообще глупо переходить на версии Linux. С каждым новым выпуском вводятся исправления безопасности и новые драйверы. Тем не менее, иногда с выпусками Linux могут возникнуть проблемы (по любой причине). Если вы чувствуете, что ваша машина лучше работает в более ранней версии Linux, инструмент ядра Manjaro позволяет очень легко выполнить откат и даже установить несколько версий ядра одновременно.

Чтобы установить старое ядро, нажмите «установить» рядом с любой версией Linux версии 4.14. После нажатия кнопки установки вам будет предложено ввести пароль. Сделайте так, и установка начнется.

После завершения установки перезагрузите компьютер и выберите версию, установленную на экране загрузки.

Примечание: старые версии Linux восходят к версии 3.16 на Manjaro.

Удаление старых ядер

Удаление старого ядра из Manjaro работает так же, как и установка нового. Для начала откройте Диспетчер настроек Manjaro и щелкните значок пингвина. Отсюда прокрутите вниз и выберите установленное ядро ​​Linux, которое вы хотите удалить. Нажмите кнопку «Удалить», чтобы начать процесс удаления.

Далее следует, что система запрашивает пароль. Введите его правильно, и Манджаро очистит ядро ​​от Grub и от остальной системы. Имейте в виду, что вы не можете удалить версию ядра Linux из Manjaro, если используете ее. Сначала вы должны переключиться на другое ядро.

Переключение ядер через терминал

Наряду с установкой ядер через инструмент управления ядром Manjaro Linux, пользователи могут также устанавливать (и удалять) различные версии ядра Linux через терминал и менеджер пакетов pacman. Чтобы найти версии ядра Linux, откройте терминал и используйте этот шаблон поиска:

Читайте также:  Макбук не видит принтер canon

pacman -Ss linux4 * | grep «ядро и модули»

Хотите версию Linux для Manjaro Linux, которая находится под версией 4.x? Если это так, попробуйте этот шаблон поиска. Пожалуйста, поймите, что этот шаблон поиска не идеален.

pacman -Ss linux3 * | grep «ядро и модули»

Используя *, менеджер пакетов перечислит все пакеты Linux с 3.x или 4.x. Когда вы определили точную версию ядра, которое хотите установить, процесс так же прост, как и установка любой другой программы через pacman в терминале. Например: чтобы установить версию ядра 4.12, вы должны сделать:

sudo pacman -S linux412

Удаление ядер в Манджаро через терминал

Удалять старые или альтернативные ядра, установленные на Manjaro, можно довольно легко, прямо в терминале, с помощью менеджера пакетов. Для этого сначала объедините инструмент pacman с фильтром, чтобы найти точное имя удаляемого пакета ядра.

pacman -Ss linux4 * | grep «установлен»

Еще раз, чтобы отфильтровать установленные ядра, которые начинаются с 3, а не с 4, попробуйте использовать этот шаблон:

pacman -Ss linux3 * | grep «установлен»

Этот метод не идеален, но он выделит большинство (если не все) ядра Linux, которые в настоящее время установлены внутри Manjaro. Отсюда обратите внимание на имя пакета и используйте инструмент менеджера пакетов, чтобы удалить его из системы.

Источник

Compiling a custom Linux kernel on Manjaro

Compiling a custom kernel on Manjaro is very simple once you know how to do it and if you just need to change a few configurations then this quick guide is for you!

As such I researched how to do this and I quickly had to face the very unpleasant web of forum posts and passive aggressive “use the search function” dead ends that most threads on the subject end with on the Manjaro Forum. As such I will be saving you the trouble of finding the correct post buried in a thread somewhere and this will be a quick tutorial on how to recompile your kernel quickly and easily.

For the purpose of fixing slow boot times with my 3D accelerated Windows 10 libvirt Virtual machine running on a Manjaro host, it was necessary for me to compile a kernel with a few options that differ from the default kernel. We will use these changes as an example for this guide. Also if you are interested in gaming on a Windows VM on linux, then check my other guide here.

The steps are as follow:

  1. Get the kernel source from the Manjaro gitlab core repository

2. Clone the repository

3. Modify the configuration to suit your needs. In my case I had to remove CONFIG_PREEMPT and enable CONFIG_PREEMPT_VOLUNTARY. These configuration are located in the file starting with “config” and ending with your target architecture. In my case I run an x86_64 machine just like yours probably does, so my config file is “ config.x86_64”

Note: From version 5.7 and onward there is only a single config file for all architectures and it’s named “config”.

4. Update the configuration file checksum as the build tools will check the checksums of every file in the repository before compilation.

5. Compile your kernel. This may take from 15 to 60+ minutes depending on how powerful is your machine

6. Install your newly compiled kernel

Now you may want to add a backup kernel to your grub configuration before rebooting but its up to you!

Now reboot and confirm that your kernel is correctly configured by running the following command:

Источник

How to Change Kernel Version in Manjaro

A kernel is a core component of any Operating system. It works as an interface between the machine hardware and the software applications that allocate hardware resources to system processes. Since each element of a Linux OS is built around it, the increasing software and hardware sophistication requires full kernel utilization. Hence, Linux Kernels are always under development with regular updates and version releases. Similarly, updating kernels is an ideal way to ensure that the devices and software are functioning at their best.

Manjaro offers various ways to identify, upgrade, downgrade or add new/old kernels. Manjaro provides a great graphical user interface known as Manjaro System Manager for kernel management. Moreover, Manjaro package manager Pacman also provides kernel version management.

However, the best feature that distinguishes Manjaro Linux is its hardware detection management tool mhwd-kernel command that allows easy management and installation of multiple kernels.

In this article, we demonstrate the use of the Manjaro command-line terminal and GUI to update, add and remove the Manjaro kernel versions.

Switching Manjaro Kernels via CLI

Manjaro kernel version addition, update, downgrade, and removal can happen via two ways, i.e., Pacman and Manjaro hardware detection tool (mhwd). This section discusses how to switch kernels using Manjaro package manager Pacman and its unique feature mhwd-kernel, side by side.

Pacman: uses the official manjaro repository to upgrade the package database and all system packages.

Читайте также:  Linux red hat sap

mhwd-kernel: manjaro hardware detection command unique feature that provides easy installation and management of system kernels.

Identify In-Use Kernel

Before beginning the process of kernel version upgrade/downgrade, identify current version details via the mhwd-kernel command:

Currently running: 5.9.16- 1 -MANJARO ( linux59 )

The following kernels are installed in your system:

The above command outputs the system kernel version, 5.9.16-1-MANJARO, along with the list of installed kernels.

Upgrade Kernel

One of the other distinguishing features of Manjaro is the use and installation of multiple Kernel versions, as well as the user’s access to bleeding-edge kernels.

Use the pacman command to list all the kernel version packages with 5.x and below:

] $ pacman -Ss linux5 * | grep «kernel and modules»

The Linux414 kernel and modules

The Linux419 kernel and modules

The Linux44 kernel and modules

The Linux49 kernel and modules

The Linux510 kernel and modules

The Linux511 kernel and modules

The Linux512 kernel and modules

The Linux54 kernel and modules

The Linux59 kernel and modules

The Linux-rt-lts-manjaro kernel and modules

The Linux-rt-manjaro kernel and modules

The Linux54-rt kernel and modules

The Linux59-rt kernel and modules

The above command outputs all kernel versions, whereas kernels with the “rt” represent unstable or real-time kernel release.

Use either of the following commands to add the new kernel to the installed list:

] $ sudo mhwd-kernel -i linux510

] $ sudo pacman -S linux510

As shown above, it is not necessary to add the full kernel version number. Similarly, it’s important to note that Manjaro automatically updates all modules of the newly installed version from an old one. For instance, to update from 59 to 5.10, manjaro automatically updates modules in 5.19 with all modules in 5.14.

The above command keeps the old kernel such that the system allows users to choose the kernel preference at the boot screen.

rmc Option

The mhwd-kernel command’s rmc option plays a critical role, as it deletes the existing kernel at the installation of the new kernel. In contrast, the Manjaro official website recommends keeping the old one for a short interval when the system is updating the bleeding-edge kernel.

] $ sudo mhwd-kernel -i linux510 rmc

In any case, Manjaro automatically configures the new kernel; once done, reboot to make changes effective.

Uninstall Kernels

Before attempting to delete any kernel, make sure it’s not currently in use by Manjaro. It’s necessary to delete a total of three main elements, the kernel, its header, and its extra modules, to remove/uninstall from the system.

Use the mhwd-kernel command to remove kernel headers:

] $ sudo mhwd-kernel -r linux510

Use the following pacman command to remove all kernel elements in a single go:

] $ sudo pacman -R linux50 linux50-headers linux50-extramodules

Note: The above command may generate an error if any of the three-element is not present on the system. Similarly, if Manjaro is a virtual machine, this command won’t delete some kernels that contain necessary elements for the virtualization process.

Switching Kernel via GUI

Manjaro Setting Manager offers a series of settings unique to its distribution for hardware configuration and kernel installation. Press the ‘Windows’ key and type ‘Manjaro Setting Manager’ to view the GUI.

Select the ‘Kernel’ to enter the Manjaro GUI kernel management tool. It will list all the available kernel versions and the existing kernel details, as well.

Upgrade Kernel

Choose any of the available versions and click on install to add a new kernel. A screen will pop up for user authentication. Enter your credentials to begin the installation process.

Note that the real-time kernels only serve real-time application users that require little to no delays in I/O. In comparison, the experimental kernel is the next candidate in the release.

Downgrade Kernel

Since every new kernel release adds security patches and drivers, it’s a bit unwise to downgrade the kernel version. However, sometimes old kernel versions work better than the new release. Choose an older version under 5.9 and click install.

Uninstall Kernel

Click on ‘uninstall’ to purge the kernel. Remember not to remove/uninstall the kernel. Switch to another kernel at the boot screen and uninstall the one that isn’t required.

Conclusion

The article covers various ways to change Manjaro kernel versions. We discussed the Manjaro Hardware detection tool and Manjaro Package Manager commands, mhwd-kernel, and Pacman commands to add, remove, and update kernel versions. We also discussed the Manjaro GUI Kernel Management tool that provides a list of available kernels to choose from outdated and latest kernel versions.

About the author

Usama Azad

A security enthusiast who loves Terminal and Open Source. My area of expertise is Python, Linux (Debian), Bash, Penetration testing, and Firewalls. I’m born and raised in Wazirabad, Pakistan and currently doing Undergraduation from National University of Science and Technology (NUST). On Twitter i go by @UsamaAzad14

Источник

Поделиться с друзьями
КомпСовет
Adblock
detector