translating

This commit is contained in:
geekpi 2022-12-13 08:43:58 +08:00
parent 5da1e2580c
commit 41204c3485
2 changed files with 122 additions and 122 deletions

View File

@ -1,122 +0,0 @@
[#]: subject: "How to Access UEFI Settings in Linux Systems"
[#]: via: "https://itsfoss.com/access-uefi-from-linux/"
[#]: author: "Sagar Sharma https://itsfoss.com/author/sagar/"
[#]: collector: "lkxed"
[#]: translator: "geekpi"
[#]: reviewer: " "
[#]: publisher: " "
[#]: url: " "
How to Access UEFI Settings in Linux Systems
======
Want to check the boot order or the power settings at the firmware level? **You can access the UEFI settings by pressing the F2, F10 or Del buttons when your system boots**.
The problem with this approach is that you may not know the exact key and must be alert about pressing those keys at the right time.
![Mr. Bean][1a]
If you dont want to feel like Mr. Bean in the above Gif, you can access the UEFI settings from the [Grub bootloader][1] screen in Linux.
![uefi firmware settings grub linux][2]
You see this screen when you turn on your Linux system. Most Linux distributions like Fedora and Ubuntu use Grub and they allow you to access the UEFI settings from the Grub screen like this.
What if you dont see this screen or your distro doesnt use Grub? There are still ways to access UEFI settings from within Linux.
Before you see how to do that, please [ensure that your system uses UEFI][3].
**_Another important thing. Your system will reboot into UEFI settings._** _You cannot access and modify the firmware settings from within an operating system._
### Boot into UEFI settings from Linux
This method will only work on Linux distros having systemd. This means this method will work on anything based on Ubuntu, Debian, Fedora, and any mainstream Arch-based distros, including Manjaro and EndeavourOS.
It is still a good idea to [ensure that your Linux distro uses systemd][4]. Use the given command and if it returns systemd you are good to go:
```
ps --no-headers -o comm 1
```
![how to know if i am using systemd on linux?][5]
Once you figure out that your distro is utilizing systemd, you can use the given command to boot into UEFI settings:
```
systemctl reboot --firmware-setup
```
Let me break down the used options first:
- `reboot`: As its name suggest, it will reboot your system.
- `--firmware-setup`: When this option is used with `reboot`, it will indicate to the systems firmware to boot into the firmware setup interface.
Yup, that was it! A single command and you will be kicked into UEFI settings. I know Windows allows [booting into UEFI firmware settings from within Windows][6]. Its good to see something similar in Linux as well.
#### Create a desktop shortcut to boot into UEFI settings (optional)
If you often find yourself booting into the UEFI settings and dont remember the command all the time, you can make your life easier by creating a desktop shortcut. This will let you boot into UEFI by clicking on desktop icon.
_**Now, this is unnecessary and not required for most Linux users. Do it only if you feel the need for it. The method requires [editing files in the command line][7].**_
First, use the given command to create a desktop shortcut file for UEFI settings:
```
sudo nano /usr/share/applications/uefi-reboot.desktop
```
And paste the following content in the file:
```
[Desktop Entry]
Name=UEFI Firmware Setup (Reboot)
Comment=Access the motherboard configuration utility
Exec=systemctl reboot --firmware-setup
Icon=system-restart
Terminal=false
Type=Application
Categories=System;Settings;
```
![create a desktop shortcut to boot into uefi settings][8]
Once done, [save the changes and exit from the nano][9] text editor.
And now, you will find the shortcut for UEFI Firmware Setup in your system menu:
![boot into uefi firmware from system menu][10]
Thats it! A neat way to get into UEFI settings.
### Wrapping Up
The classic ways of accessing the boot settings may be a little inconvenient for some people. The grub screen may not show the UEFI option for older versions.
And this is where the systemd method shines. I found this method a lifesaver when my system crashed and my function keys were not responding, which are necessary to boot into UEFI (thats what I thought then!).
I hope you find it equally helpful.
--------------------------------------------------------------------------------
via: https://itsfoss.com/access-uefi-from-linux/
作者:[Sagar Sharma][a]
选题:[lkxed][b]
译者:[译者ID](https://github.com/译者ID)
校对:[校对者ID](https://github.com/校对者ID)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]: https://itsfoss.com/author/sagar/
[b]: https://github.com/lkxed
[1a]: https://external-preview.redd.it/dxmsKYDmzgfb1thu3EFI8Ni-DNfprNX8W8xDtff4QWU.gif?format=mp4&s=c31204644ac6a2a348133986714ff97cf3c4a48a
[1]: https://itsfoss.com/what-is-grub/
[2]: https://itsfoss.com/wp-content/uploads/2022/12/uefi-firmware-settings-grub-linux.webp
[3]: https://itsfoss.com/check-uefi-or-bios/
[4]: https://linuxhandbook.com/check-if-systemd/
[5]: https://itsfoss.com/wp-content/uploads/2022/12/how-to-know-if-i-am-using-systemd-on-linux.png
[6]: https://itsfoss.com/access-uefi-settings-windows-10/
[7]: https://learnubuntu.com/edit-files-command-line/
[8]: https://itsfoss.com/wp-content/uploads/2022/12/create-a-desktop-shortcut-to-boot-into-uefi-settings.png
[9]: https://linuxhandbook.com/nano-save-exit/
[10]: https://itsfoss.com/wp-content/uploads/2022/12/boot-into-uefi-firmware-from-system-menu.png

View File

@ -0,0 +1,122 @@
[#]: subject: "How to Access UEFI Settings in Linux Systems"
[#]: via: "https://itsfoss.com/access-uefi-from-linux/"
[#]: author: "Sagar Sharma https://itsfoss.com/author/sagar/"
[#]: collector: "lkxed"
[#]: translator: "geekpi"
[#]: reviewer: " "
[#]: publisher: " "
[#]: url: " "
如何在 Linux 系统中访问 UEFI 设置
======
想要在固件级别检查启动顺序或电源设置? **你可以在系统启动时按 F2、F10 或 Del 按键访问 UEFI 设置**
这种方法的问题是你可能不知道确切的键,并且必须警惕在正确的时间按下这些键。
![Mr. Bean][1a]
如果你不想像上面 Gif 中的憨豆先生,你可以从 Linux 中的 [Grub bootloader][1] 也没访问 UEFI 设置。
![uefi firmware settings grub linux][2]
当你打开 Linux 系统时你会看到这个页面。Fedora 和 Ubuntu 等大多数 Linux 发行版都使用 Grub它们允许你像这样从 Grub 页面访问 UEFI 设置。
如果你没有看到此页面或你的发行版不使用 Grub 怎么办? 仍然有一些方法可以从 Linux 中访问 UEFI 设置。
在你了解如何操作之前,请[确保你的系统使用 UEFI][3]。
**_另一件重要的事情。你的系统将重启进入 UEFI 设置。_** _你无法从操作系统中访问和修改固件设置。_
### 从 Linux 启动到 UEFI 设置
此方法仅适用于具有 systemd 的 Linux 发行版。这意味着这种方法适用于任何基于 Ubuntu、Debian、Fedora 和任何主流的基于 Arch 的发行版,包括 Manjaro 和 EndeavourOS。
[确保你的 Linux 发行版使用 systemd][4] 仍然是一个好主意。使用给定的命令,如果它返回 systemd你就可以开始了
```
ps --no-headers -o comm 1
```
![how to know if i am using systemd on linux?][5]
当你发现你的发行版正在使用 systemd你可以使用给定的命令启动到 UEFI 设置:
```
systemctl reboot --firmware-setup
```
让我首先分解使用的选项:
- `reboot`:顾名思义,它将重启你的系统。
- `--firmware-setup`: 当此选项与 `reboot` 一起使用时,它会指示系统固件启动进入固件设置界面。
就是这样! 一个命令,你将进入 UEFI 设置。我知道 Windows 允许[从 Windows 中启动进入 UEFI 固件设置][6]。很高兴在 Linux 中看到类似的东西。
#### 创建桌面快捷方式以启动到 UEFI 设置(可选)
如果你经常发现自己启动进入 UEFI 设置并且不记得所有命令,你可以通过创建桌面快捷方式让你的生活更轻松。这将使你可以通过单击桌面图标启动到 UEFI。
_**现在,对于大多数 Linux 用户来说,这是不必要的,也不是必需的。只有当你觉得有必要时才去做。该方法需要[在命令行中编辑文件][7]。**_
首先,使用给定的命令为 UEFI 设置创建桌面快捷方式文件:
```
sudo nano /usr/share/applications/uefi-reboot.desktop
```
并将以下内容粘贴到文件中:
```
[Desktop Entry]
Name=UEFI Firmware Setup (Reboot)
Comment=Access the motherboard configuration utility
Exec=systemctl reboot --firmware-setup
Icon=system-restart
Terminal=false
Type=Application
Categories=System;Settings;
```
![create a desktop shortcut to boot into uefi settings][8]
完成后,[保存更改并退出 nano][9] 文本编辑器。
现在,你将在系统菜单中找到 UEFI 固件设置的快捷方式:
![boot into uefi firmware from system menu][10]
完成了! 一种进入 UEFI 设置的巧妙方法。
### 总结
访问启动设置的经典方法对某些人来说可能有点不方便。grub 页面可能不会显示旧版本的 UEFI 选项。
这就是 systemd 方法的亮点所在。当我的系统崩溃并且我的功能键没有响应时,我发现这种方法是救命稻草,这是启动到 UEFI 所必需的(我当时就是这么想的!)。
我希望你发现它同样有用。
--------------------------------------------------------------------------------
via: https://itsfoss.com/access-uefi-from-linux/
作者:[Sagar Sharma][a]
选题:[lkxed][b]
译者:[geekpi](https://github.com/geekpi)
校对:[校对者ID](https://github.com/校对者ID)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]: https://itsfoss.com/author/sagar/
[b]: https://github.com/lkxed
[1a]: https://external-preview.redd.it/dxmsKYDmzgfb1thu3EFI8Ni-DNfprNX8W8xDtff4QWU.gif?format=mp4&s=c31204644ac6a2a348133986714ff97cf3c4a48a
[1]: https://itsfoss.com/what-is-grub/
[2]: https://itsfoss.com/wp-content/uploads/2022/12/uefi-firmware-settings-grub-linux.webp
[3]: https://itsfoss.com/check-uefi-or-bios/
[4]: https://linuxhandbook.com/check-if-systemd/
[5]: https://itsfoss.com/wp-content/uploads/2022/12/how-to-know-if-i-am-using-systemd-on-linux.png
[6]: https://itsfoss.com/access-uefi-settings-windows-10/
[7]: https://learnubuntu.com/edit-files-command-line/
[8]: https://itsfoss.com/wp-content/uploads/2022/12/create-a-desktop-shortcut-to-boot-into-uefi-settings.png
[9]: https://linuxhandbook.com/nano-save-exit/
[10]: https://itsfoss.com/wp-content/uploads/2022/12/boot-into-uefi-firmware-from-system-menu.png