An increase to 3 Gig of RAM slows down Ubuntu 10.04 LTS

Asked by William Pabon on 2012-03-10

I have Ubuntu 10.04 running from an external hard drive (installed on an enclosure) connected via USB port. Like a month or so ago, I increased RAM on my pc from 2 Gigs to 3 Gigs. This resulted on extremely long boot times and slow application loads. While I was understanding the nature of my problem, I posted various threads on this forum ( Questions # 188417, 188801), where I was advised to gather speed tests, and other info on my machine. I was also suggested that I might have problems with the RAM installed. Initially, I did not consider that possibility because:

1) I did a memory test with a diagnostic program from DELL (My pc is from Dell)
2) My pc works fine with Windows XP (the default OS), no problems with memory
3) My pc works fine when booting with Ubuntu 10.10 memory stick, no speed problems
4) My pc works fine when booting with Ubuntu 11.10 memory stick, no speed problems

Anyway, I performed the memory tests suggested. But before doing it, and to check out any possibility of hardware issues on the hard drive, I did the following: (1) purchased a new hard drive enclosure and moved my hard drive to it, (2) purchased a new USB cable and used it to connect my hard drive/enclosure setup to a different USB port on my pc.

Then, I performed speed tests with 1 Gig, 2 Gigs and 3 Gigs of RAM with my Ubuntu 10.04 OS. Ubuntu 10.04 worked well when booted with 1 Gig or 2 Gigs of RAM. When I increased to 3 Gigs, it slowed down to a crawl. I can't understand the relationship between an increase of 1 Gig and the effect it has in Ubuntu 10.04. This doesn't happen with Ubuntu 10.10 and 11.10. Unfortunately for me, Ubuntu 10.04 is my principal work operating system. So, I need a solution for this.

Hardware and system information:

DELL Precision 670
2 internal SATA Hard drives
Audigy 2 ZS audio system
Factory OS: Windows XP Professional SP3
NVidia 8400 GTS video card

williepabon@WP-WrkStation:~$ uname -a
Linux WP-WrkStation 2.6.32-38-generic #83-Ubuntu SMP Wed Jan 4 11:13:04 UTC 2012 i686 GNU/Linux

williepabon@WP-WrkStation:~$ lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 10.04.4 LTS
Release: 10.04
Codename: lucid

Speed test with the 3 Gigs of RAM installed:
williepabon@WP-WrkStation:~$ sudo hdparm -tT /dev/sdc
[sudo] password for williepabon:

/dev/sdc:
Timing cached reads: 84 MB in 2.00 seconds = 41.96 MB/sec
Timing buffered disk reads: 4 MB in 3.81 seconds = 1.05 MB/sec

This is a very slow transfer rate from a hard drive.

I will really appreciate a solution or a work around for this problem. I know that that there are users that have Ubuntu 10.04 with 3 Gigs or more of RAM and they don't have this problem. Thanks.
wp

Question information

Language:
English Edit question
Status:
Solved
For:
Ubuntu linux Edit question
Assignee:
No assignee Edit question
Solved by:
William Pabon
Solved:
2012-03-23
Last query:
2012-03-23
Last reply:
2012-03-11
Chris (fabricator4) said : #1

Have you considered installing the 64 bit release? The 64 bit kernel will be able to use the extra RAM properly. From what you've pasted here the kernel does not appear to be identifying itself as the pae release, so It's not clear to me how it's accessing more than 2GB RAM. Maybe this is part of the problem?

What's the output of the following in terminal:

free

Chris

William Pabon (williepabon) said : #2

Chris:
I have some questions for you. Please, excuse my lack of knowledge on these matters.

(1) I installed the 32 bit version of the OS, and if it is like Windows, it should address up to 3.5 Gigs of RAM. On the other hand, I have received reports from other forums (linuxquestions.org) that 10.04 works OK with 3 Gigs or RAM. Maybe they have the 64 bit version. Is it correct to say that Ubuntu 10.04(32 bit) cannot address more than 2 Gigs of RAM? If this is true, why should this have any bearing on the speed of the machine?

(2) I don't understand what you say about the pae release. Not familiar with the term. Please, explain.

(3) How do I install the 64 bit kernel? Will that erase my configurations, applications and settings? 10.04 is my main OS and I have all my stuff there.

Right now I'm writing this post with Ubuntu 11.10 (32 bit) on the same pc as described above. Using this OS, I ran the command suggested. This is the result.

williepabon@WorkStation-670:~$ sudo free
[sudo] password for williepabon:
             total used free shared buffers cached
Mem: 3096992 1224832 1872160 0 81620 644072
-/+ buffers/cache: 499140 2597852
Swap: 498684 0 498684

If you need the results of it for 10.04, I will boot up an run the command, and send the results to you. Thanks for your help.
wp

William Pabon (williepabon) said : #3

Chris:
 Here is the result of free on Ubuntu 10.04:

williepabon@WP-WrkStation:~$ sudo free
[sudo] password for williepabon:
             total used free shared buffers cached
Mem: 3095340 792304 2303036 0 82212 386240
-/+ buffers/cache: 323852 2771488
Swap: 1991672 0 1991672

Hope this helps.
wp

William Pabon (williepabon) said : #4

Chris:

A few minutes ago, I installed the pae version of the kernel:

williepabon@WP-WrkStation:~$ sudo uname -a
[sudo] password for williepabon:
Linux WP-WrkStation 2.6.32-39-generic-pae #86-Ubuntu SMP Mon Feb 13 23:05:11 UTC 2012 i686 GNU/Linux

williepabon@WP-WrkStation:~$ lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 10.04.4 LTS
Release: 10.04
Codename: lucid

The low speed problem still exists.

William Pabon (williepabon) said : #5

Any ideas yet for the solution of this issue? Thanks
wp

William Pabon (williepabon) said : #6

My suspicions on the cause of this problem is moving into the way the OS loads the USB drivers (uhci-hcd and ehci_hcd). It appears that the OS is not loading ehci_hcd, which is the fast usb driver.

Here are the results of lsusb -t for ubuntu 10.04

williepabon@WP-WrkStation:~$ sudo lsusb -t
[sudo] password for williepabon:
/: Bus 04.Port 1: Dev 1, Class=root_hub, Driver=uhci_hcd/2p, 12M
|__ Port 1: Dev 2, If 0, Class=hub, Driver=hub/3p, 12M
|__ Port 1: Dev 3, If 0, Class=HID, Driver=usbhid, 12M
|__ Port 1: Dev 3, If 1, Class=HID, Driver=usbhid, 12M
/: Bus 03.Port 1: Dev 1, Class=root_hub, Driver=uhci_hcd/2p, 12M
|__ Port 1: Dev 2, If 0, Class=stor., Driver=ums-cypress, 12M
/: Bus 02.Port 1: Dev 1, Class=root_hub, Driver=uhci_hcd/2p, 12M
/: Bus 01.Port 1: Dev 1, Class=root_hub, Driver=uhci_hcd/2p, 12M
|__ Port 2: Dev 2, If 0, Class='bInterfaceClass 0x0e not yet handled', Driver=uvcvideo, 12M
|__ Port 2: Dev 2, If 1, Class='bInterfaceClass 0x0e not yet handled', Driver=uvcvideo, 12M
|__ Port 2: Dev 2, If 2, Class=audio, Driver=snd-usb-audio, 12M
|__ Port 2: Dev 2, If 3, Class=audio, Driver=snd-usb-audio, 12M

Compared to booting with Ubuntu 10.10,

williepabon@Precision-WorkStation-670:~$ sudo lsusb -t
[sudo] password for williepabon:
/: Bus 05.Port 1: Dev 1, Class=root_hub, Driver=uhci_hcd/2p, 12M
/: Bus 04.Port 1: Dev 1, Class=root_hub, Driver=uhci_hcd/2p, 12M
/: Bus 03.Port 1: Dev 1, Class=root_hub, Driver=uhci_hcd/2p, 12M
/: Bus 02.Port 1: Dev 1, Class=root_hub, Driver=uhci_hcd/2p, 12M
/: Bus 01.Port 1: Dev 1, Class=root_hub, Driver=ehci_hcd/8p, 480M
|__ Port 1: Dev 2, If 0, Class=stor., Driver=usb-storage, 480M
|__ Port 2: Dev 3, If 0, Class='bInterfaceClass 0x0e not yet handled', Driver=uvcvideo, 480M
|__ Port 2: Dev 3, If 1, Class='bInterfaceClass 0x0e not yet handled', Driver=uvcvideo, 480M
|__ Port 2: Dev 3, If 2, Class=audio, Driver=snd-usb-audio, 480M
|__ Port 2: Dev 3, If 3, Class=audio, Driver=snd-usb-audio, 480M

where you see ehci_hcd loaded.

I'm including here a portion of the /var/log/message for you people to analyze and advice.

Problem messages from messages log.

Mar 12 13:16:07 WP-WrkStation kernel: [ 0.735247] pci 0000:00:1d.7: BAR 0: can't allocate resource
Mar 12 13:16:07 WP-WrkStation kernel: [ 0.735398] Expanded resource reserved due to conflict with PCI Bus 0000:00

Mar 12 13:16:07 WP-WrkStation kernel: [ 0.814255] pci 0000:00:1d.7: EHCI: unrecognized capability e0
Mar 12 13:16:07 WP-WrkStation kernel: [ 0.814260] pci 0000:00:1d.7: EHCI: unrecognized capability e0
Mar 12 13:16:07 WP-WrkStation kernel: [ 0.814265] pci 0000:00:1d.7: EHCI: unrecognized capability e0
Mar 12 13:16:07 WP-WrkStation kernel: [ 0.814269] pci 0000:00:1d.7: EHCI: unrecognized capability e0
.....
Mar 12 13:16:07 WP-WrkStation kernel: [ 0.814517] pci 0000:00:1d.7: EHCI: unrecognized capability e0
.....
Mar 12 13:16:07 WP-WrkStation kernel: [ 0.883387] ehci_hcd: USB 2.0 'Enhanced' Host Controller (EHCI) Driver
Mar 12 13:16:07 WP-WrkStation kernel: [ 0.883428] ehci_hcd 0000:00:1d.7: PCI INT D -> GSI 23 (level, low) -> IRQ 23
Mar 12 13:16:07 WP-WrkStation kernel: [ 0.883458] ehci_hcd 0000:00:1d.7: EHCI Host Controller
Mar 12 13:16:07 WP-WrkStation kernel: [ 0.883526] ehci_hcd 0000:00:1d.7: new USB bus registered, assigned bus number 1
Mar 12 13:16:07 WP-WrkStation kernel: [ 0.883571] ehci_hcd 0000:00:1d.7: debug port 15 IN USE
Mar 12 13:16:07 WP-WrkStation kernel: [ 0.907258] ehci_hcd 0000:00:1d.7: irq 23, io mem 0xbff00000
Mar 12 13:16:07 WP-WrkStation kernel: [ 0.907284] ehci_hcd 0000:00:1d.7: USB bus 1 deregistered
Mar 12 13:16:07 WP-WrkStation kernel: [ 0.907359] ehci_hcd 0000:00:1d.7: PCI INT D disabled

.....
Mar 12 13:16:07 WP-WrkStation kernel: [ 0.907403] ohci_hcd: USB 1.1 'Open' Host Controller (OHCI) Driver
Mar 12 13:16:07 WP-WrkStation kernel: [ 0.907434] uhci_hcd: USB Universal Host Controller Interface driver
Mar 12 13:16:07 WP-WrkStation kernel: [ 0.907479] uhci_hcd 0000:00:1d.0: PCI INT A -> GSI 16 (level, low) -> IRQ 16
Mar 12 13:16:07 WP-WrkStation kernel: [ 0.907495] uhci_hcd 0000:00:1d.0: UHCI Host Controller
Mar 12 13:16:07 WP-WrkStation kernel: [ 0.907553] uhci_hcd 0000:00:1d.0: new USB bus registered, assigned bus number 1
Mar 12 13:16:07 WP-WrkStation kernel: [ 0.907590] uhci_hcd 0000:00:1d.0: irq 16, io base 0x0000ff80
Mar 12 13:16:07 WP-WrkStation kernel: [ 0.907757] usb usb1: configuration #1 chosen from 1 choice
Mar 12 13:16:07 WP-WrkStation kernel: [ 0.907815] hub 1-0:1.0: USB hub found
Mar 12 13:16:07 WP-WrkStation kernel: [ 0.907828] hub 1-0:1.0: 2 ports detected
Mar 12 13:16:07 WP-WrkStation kernel: [ 0.907919] uhci_hcd 0000:00:1d.1: PCI INT B -> GSI 19 (level, low) -> IRQ 19
Mar 12 13:16:07 WP-WrkStation kernel: [ 0.907934] uhci_hcd 0000:00:1d.1: UHCI Host Controller
Mar 12 13:16:07 WP-WrkStation kernel: [ 0.907991] uhci_hcd 0000:00:1d.1: new USB bus registered, assigned bus number 2
Mar 12 13:16:07 WP-WrkStation kernel: [ 0.908026] uhci_hcd 0000:00:1d.1: irq 19, io base 0x0000ff60
Mar 12 13:16:07 WP-WrkStation kernel: [ 0.908191] usb usb2: configuration #1 chosen from 1 choice
Mar 12 13:16:07 WP-WrkStation kernel: [ 0.908242] hub 2-0:1.0: USB hub found
Mar 12 13:16:07 WP-WrkStation kernel: [ 0.908253] hub 2-0:1.0: 2 ports detected
Mar 12 13:16:07 WP-WrkStation kernel: [ 0.908329] uhci_hcd 0000:00:1d.2: PCI INT C -> GSI 18 (level, low) -> IRQ 18
Mar 12 13:16:07 WP-WrkStation kernel: [ 0.908346] uhci_hcd 0000:00:1d.2: UHCI Host Controller
Mar 12 13:16:07 WP-WrkStation kernel: [ 0.908403] uhci_hcd 0000:00:1d.2: new USB bus registered, assigned bus number 3
Mar 12 13:16:07 WP-WrkStation kernel: [ 0.908429] uhci_hcd 0000:00:1d.2: irq 18, io base 0x0000ff40
Mar 12 13:16:07 WP-WrkStation kernel: [ 0.908587] usb usb3: configuration #1 chosen from 1 choice
Mar 12 13:16:07 WP-WrkStation kernel: [ 0.908636] hub 3-0:1.0: USB hub found
Mar 12 13:16:07 WP-WrkStation kernel: [ 0.908648] hub 3-0:1.0: 2 ports detected
Mar 12 13:16:07 WP-WrkStation kernel: [ 0.908721] uhci_hcd 0000:00:1d.3: PCI INT A -> GSI 16 (level, low) -> IRQ 16
Mar 12 13:16:07 WP-WrkStation kernel: [ 0.908736] uhci_hcd 0000:00:1d.3: UHCI Host Controller
Mar 12 13:16:07 WP-WrkStation kernel: [ 0.908799] uhci_hcd 0000:00:1d.3: new USB bus registered, assigned bus number 4
Mar 12 13:16:07 WP-WrkStation kernel: [ 0.908825] uhci_hcd 0000:00:1d.3: irq 16, io base 0x0000ff20
Mar 12 13:16:07 WP-WrkStation kernel: [ 0.908983] usb usb4: configuration #1 chosen from 1 choice
Mar 12 13:16:07 WP-WrkStation kernel: [ 0.909033] hub 4-0:1.0: USB hub found
Mar 12 13:16:07 WP-WrkStation kernel: [ 0.909045] hub 4-0:1.0: 2 ports detected
......
Mar 12 13:16:07 WP-WrkStation kernel: [ 1.968031] usb 4-1: new full speed USB device using uhci_hcd and address 2
Mar 12 13:16:07 WP-WrkStation kernel: [ 2.137898] usb 4-1: configuration #1 chosen from 1 choice
Mar 12 13:16:07 WP-WrkStation kernel: [ 2.145795] hub 4-1:1.0: USB hub found
Mar 12 13:16:07 WP-WrkStation kernel: [ 2.146757] hub 4-1:1.0: 3 ports detected
Mar 12 13:16:07 WP-WrkStation kernel: [ 2.425732] usb 4-1.1: new full speed USB device using uhci_hcd and address 3

On the kern.log I get the following:

.........
Mar 12 13:16:07 WP-WrkStation kernel: [ 0.907258] ehci_hcd 0000:00:1d.7: irq 23, io mem 0xbff00000
Mar 12 13:16:07 WP-WrkStation kernel: [ 0.907273] ehci_hcd 0000:00:1d.7: startup error -19
Mar 12 13:16:07 WP-WrkStation kernel: [ 0.907284] ehci_hcd 0000:00:1d.7: USB bus 1 deregistered
Mar 12 13:16:07 WP-WrkStation kernel: [ 0.907359] ehci_hcd 0000:00:1d.7: PCI INT D disabled
Mar 12 13:16:07 WP-WrkStation kernel: [ 0.907365] ehci_hcd 0000:00:1d.7: init 0000:00:1d.7 fail, -19

William Pabon (williepabon) said : #7

Problem is solved. One of the folks from AskUbuntu showed me how to install the 11.10 kernel in my Ubuntu LTS, and with the new kernel, the problem of low speed disappeared. Evidently, there is an issue with 10.04 when you increase RAM, that makes it not to load the ehci_hcd driver (USB) which causes such ports to run very slow.