Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Virtual machine monitor done
- Virtual machine communication interface done
- VM communication interface socket family done
- Blocking file system done
- Virtual ethernet failed
- VMware Authentication Daemon done
- 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);
- > #endif
- sudo -E -s
- cd /usr/lib/vmware/modules/source/
- cp vmnet.tar vmnet.tar.original
- tar xvf vmnet.tar vmnet-only/filter.c
- patch vmnet-only/filter.c < /tmp/filter.c.diff
- tar -uvf vmnet.tar vmnet-only/filter.c
- rm -rf vmnet-only/
- Starting VMware services:
- Virtual machine monitor done
- Virtual machine communication interface done
- VM communication interface socket family done
- Blocking file system done
- Virtual ethernet done
- VMware Authentication Daemon done
- Shared Memory Available done
- sudo chown -R one:one .vmware
- curl http://pastie.org/pastes/9636106/download -o /tmp/vmware-3.17.patch
- cd /usr/lib/vmware/modules/source
- for i in vmci vmmon vmnet vsock; do tar -xf $i.tar; done
- patch -p1 -i /tmp/vmware-3.17.patch
- for i in *-only; do tar -cf ${i/-only}.tar $i; done
- rm -r *-only
- vmware-modconfig --console --install-all
- userif.c
- #!/bin/bash
- cat << EOF > /tmp/filter.c.patch
- --- vmnet-only/filter.c 2013-10-18 15:11:55.000000000 -0400
- +++ vmnet-only/filter.c 2013-12-21 20:15:15.000000000 -0500
- @@ -27,6 +27,7 @@
- #include "compat_module.h"
- #include <linux/mutex.h>
- #include <linux/netdevice.h>
- +#include <linux/version.h>
- #if COMPAT_LINUX_VERSION_CHECK_LT(3, 2, 0)
- # include <linux/module.h>
- #else
- @@ -203,7 +204,11 @@
- #endif
- static unsigned int
- +#if LINUX_VERSION_CODE < KERNEL_VERSION(3, 13, 0)
- VNetFilterHookFn(unsigned int hooknum, // IN:
- +#else
- +VNetFilterHookFn(const struct nf_hook_ops *ops, // IN:
- +#endif
- #ifdef VMW_NFHOOK_USES_SKB
- struct sk_buff *skb, // IN:
- #else
- @@ -252,7 +257,12 @@
- /* When the host transmits, hooknum is VMW_NF_INET_POST_ROUTING. */
- /* When the host receives, hooknum is VMW_NF_INET_LOCAL_IN. */
- - 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);
- +#endif
- packetHeader = compat_skb_network_header(skb);
- ip = (struct iphdr*)packetHeader;
- EOF
- 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 < /tmp/filter.c.patch
- # re-tar the modules
- tar -uvf vmnet.tar vmnet-only
- #delete the previous working directory
- rm -rf vmnet-only
Add Comment
Please, Sign In to add comment