“Vmware”的版本间差异

来自Shiyin's note
跳到导航 跳到搜索
(以“VMware 10.0.1 modules & kernel 3.13 Short story VMware Workstation kernels don’t compile correctly on Linux Kernel 3.13 located in the Fedora rawhide repo. Here...”为内容创建页面)
 
 
(未显示同一用户的7个中间版本)
第1行: 第1行:
==解决在新版内核下编译vmware player内核模块错误==
VMware 10.0.1 modules & kernel 3.13


错误提示:/tmp/modconfig-e1UexH/vmnet-only/netif.c:152:64: 错误:宏“alloc_netdev”需要 4 个参数,但只给出了 3 个
Short story VMware Workstation kernels don’t compile correctly on Linux Kernel 3.13 located in the Fedora rawhide repo.
cd /usr/lib/vmware/modules/source
Here’s the module patch: (Updated: Thanks DanDar3)
sudo tar xf vmnet.tar
205a206 > #if LINUX_VERSION_CODE < KERNEL_VERSION(3, 13, 0) 206a208,210 > #else > VNetFilterHookFn(const struct nf_hook_ops *ops, // IN: > #endif 255c259,263 < transmit = (hooknum == VMW_NF_INET_POST_ROUTING); --- > #if LINUX_VERSION_CODE < KERNEL_VERSION(3, 13, 0) > transmit = (hooknum == VMW_NF_INET_POST_ROUTING); > #else > transmit = (ops->hooknum == VMW_NF_INET_POST_ROUTING); > #endifSave that text as vmnet313.patch in your home dir.
cd vmnet-only
sudo vim netif.c
;修改152行,dev = alloc_netdev(sizeof *netIf, deviceName, VNetNetIfSetup);改为dev = alloc_netdev(sizeof *netIf, deviceName, NET_NAME_UNKNOWN, VNetNetIfSetup);
cd ..
sudo mv vmnet.tar vmnet.tar.bak
sudo tar cf vmnet.tar vmnet-only
vmplayer
;成功运行后,可以删除vmnet.tar.bak及vmnet-only文件夹



#Change directory into the vmware module source directory cd /usr/lib/vmware/modules/source# untar the vmnet modules tar -xvf vmnet.tar#run a the patch you should have just saved earlier patch vmnet-only/filter.c < ~/vmnet313.patch# re-tar the modules tar -uvf vmnet.tar vmnet-only#delete the previous working directory rm -r vmnet-only
==fc23上出错==
# run the vmware
参见知乎 https://www.zhihu.com/question/45115604?sort=created
vmvare

==[[fedora 25]]安装vmware pro 12,启动出错==
错误信息:

tmp/modconfig-LhcFS7/vmnet-only/userif.c:117:13: 错误:提供给函数‘get_user_pages’的实参太多
retval = get_user_pages(addr, 1, 1, 0, &page, NULL);

*找到/usr/lib/vmware/modules/source下, unpack vmmon.tar ( hostif.c )和 vmnet.tar ( userif.c )
*find all get_user_pages function.
*Remove one parameter before "ppage" or "&page"
*pack it back.

---
'''有效license:AA3E0-0VDE1-0893Z-KGZ59-QGAVF
'''

2017年3月1日 (三) 02:47的最新版本

解决在新版内核下编译vmware player内核模块错误

错误提示:/tmp/modconfig-e1UexH/vmnet-only/netif.c:152:64: 错误:宏“alloc_netdev”需要 4 个参数,但只给出了 3 个

cd /usr/lib/vmware/modules/source
sudo tar xf vmnet.tar
cd vmnet-only
sudo vim netif.c
修改152行,dev = alloc_netdev(sizeof *netIf, deviceName, VNetNetIfSetup);改为dev = alloc_netdev(sizeof *netIf, deviceName, NET_NAME_UNKNOWN, VNetNetIfSetup);
cd ..
sudo mv vmnet.tar vmnet.tar.bak
sudo tar cf vmnet.tar vmnet-only
vmplayer

成功运行后,可以删除vmnet.tar.bak及vmnet-only文件夹


fc23上出错

参见知乎 https://www.zhihu.com/question/45115604?sort=created

fedora 25安装vmware pro 12,启动出错

错误信息:

tmp/modconfig-LhcFS7/vmnet-only/userif.c:117:13: 错误:提供给函数‘get_user_pages’的实参太多
   retval = get_user_pages(addr, 1, 1, 0, &page, NULL);
  • 找到/usr/lib/vmware/modules/source下, unpack vmmon.tar ( hostif.c )和 vmnet.tar ( userif.c )
  • find all get_user_pages function.
  • Remove one parameter before "ppage" or "&page"
  • pack it back.

--- 有效license:AA3E0-0VDE1-0893Z-KGZ59-QGAVF