Bug 3318

Summary: cannot run qemuarm for denzil 1.2.2
Product: [Yocto Project Subprojects] ADT Reporter: Alexandru Georgescu <alexandru.c.georgescu>
Component: adtAssignee: Jessica <jessica.zhang>
Status: VERIFIED WORKSFORME QA Contact:
Severity: normal    
Priority: Low CC: poky.adt.watcher, poky.watcher
Version: 1.2.2   
Target Milestone: 1.2.2   
Hardware: x86   
OS: Multiple   
Whiteboard:
OS type for building Yocto: --- Type of Regression: ---
Verified: Documentation change: ---

Description Alexandru Georgescu 2012-10-22 13:26:06 UTC
GENERAL DESCRIPTION
qemuarm cannot be launched if adt-installer or a standalone toolchain is used
Happenes for Denzil 1.2.2 build.

IMAGES DOWNLOADED FROM:
http://autobuilder.yoctoproject.org/pub/nightly/20121018-4

STEPS TO REPRODUCE:
1. Download ADT installer from the above link.
2. Install using default settings
3. Download the qemuarm kernel from the above link to local disk
4. Source the arm environment:
[yocto@yocto-dell2 ~]$ source /opt/poky/1.2.1/environment-setup-armv5te-poky-linux-gnueabi 
5. Run qemu:
[yocto@yocto-dell2 ~]$ runqemu ~/test-yocto/arm/ ~/test-yocto/zImage-qemuarm.bin 



EXPECTED RESULT:
5. QEMU starts

ACTUAL RESULT:
6. QEMU fails to start:


[yocto@yocto-dell2 ~]$ runqemu ~/test-yocto/arm/ ~/test-yocto/zImage-qemuarm.bin 
Assuming /home/yocto/test-yocto/arm/ is an nfs rootfs
Set MACHINE to [qemuarm] based on kernel [/home/yocto/test-yocto/zImage-qemuarm.bin]

Continuing with the following parameters:
KERNEL: [/home/yocto/test-yocto/zImage-qemuarm.bin]
ROOTFS: [/home/yocto/test-yocto/arm/]
FSTYPE: [nfs]
Acquiring lockfile for tap1:...
Using preconfigured tap device 'tap1:'
/opt/poky/1.2.1/sysroots/x86_64-pokysdk-linux/usr/bin/runqemu-internal: line 214: (1: * 2) + 1 : missing `)' (error token is ": * 2) + 1 ")
/opt/poky/1.2.1/sysroots/x86_64-pokysdk-linux/usr/bin/runqemu-internal: line 215: (1: * 2) + 2 : missing `)' (error token is ": * 2) + 2 ")
/opt/poky/1.2.1/sysroots/x86_64-pokysdk-linux/usr/bin/runqemu-internal: line 262: 21111 + 1: : syntax error in expression (error token is ": ")
WARNING: distccd not present, no distcc support loaded.
Running qemu-system-arm...
/opt/poky/1.2.1/sysroots/x86_64-pokysdk-linux/usr/bin/qemu-system-arm -kernel /home/yocto/test-yocto/zImage-qemuarm.bin -net nic,vlan=0 -net tap,vlan=0,ifname=tap1:,script=no,downscript=no -M versatilepb --no-reboot -show-cursor -usb -usbdevice wacom-tablet -no-reboot -m 128 --append "root=/dev/nfs nfsroot=192.168.7.1:/home/yocto/test-yocto/arm/, rw ip=192.168.7.::192.168.7.:255.255.255.0 mem=128M "
qemu-system-arm: -net tap,vlan=0,ifname=tap1:,script=no,downscript=no: could not configure /dev/net/tun (tap1:): Operation not permitted
qemu-system-arm: -net tap,vlan=0,ifname=tap1:,script=no,downscript=no: Device 'tap' could not be initialized
[sudo] password for yocto: 
Set 'tap1:' nonpersistent
Releasing lockfile of preconfigured tap device 'tap1:'
[yocto@yocto-dell2 ~]$
Comment 1 Alexandru Georgescu 2012-10-22 13:27:52 UTC
QEMU also fails to start if a standalone toolchain is used.
Comment 2 Jessica 2012-10-22 17:41:33 UTC
Alex,

please check whether on your machine you've already have another qemu instance running.  I was able to run qemu with downloaded 1.2.2 arm images via ext3 file and nfs successfully.  Normally, when I have this issue, there's some left behind qemu process that I have to manually kill them.
Comment 3 Alexandru Georgescu 2012-10-23 11:55:06 UTC
Jessica,
I have tried on other Fedora 17 machine that I used and failed.

I also tried on a CLEAN Fedora 17 machine, and it worked fine. So it seems that might be an isolated case.

Still, can you help me find what might be the issue?

Thanks,
Alex.
Comment 4 Jessica 2012-11-01 06:59:14 UTC
Alex,

Sometimes when you exit qemu, it may not exit cleanly and thus cause issue for the next when you try to start qemu instance.  I'm closing this bug till we can consistently reproduce it.
Comment 5 Alexandru Georgescu 2013-03-11 16:18:13 UTC
verified.