因为是老的日本,所以是 xen ,没有 grub2
看了 linode 的教程: https://www.linode.com/docs/tools-reference/custom-kernels-distros/run-a-distributionsupplied-kernel-with-pvgrub
/boot/grub/menu.lst 如下:
timeout 5
title CentOS 7 (4.10)
root (hd0)
kernel /boot/vmlinuz-4.10.3-1.el7.elrepo.x86_64 root=/dev/xvda
initrd /boot/initramfs-4.10.3-1.el7.elrepo.x86_64.img
也确保了 /boot 下有 vmlinuz-4.10.3-1.el7.elrepo.x86_64 root=/dev/xvda 和 initrd /boot/initramfs-4.10.3-1.el7.elrepo.x86_64.img
然后修改 linode 的 Kernel 为 pv-grub-x86_64 ,重启后启动不了,通过 Launch Lish Console 看到一直卡在这里:
[10171466.997898] audit: type=1400 audit(1489754987.062:8): avc: denied { setattr } for pid=411 comm="auditd" name="a
udit.log" dev="xvda" ino=723 scontext=system_u:system_r:auditd_t:s0 tcontext=system_u:object_r:unlabeled_t:s0 tclass=fil
e permissive=1
[ OK ] Started Security Auditing Service.
Starting Update UTMP about System Boot/Shutdown...
[ OK ] Started Update UTMP about System Boot/Shutdown.
[10171467.145078] input: PC Speaker as /devices/platform/pcspkr/input/input0
[ OK ] Found device /dev/hvc0.
[10171467.225362] RAPL PMU: API unit is 2^-32 Joules, 3 fixed counters, 163840 ms ovfl timer
[10171467.225380] RAPL PMU: hw unit of domain pp0-core 2^-16 Joules
[10171467.225387] RAPL PMU: hw unit of domain package 2^-16 Joules
[10171467.225393] RAPL PMU: hw unit of domain dram 2^-16 Joules
[10171467.259634] AVX version of gcm_enc/dec engaged.
[10171467.259647] AES CTR mode by8 optimization enabled
[ OK ] Found device /dev/xvdb.
Activating swap /dev/xvdb...
[10171467.350582] Adding 262140k swap on /dev/xvdb. Priority:-1 extents:1 across:262140k SSFS
[ OK ] Activated swap /dev/xvdb.
[ OK ] Reached target Swap.
[10171467.444301] alg: No test for pcbc(aes) (pcbc-aes-aesni)
[10171467.519767] EDAC MC: Ver: 3.0.0
[10171467.524505] EDAC sbridge: Ver: 1.1.1
[10171477.858269] random: crng init done
Warning: Skipping the following R/O filesystems:
/sys/fs/cgroup
还有另外一台老日本的一模一样的服务器,升 4.10 后完全没问题能启动
1
msg7086 2017-03-18 13:09:01 +08:00
有什么原因要用 CentOS 吗? Debian 搞自定义内核挺简单的好像。
话说你这个应该是引导起来以后卡住的,具体原因很难说,建议敲客服问问看。 |
2
lucifer9 2017-03-20 13:45:50 +08:00
看看 /etc/fstab 里面有没有写 barrier 之类的
有的话去掉,都改成 defaults |