moongoose Posted October 26, 2009 Share Posted October 26, 2009 Hi everyone! I'm pretty new to OSX and my goal is to install an instance of OSX in a virtual environment on my Linux host. I got myself iPC 10.5.6 and iDeneb 10.5.6 images and first of all failed to install them with both VirtualBox and vmWare. However, the installation in qemu worked very well and the performance of the OSX guest system is excellent! There is only one issue: The emulated network card (RTL8139) is not working. It is recognized by OSX (green icon in System Settings, Network Utitilty says Manufacturer Realtek Model 8139). I also tried every other virtual network device qemu provides, but they don't even get recognized. Qemu provides a DHCP server and should get my OSX an IP Adress, but the DHCP request times out and OSX gets a Self-assigned IP which again results in no connectivity. Static IP configurations is not working either. The network adapter seems to be up for just a very short time. I dumped all the traffic of the virtual network adapter to a file and analyzed it with wireshark: First, OSX sends a DHCP Request, qemu responds with a DHCP Ack. They negotiate to 10.0.2.15. However, after that, no more packets are transmitted in both directions and the negotiated IP address is not assigned to en0. My command line for starting qemu is: sudo qemu-system-x86_64 -vga std -net nic,model=rtl8139 -net user -m 1024 -hda ~/osxinstall/osx.disk Now here comes the intersting part: When i launch qemu with qemu-system-i386, the network driver is working and I can access the Internet from commandline. But the system is terribly slow and practically unusable (which makes sense as there is no hardware acceleration). Also, Safari crashes upon launching, which it doesnt when running in x86_64 mode. I tried several AppleRTL8139Ethernet and PCGen kexts off the Internet and from your forums, but the problem remains the same. I'm really stuck here and your help would be greatly appreciated! Thanks in advance! moongoose Link to comment Share on other sites More sharing options...
Hein Blöd Posted November 4, 2009 Share Posted November 4, 2009 Pinging an outside host speeds up networking dramatically here. Open a terminal in Mac OS X and run this command: ping 10.0.2.1 Keep this running while surfing with Safari. Link to comment Share on other sites More sharing options...
maticta Posted November 5, 2009 Share Posted November 5, 2009 Hi, I have EXACTLY the same problem; iPC 10.5.6 also. I can't make the network work, it's driving me crazy. Currently I'm still playing with it, so will report back if it works. In the meantime, if someone knows how, please tell See you later ! Link to comment Share on other sites More sharing options...
maticta Posted November 5, 2009 Share Posted November 5, 2009 Well, I was able to make a (slow) connection using serial. kvm -m 384 -hda osx.img -serial vc -serial pty Then in OSx I configured "Built-in Serial Port" as: Vendor: Null Modem Model:115200 bps no compression and correction The rest as it was on the host: sudo pppd nodetach crtscts lock debug noauth 192.168.0.1:192.168.0.2 /dev/pts/3 <- replace pts/3 with the one kvm provides as "char device redirected to XXX" I can ping and use the web with a proxy (4kb/s ~_~). Will try to make the **** real network work tough Link to comment Share on other sites More sharing options...
maticta Posted November 5, 2009 Share Posted November 5, 2009 FTR I finally made a dhcp/user mode connection, but it's as slow as serial. kvm -m 384 -hda osx.img -usb -usbdevice net:vlan=0 -net user,vlan=0 OSx recognize the usb network and configure it automatically, sadly at 4kb/s ~_~ Link to comment Share on other sites More sharing options...
fgiust Posted November 7, 2009 Share Posted November 7, 2009 Same problem here. After a successful installation of osx (ideneb 1.6 10.5.8) under qemu I spent some time in trying to make network working without luck. The RTL8139 card is recognized but dhcp doesn't work (setting a manual address doesn't work either). With qemu tap networking it seems even more close to working, I was able to see an IP address successfully assigned from dhcp (a "real" dhcp, non the virtual qemu one), a working ping to the gateway, but nothing more... trying to ping an external address or to navigate using safari still does not work. I also tried all the other qemu emulated networ adapters, still no luck: ne2k_pci -> Realtek RTL-8029(AS) -> not detected, no kext found i82551,i82557b,i82559er, -> qemu crashes with "eepro100.c:1514: nic_receive: Assertion `size <= rfd_size' failed" (also tried patching the qemu sources, removing that assertion ends up in a kernel panic) e1000, -> 82540EM Gigabit Ethernet Controller -> not detected by the standard driver. Also tried the SmallTree driver (both kext with fixed ids) pcnet -> amd 79C970 [pcNET32 lance] -> not detected, no kext found virtio -> not detected, no kext found anybody had more luck? Link to comment Share on other sites More sharing options...
moongoose Posted November 9, 2009 Author Share Posted November 9, 2009 hey maticta! thanks for sharing! having not tried to use the usb adapter makes me feel like an idiot I can confirm the usbdevice working, but just as you mentioned at very slow speed! cheers! moongoose Link to comment Share on other sites More sharing options...
dkano Posted November 12, 2009 Share Posted November 12, 2009 Hi everyone! I'm pretty new to OSX and my goal is to install an instance of OSX in a virtual environment on my Linux host. I got myself iPC 10.5.6 and iDeneb 10.5.6 images and first of all failed to install them with both VirtualBox and vmWare. However, the installation in qemu worked very well and the performance of the OSX guest system is excellent! Hi, moongose, sorry for bad english. My goal is the same but i try to install on qemu and fail! Hi have tried with iDeneb 1.5.1 and iPc. I think my problem is that i'm not able to found a good guide to do this, with all necessary steps and qemu and boot parameters. Can you post your qemu complete instruction used for installation from iso and the boot parameters used after? Thanks! Link to comment Share on other sites More sharing options...
moongoose Posted November 16, 2009 Author Share Posted November 16, 2009 hi dkano, the qemu command line is like mentioned above, of course with the iPC / iDeneb image attached to cdrom: sudo qemu-system-x86_64 -monitor stdio -usb -vga std -usbdevice net:vlan=0 -net user,vlan=0 -m 1024 -hda /path/to/your/diskfile -cdrom /path/to/your/isofile.iso Of course you have to create the disk file in advance (qemu-img create). After that, the installation is pretty straight forward. Read the instructions that come with iPC / iDeneb and in my case the installation succeeded (I needed two attemps because I didn't read the instructions properly, so make sure you do ;-) Also search this forum for guides. Even if they are not qemu related, they can also help. Cheers moongoose Link to comment Share on other sites More sharing options...
maticta Posted November 19, 2009 Share Posted November 19, 2009 Well, yesterday I upgraded my Debian Sid and qemu 0.11 was available with kvm enabled. Tried again and now it works ! Well, sort of qemu-system-x86_64 -m 384 -hda osx.img -vga std --enable-kvm -net user -net nic,model=rtl8139 It works with dhcp, but network is slow. If you open a terminal and run "ping 10.0.2.2" it gets a little faster (about 12kb/s downlading adium in my case), just like Hein Bl�d said. BUT, running various pings in parallel give even more speed, with 6 pings I'm almost at the top of my internet connection (I have only 512kbps). I think I'm going to make a script running in background for this. Anyway, now that rtl8139 works I think I'm going to try bridge networking and see how it goes =) Edit: I upgraded from kernel 2.6.30 to 2.6.31.5 the same day, so maybe the issue was solved by the new kvm module Edit2: Nop, tried with the old qemu and still doesn't work, so it's something that was solved in qemu 0.11 and not in the kvm module Edit3: Instead of multiple pings, just using "ping -q -i 0.1 10.0.2.2" is enough for getting full network speed (at least for me). Now is time to play =) Link to comment Share on other sites More sharing options...
dkano Posted November 24, 2009 Share Posted November 24, 2009 After that, the installation is pretty straight forward. Read the instructions that come with iPC / iDeneb and in my case the installation succeeded (I needed two attemps because I didn't read the instructions properly, so make sure you do ;-) Also search this forum for guides. Even if they are not qemu related, they can also help. Cheers moongoose Thanks! Works on qemu 0.11 (Ubuntu 9.10) but not in qemu 0.10 (Ubuntu 9.04). My installation procedure is not complete, for now (still installing), but i will try, once finished, to prepare a comprensive guide to install and configure on qemu Link to comment Share on other sites More sharing options...
blwegrzyn Posted January 3, 2010 Share Posted January 3, 2010 Well, yesterday I upgraded my Debian Sid and qemu 0.11 was available with kvm enabled. Tried again and now it works ! Well, sort of qemu-system-x86_64 -m 384 -hda osx.img -vga std --enable-kvm -net user -net nic,model=rtl8139 It works with dhcp, but network is slow. If you open a terminal and run "ping 10.0.2.2" it gets a little faster (about 12kb/s downlading adium in my case), just like Hein Bl�d said. BUT, running various pings in parallel give even more speed, with 6 pings I'm almost at the top of my internet connection (I have only 512kbps). I think I'm going to make a script running in background for this. Anyway, now that rtl8139 works I think I'm going to try bridge networking and see how it goes =) Edit: I upgraded from kernel 2.6.30 to 2.6.31.5 the same day, so maybe the issue was solved by the new kvm module Edit2: Nop, tried with the old qemu and still doesn't work, so it's something that was solved in qemu 0.11 and not in the kvm module Edit3: Instead of multiple pings, just using "ping -q -i 0.1 10.0.2.2" is enough for getting full network speed (at least for me). Now is time to play =) hmm, I am running ubuntu 9.10 and i am having same issue, I cannot get the networking to work at all, i get dhcp address and then it goes away? Any new resolution to the problem? Link to comment Share on other sites More sharing options...
bredroll Posted January 6, 2010 Share Posted January 6, 2010 Hello there, Has anyone had any luck with getting rtl8139 + tap working here? I 'can' get really terrible networking with the usb net device but it is very unreliable. Link to comment Share on other sites More sharing options...
grubshka Posted January 13, 2010 Share Posted January 13, 2010 Hello there, Has anyone had any luck with getting rtl8139 + tap working here? I 'can' get really terrible networking with the usb net device but it is very unreliable. I still have the same problem... No network with iPC 10.5.6 on qemu-kvm 0.11.0. I just updated to 0.11.1, it seems to have an update for "net", hoping I can't get IDeneb 1.6 working at all : without Chameleon I'm stuck while booting at "Booting from hard disk..." message, and with Chameleon it automatically reboots after the bootloader. Link to comment Share on other sites More sharing options...
bredroll Posted January 17, 2010 Share Posted January 17, 2010 Hello All, I've had some excellent success at last. After having a think and putting my driver debug hat on I thought, what could make the network slow. What could it be that means generating more ping packets makes it go faster.. My build of kvm is from the instructions listed here:- http://d4wiki.goddamm.it/index.php?title=H..._Mac_OSX_on_KVM And my startup script is this:- #!/bin/sh DISK=osx-hda.img OSK=NOIDEA echo 1 > /proc/sys/net/ipv4/ip_forward tunctl -t tap0 ifconfig tap0 10.6.0.1 netmask 255.255.255.0 KVM="/opt/qemu-mac/bin/qemu-system-x86_64 -M mac -no-kvm-irqchip" $KVM -kernel /root/kvm-osx-bootloader/boot \ -m 512 -serial stdio \ -net nic,model=rtl8139 \ -net tap,ifname=tap0,script=no \ -hda $DISK $@ The key change here is -no-kvm-irqchip which forces kvm to do all irq routing in software (makes sense as someone else posted that non-kvm qemu works fine) This gives me a good solid network connection and works with -net user and -net tap I can now get full speed out of my LAN connection without needing to do anything like ping gateway addresses Link to comment Share on other sites More sharing options...
Drovani Posted January 17, 2010 Share Posted January 17, 2010 Hello All, I've had some excellent success at last. Wow! It's amazing!!! I had same troubles like everybody here, but even more - pinging don't helped even a bit. Now it is works fine with -net user, but I failed to configure with -net tap. Can you show you IP configuration setting in Mac Os X which works with your "tap0 10.6.0.1 netmask 255.255.255.0"? I can now get full speed out of my LAN connection without needing to do anything like ping gateway addresses I can use full speed too but still have need to ping 10.0.2.2. Link to comment Share on other sites More sharing options...
Recommended Posts