Re: bhyve tty / login problems / panic

2013-03-30 Thread Dan Mack

Here you go:

 - uni-processor output:

root@olive:~ # bhyvectl --vm=coco --get-stats --cpu=0
vcpu0
vm exits due to external interrupt  1330
number of times hlt was intercepted 676
number of times %cr access was intercepted  1
number of times rdmsr was intercepted   0
number of times wrmsr was intercepted   4
number of monitor trap exits0
number of times pause was intercepted   428499
vm exits due to interrupt window opening1231
vm exits due to nmi window opening  0
number of times in/out was intercepted  423985
number of times cpuid was intercepted   22
vm exits due to nested page fault   7523
number of vm exits for unknown reason   0
number of times astpending at exit  38
number of vm exits handled in userspace 853290
number of NMIs delivered to vcpu0
vcpu total runtime  6954314530
number of ticks vcpu was idle   59572
vcpu migration across host cpus 29
number of times hlt was ignored 0
total number of vm exits863271

And here is when running with vcpu==2:

root@olive:~ # bhyvectl --vm=coco --get-stats --cpu=0
vcpu0
vm exits due to external interrupt  19234
number of times hlt was intercepted 1965
number of times %cr access was intercepted  1
number of times rdmsr was intercepted   0
number of times wrmsr was intercepted   4
number of monitor trap exits0
number of times pause was intercepted   3907709
vm exits due to interrupt window opening8105
vm exits due to nmi window opening  0
number of times in/out was intercepted  457998
number of times cpuid was intercepted   50
vm exits due to nested page fault   940909
number of vm exits for unknown reason   0
number of times astpending at exit  102
number of vm exits handled in userspace 4367825
number of NMIs delivered to vcpu0
vcpu total runtime  51834598990
number of ticks vcpu was idle   887
vcpu migration across host cpus 25
number of times hlt was ignored 0
total number of vm exits5335975
root@olive:~ # bhyvectl --vm=coco --get-stats --cpu=1
vcpu1
vm exits due to external interrupt  51249
number of times hlt was intercepted 3676
number of times %cr access was intercepted  2
number of times rdmsr was intercepted   0
number of times wrmsr was intercepted   4
number of monitor trap exits0
number of times pause was intercepted   4667527
vm exits due to interrupt window opening32453
vm exits due to nmi window opening  0
number of times in/out was intercepted  57278
number of times cpuid was intercepted   63
vm exits due to nested page fault   266091
number of vm exits for unknown reason   0
number of times astpending at exit  164
number of vm exits handled in userspace 4728481
number of NMIs delivered to vcpu0
vcpu total runtime  53833466076
number of ticks vcpu was idle   965
vcpu migration across host cpus 16
number of times hlt was ignored 0
total number of vm exits5078343

The panic comes eventually like this:

login: panic: deadlkres: possible deadlock detected for 0xfe0090fb5490, 
blocked for 217798 ticks

cpuid = 0
Uptime: 255d6h29m56s
Automatic reboot in 15 seconds - press a key on the console to abort


Hope this helps, and FYI, here's a dmesg from the host:

Copyright (c) 1992-2013 The FreeBSD Project.
Copyright (c) 1979, 1980, 1983, 1986, 1988, 1989, 1991, 1992, 1993, 1994
The Regents of the University of California. All rights reserved.
FreeBSD is a registered trademark of The FreeBSD Foundation.
FreeBSD 10.0-CURRENT #7 r248935: Sat Mar 30 13:19:43 CDT 2013
r...@olive.example.com:/usr/obj/usr/src/sys/MACKGEN amd64
FreeBSD clang version 3.2 (tags/RELEASE_32/final 170710) 20121221
CPU: Intel(R) Core(TM) i7-3930K CPU @ 3.20GHz (3200.19-MHz K8-class CPU)
  Origin = GenuineIntel  Id = 0x206d7  Family = 0x6  Model = 0x2d 
Stepping = 7


Features=0xbfebfbffFPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CLFLUSH,DTS,ACPI,MMX,FXSR,SSE,SSE2,SS,HTT,TM,PBE

Features2=0x1fbee3bfSSE3,PCLMULQDQ,DTES64,MON,DS_CPL,VMX,EST,TM2,SSSE3,CX16,xTPR,PDCM,PCID,DCA,SSE4.1,SSE4.2,x2APIC,POPCNT,TSCDLT,AESNI,XSAVE,OSXSAVE,AVX
  AMD Features=0x2c100800SYSCALL,NX,Page1GB,RDTSCP,LM
  AMD Features2=0x1LAHF
  TSC: P-state invariant, performance statistics
real memory  = 68719476736 (65536 MB)
avail memory = 63123800064 (60199 MB)
Event timer LAPIC quality 600

bhyve tty / login problems / panic

2013-03-28 Thread Dan Mack


I haven't spent too much time debugging this yet but I'd thought I'd ask 
just in case someone else has seen this:


 - fresh 10.x system (248804) , standard FreeBSD iso image I made with
   make release

 - latest vmrun.sh release.iso ...
 - install went okay, everything seemed normal

 - boot splash screen comes up fine, select default and do first boot

 - cannot login ... first few attempts result in 'login timed out 
messages' (but they get emitted as soon as I hit CR)


 - eventually I can get in after a few tries but then the shell 
immediately boots me after emitting the motd  :-)


 - and just leaving it sit results in panic

 - my kernel is mainly just GENERIC with the debugging yanked out and 
raid, scsi, and wifi devices.


Any ideas?


Below is the boot log and what I saw ...
Booting...
GDB: no debug ports present
KDB: debugger backends: ddb
KDB: current backend: ddb
Copyright (c) 1992-2013 The FreeBSD Project.
Copyright (c) 1979, 1980, 1983, 1986, 1988, 1989, 1991, 1992, 1993, 1994
The Regents of the University of California. All rights reserved.
FreeBSD is a registered trademark of The FreeBSD Foundation.
FreeBSD 10.0-CURRENT #4 r248804: Wed Mar 27 19:29:38 CDT 2013
r...@olive.example.com:/usr/obj/usr/src/sys/MACKGEN amd64
FreeBSD clang version 3.2 (tags/RELEASE_32/final 170710) 20121221
CPU: Intel(R) Core(TM) i7-3930K CPU @ 3.20GHz (3199.83-MHz K8-class CPU)
  Origin = GenuineIntel  Id = 0x206d7  Family = 0x6  Model = 0x2d 
Stepping = 7


Features=0x8fa3ab7fFPU,VME,DE,PSE,TSC,MSR,PAE,CX8,APIC,SEP,PGE,CMOV,PAT,PSE36,DTS,MMX,FXSR,SSE,SSE2,SS,PBE

Features2=0x83bee217SSE3,PCLMULQDQ,DTES64,DS_CPL,SSSE3,CX16,xTPR,PDCM,PCID,DCA,SSE4.1,SSE4.2,x2APIC,POPCNT,TSCDLT,AESNI,HV
  AMD Features=0x2c100800SYSCALL,NX,Page1GB,RDTSCP,LM
  AMD Features2=0x1LAHF
  TSC: P-state invariant
real memory  = 536870912 (512 MB)
avail memory = 482803712 (460 MB)
Event timer LAPIC quality 400
ACPI APIC Table: BHYVE  BVMADT  
FreeBSD/SMP: Multiprocessor System Detected: 2 CPUs
FreeBSD/SMP: 2 package(s) x 1 core(s)
 cpu0 (BSP): APIC ID:  0
login: /amd64 (cocopuff.example.com) (console)ds.KLOCALic 0 mtu 
1500tation)3fff at device 2.0 on pci0i0


FreeBSD/amd64 (cocopuff.example.com) (console)

login: root
Login timed out after 300 seconds

FreeBSD/amd64 (cocopuff.example.com) (console)

login: root
Login timed out after 300 seconds

FreeBSD/amd64 (cocopuff.example.com) (console)

login: root
Login timed out after 300 seconds

FreeBSD/amd64 (cocopuff.example.com) (console)

login: root
Login timed out after 300 seconds

FreeBSD/amd64 (cocopuff.example.com) (console)

login: root
Password:
Jul 12 07:12:58 cocopuff login: ROOT LOGIN (root) ON console
FreeBSD 10.0-CURRENT (MACKGEN) #4 r248804: Wed Mar 27 19:29:38 CDT 2013

Welcome to FreeBSD!

Before seeking technical support, please use the following resources:

o  Security advisories and updated errata information for all releases are
   at http://www.FreeBSD.org/releases/ - always consult the ERRATA section
   for your release first as it's updated frequently.

o  The Handbook and FAQ documents are at http://www.FreeBSD.org/ and,
   along with the mailing lists, can be searched by going to
   http://www.FreeBSD.org/search/.  If the doc package has been installed
   (or fetched via pkg install lang-freebsd-doc, where lang is the
   2-letter language code, e.g. en), they are also available formatted

If you still have a question or problem, please take the output of
`uname -a', along with any relevant error messages, and email it
as a question to the questi...@freebsd.org mailing list.  If you are
unfamiliar with FreeBSD's directory layout, please refer to the hier(7)
manual page.  If you are not familiar with manual pages, type `man man'.

Edit /etc/motd to change this login announcement.

You have new mail.
You have new mail.
root@cocopuff:~ # auto-logout

FreeBSD/amd64 (cocopuff.macktronics.com) (console)

login: panic: deadlkres: possible deadlock detected for 
0xfe001c919920, blocked for 303081 ticks


cpuid = 0
KDB: enter: panic
[ thread pid 0 tid 100027 ]
Stopped at  kdb_enter+0x3e: movq$0,kdb_why
db bt
Tracing pid 0 tid 100027 td 0xfe000358f490
kdb_enter() at kdb_enter+0x3e/frame 0xff80002bcae0
panic() at panic+0x176/frame 0xff80002bcb60
deadlkres() at deadlkres+0x488/frame 0xff80002bcbb0
fork_exit() at fork_exit+0x9a/frame 0xff80002bcbf0
fork_trampoline() at fork_trampoline+0xe/frame 0xff80002bcbf0
--- trap 0, rip = 0, rsp = 0xff80002bccb0, rbp = 0 ---


___
freebsd-virtualization@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-virtualization
To unsubscribe, send any mail to 
freebsd-virtualization-unsubscr...@freebsd.org


Re: bhyve tty / login problems / panic

2013-03-28 Thread Dan Mack


Update#1:   I was using the default of 2 virtual CPUs.  When I switched to 
1 CPU via vmrun.sh, the system booted clean and let me login.


Also, when running with two vCPUs, the bhyve process is spinning at 100% 
even when the guest is doing nothing.


When running with one CPU, bhyve is mostly idle when the guest is idle.

Whatever was happening, it was impacting system time in a bad way as all 
of the log files were already getting rotated even though the system was 
less than 30 minutes old :-)


Let me know if there is anything I can do to help and if you have any 
ideas on a solution (other than only using uni-processor guests).


Thanks,

Dan

On Thu, 28 Mar 2013, Dan Mack wrote:



I haven't spent too much time debugging this yet but I'd thought I'd ask just 
in case someone else has seen this:


- fresh 10.x system (248804) , standard FreeBSD iso image I made with
  make release

- latest vmrun.sh release.iso ...
- install went okay, everything seemed normal

- boot splash screen comes up fine, select default and do first boot

- cannot login ... first few attempts result in 'login timed out messages' 
(but they get emitted as soon as I hit CR)


- eventually I can get in after a few tries but then the shell immediately 
boots me after emitting the motd  :-)


- and just leaving it sit results in panic

- my kernel is mainly just GENERIC with the debugging yanked out and raid, 
scsi, and wifi devices.


Any ideas?


Below is the boot log and what I saw ...
Booting...
GDB: no debug ports present
KDB: debugger backends: ddb
KDB: current backend: ddb
Copyright (c) 1992-2013 The FreeBSD Project.
Copyright (c) 1979, 1980, 1983, 1986, 1988, 1989, 1991, 1992, 1993, 1994
   The Regents of the University of California. All rights reserved.
FreeBSD is a registered trademark of The FreeBSD Foundation.
FreeBSD 10.0-CURRENT #4 r248804: Wed Mar 27 19:29:38 CDT 2013
   r...@olive.example.com:/usr/obj/usr/src/sys/MACKGEN amd64
FreeBSD clang version 3.2 (tags/RELEASE_32/final 170710) 20121221
CPU: Intel(R) Core(TM) i7-3930K CPU @ 3.20GHz (3199.83-MHz K8-class CPU)
 Origin = GenuineIntel  Id = 0x206d7  Family = 0x6  Model = 0x2d Stepping 
= 7


Features=0x8fa3ab7fFPU,VME,DE,PSE,TSC,MSR,PAE,CX8,APIC,SEP,PGE,CMOV,PAT,PSE36,DTS,MMX,FXSR,SSE,SSE2,SS,PBE

Features2=0x83bee217SSE3,PCLMULQDQ,DTES64,DS_CPL,SSSE3,CX16,xTPR,PDCM,PCID,DCA,SSE4.1,SSE4.2,x2APIC,POPCNT,TSCDLT,AESNI,HV
 AMD Features=0x2c100800SYSCALL,NX,Page1GB,RDTSCP,LM
 AMD Features2=0x1LAHF
 TSC: P-state invariant
real memory  = 536870912 (512 MB)
avail memory = 482803712 (460 MB)
Event timer LAPIC quality 400
ACPI APIC Table: BHYVE  BVMADT  
FreeBSD/SMP: Multiprocessor System Detected: 2 CPUs
FreeBSD/SMP: 2 package(s) x 1 core(s)
cpu0 (BSP): APIC ID:  0
login: /amd64 (cocopuff.example.com) (console)ds.KLOCALic 0 mtu 
1500tation)3fff at device 2.0 on pci0i0


FreeBSD/amd64 (cocopuff.example.com) (console)

login: root
Login timed out after 300 seconds

FreeBSD/amd64 (cocopuff.example.com) (console)

login: root
Login timed out after 300 seconds

FreeBSD/amd64 (cocopuff.example.com) (console)

login: root
Login timed out after 300 seconds

FreeBSD/amd64 (cocopuff.example.com) (console)

login: root
Login timed out after 300 seconds

FreeBSD/amd64 (cocopuff.example.com) (console)

login: root
Password:
Jul 12 07:12:58 cocopuff login: ROOT LOGIN (root) ON console
FreeBSD 10.0-CURRENT (MACKGEN) #4 r248804: Wed Mar 27 19:29:38 CDT 2013

Welcome to FreeBSD!

Before seeking technical support, please use the following resources:

o  Security advisories and updated errata information for all releases are
  at http://www.FreeBSD.org/releases/ - always consult the ERRATA section
  for your release first as it's updated frequently.

o  The Handbook and FAQ documents are at http://www.FreeBSD.org/ and,
  along with the mailing lists, can be searched by going to
  http://www.FreeBSD.org/search/.  If the doc package has been installed
  (or fetched via pkg install lang-freebsd-doc, where lang is the
  2-letter language code, e.g. en), they are also available formatted

If you still have a question or problem, please take the output of
`uname -a', along with any relevant error messages, and email it
as a question to the questi...@freebsd.org mailing list.  If you are
unfamiliar with FreeBSD's directory layout, please refer to the hier(7)
manual page.  If you are not familiar with manual pages, type `man man'.

Edit /etc/motd to change this login announcement.

You have new mail.
You have new mail.
root@cocopuff:~ # auto-logout

FreeBSD/amd64 (cocopuff.macktronics.com) (console)

login: panic: deadlkres: possible deadlock detected for 0xfe001c919920, 
blocked for 303081 ticks


cpuid = 0
KDB: enter: panic
[ thread pid 0 tid 100027 ]
Stopped at  kdb_enter+0x3e: movq$0,kdb_why
db bt
Tracing pid 0 tid 100027 td 0xfe000358f490
kdb_enter() at kdb_enter+0x3e/frame 0xff80002bcae0
panic() at panic+0x176/frame 0xff80002bcb60
deadlkres() at 

Re: bhyve tty / login problems / panic

2013-03-28 Thread Peter Grehan

Hi Dan,


Any ideas?


 Just to confirm: your host system is an i7 3930k, which looks like a 6 
core system. Should be plenty beefy enough for a 2 vCPU guest.


 The issue you are seeing looks a bit like what happens when systems 
are heavily oversubscribed and vCPUs can't get enough run time.


 How much spare RAM is on the host when you started the vm ? Also, is 
there much running on the host when the guest is started ?


later,

Peter.
___
freebsd-virtualization@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-virtualization
To unsubscribe, send any mail to 
freebsd-virtualization-unsubscr...@freebsd.org