升级到linux-image-3.13.0-46后安装vmware-tools 9.9出现错误
After having upgraded my guest ubuntu to linux-image-3.13.0-46 I got an error install vmware-tools and I cannot share folders any more.
在将我的访客ubuntu升级到linux-image-3.13.0-46之后,我在安装vmware-tools时出现了错误,我再也不能共享文件夹了。
I ran vmware player 7.0.0 build-2305329 both in Windows 8 and Ubuntu 14.04 LTS host machine and during the installation I got the following error log out:
我在Windows 8和Ubuntu 14.04 LTS主机上运行了vmware player 7.0.0 build-2305329,在安装过程中我有以下错误退出:
from /tmp/modconfig-NVbKuD/vmhgfs-only/inode.c:29:
include/linux/kernel.h:793:27: error: ‘struct dentry’ has no member named ‘d_alias’
const typeof( ((type *)0)->member ) *__mptr = (ptr); \
^
Is there any workaround about this issue?
在这个问题上有什么变通的办法吗?
Thanks
谢谢
4 个解决方案
#1
11
vmware-tools-distrib-9.9.2-2496486:
vmware -工具- distrib 9.9.2 - 2496486:
I have fixed the problem by going to the directory where vmhgfs.tar is located (in my case /usr/lib/vmware-tools/modules/source), unpack the tar and manually edit inode.c.
我通过访问vmhgfs所在的目录解决了这个问题。tar位于(在我的例子中是/usr/lib/vmware-tools/modules/source),解压缩tar并手动编辑inode.c。
At line 1925(just search for "d_alias" to find the exact line) you need to add an if. In the end looks like that:
在1925行(只需搜索“d_alias”以找到确切的行),您需要添加一个if。最后是这样的:
#if LINUX_VERSION_CODE < KERNEL_VERSION(3, 13, 0)
d_alias) {
#else
d_u.d_alias) {
#endif
Then again around line 1983 (search again for "d_alias"):
然后在第1983行(再次搜索“d_alias”):
#if LINUX_VERSION_CODE < KERNEL_VERSION(3, 13, 0)
struct dentry *dentry = list_entry(pos, struct dentry, d_alias);
#else
struct dentry *dentry = list_entry(pos, struct dentry, d_u.d_alias);
#endif
Caveat: Not sure on the kernel version but I have put there 3,13,0 though my Ubuntu reports:
注意:不确定内核版本,但是我已经把3、13、0放在了我的Ubuntu报告中:
# uname -a
Linux md-ubuntu 3.13.0-46-generic #76-Ubuntu SMP Thu Feb 26 18:52:13 UTC 2015 x86_64 x86_64 x86_64 GNU/Linux
And this was working fine with 3.13.0-45.
这个3。13。0-45没问题。
So probably if you downgrade the kernel the above hack will not work properly.
因此,如果您降低内核的级别,上面的代码可能无法正常工作。
Then you need to pack again the tar archive (just move the old one out of the way:
然后您需要再次打包tar存档文件(只需将旧的文件移开即可:
# mv vmhgfs.tar vmhgfs.tar.orig
and pack again the directory:
然后重新打包目录:
# tar cvf vmhgfs.tar vmhgfs-only
)
)
Hope it helps.
希望它可以帮助。
更多相关文章
- 我如何理解这个编译器错误:“...的多重定义”
- 有关Linux内核分析课程的总结
- 20169210《Linux内核原理与分析》第七周作业
- linux内核分析——扒开系统调用的三层皮(下)
- Ubuntu 12.10安装Bochs 2.6, 调试linux-0.11内核
- Linux内核黑客的虚拟环境
- linux内核日志 dmesg 出现的提示及含意
- Linux内核数据结构之链表
- Linux2.6.6内核下ACPI PCI Hot-Plug的实现机制(下)