1 |
Hello |
2 |
I would like to share my experience with ram issue on gentoo (1.12.13) |
3 |
I am running 64bit xen fedora kernel 2.6.31-6 |
4 |
(http://wiki.xensource.com/xenwiki/XenParavirtOps) |
5 |
Why? - because previous 2.6.31-r7 from |
6 |
http://code.google.com/p/gentoo-xen-kernel/downloads/list was unstable and |
7 |
also only 3GB ram were visible. |
8 |
|
9 |
There are 4GB ram installed on server. With standard kernel (2.6.30-r5), I |
10 |
am able to see it all. Because of this, I disqualify grub bug. |
11 |
With xen kernel, I saw only 3GB. |
12 |
|
13 |
xm dmesg: |
14 |
(XEN) Xen-e820 RAM map: |
15 |
(XEN) 0000000000000000 - 000000000009f000 (usable) |
16 |
(XEN) 000000000009f000 - 00000000000a0000 (reserved) |
17 |
(XEN) 00000000000f0000 - 0000000000100000 (reserved) |
18 |
(XEN) 0000000000100000 - 00000000bbeb0000 (usable) <----------- |
19 |
3GB |
20 |
(XEN) 00000000bbeb0000 - 00000000bbee3000 (ACPI NVS) |
21 |
(XEN) 00000000bbee3000 - 00000000bbef0000 (ACPI data) |
22 |
(XEN) 00000000bbef0000 - 00000000bbf00000 (reserved) |
23 |
(XEN) 00000000bc000000 - 00000000c0000000 (reserved) |
24 |
(XEN) 00000000f0000000 - 00000000f4000000 (reserved) |
25 |
(XEN) 00000000fec00000 - 0000000100000000 (reserved) |
26 |
(XEN) 0000000100000000 - 0000000140000000 (usable) <--------- 1 |
27 |
GB |
28 |
(XEN) System RAM: 4030MB (4127036kB) |
29 |
|
30 |
I do not know how this is possible: 140000000 = 5120MB and only 4030MB are |
31 |
installed. |
32 |
|
33 |
In standard dmesg output (just "dmesg" in dom0, not "xm dmesg") I saw only |
34 |
3GB address space. |
35 |
I double checked kernel configuration and compared with standard kernel |
36 |
config, however no dirrefence found (except xen options). |
37 |
|
38 |
|
39 |
lnx2 linux-2.6.31-6-xen # grep -i mem .config | grep -v "#" |
40 |
CONFIG_SHMEM=y |
41 |
CONFIG_XEN_MAX_DOMAIN_MEMORY=32 |
42 |
CONFIG_ARCH_SPARSEMEM_DEFAULT=y |
43 |
CONFIG_ARCH_SPARSEMEM_ENABLE=y |
44 |
CONFIG_ARCH_SELECT_MEMORY_MODEL=y |
45 |
CONFIG_SELECT_MEMORY_MODEL=y |
46 |
CONFIG_SPARSEMEM_MANUAL=y |
47 |
CONFIG_SPARSEMEM=y |
48 |
CONFIG_HAVE_MEMORY_PRESENT=y |
49 |
CONFIG_SPARSEMEM_EXTREME=y |
50 |
CONFIG_SPARSEMEM_VMEMMAP_ENABLE=y |
51 |
CONFIG_SPARSEMEM_VMEMMAP=y |
52 |
CONFIG_X86_BOOTPARAM_MEMORY_CORRUPTION_CHECK=y |
53 |
CONFIG_ARCH_ENABLE_MEMORY_HOTPLUG=y |
54 |
CONFIG_INPUT_FF_MEMLESS=y |
55 |
CONFIG_DEVKMEM=y |
56 |
CONFIG_FIX_EARLYCON_MEM=y |
57 |
CONFIG_FIRMWARE_MEMMAP=y |
58 |
CONFIG_DEBUG_MEMORY_INIT=y |
59 |
CONFIG_HAVE_ARCH_KMEMCHECK=y |
60 |
CONFIG_ASYNC_MEMCPY=y |
61 |
CONFIG_HAS_IOMEM=y |
62 |
|
63 |
|
64 |
lnx2 linux-2.6.31-6-xen # grep -i ram .config | grep -v "#" |
65 |
CONFIG_X86_TRAMPOLINE=y |
66 |
CONFIG_SCHED_OMIT_FRAME_POINTER=y |
67 |
CONFIG_X86_BOOTPARAM_MEMORY_CORRUPTION_CHECK=y |
68 |
CONFIG_BLK_DEV_RAM=y |
69 |
CONFIG_BLK_DEV_RAM_COUNT=16 |
70 |
CONFIG_BLK_DEV_RAM_SIZE=16384 |
71 |
CONFIG_NVRAM=y |
72 |
CONFIG_FRAMEBUFFER_CONSOLE=y |
73 |
CONFIG_FRAME_WARN=2048 |
74 |
CONFIG_ARCH_WANT_FRAME_POINTERS=y |
75 |
CONFIG_FRAME_POINTER=y |
76 |
lnx2 linux-2.6.31-6-xen # |
77 |
|
78 |
|
79 |
Another symptom: |
80 |
|
81 |
xm top: |
82 |
======= |
83 |
dom0 = 4GB |
84 |
|
85 |
xm list: |
86 |
======== |
87 |
dom0= 3GB |
88 |
|
89 |
Once VPS was started, dom0 ram size was decreased. So only 3GB were |
90 |
available for dom0 + VPS |
91 |
|
92 |
|
93 |
|
94 |
As a workaround I added dom0_mem=512M to kernel line in grub.conf |
95 |
|
96 |
title XEN-6-fedora |
97 |
root (hd0,0) |
98 |
kernel /boot/xen.gz dom0_mem=512M |
99 |
module /boot/vmlinuz-2.6.31-6-xen-dom0 root=/dev/md0 |
100 |
acpi_enforce_resources=lax |
101 |
|
102 |
|
103 |
xm top: |
104 |
======= |
105 |
dom0 = 512MB |
106 |
|
107 |
xm list: |
108 |
======== |
109 |
dom0= 512MB |
110 |
|
111 |
Now, I can see only 512MB in dom0, however rest of memory (3,5GB) is |
112 |
usable for VPS :) :) :) |
113 |
|
114 |
I was searching on google over 2 months, but noone report this issue (some |
115 |
users had turned off PAE on 32bit, some had wrongly configured BIOS). |
116 |
So I hope that this mail will help to someone who have the same problem, |
117 |
or that someone will find reason of this strangeness. |
118 |
|
119 |
|
120 |
Thanks and regards |
121 |
|
122 |
samox86 |
123 |
lnx@×××.sk |