2009/6/1 Jean Christophe Andr? <jean-christophe.andre at auf.org>:
>> + start the VM with tap0. Then if I add the route "10.0.0.0 dev eth0" inside
>> the VM I can ping the host IP, but can't reach anything else, even the
>> router of my LAN.
>>
>> I think I have misconfigured the host somewhere but can't figured out where
>> is it yet :-/
>>
> We lack some information here: what are your host and guest network
> configuration exactly?
>
> But even without knowing it I would guess this is a standard routing
> problem.
>
> You are probably using an internal network for your guest. You host
> knows it so it knows where it should send replies to a ping request.
>
> But when you ping outside this environment, eg your host's gateway, then
> the ICMP packet comes to it through standard default routes, but the
> gateway doesn't know the route to send the answer back (through your
> host) to your guest.
>
> So here are 3 classic solutions (exclusive: only one of them needed):
> - use an IP address from already known network, eg same network as your
> host ; you can do this because you are using a bridge (= virtual switch) ;
> - masquerade the guest outgoing connections with the host's external IP
> address (use iptables -j SNAT on the host) ;
> - configure routing any place your need it.
- Hmm, I tried setting the guest IP to the same IP range as the host
network (10.0.0.0/24) but it still does not work :-/
2009/6/1 Jean Christophe Andr? <jean-christophe.andre at auf.org>:
> C? V?ng a ?crit :
>> Well, I don't think OpenVZ is suited for desktop usage because the HN has to
>> use the same (modified) kernel as CT,
> And? Isn't that great? Sharing resources means not wasting them!
Yes, since I have a fetish for bleeding edge software, using the same
(old) version of the kernel doesn't sound so attractive to me.
>> so is Xen (though the idea of paravirtualization is interesting).
> Are you sure of that?? Xen, with the help of hardware support, is said
> to be able to run unmodified OS (like MS-Windows). Of course I never
> tried that...
Hmm, but IIRC, the first OS (dom0) must be modified.
>
>> And I don't know if it will work properly with X yet.
> That's simple: you need to run X on the host side.
> In fact you would probably need to run the full client on host side.
>
>> VirtualBox is okay but kinda slow. VMWare is closed. So the only one left is
>> qemu.
>>
> It's not the only one left: on my side I'm using UML.
> Check the user-mode-linux package.
>
> I don't have hardware virtualization support in my old notebook so I
> haven't many choices left. It's probably not the best at performance,
> but I don't need that just for testing anyway. And I find it good enough
> even for a full development platform (Debian here).
>
> Also, the great thing with this one is that your "Linux OS" is running
> in your host as a single process and as a normal user. Here is the
> script I use to launch it on my notebook:
>
> #!/bin/sh
> exec screen -d -m -S etch \
> nice linux.uml umid=etch mem=256M fake_ide fakehd \
> ubd0=/dev/mapper/tmp-etch \
> eth0=daemon,fe:fd:00:00:00:07
>
> Running it through screen also allows me to get the console detached and
> available at anytime even from distant connection. And, yes, I'm using
> LVM, even on my notebook.
>
> Of course I have a special udev setting to give me access rights on
> /dev/mapper/tmp-etch as a normal user, here it is:
>
> # /etc/udev/rules.d/50-progfou-permissions.rules
> # This causes devicemapper device "tmp-etch" to be owned by "progfou"
> SUBSYSTEM!="block", GOTO="dmsetowner_end"
> KERNEL!="dm-*", GOTO="dmsetowner_end"
> ACTION!="add|change", GOTO="dmsetowner_end"
> # Obtain device status
> IMPORT{program}="/sbin/dmsetup export -j%M -m%m"
> ENV{DM_NAME}=="tmp-etch", OWNER="progfou", GROUP="disk", MODE="0660"
> LABEL="dmsetowner_end"
> # /dev/net/tun (uml_switch & virtualbox)
> KERNEL=="tun", GROUP="tunusers", MODE="0660"
> # kqemu
> KERNEL=="kqemu", GROUP="qemu", MODE="0660"
> # WiiMote
> KERNEL=="uinput", GROUP="plugdev", MODE="0660"
>
> I kept in it a few additional interesting permissions... ;-)
Interesting. But here I am use it to test other Linux distros* (now is
Ubuntu) so I need it to be fully virtualized, and since I have some
problems with Arch lately (have to reinstall its 2 times in half a
month) I want to deal|modify the host as less as possible.
* Test its Vietnamese interface to be exact.
--
My job: Writing buggy softwares to make the world a worse place for
humanity ( ???)???????????? ? / ?/ ?