You are not logged in.

#1 2012-02-08 02:45:36

Oxyd
Member
From: Czech Republic
Registered: 2008-01-17
Posts: 167

Freshly booted Arch uses ~150 MB of memory

Hello everyone.

I've been trying to figure out what makes Arch use about 150 MB of RAM right up the start. To be precise: When I boot my Arch install with just syslog-ng and network daemons, no GUI loaded, freshly logged in, free -m reports 146 MB used memory -- sans buffers and cache (that is, the second line of output).

I consider that to be a bit too much -- surely bare Arch shouldn't need that many. Also I care because I noticed my machine has been hitting the swap a bit too much for my liking (and I've got 3 GB of RAM). I suspect this is not just one-time extra memory used, but overall memory usage being higher than it should be (although I can't know for sure -- but that's what I've been wanting to find out).

I Googled around a bit and saw some people suggesting it could be the nVidia proprietary driver (which I'm using). I tried using the nouveau driver; I tried switching to the on-board graphics chip (which is and AMD/ATI one) but to no avail -- memory usage right after start did decrease a little, but we're talking about 10 MB here. Certainly not what I'd been hoping for.

So I thought it could be some process I hadn't noticed. I killed everything except init, login and bash, but once again nothing much -- the system was using around 110 MB of memory for three userland processes.

I then tried downgrading the kernel to 3.0 -- freshly booted Arch with stock 3.0 kernel was using 97 MB of RAM -- an improvement once again, but still I think that's too much for just the base system.

So, anyone got any ideas what could be the cause? Any other stuff to test?

Offline

#2 2012-02-08 02:51:22

karol
Archivist
Registered: 2009-05-06
Posts: 25,440

Re: Freshly booted Arch uses ~150 MB of memory

But which process is using that memory?
My 32-bit Arch uses 19MB.

Offline

#3 2012-02-08 03:00:25

Jristz
Member
From: America/Santiago
Registered: 2011-06-11
Posts: 1,048

Re: Freshly booted Arch uses ~150 MB of memory

Realy RAM and Processor may have diferents values
exaple:
my old P4 (Kernel 3.0.3) use round 25-32Mran (i686-only)
my second less new but actual machine (x86_64) celeron (corex) use 16-20Mram


Lenovo ThinkPad L420 modified
:: Intel i7 2560QM :: 8 GB RAM :: SSD 256 GB ::
:: DVD read+Writter :: 3 USB 3.0 Expresa Card ::
:: a Favulous 1 mins lasting Io-Li battery ::cry::

Offline

#4 2012-02-08 03:48:43

Oxyd
Member
From: Czech Republic
Registered: 2008-01-17
Posts: 167

Re: Freshly booted Arch uses ~150 MB of memory

karol wrote:

But which process is using that memory?
My 32-bit Arch uses 19MB.

Well, I don't know. As I said -- I tried killing almost every process (except for init and the shell), and the memory usage stayed that high. Even though init + bash together didn't use nearly that much.

Jristz wrote:

Realy RAM and Processor may have diferents values
exaple:
my old P4 (Kernel 3.0.3) use round 25-32Mran (i686-only)
my second less new but actual machine (x86_64) celeron (corex) use 16-20Mram

Yes, I know. I'm on x86_64 -- I should have mentioned that. I would be more than happy with 50 MB RAM -- I don't quite care about a few MB here or there. But still -- what I'm seeing is 150 MB -- almost ten times as much as your machines.

Offline

#5 2012-02-08 03:53:02

karol
Archivist
Registered: 2009-05-06
Posts: 25,440

Re: Freshly booted Arch uses ~150 MB of memory

Can you post the output of 'ps aux'?

Offline

#6 2012-02-08 04:13:47

Oxyd
Member
From: Czech Republic
Registered: 2008-01-17
Posts: 167

Re: Freshly booted Arch uses ~150 MB of memory

Sure thing.

USER       PID %CPU %MEM    VSZ   RSS TTY      STAT START   TIME COMMAND
root         1  2.6  0.0   4192   672 ?        Ss   05:09   0:00 init [3]
root         2  0.0  0.0      0     0 ?        S    05:09   0:00 [kthreadd]
root         3  0.0  0.0      0     0 ?        S    05:09   0:00 [ksoftirqd/0]
root         4  0.0  0.0      0     0 ?        S    05:09   0:00 [kworker/0:0]
root         5  0.0  0.0      0     0 ?        S    05:09   0:00 [kworker/u:0]
root         6  0.0  0.0      0     0 ?        S    05:09   0:00 [migration/0]
root         7  0.0  0.0      0     0 ?        S    05:09   0:00 [watchdog/0]
root         8  0.0  0.0      0     0 ?        S    05:09   0:00 [migration/1]
root         9  0.0  0.0      0     0 ?        S    05:09   0:00 [kworker/1:0]
root        10  0.0  0.0      0     0 ?        S    05:09   0:00 [ksoftirqd/1]
root        11  0.0  0.0      0     0 ?        S    05:09   0:00 [kworker/0:1]
root        12  0.0  0.0      0     0 ?        S    05:09   0:00 [watchdog/1]
root        13  0.0  0.0      0     0 ?        S<   05:09   0:00 [cpuset]
root        14  0.0  0.0      0     0 ?        S<   05:09   0:00 [khelper]
root        15  0.0  0.0      0     0 ?        S    05:09   0:00 [kdevtmpfs]
root        16  0.0  0.0      0     0 ?        S<   05:09   0:00 [netns]
root        17  0.0  0.0      0     0 ?        S    05:09   0:00 [sync_supers]
root        18  0.0  0.0      0     0 ?        S    05:09   0:00 [bdi-default]
root        19  0.0  0.0      0     0 ?        S<   05:09   0:00 [kblockd]
root        43  0.0  0.0      0     0 ?        S    05:09   0:00 [kworker/1:1]
root        44  0.0  0.0      0     0 ?        S    05:09   0:00 [khungtaskd]
root        45  0.0  0.0      0     0 ?        S    05:09   0:00 [kswapd0]
root        46  0.0  0.0      0     0 ?        SN   05:09   0:00 [ksmd]
root        47  0.0  0.0      0     0 ?        SN   05:09   0:00 [khugepaged]
root        48  0.0  0.0      0     0 ?        S    05:09   0:00 [fsnotify_mark]
root        49  0.0  0.0      0     0 ?        S<   05:09   0:00 [crypto]
root        51  0.0  0.0      0     0 ?        S<   05:09   0:00 [kthrotld]
root        54  0.0  0.0      0     0 ?        S    05:09   0:00 [kworker/1:2]
root       104  0.0  0.0      0     0 ?        S    05:09   0:00 [khubd]
root       113  0.0  0.0      0     0 ?        S<   05:09   0:00 [ata_sff]
root       120  0.0  0.0      0     0 ?        S    05:09   0:00 [scsi_eh_0]
root       121  0.0  0.0      0     0 ?        S    05:09   0:00 [scsi_eh_1]
root       122  0.0  0.0      0     0 ?        S    05:09   0:00 [kworker/u:1]
root       124  0.0  0.0      0     0 ?        S    05:09   0:00 [kworker/u:2]
root       129  0.0  0.0      0     0 ?        S    05:09   0:00 [scsi_eh_2]
root       130  0.0  0.0      0     0 ?        S    05:09   0:00 [scsi_eh_3]
root       131  0.0  0.0      0     0 ?        S    05:09   0:00 [scsi_eh_4]
root       132  0.0  0.0      0     0 ?        S    05:09   0:00 [scsi_eh_5]
root       133  0.0  0.0      0     0 ?        S    05:09   0:00 [scsi_eh_6]
root       134  0.0  0.0      0     0 ?        S    05:09   0:00 [scsi_eh_7]
root       135  0.0  0.0      0     0 ?        S    05:09   0:00 [kworker/u:3]
root       136  0.0  0.0      0     0 ?        S    05:09   0:00 [kworker/u:4]
root       137  0.0  0.0      0     0 ?        S    05:09   0:00 [kworker/u:5]
root       138  0.0  0.0      0     0 ?        S    05:09   0:00 [kworker/u:6]
root       139  0.0  0.0      0     0 ?        S    05:09   0:00 [kworker/u:7]
root       140  0.0  0.0      0     0 ?        S    05:09   0:00 [kworker/u:8]
root       152  0.0  0.0      0     0 ?        S    05:09   0:00 [kworker/1:3]
root       153  0.0  0.0      0     0 ?        S    05:09   0:00 [kworker/0:2]
root       160  0.0  0.0      0     0 ?        S    05:09   0:00 [jbd2/sdb2-8]
root       161  0.0  0.0      0     0 ?        S<   05:09   0:00 [ext4-dio-unwrit]
root       210  0.4  0.0  21104  3016 ?        Ss   05:09   0:00 /lib/udev/udevd --daemon
root       214  0.0  0.0      0     0 ?        S<   05:09   0:00 [iprt]
root       271  0.0  0.0  21092  1048 ?        S    05:09   0:00 /lib/udev/udevd --daemon
root       272  0.0  0.0  21092  1048 ?        S    05:09   0:00 /lib/udev/udevd --daemon
root       279  0.0  0.0      0     0 ?        S<   05:09   0:00 [edac-poller]
root       295  0.0  0.0      0     0 ?        S<   05:09   0:00 [hd-audio0]
root       322  0.0  0.0      0     0 ?        S<   05:09   0:00 [hd-audio1]
root       370  0.0  0.0      0     0 ?        S    05:09   0:00 [jbd2/sdb4-8]
root       371  0.0  0.0      0     0 ?        S<   05:09   0:00 [ext4-dio-unwrit]
root       608  0.0  0.0  30984   444 ?        S    05:09   0:00 supervising syslog-ng
root       609  0.1  0.1  60584  3312 ?        Ss   05:09   0:00 /usr/sbin/syslog-ng
root       642  0.0  0.0  60920  1752 tty1     Ss   05:09   0:00 /bin/login --
root       643  0.0  0.0   8224   780 tty2     Ss+  05:09   0:00 /sbin/agetty -8 -s 38400 tty2 linux
root       644  0.0  0.0   8224   780 tty3     Ss+  05:09   0:00 /sbin/agetty -8 -s 38400 tty3 linux
root       645  0.0  0.0   8224   784 tty4     Ss+  05:09   0:00 /sbin/agetty -8 -s 38400 tty4 linux
root       646  0.0  0.0   8224   780 tty5     Ss+  05:09   0:00 /sbin/agetty -8 -s 38400 tty5 linux
root       647  0.0  0.0   8224   784 tty6     Ss+  05:09   0:00 /sbin/agetty -8 -s 38400 tty6 linux
root       648  0.0  0.0      0     0 ?        S    05:09   0:00 [flush-8:16]
root       649  0.0  0.0      0     0 ?        S    05:09   0:00 [flush-8:0]
oxyd       650  1.0  0.1  30528  3232 tty1     S    05:09   0:00 -zsh
oxyd       662  0.0  0.0  10848  1200 tty1     R+   05:10   0:00 ps aux

For the record, here's the state of the machine at the time I took the ps aux -- freshly booted, completely bare:

$ uptime
05:10:06 up 0 min,  1 user,  load average: 0.86, 0.23, 0.08
$ free -m
             total       used       free     shared    buffers     cached
Mem:          3013        184       2828          0         25         26
-/+ buffers/cache:        132       2880
Swap:         1023          0       1023

Offline

#7 2012-02-08 19:07:53

meph
Member
Registered: 2011-06-06
Posts: 160

Re: Freshly booted Arch uses ~150 MB of memory

dmesg|grep Memory

will show you how much memory is reserved by the kernel

dmesg|grep  TLB

seems to show that 64MB is reserved for TLB, which should make up for the difference between 32 and 64 bit. So it's not used by a process per se and that's why you can't find one, it's just reserved memory.

Unless I got it wrong wink


Running arch is like raising a puppy - if you spend a bit of time with it each day and do just a bit of training you'll end up with the most loyal partner you could want; if you lock it in a room and don't check on if for several days, it'll tear apart your stuff and poop everywhere.

Offline

#8 2012-02-08 19:23:45

Oxyd
Member
From: Czech Republic
Registered: 2008-01-17
Posts: 167

Re: Freshly booted Arch uses ~150 MB of memory

$ dmesg | grep Memory
[    0.000000] Memory: 3080148k/3143552k available (4281k kernel code, 452k absent, 62952k reserved, 4599k data, 728k init)
[    4.243278] VBoxDrv: dbg - g_abExecMemory=ffffffffa0351be0
$ dmesg | grep TLB
[    1.123651] HugeTLB registered 2 MB page size, pre-allocated 0 pages

Ah, looks like there's 63 MB reserved for the kernel. I'm not sure how much is allocated for TLB in my case from that output, though.

Still I'm not sure how this adds up -- kernel reserved 64 MB for itself -- okay. Where's the remaining 64 MB? Is it the TLB?

Offline

#9 2012-02-08 19:57:49

karol
Archivist
Registered: 2009-05-06
Posts: 25,440

Re: Freshly booted Arch uses ~150 MB of memory

[karol@black ~]$ ps aux
USER       PID %CPU %MEM    VSZ   RSS TTY      STAT START   TIME COMMAND
root         1  3.2  0.1   2124   612 ?        Ss   20:43   0:00 init [3]
root         2  0.0  0.0      0     0 ?        S    20:43   0:00 [kthreadd]
root         3  0.0  0.0      0     0 ?        S    20:43   0:00 [ksoftirqd/0]
root         4  0.0  0.0      0     0 ?        S    20:43   0:00 [kworker/0:0]
root         5  0.0  0.0      0     0 ?        S    20:43   0:00 [kworker/u:0]
root         6  0.0  0.0      0     0 ?        S    20:43   0:00 [migration/0]
root         7  0.0  0.0      0     0 ?        S    20:43   0:00 [watchdog/0]
root         8  0.0  0.0      0     0 ?        S<   20:43   0:00 [cpuset]
root         9  0.0  0.0      0     0 ?        S<   20:43   0:00 [khelper]
root        10  0.0  0.0      0     0 ?        S    20:43   0:00 [kdevtmpfs]
root        11  0.0  0.0      0     0 ?        S<   20:43   0:00 [netns]
root        12  0.0  0.0      0     0 ?        S    20:43   0:00 [sync_supers]
root        13  0.0  0.0      0     0 ?        S    20:43   0:00 [bdi-default]
root        14  0.0  0.0      0     0 ?        S<   20:43   0:00 [kblockd]
root        15  0.0  0.0      0     0 ?        S    20:43   0:00 [kworker/0:1]
root        16  0.0  0.0      0     0 ?        S    20:43   0:00 [khungtaskd]
root        17  0.0  0.0      0     0 ?        S    20:43   0:00 [kswapd0]
root        18  0.0  0.0      0     0 ?        SN   20:43   0:00 [ksmd]
root        19  0.0  0.0      0     0 ?        S    20:43   0:00 [fsnotify_mark]
root        20  0.0  0.0      0     0 ?        S<   20:43   0:00 [crypto]
root        22  0.0  0.0      0     0 ?        S<   20:43   0:00 [kthrotld]
root        23  0.0  0.0      0     0 ?        S    20:43   0:00 [kworker/0:2]
root        39  0.0  0.0      0     0 ?        S<   20:43   0:00 [ata_sff]
root        40  0.0  0.0      0     0 ?        S    20:43   0:00 [scsi_eh_0]
root        41  0.0  0.0      0     0 ?        S    20:43   0:00 [scsi_eh_1]
root        42  0.0  0.0      0     0 ?        S    20:43   0:00 [kworker/u:1]
root        43  0.0  0.0      0     0 ?        S    20:43   0:00 [kworker/u:2]
root        62  0.0  0.0      0     0 ?        S    20:43   0:00 [kjournald]
root       111  0.6  0.5   4536  2724 ?        Ss   20:43   0:00 /lib/udev/udevd --daemon
root       149  0.0  0.1   4416   620 ?        S    20:43   0:00 /lib/udev/udevd --daemon
root       150  0.0  0.1   4416   620 ?        S    20:43   0:00 /lib/udev/udevd --daemon
root       154  0.0  0.0      0     0 ?        S    20:43   0:00 [khubd]
root       166  0.0  0.0      0     0 ?        S<   20:43   0:00 [kpsmoused]
root       169  0.1  0.0      0     0 ?        S    20:43   0:00 [kworker/0:3]
root       178  0.0  0.0      0     0 ?        S    20:43   0:00 [flush-8:0]
root       183  0.0  0.0      0     0 ?        S    20:43   0:00 [kjournald]
root       463  0.0  0.0   4360   400 ?        S    20:43   0:00 supervising syslog-ng
root       464  0.2  0.5   7112  2824 ?        Ss   20:43   0:00 /usr/sbin/syslog-ng
dbus       490  0.0  0.0   2868   356 ?        Ss   20:43   0:00 /usr/bin/dbus-daemon --system
root       492  0.0  0.1   3536   632 ?        S    20:43   0:00 /bin/bash /etc/rc.multi
root       499  0.0  0.2   3532  1408 ?        S    20:43   0:00 /bin/bash /etc/rc.d/network start
root       526  0.0  0.1   2332   776 ?        S    20:43   0:00 dhcpcd -q eth0
root       535  0.0  0.0   2364   380 ?        Ss   20:43   0:00 /usr/sbin/gpm -m /dev/psaux -t ps2
root       537  0.0  0.0   3424   356 ?        S    20:43   0:00 /bin/bash /etc/rc.local
root       539  0.0  0.0   2112   280 ?        S    20:43   0:00 sleep 300
root       540  0.0  0.1   2144   596 ?        Ss   20:43   0:00 /usr/sbin/acpid
root       546  0.0  0.1   2168   616 ?        Ss   20:43   0:00 /usr/sbin/crond -S -l info
root       552  0.0  0.1   2324   588 ?        Ss   20:43   0:00 /usr/sbin/vnstatd -d
root       555  0.0  0.2   3240  1456 tty1     Ss   20:43   0:00 /bin/login -f
root       556  0.0  0.1   4224   724 tty2     Ss+  20:43   0:00 /sbin/agetty -8 38400 tty2 linux
root       557  0.0  0.1   4224   720 tty3     Ss+  20:43   0:00 /sbin/agetty -8 38400 tty3 linux
karol      558  0.3  0.5   6508  2784 tty1     S    20:43   0:00 -bash
root       566  0.0  0.0      0     0 ?        S    20:43   0:00 [flush-254:0]
karol      568  0.0  0.2   4792  1116 tty1     R+   20:43   0:00 ps aux
[karol@black ~]$ free -m
             total       used       free     shared    buffers     cached
Mem:           490         47        443          0          2         24
-/+ buffers/cache:         19        471
Swap:          308          0        308
[karol@black ~]$ pstree
init─┬─acpid
     ├─2*[agetty]
     ├─crond
     ├─dbus-daemon
     ├─gpm
     ├─login───bash───pstree
     ├─rc.local───sleep
     ├─rc.multi───network───dhcpcd
     ├─syslog-ng───syslog-ng
     ├─udevd───2*[udevd]
     └─vnstatd
[karol@black ~]$ dmesg | grep Memory
[    0.000000] Memory: 499432k/515584k available (3573k kernel code, 15636k reserved, 1404k data, 516k    init, 0k highmem)
[karol@black ~]$ dmesg | grep TLB
[    0.407588] HugeTLB registered 4 MB page size, pre-allocated 0 pages

I don't understand the dmesg output, but the RSS from the processes adds up to 19MB.

Last edited by karol (2012-02-08 20:01:44)

Offline

#10 2012-02-08 20:07:29

Oxyd
Member
From: Czech Republic
Registered: 2008-01-17
Posts: 167

Re: Freshly booted Arch uses ~150 MB of memory

karol, and you're on 32 bit, right? It's kidna weird that the difference between 32 bit and 64 bit should be almost 100 MB...

Offline

#11 2012-02-08 20:15:37

masteryod
Member
Registered: 2010-05-19
Posts: 433

Re: Freshly booted Arch uses ~150 MB of memory

Oxyd wrote:

karol, and you're on 32 bit, right? It's kidna weird that the difference between 32 bit and 64 bit should be almost 100 MB...


about memory consumption on 32bit vs 64bit look at this: https://bbs.archlinux.org/viewtopic.php?id=134279

Offline

#12 2012-02-08 20:26:56

karol
Archivist
Registered: 2009-05-06
Posts: 25,440

Re: Freshly booted Arch uses ~150 MB of memory

Yes, I'm using 32-bit and I don't have any 64-bit-capable CPU so I can't compare, but masteryod linked to a thread that links to another thread that says https://bbs.archlinux.org/viewtopic.php … 02#p860702 so it indeed may be TLB on 64-bit that "eats" some RAM.

Offline

#13 2012-02-08 23:06:42

meph
Member
Registered: 2011-06-06
Posts: 160

Re: Freshly booted Arch uses ~150 MB of memory

Oxyd wrote:
$ dmesg | grep Memory
[    0.000000] Memory: 3080148k/3143552k available (4281k kernel code, 452k absent, 62952k reserved, 4599k data, 728k init)
[    4.243278] VBoxDrv: dbg - g_abExecMemory=ffffffffa0351be0
$ dmesg | grep TLB
[    1.123651] HugeTLB registered 2 MB page size, pre-allocated 0 pages

Ah, looks like there's 63 MB reserved for the kernel. I'm not sure how much is allocated for TLB in my case from that output, though.

Still I'm not sure how this adds up -- kernel reserved 64 MB for itself -- okay. Where's the remaining 64 MB? Is it the TLB?

Those 63 MB we possibly found now doesn't represent reserved memory for whole kernel, just TLB. I don't know why it does that, though I think it might have something to do with logical assumption that for modern 64bit systems 63 MB of memory is a non-issue, at least for most of them. So, as long as the amount of memory actually used is just below those 63 MBs (and thus the reserved amount isn't completely wasted), then it's safe to simply reserve it. All of that doesn't mean that there isn't  other stuff going on, TLB is just one I was able to find. If you really want to find out, then I'd suggest going through dmesg line after line, there may be more memory eaters to discover.

Karol, your 32bit system only uses 19 MBs. That seems to be really low, although I haven't used a 32bit system for a while, don't have anything to compare with. Have you taken any steps to optimize your system and reduce memory usage? I never actually did any research in this area, but I'm sure there are some possibilities, beginning with say some custom compiled and optimized kernel.


Running arch is like raising a puppy - if you spend a bit of time with it each day and do just a bit of training you'll end up with the most loyal partner you could want; if you lock it in a room and don't check on if for several days, it'll tear apart your stuff and poop everywhere.

Offline

#14 2012-02-08 23:52:36

Oxyd
Member
From: Czech Republic
Registered: 2008-01-17
Posts: 167

Re: Freshly booted Arch uses ~150 MB of memory

As far as custom kernel goes -- I just tried that. First I tried just plain vanilla kernel.org source with Arch's config, then I tried disabling everything I don't need, but nope -- it's at around 120 MB now. Which is a decrease, but I still feel it's high.

Or is it high even? Throughout this thread I've been assuming that even on a 64-bit system, it isn't common for it to be this much. From what I found out, it should be somewhere around 50 MB for a 64-bit system.

Last edited by Oxyd (2012-02-08 23:53:24)

Offline

#15 2012-02-08 23:56:21

karol
Archivist
Registered: 2009-05-06
Posts: 25,440

Re: Freshly booted Arch uses ~150 MB of memory

I use stock packages.
I just went down to 14 MB by disabling all the daemons, extra ttys and using dash instead of bash. At this point the output of ps accounted only for 8 MB, so 6 MB went missing:

$ pstree
init-+-login---dash---pstree
     `-udevd---2*[udevd]
$ free -m
             total       used       free     shared    buffers     cached
Mem:           490         35        455          0          2         18
-/+ buffers/cache:         14        476
Swap:          308          0        308
$ ps aux
USER       PID %CPU %MEM    VSZ   RSS TTY      STAT START   TIME COMMAND
root         1  1.2  0.1   2124   608 ?        Ss   00:42   0:00 init [3]  
root         2  0.0  0.0      0     0 ?        S    00:42   0:00 [kthreadd]
root         3  0.0  0.0      0     0 ?        S    00:42   0:00 [ksoftirqd/0]
root         4  0.0  0.0      0     0 ?        S    00:42   0:00 [kworker/0:0]
root         5  0.0  0.0      0     0 ?        S    00:42   0:00 [kworker/u:0]
root         6  0.0  0.0      0     0 ?        S    00:42   0:00 [migration/0]
root         7  0.0  0.0      0     0 ?        S    00:42   0:00 [watchdog/0]
root         8  0.0  0.0      0     0 ?        S<   00:42   0:00 [cpuset]
root         9  0.0  0.0      0     0 ?        S<   00:42   0:00 [khelper]
root        10  0.0  0.0      0     0 ?        S    00:42   0:00 [kdevtmpfs]
root        11  0.0  0.0      0     0 ?        S<   00:42   0:00 [netns]
root        12  0.0  0.0      0     0 ?        S    00:42   0:00 [sync_supers]
root        13  0.0  0.0      0     0 ?        S    00:42   0:00 [bdi-default]
root        14  0.0  0.0      0     0 ?        S<   00:42   0:00 [kblockd]
root        15  0.0  0.0      0     0 ?        S    00:42   0:00 [kworker/0:1]
root        16  0.0  0.0      0     0 ?        S    00:42   0:00 [khungtaskd]
root        17  0.0  0.0      0     0 ?        S    00:42   0:00 [kswapd0]
root        18  0.0  0.0      0     0 ?        SN   00:42   0:00 [ksmd]
root        19  0.0  0.0      0     0 ?        S    00:42   0:00 [fsnotify_mark]
root        20  0.0  0.0      0     0 ?        S<   00:42   0:00 [crypto]
root        22  0.0  0.0      0     0 ?        S<   00:42   0:00 [kthrotld]
root        23  0.0  0.0      0     0 ?        S    00:42   0:00 [kworker/0:2]
root        39  0.0  0.0      0     0 ?        S<   00:42   0:00 [ata_sff]
root        40  0.0  0.0      0     0 ?        S    00:42   0:00 [scsi_eh_0]
root        41  0.0  0.0      0     0 ?        S    00:42   0:00 [scsi_eh_1]
root        42  0.0  0.0      0     0 ?        S    00:42   0:00 [kworker/u:1]
root        43  0.0  0.0      0     0 ?        S    00:42   0:00 [kworker/u:2]
root        62  0.0  0.0      0     0 ?        S    00:42   0:00 [kjournald]
root       111  0.2  0.5   4520  2716 ?        Ss   00:42   0:00 /lib/udev/udevd --daemon
root       135  0.0  0.1   4416   772 ?        S    00:42   0:00 /lib/udev/udevd --daemon
root       139  0.0  0.1   4484   796 ?        S    00:42   0:00 /lib/udev/udevd --daemon
root       142  0.0  0.0      0     0 ?        S<   00:42   0:00 [kpsmoused]
root       147  0.0  0.0      0     0 ?        S    00:42   0:00 [khubd]
root       164  0.0  0.0      0     0 ?        S    00:42   0:00 [flush-8:0]
root       168  0.0  0.0      0     0 ?        S    00:42   0:00 [kjournald]
root       438  0.1  0.2   3240  1488 tty2     Ss   00:42   0:00 /bin/login --          
root       439  0.0  0.0      0     0 ?        S    00:43   0:00 [flush-254:0]
1005       440  0.0  0.1   2192   548 tty2     S    00:43   0:00 -dash
1005       448  0.0  0.1   2612   904 tty2     R+   00:43   0:00 ps aux

I optimize by using lightweight apps.

Offline

#16 2012-02-09 00:22:23

Oxyd
Member
From: Czech Republic
Registered: 2008-01-17
Posts: 167

Re: Freshly booted Arch uses ~150 MB of memory

And another thing: I installed Arch on VirtualBox -- it's a 64-bit clean install, up to date -- and right after boot it uses only 36 MB of memory. That means there's definitely something wrong with my machine...

Offline

#17 2012-02-09 00:26:21

meph
Member
Registered: 2011-06-06
Posts: 160

Re: Freshly booted Arch uses ~150 MB of memory

Oxyd, there's something fishy going on. I just went down to 98 MB, only had to stop daemons, if I did the same stuff as karol I'd probably be somewhere around 90 MB. In your original post you said ~150 MB on a fresh system, with almost everything turned off. That's weird...

If I deducted 64 MB reserved for TLB, I'd be around 35 MB. That's more like it. Still it's almost twice as much as karol's original 19 MB though, and I don't know why.


Running arch is like raising a puppy - if you spend a bit of time with it each day and do just a bit of training you'll end up with the most loyal partner you could want; if you lock it in a room and don't check on if for several days, it'll tear apart your stuff and poop everywhere.

Offline

#18 2012-02-09 00:30:57

meph
Member
Registered: 2011-06-06
Posts: 160

Re: Freshly booted Arch uses ~150 MB of memory

Oxyd wrote:

And another thing: I installed Arch on VirtualBox -- it's a 64-bit clean install, up to date -- and right after boot it uses only 36 MB of memory. That means there's definitely something wrong with my machine...

... or with the VM. From our common experience and from the links in this thread, we know that that being at >100 MB on 64bit is normal. I don't know why it is so, but it seems to be just normal. So far your VM is the only one which doesn't do that.

edit: I mean, as I said above, your fresh install being at around 150 MB is weird. But that 36 MB virtual machine doesn't compute either. I just don't know.... a quick guess, by any chance, do you use any proprietary drivers on your machine? nvidia perhaps?

Last edited by meph (2012-02-09 00:33:29)


Running arch is like raising a puppy - if you spend a bit of time with it each day and do just a bit of training you'll end up with the most loyal partner you could want; if you lock it in a room and don't check on if for several days, it'll tear apart your stuff and poop everywhere.

Offline

#19 2012-02-09 00:31:19

Oxyd
Member
From: Czech Republic
Registered: 2008-01-17
Posts: 167

Re: Freshly booted Arch uses ~150 MB of memory

Yes, definitely something fishy going on here. Especially see my post above -- looks like you can get much lower than 90 MB even with 64-bit system on a virtual machine (not sure if it could possibly be using memory thanks to being run inside a VM).

Edit: Uhuh.. It could perhaps share some memory with the host (I do have guest additions installed), that's true.

Last edited by Oxyd (2012-02-09 00:33:06)

Offline

#20 2012-02-09 00:38:40

meph
Member
Registered: 2011-06-06
Posts: 160

Re: Freshly booted Arch uses ~150 MB of memory

By the way, your fresh VM's 36 MB used is exactly the same as my 98 MB if I deducted that tlb reserved memory. Don't think that's a coincidence... All it tells us is that fresh 64 bit uses say 35-40 MB.


Running arch is like raising a puppy - if you spend a bit of time with it each day and do just a bit of training you'll end up with the most loyal partner you could want; if you lock it in a room and don't check on if for several days, it'll tear apart your stuff and poop everywhere.

Offline

#21 2012-03-20 03:34:49

workdowg
Member
Registered: 2010-12-31
Posts: 69

Re: Freshly booted Arch uses ~150 MB of memory

meph wrote:

By the way, your fresh VM's 36 MB used is exactly the same as my 98 MB if I deducted that tlb reserved memory. Don't think that's a coincidence... All it tells us is that fresh 64 bit uses say 35-40 MB.

Ok... So how can we reduce the amount it is setting aside?

Here is mine on an upgraded x64 install.

free -m
             total       used       free     shared    buffers     cached
Mem:          3958        879       3079          0         72        388
-/+ buffers/cache:        418       3539
Swap:         3812          0       3812

dmesg|grep Memory
[    0.000000] Memory: 3981824k/4980736k available (4490k kernel code, 787336k absent, 211576k reserved, 4412k data, 736k init)

dmesg|grep TLB
[    1.287810] HugeTLB registered 2 MB page size, pre-allocated 0 pages

Notice mine is reserving ~212MB!

Offline

#22 2012-03-20 05:12:19

helloworld1
Member
Registered: 2010-12-26
Posts: 72

Re: Freshly booted Arch uses ~150 MB of memory

I used XMonad and the start memory is about 132MB. Sans XWindow and XMonad, it should use less.

Offline

Board footer

Powered by FluxBB