# System Console Slow and inoperative



## torcod (Oct 10, 2011)

I'm not quite sure if this should go here or in system hardware so if a mod wants to move it I won't be offended. 

Anyway a few weeks ago I received a HP Microserver at work in order to replace a FreeBSD server which had a hardware failure. The system is running 8.2-RELEASE and everything operates normally except the console.

I noticed during installation that changing virtual consoles seemed to lag I didn't really think anything of it though as the server is managed 99% of the time through ssh.

Recently some of the virtual consoles have become unusable. On the first console the system log messages are printed normally but the keyboard is completely unresponsive. The second has the same issue only on the screen it looks as if the enter key has been pressed a few times in the login and it displays a password prompt only the 'p' is missing. (I did check to see if the monitor was just cutting off the first letter but it was not) The third console worked fine a few days ago but when I checked it today the same password prompt has appeared only missing a letter. The fourth console is still working but I assume the same thing will happen by tomorrow.

As far as I know no one else has touched the server except me and corporate policies do prevent others from doing so.

So does anyone have any ideas? (No this isn't a joke I've just been stumped looking at it the last few days.

The logs have no relevant messages and the only things that are different on this machine from a stock install are that netatalk and samba were added from ports, no other system files have changed.

I have also tried the obvious fixes of trying a different keyboard, trying it without the kvm, disabling usb legacy, etc.

I've added the dmesg below and can add any other files if anyone wants to see them.
Lastly in the dmesg there is a mention of a usb->ps/2 converter the problem exists whether or not it is active.


```
Copyright (c) 1992-2011 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 8.2-RELEASE-p3 #0: Tue Sep 27 18:45:57 UTC 2011
    root@amd64-builder.daemonology.net:/usr/obj/usr/src/sys/GENERIC amd64
Timecounter "i8254" frequency 1193182 Hz quality 0
CPU: AMD Turion(tm) II Neo N40L Dual-Core Processor (1497.51-MHz K8-class CPU)
  Origin = "AuthenticAMD"  Id = 0x100f63  Family = 10  Model = 6  Stepping = 3
  Features=0x178bfbff<FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CLFLUSH,MMX,FXSR,SSE,SSE2,HTT>
  Features2=0x802009<SSE3,MON,CX16,POPCNT>
  AMD Features=0xee500800<SYSCALL,NX,MMX+,FFXSR,Page1GB,RDTSCP,LM,3DNow!+,3DNow!>
  AMD Features2=0x837ff<LAHF,CMP,SVM,ExtAPIC,CR8,ABM,SSE4A,MAS,Prefetch,OSVW,IBS,SKINIT,WDT,<b19>>
  TSC: P-state invariant
real memory  = 2147483648 (2048 MB)
avail memory = 1924272128 (1835 MB)
ACPI APIC Table: <HP     ProLiant>
FreeBSD/SMP: Multiprocessor System Detected: 2 CPUs
FreeBSD/SMP: 1 package(s) x 2 core(s)
 cpu0 (BSP): APIC ID:  0
 cpu1 (AP): APIC ID:  1
ioapic0 <Version 2.1> irqs 0-23 on motherboard
kbd1 at kbdmux0
acpi0: <HP ProLiant> on motherboard
acpi0: [ITHREAD]
acpi0: Power Button (fixed)
acpi0: reservation of fee00000, 1000 (3) failed
acpi0: reservation of ffb80000, 80000 (3) failed
acpi0: reservation of fec10000, 20 (3) failed
acpi0: reservation of fed80000, 1000 (3) failed
acpi0: reservation of 0, a0000 (3) failed
acpi0: reservation of 100000, 77f00000 (3) failed
Timecounter "ACPI-safe" frequency 3579545 Hz quality 850
acpi_timer0: <32-bit timer at 3.579545MHz> port 0x808-0x80b on acpi0
cpu0: <ACPI CPU> on acpi0
cpu1: <ACPI CPU> on acpi0
pcib0: <ACPI Host-PCI bridge> port 0xcf8-0xcff on acpi0
pci0: <ACPI PCI bus> on pcib0
pcib1: <ACPI PCI-PCI bridge> at device 1.0 on pci0
pci1: <ACPI PCI bus> on pcib1
vgapci0: <VGA-compatible display> port 0xe000-0xe0ff mem 0xf0000000-0xf7ffffff,0xfe8f0000-0xfe8fffff,0xfe700000-0xfe7fffff irq 18 at device 5.0 on pci1
pcib2: <ACPI PCI-PCI bridge> irq 18 at device 6.0 on pci0
pci2: <ACPI PCI bus> on pcib2
bge0: <HP NC107i PCIe Gigabit Server Adapter, ASIC rev. 0x5784100> mem 0xfe9f0000-0xfe9fffff irq 18 at device 0.0 on pci2
bge0: CHIP ID 0x05784100; ASIC REV 0x5784; CHIP REV 0x57841; PCI-E
miibus0: <MII bus> on bge0
brgphy0: <BCM5784 10/100/1000baseTX PHY> PHY 1 on miibus0
brgphy0:  10baseT, 10baseT-FDX, 100baseTX, 100baseTX-FDX, 1000baseT, 1000baseT-master, 1000baseT-FDX, 1000baseT-FDX-master, auto, auto-flow
bge0: Ethernet address: 3c:d9:2b:04:23:e4
bge0: [FILTER]
atapci0: <ATI IXP700/800 SATA300 controller> port 0xd000-0xd007,0xc000-0xc003,0xb000-0xb007,0xa000-0xa003,0x9000-0x900f mem 0xfe6ffc00-0xfe6fffff irq 19 at device 17.0 on pci0
atapci0: [ITHREAD]
atapci0: AHCI v1.20 controller with 4 3Gbps ports, PM supported
ata2: <ATA channel 0> on atapci0
ata2: [ITHREAD]
ata3: <ATA channel 1> on atapci0
ata3: [ITHREAD]
ata4: <ATA channel 2> on atapci0
ata4: [ITHREAD]
ata5: <ATA channel 3> on atapci0
ata5: [ITHREAD]
ohci0: <OHCI (generic) USB controller> mem 0xfe6fe000-0xfe6fefff irq 18 at device 18.0 on pci0
ohci0: [ITHREAD]
usbus0: <OHCI (generic) USB controller> on ohci0
ehci0: <EHCI (generic) USB 2.0 controller> mem 0xfe6ff800-0xfe6ff8ff irq 17 at device 18.2 on pci0
ehci0: [ITHREAD]
usbus1: EHCI version 1.0
usbus1: <EHCI (generic) USB 2.0 controller> on ehci0
ohci1: <OHCI (generic) USB controller> mem 0xfe6fd000-0xfe6fdfff irq 18 at device 19.0 on pci0
ohci1: [ITHREAD]
usbus2: <OHCI (generic) USB controller> on ohci1
ehci1: <EHCI (generic) USB 2.0 controller> mem 0xfe6ff400-0xfe6ff4ff irq 17 at device 19.2 on pci0
ehci1: [ITHREAD]
usbus3: EHCI version 1.0
usbus3: <EHCI (generic) USB 2.0 controller> on ehci1
pci0: <serial bus, SMBus> at device 20.0 (no driver attached)
atapci1: <ATI IXP700/800 UDMA133 controller> port 0x1f0-0x1f7,0x3f6,0x170-0x177,0x376,0xff00-0xff0f at device 20.1 on pci0
ata0: <ATA channel 0> on atapci1
ata0: [ITHREAD]
ata1: <ATA channel 1> on atapci1
ata1: [ITHREAD]
isab0: <PCI-ISA bridge> at device 20.3 on pci0
isa0: <ISA bus> on isab0
pcib3: <ACPI PCI-PCI bridge> at device 20.4 on pci0
pci3: <ACPI PCI bus> on pcib3
ohci2: <OHCI (generic) USB controller> mem 0xfe6fc000-0xfe6fcfff irq 18 at device 22.0 on pci0
ohci2: [ITHREAD]
usbus4: <OHCI (generic) USB controller> on ohci2
ehci2: <EHCI (generic) USB 2.0 controller> mem 0xfe6ff000-0xfe6ff0ff irq 17 at device 22.2 on pci0
ehci2: [ITHREAD]
usbus5: EHCI version 1.0
usbus5: <EHCI (generic) USB 2.0 controller> on ehci2
acpi_button0: <Power Button> on acpi0
atrtc0: <AT realtime clock> port 0x70-0x71 irq 8 on acpi0
acpi_hpet0: <High Precision Event Timer> iomem 0xfed00000-0xfed003ff on acpi0
acpi_hpet0: HPET never increments, disabling
device_attach: acpi_hpet0 attach returned 6
atkbd: unable to set the command byte.
sc0: <System console> at flags 0x100 on isa0
sc0: VGA <16 virtual consoles, flags=0x300>
vga0: <Generic ISA VGA> at port 0x3c0-0x3df iomem 0xa0000-0xbffff on isa0
atkbdc0: <Keyboard controller (i8042)> at port 0x60,0x64 on isa0
atkbd0: <AT Keyboard> irq 1 on atkbdc0
kbd0 at atkbd0
atkbd0: [GIANT-LOCKED]
atkbd0: [ITHREAD]
psm0: unable to set the command byte.
ppc0: cannot reserve I/O port range
acpi_throttle0: <ACPI CPU Throttling> on cpu0
hwpstate0: <Cool`n'Quiet 2.0> on cpu0
Timecounters tick every 1.000 msec
usbus0: 12Mbps Full Speed USB v1.0
usbus1: 480Mbps High Speed USB v2.0
usbus2: 12Mbps Full Speed USB v1.0
usbus3: 480Mbps High Speed USB v2.0
usbus4: 12Mbps Full Speed USB v1.0
usbus5: 480Mbps High Speed USB v2.0
ad4: 238475MB <VB0250EAVER HPG0> at ata2-master UDMA100 SATA 3Gb/s
ugen0.1: <ATI> at usbus0
uhub0: <ATI OHCI root HUB, class 9/0, rev 1.00/1.00, addr 1> on usbus0
ugen1.1: <ATI> at usbus1
uhub1: <ATI EHCI root HUB, class 9/0, rev 2.00/1.00, addr 1> on usbus1
ugen2.1: <ATI> at usbus2
uhub2: <ATI OHCI root HUB, class 9/0, rev 1.00/1.00, addr 1> on usbus2
ugen3.1: <ATI> at usbus3
uhub3: <ATI EHCI root HUB, class 9/0, rev 2.00/1.00, addr 1> on usbus3
ugen4.1: <ATI> at usbus4
uhub4: <ATI OHCI root HUB, class 9/0, rev 1.00/1.00, addr 1> on usbus4
ugen5.1: <ATI> at usbus5
uhub5: <ATI EHCI root HUB, class 9/0, rev 2.00/1.00, addr 1> on usbus5
ad6: 1907729MB <Seagate ST32000542AS CC34> at ata3-master UDMA100 SATA 3Gb/s
SMP: AP CPU #1 Launched!
uhub4: 4 ports with 4 removable, self powered
uhub0: 5 ports with 5 removable, self powered
uhub2: 5 ports with 5 removable, self powered
Root mount waiting for: usbus5 usbus3 usbus1
Root mount waiting for: usbus5 usbus3 usbus1
uhub5: 4 ports with 4 removable, self powered
uhub1: 5 ports with 5 removable, self powered
uhub3: 5 ports with 5 removable, self powered
Trying to mount root from ufs:/dev/ad4s1a
ugen2.2: <Composite USB PS2 Converter> at usbus2
ukbd0: <Composite USB PS2 Converter USB to PS2 Adaptor  V3.10, class 0/0, rev 1.10/3.10, addr 2> on usbus2
kbd2 at ukbd0
ums0: <Composite USB PS2 Converter USB to PS2 Adaptor  V3.10, class 0/0, rev 1.10/3.10, addr 2> on usbus2
ums0: 5 buttons and [XYZ] coordinates ID=1
bge0: link state changed to UP
ugen1.2: <HitachiGST> at usbus1
umass0: <MSC Bulk-Only Transfer> on usbus1
umass0:  SCSI over Bulk-Only; quirks = 0x0000
umass0:0:0:-1: Attached to scbus0
```

Thanks for looking.


----------



## wblock@ (Oct 10, 2011)

Escape sequences might eat one or more characters.  Plug in a keyboard directly and see if it works.  Try ctrl-q, too.


----------



## SirDice (Oct 11, 2011)

What videocard does the machine have? I can't make it out from the dmesg output?

And on the console, did somebody use a different resolution (vidcontrol(1))? Those tend to be quite slow.


----------



## torcod (Oct 11, 2011)

SirDice said:
			
		

> What videocard does the machine have? I can't make it out from the dmesg output?
> 
> And on the console, did somebody use a different resolution (vidcontrol(1))? Those tend to be quite slow.



I believe the card is a integrated radeon but I'm not 100% sure. (HP doesn't have any good documentation on it and the system seems to show it as a generic vga card everywhere I look)
I did try changing resolutions with vidcontrol when I first discovered the problem but none of them fixed it. None of the changes were permanent though so it is still running on the default 80x25 console.



			
				wblock@ said:
			
		

> Escape sequences might eat one or more characters. Plug in a keyboard directly and see if it works. Try ctrl-q, too.



Doing ctrl-q and ctrl-c seems to bring the console back to a usable state, thanks!

Since this has happened with multiple keyboards and with and without the kvm and adapters I'm starting to think that this is more of a hardware problem.

The only other thing I can think of to mention is that along with the lag when switching consoles (it's 3-5 seconds) there is also a lag when pressing the numlock, scroll lock, etc. If anyone has ever used an old IBM model M keyboard it's the same sort of delay. It takes ~3 seconds between pressing the key and seeing the light come on / having the system respond.

Thanks for the input everyone.


----------



## torcod (Oct 11, 2011)

SirDice said:
			
		

> What videocard does the machine have? I can't make it out from the dmesg output?
> 
> And on the console, did somebody use a different resolution (vidcontrol(1))? Those tend to be quite slow.



Please disregard what I said about the video card in the last post. I forgot lspci was in ports.


```
01:05.0 VGA compatible controller: ATI Technologies Inc M880G [Mobility Radeon HD 4200]
```


----------



## wblock@ (Oct 12, 2011)

pciconf(8) is the FreeBSD equivalent of lspci.  Mobility Radeon HD4200 should be fine for console or X.


----------



## wblock@ (Oct 12, 2011)

Another idea: if ctrl-q (xon) fixed it, maybe you have a serial console configured?  Check the BIOS.


----------



## torcod (Oct 12, 2011)

The server doesn't contain any serial ports. I did a quick check in the BIOS just to be safe though and found nothing.


----------



## jem (Oct 13, 2011)

Does your MicroServer have the optional IPMI card installed?  That might interfere with the console.


----------



## Crivens (Oct 13, 2011)

Do you run powerd? It may be that the machine is taking too long to wake from some very deep sleep state/acpi_throttle mode and this may mess up connections to the keyboard.


----------



## torcod (Oct 17, 2011)

jem said:
			
		

> Does your MicroServer have the optional IPMI card installed?  That might interfere with the console.



Nope I thought about getting the card but I heard it caused lots of problems so I avoided it.



			
				Crivens said:
			
		

> Do you run powerd? It may be that the machine is taking too long to wake from some very deep sleep state/acpi_throttle mode and this may mess up connections to the keyboard.



I don't run powerd either, I looked through the bios a short while ago to see if there were any cpu frequency scaling related options I could disable but I didn't see any.


----------

