On 2011-04-28,at 13:49:00, wuyu8242 wrote: >发送日期:2011-04-28 13:49:00 >收件人:Amos Kong >抄送:autotest >主题:Re: [Autotest]log_into_'vm1'_via_serial_console >> >On 2011-04-26,at 17:24:16, Amos Kong wrote: > >>发送日期:2011-04-26 17:24:16 >>收件人:wuyu8242 >>抄送:autotest >>主题:Re: Re: [Autotest] log_into_'vm1'_via_serial_console >>> >>On Tue, Apr 26, 2011 at 04:54:46PM +0800, wuyu8242 wrote: >>> On 2011-04-26,at 13:58:04, wuyu8242 wrote: >>> >>> >发送日期:2011-04-26 13:58:04 >>> >收件人:Amos Kong >>> >抄送:autotest >>> >主题:Re: [Autotest] log_into_'vm1'_via_serial_console >>> >> >>> >On 2011-04-26,at 13:24:24, Amos Kong wrote: >>> > >>> >>发送日期:2011-04-26 13:24:24 >>> >>收件人:wuyu8242 >>> >>抄送:autotest >>> >>主题:Re: [Autotest] log into 'vm1' via serial console >>> >>> >>> >>On Tue, Apr 26, 2011 at 01:15:22PM +0800, wuyu8242 wrote: >>> >>> hi all, >>> >>> >>> >>> There are some cases failed beacause of >>> >>> "Attempting to log into 'vm1' via serial console (timeout 360s) ", how >>> >>> to setup >>> >>> serial console? >>> >> >>> >>Autotest only support serial login of linux guest. >>> >>Try to add 'console=tty0 console=ttyS0,115200' in guest kernel cmdline. >>> >>http://www.vanemery.com/Linux/Serial/serial-console.txt >>> >Okay, I try it. >>> > >>> >>You can test with this cmd: >>> >># qemu-kvm .... -serial stdio >>> This test with this cmd failed. >> >>failed ? >>error msg? snapshot? >> >> >>An Example: >># qemu-kvm -m 800 RHEL-Server-6.0-64-virtio.qcow2 -vnc :9 -serial stdio >When I run this command above on my CentOS, the command don't run and stop >immediatly, but not quit. >what's wrong with the result? when I run enospc case, I modify the serial paras to "-serial stdio" , and the error log as following: Running qemu command: 122 /usr/bin/qemu-kvm -name 'vm1' -monitor unix:'/tmp/monitor-humanmonitor1-20110428-070833-6pMS',server,nowait -serial stdio -drive file='/tmp/kvm_autotest_root/images/f11-64.qcow2',index=0,if=ide,cache=none,werror=stop -drive file='/tmp/kvm_autotest_root/ images/enospc.qcow2',if=ide,cache=none,werror=stop -net nic,vlan=0,model=rtl8139,macaddr='9a:a3:23:b0:2d:1a',id='id0FwWVO' -net tap,vlan=0,ifname='t0-070833-6pMS',script='/root/autotest/client/tests/kvm/scripts/qemu-ifup',downscript='no' -m 1024 -smp 2 - redir tcp:5000::22 -vnc :0 123 04/28 11:14:07 DEBUG| kvm_vm:1044| VM appears to be alive with PID 4758 124 04/28 11:14:07 DEBUG| kvm_vm:1548| Attempting to log into 'vm1' via serial console (timeout 360s) 125 04/28 11:14:07 DEBUG| kvm_vm:1554| Client process terminated (status: 1, output: '') 04/28 11:14:43 DEBUG|kvm_prepro:0389| (address cache) Adding cache entry: 9a:a3:23:b0:2d:1a ---> 192.168.60.47 145 04/28 11:14:43 DEBUG| kvm_vm:1554| Client process terminated (status: 1, output: '') 04/28 11:20:08 ERROR| kvm:0087| Test failed: LoginProcessTerminatedError: Client process terminated (status: 1, output: '') 04/28 11:20:26 ERROR| test:0422| Exception escaping from test: 336 Traceback (most recent call last): 337 File "/root/autotest/client/common_lib/test.py", line 419, in _exec 338 _call_test_function(self.execute, *p_args, **p_dargs) 339 File "/root/autotest/client/common_lib/test.py", line 612, in _call_test_function 340 raise error.UnhandledTestFail(e) 341 UnhandledTestFail: Unhandled LoginProcessTerminatedError: Client process terminated (status: 1, output: '') [context: logging into 'vm1' via serial console] 342 Traceback (most recent call last): 343 File "/root/autotest/client/common_lib/test.py", line 605, in _call_test_function 344 return func(*args, **dargs) 345 File "/root/autotest/client/common_lib/test.py", line 291, in execute 346 postprocess_profiled_run, args, dargs) 347 File "/root/autotest/client/common_lib/test.py", line 208, in _call_run_once 348 self.run_once_profiling(postprocess_profiled_run, 349 File "/root/autotest/client/common_lib/test.py", line 315, in run_once_profiling 350 self.run_once(*args, **dargs) 351 File "/root/autotest/client/tests/kvm/kvm.py", line 80, in run_once 352 run_func(self, params, env) 353 File "/root/autotest/client/tests/kvm/tests/enospc.py", line 119, in run_enospc 354 session_serial = vm.wait_for_serial_login(timeout=login_timeout) 355 File "/root/autotest/client/tests/kvm/kvm_vm.py", line 1558, in wait_for_serial_login 356 return self.serial_login(internal_timeout) 357 File "/root/autotest/client/common_lib/error.py", line 138, in new_fn 358 return fn(*args, **kwargs) 359 File "/root/autotest/client/tests/kvm/kvm_vm.py", line 1535, in serial_login 360 prompt, timeout) 361 File "/root/autotest/client/tests/kvm/kvm_utils.py", line 605, in _remote_login 362 raise LoginProcessTerminatedError(e.status, e.output) 363 LoginProcessTerminatedError: Client process terminated (status: 1, output: '') 364 365 04/28 11:20:26 DEBUG|logging_ma:0561| Logging subprocess finished 366 04/28 11:20:26 DEBUG|logging_ma:0561| Logging subprocess finished >>Initializing cgroup subsys cpuset >>Initializing cgroup subsys cpu >>Linux version 2.6.32-71.7.1.el6.x86_64 >>(mockbu...@hs20-bc2-4.build.redhat.com) (gcc version 4.4.4 20100726 (Red Hat >>4.4.4-13) (GCC) ) #1 SMP Wed Oct 27 03:44:59 EDT 2010 >>Command line: ro root=/dev/mapper/vg_virtlab6685153-lv_root >>rd_LVM_LV=vg_virtlab6685153/lv_root rd_LVM_LV=vg_virtlab6685153/lv_swap >>rd_NO_LUKS rd_NO_MD rd_NO_DM LANG=en_US.UTF-8 SYSFONT=latarcyrheb-sun16 >>KEYBOARDTYPE=pc KEYTABLE=us crashkernel=auto rhgb console=tty0 >>console=ttyS0,115200 >>KERNEL supported cpus: >> Intel GenuineIntel >> AMD AuthenticAMD >> Centaur CentaurHauls >>BIOS-provided physical RAM map: >> BIOS-e820: 0000000000000000 - 000000000009f400 (usable) >>.... >>.... >>Starting postfix: [ OK ] >>Starting abrt daemon: [ OK ] >>[ OK ] crond: [ OK ] >>[ OK ] atd: [ OK ] >> >>Red Hat Enterprise Linux Server release 6.0 Beta (Santiago) >>Kernel 2.6.32-71.7.1.el6.x86_64 on an x86_64 >> >>virtlab-66-85-153.englab.nay.redhat.com login: >> >>(you will got a prompt in terminal) >> >>> I midify the sentence of ''' return " -serial unix:'%s',server,nowait" % >>> filename ''' to ''' return " -serial stdio,server,nowait" ''' in >>> kvm_vm.py, but failed. >> >>why modify the code? it's right. >> >> > > >------------------ >wuyu8242 >2011-04-28 >_______________________________________________ >Autotest mailing list >Autotest@test.kernel.org >http://test.kernel.org/cgi-bin/mailman/listinfo/autotest >
------------------ wuyu8242 2011-04-28 _______________________________________________ Autotest mailing list Autotest@test.kernel.org http://test.kernel.org/cgi-bin/mailman/listinfo/autotest