Hello all,<br><br><br><meta name="qrichtext" content="1"><meta http-equiv="Content-Type" content="text/html; charset=utf-8"><style type="text/css">
p, li { white-space: pre-wrap; }
</style>
<p style="margin: 0px; text-indent: 0px;">I have a host laptop which acts as a host to virtual machines and a samba server. The main purpose of setting up the samba server was to transfer files from the XP vm guest to the host which is my main workstation. The problem is that the XP guest can only find the samba server intermittently. Don&#39;t hesitate to correct my networking skills... It is definitely my weak point in all of this.</p>

<p style="margin: 0px; text-indent: 0px;"><br></p>
<p style="margin: 0px; text-indent: 0px;"></p>
<p style="margin: 0px; text-indent: 0px;">I know the samba server is set up correctly on my laptop &quot;Babbage&quot;, as other machines can connect to the samba server just fine. My virtual machine network works flawlessly as I can ping everything from everywhere. I think my problem lies in my guest VM&#39;s local network name resolution. My guests don&#39;t know where host Babbage is located. The odd part is that I can intermittently connect to the samba server from the guest xp vm by mapping a network drive. when it works, it works fine. when it does not work, I get this message: </p>


<p style="margin: 0px; text-indent: 0px;">&quot;The network path to Babbage\share could not be found.&quot;</p>
<p style="margin: 0px; text-indent: 0px;"></p>
<p style="margin: 0px; text-indent: 0px;"><br></p><p style="margin: 0px; text-indent: 0px;">I have tried adding Babbage&#39;s ip address to the XP vm&#39;s host file for a quick fix, but to no avail.</p>
<p style="margin: 0px; text-indent: 0px;"></p>
<p style="margin: 0px; text-indent: 0px;">Can anyone steer me in the right direction? I am googled out.</p>
<p style="margin: 0px; text-indent: 0px;"></p>
<p style="margin: 0px; text-indent: 0px;"><br></p><p style="margin: 0px; text-indent: 0px;">I have a non standard VM setup. I need more then the standard userspace ubuntu setup provides (I have to reach the VMs from the outside), and my wireless card does not support bridging, so a bridge was not a option. I often require my vm&#39;s to have network connectivity without a wired connection.</p>


<p style="margin: 0px; text-indent: 0px;"></p>
<p style="margin: 0px; text-indent: 0px;">I have scripts that normally execute this setup... I just pulled out the relevant parts to simplify it for the problem at hand:</p>
<p style="margin: 0px; text-indent: 0px;"></p>
<p style="margin: 0px; text-indent: 0px;"><br></p><p style="margin: 0px; text-indent: 0px;">Create a tap0:</p>
<p style="margin: 0px; text-indent: 0px;">        sudo tunctl -t tap0</p>
<p style="margin: 0px; text-indent: 0px;"></p>
<p style="margin: 0px; text-indent: 0px;">Create a vde switch</p>
<p style="margin: 0px; text-indent: 0px;">        sudo vde_switch -d --numports 4 --hub --mod 666 --group users --tap tap0</p>
<p style="margin: 0px; text-indent: 0px;"></p>
<p style="margin: 0px; text-indent: 0px;">Configure tap</p>
<p style="margin: 0px; text-indent: 0px;">        sudo ifconfig tap0 172.16.1.1 netmask 255.255.255.0</p>
<p style="margin: 0px; text-indent: 0px;"></p>
<p style="margin: 0px; text-indent: 0px;">Configure masquerading to allow internet access to vm. </p>
<p style="margin: 0px; text-indent: 0px;">        sudo iptables -t nat -A POSTROUTING -o eth0 -j MASQUERADE</p>
<p style="margin: 0px; text-indent: 0px;">        sudo iptables -A FORWARD -i tap0 -j ACCEPT</p>
<p style="margin: 0px; text-indent: 0px;">        sudo iptables -A INPUT -s 172.16.1.1 -d 127.0.0.1 -j ACCEPT (not sure I need, just added for assurance when samba wasn&#39;t working)  </p>
<p style="margin: 0px; text-indent: 0px;">        sudo iptables -A OUTPUT -s 127.0.0.1 -d 172.16.1.1 -j ACCEPT (not sure I need, just added for assurance when samba wasn&#39;t working)  </p>
<p style="margin: 0px; text-indent: 0px;"></p>
<p style="margin: 0px; text-indent: 0px;">Start vm ($MAC is a random mac address generated by a script). </p>
<p style="margin: 0px; text-indent: 0px;">        vdeq kvm -vga std -usb -hda /vms/xp.img -net nic,macaddr=$MAC -net vde -m 2048</p>
<p style="margin: 0px; text-indent: 0px;"></p>
<p style="margin: 0px; text-indent: 0px;"></p>
<p style="margin: 0px; text-indent: 0px;">Setting the XP pro guest settings:</p>
<p style="margin: 0px; text-indent: 0px;">Static IP: 172.16.1.2</p>
<p style="margin: 0px; text-indent: 0px;">Default gateway: 172.16.1.1 (same as tap0)</p>
<p style="margin: 0px; text-indent: 0px;">DNS Servers: OpenDNS servers        </p>
<p style="margin: 0px; text-indent: 0px;">All of this works. From the VM I can: Ping the host, the tap, the internet, connect to the internet. From the host, I can ping the guest, the tap, and all other normal functions work. Samba is my only problem</p>

<p style="margin: 0px; text-indent: 0px;"><br></p><p style="margin: 0px; text-indent: 0px;"><br></p><p style="margin: 0px; text-indent: 0px;">Thanks,</p><p style="margin: 0px; text-indent: 0px;"><br></p><p style="margin: 0px; text-indent: 0px;">

Michael Irons<br></p>