Subject: Re: vmware
To: None <port-i386@netbsd.org>
From: =?utf-8?B?6I+K5Zyw5Lie?= <jojo@ucatv.ne.jp>
List: port-i386
Date: 11/11/2001 03:37:05
This is a multi-part message in MIME format.

------=_NextPart_000_002F_01C16A62.23167C60
Content-Type: text/plain;
	charset="utf-8"
Content-Transfer-Encoding: 7bit

Hello,

Does anybody can use VMware on NetBSD?
I tryed to install , but I can't install.

I use NetBSD-1.5.2-release (GENERIC_LAPTOP)
    options         LKM             # loadable kernel modules
    options         COMPAT_LINUX    # binary compatibility with Linux
and pkgsrc.tar.gz ( 2001 Oct 20th )

# pkg_info -a |grep suse
suse_base-6.4nb3    Linux compatibility package
suse_audio-6.4      Linux compatibility package for audio libraries
suse_libc5-6.4      Linux compatibility package for libc5 binaries
suse_libpng-6.4     Linux compatibility package for png library
suse_libjpeg-6.4    Linux compatibility package for jpeg binary
suse_glx-6.4        Linux compatibility package for GLX binaries
suse_gtk-6.4        Linux compatibility package for GTK binaries
suse_xforms-6.4     Linux compatibility package for xforms binaries
suse_linux-6.4      Linux compatibility package collection
suse_x11-6.4        Linux compatibility package for X11 binaries
suse_compat-6.4     Linux compatibility package with old shared libraries
suse_vmware-6.4nb1  Linux compatibility package to support running VMware

The following procedure is bad?
If it was bad, please teach me how to install VMware and how to use VMware
on NetBSD.

please help me.


-------- procedure ------------
# cp VMware-2.0.4-1142.tar.gz /tmp
# tar xzf VMware-2.0.4-1142.tar.gz

# cp vmware-netbsd-1.0.tgz /tmp
# tar xzf vmware-netbsd-1.0.tgz

# su
# sh install.sh

Where should VMware should be installed? [/usr/local]
Which directory contains the unpacked VMware distribution? [/tmp]
ln: /emul/linux/dev/cdrom: File exists
ln: /emul/linux/dev/fd0: File exists
ln: /emul/linux/dev/hda: File exists
ln: /emul/linux/dev/hdb: File exists
ln: /emul/linux/dev/hdc: File exists
ln: /emul/linux/dev/hdd: File exists
ln: /emul/linux/dev/hde: File exists
ln: /emul/linux/dev/hdf: File exists
ln: /emul/linux/dev/hdg: File exists
ln: /emul/linux/dev/hdh: File exists
ln: /emul/linux/dev/hdi: File exists
ln: /emul/linux/dev/tty1: File exists
ln: /emul/linux/dev/tty2: File exists
ln: /emul/linux/dev/tty3: File exists
ln: /emul/linux/dev/tty4: File exists
ln: /emul/linux/dev/tty5: File exists
ln: /emul/linux/dev/tty6: File exists
ln: /emul/linux/dev/tty0: File exists
Install finished.

# mkdir /root/.vmware
# cp license .vmware/

# cd vmware-distrib
# perl vmware-install.pl

Creating a new installer database using the tar2 format.

Installing the content of the package.

In which directory do you want to install the binary files?
[/usr/bin]

In which directory do you want to install the library files?
[/usr/lib/vmware]

The path "/usr/lib/vmware" does not exist currently. This script is going to
create it, including needed parent directories. Is this what you want? [yes]


In which directory do you want to install the manual files?
[/usr/share/man]

In which directory do you want to install the documentation files?
[/usr/share/doc/vmware]

The path "/usr/share/doc/vmware" does not exist currently. This script is
going
to create it, including needed parent directories. Is this what you want?
[yes]

What is the directory that contains the init directories (rc0.d/ to
rc6.d/)?

The path "" is not an existing directory.

What is the directory that contains the init directories (rc0.d/ to
rc6.d/)? /usr/pkg/emul/linux/sbin/init.d

What is the directory that contains the init scripts?
[/usr/pkg/emul/linux/sbin/init.d/init.d]

The installation of VMware 2.0.4 build-1142 for Linux completed
successfully.
You can decide to remove this software from your system at any time by
invoking
the following command: "/usr/bin/vmware-uninstall.pl".

Before running VMware for the first time, you need to configure it for your
running kernel by invoking the following command:
"/usr/bin/vmware-config.pl".
Do you want this script to invoke the command for you now? [yes]

/usr/bin/vmware-config.pl: not found

# /usr/bin
# perl vmware-config.pl
Making sure VMware's services are stopped.

grep: /proc/1711/status: No such file or directory
grep: /proc//status: No such file or directory
lsmod: QM_MODULES: Function not implemented

Stopping VMware services:
   Virtual machine monitor-ne \033[71G done


You are not running Linux. This version of the product only runs on Linux.

Execution aborted.


# mount -t procfs /proc /proc
# cd /usr/bin
# ./vmware-wizard

   (clic next several and clic done, but VMware is not started. The window
destroyed.)


# reboot
(reboot message )
...
...
Start vmnet
modload: nlist /usr/local/share/vmware/lkm/if_hub.o : No such file or
directory
Start vmmon
modload: nlist /usr/local/share/vmware/lkm/vmmon.o : No such file or
directory
Starting vmnetif
eval: /usr/local/bin/vmnet-netifup: not found
...
...


(but in /usr/local/share/vmware/lkm/
-r--r--r--  1 root  wheel  11819 Nov 11 01:13 if_hub.o
-r-xr-xr-x  1 root  wheel    493 Nov 11 01:13 if_hub_post.sh
-r--r--r--  1 root  wheel   2134 Nov 11 01:13 linuxrtc.o
-r-xr-xr-x  1 root  wheel    352 Nov 11 01:13 linuxrtc_post.sh
-r--r--r--  1 root  wheel  25371 Nov 11 01:13 vmmon.o
-r-xr-xr-x  1 root  wheel    359 Nov 11 01:13 vmmon_post.sh
)


# cd source/linuxrtc
# vi Makefile
  - S?= /work/trees/netbsd-1-5/sys
  + S?= /usr/src/sys/
# make install

# cd source/vmmon
# vi Makefile
  - S?= /work/trees/netbsd-1-5/sys
  + S?= /usr/src/sys/
# make install


# cd souce/vmnet
# make

rm -f machine &&  ln -s /usr/src/sys/arch/i386/include machine
rm: machine: is a directory
*** Error code 1 (ignored)
rm -f i386 &&  ln -s /usr/src/sys/arch/i386/include i386
rm: i386: is a directory
*** Error code 1 (ignored)
cc -O2  -D_KERNEL -D_LKM -I. -I/usr/home/jojo/packages/VMware/vmware-netbsd-
1.0/source/vmnet.org -I/usr/src/sys -I/usr/src/sys/arch -Wall -Wstrict-proto
types -Wmissing-prototypes -Wpointer-arith -Wno-uninitialized -Werror   -nos
tdinc -DNBPFILTER=1 -DINET -c if_hubmod.c
if_hubmod.c:147: macro `ETHER_MAX_FRAME' used with only 2 args
if_hubmod.c:920: macro `ETHER_MAX_FRAME' used with only 2 args
*** Error code 1

Stop.
make: stopped in
usr/home/jojo/packages/VMware/vmware-netbsd-1.0/source/vmnet


( edit in vmnet/Makefile )
# vi Makefile
  - S?= /work/trees/netbsd-1-5/sys
  + S?= /usr/src/sys/

# mv i386 i386.orig
# ln -s /usr/src/sys/arch/i386/include /tmp/source/vmnet/i386
# mv machine machine.orig
# ln -s /usr/src/sys/arch/i386/include /tmp/source/vmnet/machine

# make
rm -f machine &&  ln -s /usr/src/sys/arch/i386/include machine
rm -f i386 &&  ln -s /usr/src/sys/arch/i386/include i386
cc -O2  -D_KERNEL -D_LKM -I. -I/usr/home/jojo/packages/VMware/vmware-netbsd-
1.0/source/vmnet -I/usr/src/sys -I/usr/src/sys/arch -Wall -Wstrict-prototype
s -Wmissing-prototypes -Wpointer-arith -Wno-uninitialized -Werror   -nostdin
c -DNBPFILTER=1 -DINET -c if_hubmod.c
In file included from if_hubmod.c:79:
if_hubvar.h:84: Invalid token in expression
if_hubmod.c:147: macro `ETHER_MAX_FRAME' used with only 2 args
if_hubmod.c:920: macro `ETHER_MAX_FRAME' used with only 2 args
*** Error code 1

Stop.
make: stopped in
usr/home/jojo/packages/VMware/vmware-netbsd-1.0/source/vmnet


( patching vmnet.patch file )
# patch < vmnet.patch
# make

rm -f machine &&  ln -s /usr/src/sys/arch/i386/include machine
rm -f i386 &&  ln -s /usr/src/sys/arch/i386/include i386
cc -O2  -D_KERNEL -D_LKM -I. -I/usr/home/jojo/packages/VMware/vmware-netbsd-
1.0/
source/vmnet.patch -I/usr/src/sys -I/usr/src/sys/arch -Wall -Wstrict-prototy
pes
-Wmissing-prototypes -Wpointer-arith -Wno-uninitialized -Werror   -nostdinc 
-DNB
PFILTER=1 -DINET -c if_hubmod.c
In file included from if_hubmod.c:79:
if_hubvar.h:84: Invalid token in expression
if_hubmod.c:146: Invalid token in expression
if_hubmod.c:153: Invalid token in expression
if_hubmod.c:158: macro `ETHER_MAX_FRAME' used with only 2 args
if_hubmod.c:919: Invalid token in expression
if_hubmod.c:936: Invalid token in expression
if_hubmod.c:941: macro `ETHER_MAX_FRAME' used with only 2 args
*** Error code 1

Stop.
make: stopped in
usr/home/jojo/packages/VMware/vmware-netbsd-1.0/source/vmnet



----- Original Message -----
From: "emanuel stiebler" <emu@ecubics.com>
To: <port-i386@netbsd.org>
Sent: Saturday, October 06, 2001 2:47 AM
Subject: vmware


> Hi,
>
> anybody out here is using vmware on NetBSD ?
> Remarks ? Recommendations ?
>
> cheers & thanks a lot,
> emanuel
>


------=_NextPart_000_002F_01C16A62.23167C60
Content-Type: application/octet-stream;
	name="vmnet.patch"
Content-Transfer-Encoding: quoted-printable
Content-Disposition: attachment;
	filename="vmnet.patch"

--- source/vmnet/if_hubvar.h	Tue Apr  3 00:57:57 2001=0A=
+++ source/vmnet/if_hubvar.h	Sun Jun 10 11:35:34 2001=0A=
&#64;&#64; -76,4 +76,8 &#64;&#64;=0A=
 #define MAKEHUBDEV(d,u)  MAKEPORTDEV(d,0,-1)=0A=
 =0A=
 #define HUBMINPKT	ETHER_HDR_LEN=0A=
-#define HUBMAXPKT	(ETHER_MAX_FRAME(ETHERTYPE_VLAN, 1))=0A=
+#if __NetBSD_Version__ &gt;=3D 105230000=0A=
+# define HUBMAXPKT(ifp)	(ETHER_MAX_FRAME(ifp, ETHERTYPE_VLAN, 1))=0A=
+#else=0A=
+# define HUBMAXPKT	(ETHER_MAX_FRAME(ETHERTYPE_VLAN, 1))=0A=
+#endif=0A=
--- source/vmnet/if_hubmod.c	Tue Apr  3 22:51:19 2001=0A=
+++ source/vmnet/if_hubmod.c	Sun Jun 10 12:31:03 2001=0A=
&#64;&#64; -141,10 +141,18 &#64;&#64;=0A=
 {=0A=
 	int error =3D 0, i, j;=0A=
 	struct hubdev_softc *sc;=0A=
+#if __NetBSD_Version__ &gt;=3D 105230000=0A=
+	struct ifnet *ifp;=0A=
+#endif=0A=
 	=0A=
 	switch (cmd) {=0A=
 	case LKM_E_LOAD:=0A=
+#if __NetBSD_Version__ &gt;=3D 105230000=0A=
+		ifp-&gt;if_mtu =3D ETHERMTU;=0A=
+		if (HUBMAXPKT(ifp) &gt; MCLBYTES) {=0A=
+#else=0A=
 		if (HUBMAXPKT &gt; MCLBYTES) {=0A=
+#endif=0A=
 			printf(&quot;if_hub: HUBMAXPKT &gt; MCLBYTES\n&quot;);=0A=
 			return EIO;=0A=
 		}=0A=
&#64;&#64; -903,6 +911,9 &#64;&#64;=0A=
 	struct hubport_softc *portsc;=0A=
 	struct mbuf *m;=0A=
 	int error;=0A=
+#if __NetBSD_Version__ &gt;=3D 105230000=0A=
+	struct ifnet *ifp;=0A=
+#endif=0A=
 =0A=
 	hubsc =3D hub_scs[HUBUNIT(dev)];=0A=
 	if (hubsc =3D=3D NULL)=0A=
&#64;&#64; -917,7 +928,12 &#64;&#64;=0A=
 	if (uio-&gt;uio_resid =3D=3D 0)=0A=
 		return (0);=0A=
 =0A=
+#if __NetBSD_Version__ &gt;=3D 105230000=0A=
+	ifp =3D &amp;portsc-&gt;port_if;=0A=
+	if ((uio-&gt;uio_resid &lt; HUBMINPKT) || (uio-&gt;uio_resid &gt; =
HUBMAXPKT(ifp))) {=0A=
+#else=0A=
 	if ((uio-&gt;uio_resid &lt; HUBMINPKT) || (uio-&gt;uio_resid &gt; =
HUBMAXPKT)) {=0A=
+#endif=0A=
 		HUBDEBUG(&quot;if_hub: write: illegal length %d\n&quot;, =
uio-&gt;uio_resid);=0A=
 		return EIO;=0A=
 	}=0A=

------=_NextPart_000_002F_01C16A62.23167C60--