“error getting socket: Address family not supported by protocol”的解决方案_MQ, Tuxedo及OLTP讨论区_Weblogic技术|Tuxedo技术|中间件技术|Oracle论坛|JAVA论坛|Linux/Unix技术|hadoop论坛_联动北方技术论坛  
网站首页 | 关于我们 | 服务中心 | 经验交流 | 公司荣誉 | 成功案例 | 合作伙伴 | 联系我们 |
联动北方-国内领先的云技术服务提供商
»  游客             当前位置:  论坛首页 »  自由讨论区 »  MQ, Tuxedo及OLTP讨论区 »
总帖数
1
每页帖数
101/1页1
返回列表
0
发起投票  发起投票 发新帖子
查看: 2940 | 回复: 0   主题:  “error getting socket: Address family not supported by protocol”的解决方案        下一篇 
Michelle
注册用户
等级:列兵
经验:88
发帖:58
精华:0
注册:2011-8-11
状态:离线
发送短消息息给Michelle 加好友    发送短消息息给Michelle 发消息
发表于: IP:您无权察看 2015-3-31 10:20:20 | [全部帖] [楼主帖] 楼主

“error getting socket: Address family not supported by protocol”的解决方案

原本我是想KVM支持NAT,在重新编译kernel,当然为了NAT,我得去重新menuconfig,不知为啥手贱,估计将“Networking options”里面的“Unix domain sockets”选项选为了编译为module,于是就遇到了如下的kernel panic。

FATAL: Module scsi_wait_scan not found.
udevadm[2067]: error getting socket: Address family not supported by protocol
udevadm[2073]: error getting socket: Address family not supported by protocol
dracut Warning: No root device "block:/dev/disk/by-uuid/e006b79d-9eb6-4f18-a11c-517448eb074f" found
dracut Warning: Boot has failed. To debug this issue add "rdshell" to the kernel command line.
dracut Warning: Signal caught!
dracut Warning: Boot has failed. To debug this issue add "rdshell" to the kernel command line.
Kernel panic - not syncing: Attempted to kill init! exitcode=0x00000100
Pid: 1, comm: init Not tainted 3.5.0+ #1
Call Trace:
[<ffffffff81361cb8>] ? panic+0xbe/0x1c6
[<ffffffff8102ff51>] ? do_exit+0x366/0x7c0
[<ffffffff8103041f>] ? do_group_exit+0x74/0x9e
[<ffffffff8103045b>] ? sys_exit_group+0x12/0x19
[<ffffffff81369562>] ? system_call_fastpath+0x16/0x1b


当我遇到这个panic的现象后,其实我也进行了.config文件的对比,我其实也看到了“CONFIG_UNIX”这一项的差异,由于还有其他的不同点,我就没把这个差异放在心上,没重视它。后来才发现,“CONFIG_UNIX”是为了配置“Unix domain sockets”的,“CONFIG_UNIX”一般都是应该配置为y(编译进kernel),如果只有在少数(如嵌入式)系统中才配置为m(作为module,名为”unix”的module)。即是没有连接到任何网络,有很多常用的程序都使用“unix domain socket”进行通信的,如X-Window、syslog等程序,估计还有我本例遇到的udevadm(udevd)等程序,都是依赖于“CONFIG_UNIX=y”这个配置的。

另外,看了一下配置kernel时,对CONIFG_UNIX选项的说明,如下,看了就都明白了吧。

CONFIG_UNIX:
x If you say Y here, you will include support for Unix domain sockets;
x sockets are the standard Unix mechanism for establishing and
x accessing network connections. Many commonly used programs such as
x the X Window system and syslog use these sockets even if your
x machine is not connected to any network. Unless you are working on
x an embedded system or something similar, you therefore definitely
x want to say Y here.
x To compile this driver as a module, choose M here: the module will be
x called unix. Note that several important services won't work
x correctly if you say M here and then neglect to load the module.
x Say Y unless you know what you are doing.
x Symbol: UNIX [=y]
x Type : tristate
x Prompt: Unix domain sockets
x Defined at net/unix/Kconfig:5
x Depends on: NET [=y]
x Location:
x -> Networking support (NET [=y])
x -> Networking options


【后记1】2012.08

关于“FATAL: Module scsi_wait_scan not found.”这个错误,应该在kernel config中配置“CONFIG_SCSI_SCAN_ASYNC=y”,如果有“CONFIG_SCSI_WAIT_SCAN”则也应该配置“CONFIG_SCSI_WAIT_SCAN=m”。加这个后记是因为,我在8月份遇到一次kernel panic是和“FATAL: Module scsi_wait_scan not found.”相关的。

【后记2】2012.10.30

我在启动KVM guest(guest中使用Linux 3.6 kernel)再次遇到一直打印“FATAL: Module scsi_wait_scan not found.”的错误信息。后来查了一下,Linux 3.6中已经没有CONFIG_SCSI_WAIT_SCAN配置项可选了,后来发现guest的grub中的root设备写法的问题(这时不能写成/dev/sda1)。

出现问题的grub中kernel行如下:

kernel (hd0,0)/boot/vmlinuz-3.6.0 ro root=/dev/sda1


修改为UUID的方式去找到root设备,就没有“FATAL: Module scsi_wait_scan not found.”错误,可以正常启动了,如下:

kernel /boot/vmlinuz-3.6.0 ro ro root=UUID=7391683c-12c6-405a-b2e0-ee05c678772c


--转自 北京联动北方科技有限公司




赞(0)    操作        顶端 
总帖数
1
每页帖数
101/1页1
返回列表
发新帖子
请输入验证码: 点击刷新验证码
您需要登录后才可以回帖 登录 | 注册
技术讨论