mount /dev/sdx /mnt/gentoo mount -t proc none /mnt/gentoo/proc/ 或 mount -t proc proc /mnt/gentoo/proc/ mount --rbind /sys /mnt/gentoo/sys/ mount --rbind /dev /mnt/gentoo/dev/ mount --rbind /tmp /mnt/gentoo/tmp (gentoo) 可选:mount --rbind /run /mnt/arch/run (arch) DNS: cp /etc/resolv.conf etc/resolv.conf chroot /mnt/gentoo /bin/bash env-update (gentoo) source /etc/profile
Optionally, create a unique prompt to be able to differentiate your chroot environment:
export PS1="(chroot) $PS1"
本文出自 “博主:孤逐王” 博客,请务必保留此出处http://aceking.blog.51cto.com/3681913/1561554
原文地址:http://aceking.blog.51cto.com/3681913/1561554