Chinaunix

标题: Installing VMware Tools In A FreeBSD 7.0 Guest [打印本页]

作者: kmindg    时间: 2008-08-16 20:11
标题: Installing VMware Tools In A FreeBSD 7.0 Guest

From
http://blog.sourcehosting.net/2008/03/10/vmware-tools-installation-problem-under-freebsd-70/
March 10, 2008
Installing VMware Tools In A FreeBSD 7.0 Guest
Filed under:
Operating Systems
— Tags:
freebsd
,
vmware


Greg Larkin @ 7:35 pm
Hi everyone,
I’ve got
FreeBSD 7.0
downloaded and running as a VMware Server virtual machine so I can start checking it out and get a feel for how it works. Once
ZFS
is deemed stable for production, I’ll plan to migrate to the 7.x series.
The first thing I generally do after setting up a new VM is install
VMware Tools
. Wait - scratch that. The first thing I have to do before installing VMware Tools is install Perl, since it’s not part of the FreeBSD base system. That’s easy enough:
cd /usr/ports/lang/perl5.8 && make WITH_GDBM=yes install clean
Ok, on to the VMware Tools installer! After starting the vmware-install.pl script, I answered a bunch of questions (used all default responses), and finally was met with this somewhat odd message:

Wait a minute - I’m pretty sure I’m installing in a virtual machine here! Initially, I pored through the installation Perl script and discovered that it executes vmware-checkvm to determine if it’s running inside a VM or not. Ok, let’s try that by hand:

That’s a problem! vmware-checkvm is a statically-linked binary, and to get it working, the FreeBSD compat6x port needs to be installed. The compat6x port installs a variety of libraries that were found in FreeBSD 6.x but have had their versions bumped for FreeBSD 7.0.
cd /usr/ports/misc/compat6x && make install clean
Hmm, still no joy after doing that - vmware-checkvm is still core dumping. After more Googling and nosing about in the VMware Tools installation script, I learned that VMware expects the libc.so.6 library installed by compat6x to be in /lib. However, all compat{3,4,5,6}x ports install their libraries in /usr/local/lib/compat to avoid messing with the base system.
A simple symbolic link gets libc.so.6 in place for VMware:
ln -s /usr/local/lib/compat/libc.so.6 /lib
And now success, right? Wrong!

I’m not logged in over the network, so why am I getting this message? It turns out that tcsh (root shell in FreeBSD) is setting the REMOTEHOST environment variable, even though I’m logged in at the VM’s console.
The solution is a simple command:
unsetenv REMOTEHOST
Start up the VMware Tool installer one more time, and now it works!
Maybe the
newest version of VMware Server
supports FreeBSD 7.0 natively, so I’ll have to test that out soon. Details will be posted here when I do!
Keep in touch,
Greg


本文来自ChinaUnix博客,如果查看原文请点:http://blog.chinaunix.net/u/19810/showart_1132308.html




欢迎光临 Chinaunix (http://bbs.chinaunix.net/) Powered by Discuz! X3.2