본문 바로가기

TroubleShooting/Kernel

커널 컴파일후, 부팅 실패 - mount: could not find filesystem '/dev/root'

728x90
CentOS 5.2(v2.6.18) 를 최신 커널로 올리기 위해 kernel.org 에서 mainline 인 최신 버전(저 같은 경우는v2.6.35.4) 을 다운받아서 config 설정을 하고 컴파일 한후, 재부팅하면
다음과
다음과 비슷한 에러메시지를 내고 멈추는 경우가 있습니다. 
Mounting root filesystem.
mount: could not find filesystem '/dev/root'
Setting up other filesystems.
Setting up new root fs
setuproot: moving /dev failed: No such file or directory
no fstab.sys, mounting internal defaults
setuproot: error mounting /proc: No such file or directory
setuproot: error mounting /sys: No such file or directory
Switching to new root and running init.
unmounting old /dev
unmounting old /proc
unmounting old /sys
switchroot: mount failed: No such file or directory
Kernel panic - not syncing: Attempted to kill init!
그래서, 찾아본 곳이 아래 2 곳이었는데 그래도 동일하게 에러가 납니다. 드라이버 문제보다는 분명히 파일시스템하고 관계과 있을거라 생각하고 SATA 관련 설정을 다 켜보았지만 똑같은 결과가 나왔습니다.
http://wiki.centos.org/HowTos/Custom_Kernel
http://www.howtoforge.com/kernel_compilation_centos_p2

한번 더 힘을 내서 찾았는데, 이번에는 아래에서 해결 방법을 찾았습니다. ".config" 에서 아래 항목을 추가한 후 컴파일해서 부팅해보면 정상적으로 부팅합니다.
CONFIG_SYSFS_DEPRECATED_V2=y
관련된 링크는 
http://funky-dennis.livejournal.com/3290.html입니다.