LibreOffice memory usage

I upraded to 11.4 and LibreOffice and realized a slow response time generally. Looking at the running processes I see a soffice.bin which claimed 1.7 GiB of memory. Without any open document! Don’t know how much openoffice used in 11.3 since I never checked but when one app uses half of my memory (even if most of it swappable) I wonder if this can be true. Doesn’t look normal to me. Any ideas on this?

Peter

I upraded to 11.4 and LibreOffice

How?

I have no issues as you describe

How? zypper dup.

The pmap is not of much help but contains some huge sections:

0000000000603000 92368K 91648K 91648K 91648K 0K rw-p [heap]
00000000bf200000 21248K 11768K 11768K 11768K 0K rw-p [anon]
00000000c06c0000 62720K 0K 0K 0K 0K rw-p [anon]
00000000c4400000 40832K 6164K 6164K 6164K 0K rw-p [anon]
00000000c6be0000 611840K 0K 0K 0K 0K rw-p [anon]
00000000ec160000 35712K 20296K 20296K 20296K 0K rw-p [anon]
00000000ee440000 290560K 0K 0K 0K 0K rw-p [anon]

now even if the hugest pieces don’t have any RSS, the sum for that part is still 200MiB for doing nothing…

Peter

Have you been able to compare a fresh install against this one? Or don’t you have the space to try that?

On 04/01/2011 12:06 PM, peterlipp wrote:
>
> soffice.bin which claimed 1.7 GiB of memory

in what application are you seeing how much memory is being used by
soffice.bin?

i think it is a LOT closer to 1.7% of total memory available than it
is 1.7 GiB!!

and, i think it is about the same as used in 11.3


CAVEAT: http://is.gd/bpoMD
Tried LibreOffice? Do that and help at http://is.gd/dZ9j2W
[NNTP via openSUSE 11.3 + KDE4.5.5 + Thunderbird3.1.8]

On 2011-04-01 12:06, peterlipp wrote:
>
> I upraded to 11.4 and LibreOffice and realized a slow response time
> generally. Looking at the running processes I see a soffice.bin which
> claimed 1.7 GiB of memory. Without any open document! Don’t know how
> much openoffice used in 11.3 since I never checked but when one app uses
> half of my memory (even if most of it swappable) I wonder if this can be
> true. Doesn’t look normal to me. Any ideas on this?

Yes, OOo in 11.2 does the same, after creating a single new text document:

Code:

> PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND
> 19844 cer 20 0 2868m 170m 74m S 0 2.1 0:04.16 soffice.bin


Cheers / Saludos,

Carlos E. R.
(from 11.2 x86_64 “Emerald” at Telcontar)

Should be possible, need to find the time to do that :wink:

in what application are you seeing how much memory is being used by
soffice.bin?
system monitor or however this is called in English (“Systemüberwachung”). And with the pmap tool.

And currently, with 3 open docs, it’s 2.0 GiB

Peter

On 04/02/2011 12:36 AM, peterlipp wrote:
>
> system monitor or however this is called in English
> (“Systemüberwachung”). And with the pmap tool.

either the tools you are using are wrong or you must have a terribly
gone wrong install, i wonder if you did this:
http://tinyurl.com/2ebcf27

but, instead of pmap, give top or htop a try as i think you might be
looking at memory ‘reserved’ rather than actually in use…

> And currently, with 3 open docs, it’s 2.0 GiB

of course, since you have 2 GiB of RAM, if your machine slows to a
crawl and freezes your mouse cursor in one spot on the screen
because the RAM is packed and being shuffled to disk…then, you got a
problem, but you began with not that description but rather “a slow
response time generally”

what was the total physical file size of the three documents opened? i
ask because i just opened one empty document in each of Writer,
Presentation and Calc and my memory in use went up a small part of
one MB (57.3k) [using the command ‘free’ before and after opening
the three]


CAVEAT: http://is.gd/bpoMD
Tried LibreOffice? Do that and help at http://is.gd/dZ9j2W
[NNTP via openSUSE 11.3 + KDE4.5.5 + Thunderbird3.1.8]

No, since I did a dup over the network.

looking at memory ‘reserved’ rather than actually in use…
partially this is certainly true, still wondering why Libre wants to reserve that much in the first place.

ask because i just opened one empty document in each of Writer,
Presentation and Calc and my memory in use went up a small part of
one MB (57.3k) [using the command ‘free’ before and after opening
the three]

I just opened one with a size of 350kB (calc) and the difference with “free” is

before: used 3752112 free 162400
after: 3831296 83216
closing again: 3762308 152204
opening same doc: 3832316 82196
opening another one: 3867452 47060

I realized that opening an .xls-doc uses way more than an ods-one. So its the Microsoft-effect apparently built into Libre: if you open a MS-Document, you get the memory wasted on a windows machine :slight_smile:

Still, I feel that all programs seem to use too much. Beside the virtual box using 1GB I have just firefox and thunderbird and one terminal actively started (plus Gnome and whatever runs anyway) and have about 3.6 GB used.

Peter

On 04/03/2011 10:36 AM, peterlipp wrote:
>
>> looking at memory ‘reserved’ rather than actually in use…
>partially this is certainly true, still wondering why Libre wants to
> reserve that much in the first place.

you know, i guess *, that Linux uses
memory differently from MS and some other systems …that is, MS
typically dumps stuff out of memory as soon as possible…whereas,
basic Linux idea is that unused memory is wasted memory…and
anything in memory now may be called for use again, even if the app
which was using it is closed (the user may fire it up again)…so it
is typical in Linux to see RAM full or near full all the time…and,
it will stay that way, and dump out the oldest stuff as soon as
something new is opened which needs space…

i do not know how it does it, but sometimes when making room for new
stuff it will put some into swap, sometimes not (i guess if it is old
enough it just dumped…if actively in use but not in the last
seconds, it goes to swap…

as for reserved space: if nothing is going on in another app and some
large portion of RAM is not in use, why not mark it all reserved for
the app just opened? it can always be _un_reserved when something else
needs it… right?

>
> I realized that opening an .xls-doc uses way more than an ods-one. So
> its the Microsoft-effect apparently built into Libre: if you open a
> MS-Document, you get the memory wasted on a windows machine :slight_smile:

well, yes and no:

no because the size of the document you open is (say) .5 GB then for
you to use it the document has to be in memory (actual or
swap)…and that holds true if it is a .doc or .odt (or Mac/Atari
whatever)

yes, in that MS-docs are far larger than universe, overall :wink:

and, it is wrong to consider the memory “wasted” in either MS or
other, because it is being used…

> Still, I feel that all programs seem to use too much.

when you say “seem to” i don’t have any idea how you are measuring…
for an app to operate it must be resident in memory…and, the amount
used will be equal to the size of the executable + its libs + its
document (if, for example, using LibreOffice) and probably stuff i
don’t know about…but it is those things that determine the need,
and it is fixed…

the deal with MS is just about everything they produces is larger
(FAR larger) than here…now, i’ve not measure the bytes needed just
to install LibreOffice on any systems, but i’d bet a good cup of
espresso that the MS install is not the smallest…

> Beside the
> virtual box using 1GB I have just firefox and thunderbird and one
> terminal actively started (plus Gnome and whatever runs anyway) and have
> about 3.6 GB used.

but it is still running alright, huh?

remember, unused memory is wasted…which means that there is stuff
in memory not being used, and will be dumped before it starts
impacting whats going on…

make sense? if not, there are thousands of other explanations of the
difference between Linux memory usage and what you may be more
familiar with… [and, you are not the first here wondering why your
RAM is full: http://tinyurl.com/3q9mgj3]


CAVEAT: http://is.gd/bpoMD
Tried LibreOffice? Do that and help at http://is.gd/dZ9j2W
[NNTP via openSUSE 11.3 + KDE4.5.5 + Thunderbird3.1.8]
*

I have a pretty good theoretical background but don’t know all the bells and whistles of the current kernels.

if nothing is going on in another app and some
large portion of RAM is not in use, why not mark it all reserved for
the app just opened? it can always be _un_reserved when something else
needs it… right?
well, yes, but it is not very logical either. Unless the app announces more memory needs, why would that make sense.

no because the size of the document you open is (say) .5 GB then for
you to use it the document has to be in memory (actual or
swap)…and that holds true if it is a .doc or .odt (or Mac/Atari
whatever)

That doesn’t explain why a 0.5MB doc needs 50 MB after loading (rounded figures) unless they are using a pretty good compression algorithm and a pretty bad document format :wink:

but it is those things that determine the need,
and it is fixed…
Sure. But for what these apps do, its too much code overall. Unless they are counting dynamic libraries twice or I have somehow been switched to all statically linked code…

I will probably try booting a live-image later this week and see if this makes any difference and if, consider a fresh install… or not…

Thanks
Peter

I don’t have the issue here. Did have it though when I was running LibreOffice alongside OO.o (in the early days of LibreOffice). Could it be you still have some “old” packages installed?

Not that I would see any in the package list.

Peter

On 2011-04-04 10:36, peterlipp wrote:
>
> DenverD;2317014 Wrote:

> That doesn’t explain why a 0.5MB doc needs 50 MB after loading (rounded
> figures) unless they are using a pretty good compression algorithm and a
> pretty bad document format :wink:

Which they are.

The document is XML compressed with gzip.

> I will probably try booting a live-image later this week and see if
> this makes any difference and if, consider a fresh install… or not…

There is nothing broken, I have similar figures in OOo in 11.2.


Cheers / Saludos,

Carlos E. R.
(from 11.2 x86_64 “Emerald” at Telcontar)