顯示具有 grub 標籤的文章。 顯示所有文章
顯示具有 grub 標籤的文章。 顯示所有文章

2022/05/09

今天要disable ubuntu 18.04 的ipv6的時候


在 /etc/sysctl.conf 加入以下三行


net.ipv6.conf.all.disable_ipv6=1

net.ipv6.conf.default.disable_ipv6=1

net.ipv6.conf.lo.disable_ipv6 = 1


sysctl -p 是有作用的 可是重開就不行了

有人說是bug

只好換一種方法

修改 /etc/default/grub

GRUB_CMDLINE_LINUX="ipv6.disable=1"

再update grub

sudo update-grub


重開就ok了


https://linuxconfig.org/how-to-disable-ipv6-address-on-ubuntu-18-04-bionic-beaver-linux

2021/08/10

proxmox 升到7後

LXC的 Centos 7 無法開机 出現以下錯誤


WARN: old systemd (< v232) detected, container won't run in a pure cgroupv2 environment! Please see documentation -> container -> cgroup version.

TASK WARNINGS: 1 


解決方法如下



vi /etc/default/grub


I changed this line from,

GRUB_CMDLINE_LINUX_DEFAULT="quiet"

to

GRUB_CMDLINE_LINUX_DEFAULT="systemd.unified_cgroup_hierarchy=0 quiet"


更新grub

update-grub


重開機


https://pve.proxmox.com/pve-docs/chapter-sysadmin.html#sysboot_edit_kernel_cmdline

https://pve.proxmox.com/wiki/Upgrade_from_6.x_to_7.0#Old_Container_and_CGroupv2

https://pve.proxmox.com/pve-docs/chapter-pct.html#pct_cgroup_compat

https://forum.proxmox.com/threads/unified-cgroup-v2-layout-upgrade-warning-pve-6-4-to-7-0.92459/

2020/06/28

今天升到 ubuntu 20.04 後出現無法開机的情況
直接進入
grub rescure 

解決方法如下

使用 ubuntu live 開几進入桌面
打開 xterminal

查看原本的磁碟代號

sudo fdisk -l

假設為 /dev/sda 

而且原本的 /boot 放在 /dev/sda1

sudo mkdir /mnt/ubuntu

sudo mount /dev/sda1 /mnt/ubuntu

sudo grub-install --boot-directory=/mnt/ubuntu/boot /dev/sda

重開機

2018/09/09

最近電腦開不了機
之前就有幾次
ram重插拔後又可以
不過這次看來是完全GG了
所以上網買了 cpu ram 主機板的套裝
cpu 配的是 AMD A4-6300 APU with Radeon(tm) HD Graphics

要開始裝os  linux mint 19 就碰到無法開機的問題
到linux mint的網站看到以下的解法
在開機時要選擇 Compatibility mode
可是裝好後開機還是有問題
還有一個地方要改
/boot/grub/grub.conf裡

Replace quiet splash with nomodeset and press Enter to boot.

可是另一個問題又來了
醬我每次更新kernel又要再重改一次
所以來改一下預設值
/etc/default/grub


#GRUB_CMDLINE_LINUX_DEFAULT="quiet splash"
GRUB_CMDLINE_LINUX_DEFAULT="nomodeset"

醬開機就沒問題了
再來是開進os後
開youtube
1080P竟然很lag

再來裝一下vga的driver
ubuntu有直接提供
sudo apt install fglrx-pxpress
順了

另外就是輸入法 linux mint 19預設是使用fcitx 
我還是比較習慣用ibus 所以改了一下


https://linuxmint-installation-guide.readthedocs.io/en/latest/boot_options.html

https://launchpad.net/ubuntu/bionic/+package/fglrx-pxpress

2014/02/10

昨天host重開
有一個guest一直停在

Booting from Hard Disk...

倒回之前的backup也沒用
想不到是grub壞了
修復方法如下
到底是誰搞壞的
Orz

單單利用 grub 安裝開機程式

你也可利用 grub 這個指令來安裝開機程式,它卻不會在 /boot/grub 內安裝 Grub 的檔案。要是開機程式被蓋過或損壞了,此方法可修復 Grub 的安裝。

執行 grub。
你可選擇執行 find /boot/grub/stage1 尋找哪個分割區在 /boot/grub 內含有 Grub 所需的檔案。如果你的 /boot 採用獨立分割區,請執行 find /grub/stage1。
執行 root [按 Grub 方式命名的分割區] 來指定哪個分割區的 /boot/grub 內含有 Grub 檔案及備有 /boot/grub/grub.conf。
利用 setup [按 Grub 方式命名的開機程式位置] 來安裝開機程式。
執行 quit 來離開 Grub 程式。
範例:


[root@localhost ~]# grub
Probing devices to guess BIOS drives. This may take a long time.

    GNU GRUB  version 0.97  (640K lower / 3072K upper memory)

 [ Minimal BASH-like line editing is supported.  For the first word, TAB
   lists possible command completions.  Anywhere else TAB lists the possible
   completions of a device/filename.]

grub> find /boot/grub/stage1
 (hd0,5)
 (hd0,9)

grub> root (hd0,5)
 Filesystem type is ext2fs, partition type 0x83

grub> setup (hd0)
 Checking if "/boot/grub/stage1" exists... yes
 Checking if "/boot/grub/stage2" exists... yes
 Checking if "/boot/grub/e2fs_stage1_5" exists... yes
 Running "embed /boot/grub/e2fs_stage1_5 (hd0)"...  15 sectors are embedded.
succeeded
 Running "install /boot/grub/stage1 (hd0) (hd0)1+15 p
(hd0,5)/boot/grub/stage2
/boot/grub/grub.conf"... succeeded
Done.

grub> quit

http://wiki.centos.org/zh-tw/HowTos/GrubInstallation