Bug#774399: libreoffice: aggressive (blocking) config rewrite (lag, slowness)

classic Classic list List threaded Threaded
8 messages Options
Reply | Threaded
Open this post in threaded view
|

Bug#774399: libreoffice: aggressive (blocking) config rewrite (lag, slowness)

Dmitry Smirnov
Package: libreoffice
Version: 1:4.3.3-2
Severity: important

With /home on network file system (NFS or similar) libreoffice is lagging
miserably on basic operations like when libreoffice just started or new writer
document is opened etc., as well as on innocent moves between tabs under
[Tools -> Options -> Libreoffice] even when nothing is changed.

Strace-ing revealed the problem which is aggressive re-write of
"registrymodifications.xcu" in "~/.config/libreoffice/4/user":
on almost every action in libreoffice a new temporary file is created (in user
profile folder) and renamed to "registrymodifications.xcu". The latter is
about 1 MiB and about that much data is written very very often. But the worst
thing about it is that configuration is not written in background -- instead
it is a blocking operation causing very uncomfortable lag in user interface.

Also it seems that often configuration file is unnecessary (re-)written when
nothing has changed.

What can be done to minimise rewrites of "registrymodifications.xcu" or reduce
frequency of configuration save?

An ugly workaround may be to disable configuration changes completely by
setting profile folder read-only (e.g. `chmod -c u-w
~/.config/libreoffice/4/user`) but I hope that better solution may be
available.

Thanks.

signature.asc (836 bytes) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Bug#774399: libreoffice: aggressive (blocking) config rewrite (lag, slowness)

Rene Engelhard
Hi,

On Fri, Jan 02, 2015 at 11:50:42AM +1100, Dmitry Smirnov wrote:

> With /home on network file system (NFS or similar) libreoffice is lagging
> miserably on basic operations like when libreoffice just started or new writer
> document is opened etc., as well as on innocent moves between tabs under
> [Tools -> Options -> Libreoffice] even when nothing is changed.
>
> Strace-ing revealed the problem which is aggressive re-write of
> "registrymodifications.xcu" in "~/.config/libreoffice/4/user":
> on almost every action in libreoffice a new temporary file is created (in user
> profile folder) and renamed to "registrymodifications.xcu". The latter is
> about 1 MiB and about that much data is written very very often. But the worst
That file basically contains many of your personal data:
That's what I have here in my file.
 - personal data (as entered in the options)
 - also contains the last opened files (and thumbnails of them.)
   So of course it's updated on a document open.
 - it also contains the (scanned on start) list of available system-wide
   dictionaries
 - state of the windows/toolbars

> thing about it is that configuration is not written in background -- instead
> it is a blocking operation causing very uncomfortable lag in user interface.

But that indeed is bad.

> Also it seems that often configuration file is unnecessary (re-)written when
> nothing has changed.

Except maybe some window states...

> [...] But the worst
> thing about it is that configuration is not written in background -- instead
> it is a blocking operation causing very uncomfortable lag in user interface.
>
> Also it seems that often configuration file is unnecessary (re-)written when
> nothing has changed.
>
> What can be done to minimise rewrites of "registrymodifications.xcu" or reduce
> frequency of configuration save?

Will ask upstream.

Regards,

Rene


--
To UNSUBSCRIBE, email to [hidden email]
with a subject of "unsubscribe". Trouble? Contact [hidden email]
Archive: https://lists.debian.org/20150102135601.GI13278@...

Reply | Threaded
Open this post in threaded view
|

Bug#774399: libreoffice: aggressive (blocking) config rewrite (lag, slowness)

Dmitry Smirnov
Hi Rene,

On Fri, 2 Jan 2015 14:56:01 Rene Engelhard wrote:
> Will ask upstream.

Did you hear anything from upstream regarding this issue?

We found that setting "~/.config/libreoffice/4/user" read-only has a side
effect: it breaks autosave...
When "user" directory is writeable Libreoffice slowness is unbearable due to
frequent rewrites of "registrymodifications.xcu"... Any ideas?
I shall be happy to test a patch for this issue, if any...

Thank you.

--
Cheers,
 Dmitry Smirnov.

signature.asc (836 bytes) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Processed: Re: Bug#774399: libreoffice: aggressive (blocking) config rewrite (lag, slowness)

Debian Bug Tracking System
In reply to this post by Dmitry Smirnov
Processing control commands:

> fixed -1 1:4.4.5-2
Bug #774399 [libreoffice] libreoffice: aggressive (blocking) config rewrite (lag, slowness)
Marked as fixed in versions libreoffice/1:4.4.5-2.

--
774399: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=774399
Debian Bug Tracking System
Contact [hidden email] with problems

Reply | Threaded
Open this post in threaded view
|

Bug#774399: libreoffice: aggressive (blocking) config rewrite (lag, slowness)

Dmitry Smirnov
In reply to this post by Dmitry Smirnov
Control: fixed -1 1:4.4.5-2

Hi Chris,

On Wednesday 09 September 2015 15:53:56 Chris Halls wrote:
> I've had a look into this problem. I can see
> that LO is often updating this file, but it doesn't seem to be doing it
> excessively during editing.

Thank you for looking into this problem. On 4.3.3 problem was severe not only
in editing but also in main `libreoffice` application that was lagging  
seconds behind mouse movements.


> There is some relevant information in this bug:
>
> https://bugs.documentfoundation.org/show_bug.cgi?id=92529

Here is another somewhat related bug:

  https://bugs.launchpad.net/ubuntu/+source/libreoffice/+bug/1366519

 
> There is a comment: "The way it works is that every call to the
> configmgr's commitChanges() initiates a write-back of
> registrymodifcations.xcu.  Actual writing is then delayed by 1 second to
> allow consecutive calls to commitChanges() to pile up and be processed
> in one batch."

It seems there were some improvements. I tried LibreOffice 4.4.5 and it
appears to be OK.


> That would suggest that the writing does actually happen in the
> background, so I'm surprised this is causing actual hangs for you. I've
> commented on that bug.

Perhaps somebody fixed that. :)


> This file is being used to commit changes to the users' profile, each
> time something is changed.

I had impression that navigating menu should not qualify for changes
requiring to re-write user's profile... Unfortunately rewrites were happening
as far as I can tell...


> I'm changing severity of this to normal
> because it would be possible to work around this by using faster local
> storage.

In some cases "using faster local storage" is not possible and it may require
administrative and infrastructure changes beyond user control.

FYI our network storage is actually faster than local but comparing to local
HDD it exhibit slightly different IO patterns that LibreOffice was extremely
sensitive to.

Basically problem was not in storage performance but with blocking updates of
"registrymodifications.xcu" causing extreme discomfort to users because UI
froze frequently for up to few seconds every time LO wrote a new
"registrymodifications.xcu". Even fraction of a second lag in UI is bad
enough...

The problem is fixed if LibreOffice writes to this file in background.

I can not reproduce this problem with LibreOffice 4.4.5-2 from "jessie-
backports".

 
> Out of interest, do you see similar problems with other software such as
> web browsers? They also write a lot of local changes such as browsing
> history; I'm wondering whether those are affected too?

No, all other applications are fine but LibreOffice 4.3.3 was exhibiting this
problem so badly that I've stopped using it entirely and moved to Calligra
Suite. Newer version of LibreOffice either was not available in jessie-
backports at a time or it was affected by the same problem.

Thank you.

--
All the best,
 Dmitry Smirnov.

---

I hate all sports as rabidly as a person who likes sports hates common
sense.
        -- H. L. Mencken

signature.asc (836 bytes) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Bug#774399: libreoffice: aggressive (blocking) config rewrite (lag, slowness)

Rene Engelhard
Hi,

On Thu, Sep 10, 2015 at 11:10:50AM +1000, Dmitry Smirnov wrote:
> The problem is fixed if LibreOffice writes to this file in background.
>
> I can not reproduce this problem with LibreOffice 4.4.5-2 from "jessie-
> backports".

OK, tihanks for the info. Can you try with 5.0.1, too? Marking it as fixed
in 4.4.5 does not mark it as fixed in 5.0.1 since 5.0.x branched off 4.4.2 ;)

(see https://people.debian.org/~rene/libreoffice/test/bpo/jessie/ - it's in
bpo-new right now)

Should be fixed there, too, but confirmation would be nice before closing this
finally.

Regards,

Rene

Reply | Threaded
Open this post in threaded view
|

Bug#774399: libreoffice: aggressive (blocking) config rewrite (lag, slowness)

Dmitry Smirnov
Hi Rene,

On Thursday 10 September 2015 11:25:03 Rene Engelhard wrote:
> OK, tihanks for the info. Can you try with 5.0.1, too? Marking it as fixed
> in 4.4.5 does not mark it as fixed in 5.0.1 since 5.0.x branched off 4.4.2
> ;)
 
I've just tried 1:5.0.1-2~bpo8+1 and found it definitely better comparing to
what it used to be. However it is still not ideal -- for example editing a
spreadsheet lags after modifying a cell and clicking another cell...


> Should be fixed there, too, but confirmation would be nice before closing
> this finally.

I was hoping that we can close this bug. In fact I nearly closed it myself
but user just complained to me about slowness in Calc... :(

--
All the best,
 Dmitry Smirnov.

---

Continuous effort - not strength or intelligence - is the key to unlocking
our potential.
        -- Winston Churchill

signature.asc (836 bytes) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Bug#774399: marked as done (libreoffice: aggressive (blocking) config rewrite (lag, slowness) and lags with files opened on a network)

Debian Bug Tracking System
In reply to this post by Dmitry Smirnov
Your message dated Mon, 13 May 2019 13:49:44 +0000
with message-id <[hidden email]>
and subject line libreoffice: aggressive (blocking) config rewrite (lag, slowness) and lags with files opened on a network
has caused the Debian Bug report #774399,
regarding libreoffice: aggressive (blocking) config rewrite (lag, slowness) and lags with files opened on a network
to be marked as done.

This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.

(NB: If you are a system administrator and have no idea what this
message is talking about, this may indicate a serious mail system
misconfiguration somewhere. Please contact [hidden email]
immediately.)


--
774399: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=774399
Debian Bug Tracking System
Contact [hidden email] with problems

Package: libreoffice
Version: 1:4.3.3-2
Severity: important

With /home on network file system (NFS or similar) libreoffice is lagging
miserably on basic operations like when libreoffice just started or new writer
document is opened etc., as well as on innocent moves between tabs under
[Tools -> Options -> Libreoffice] even when nothing is changed.

Strace-ing revealed the problem which is aggressive re-write of
"registrymodifications.xcu" in "~/.config/libreoffice/4/user":
on almost every action in libreoffice a new temporary file is created (in user
profile folder) and renamed to "registrymodifications.xcu". The latter is
about 1 MiB and about that much data is written very very often. But the worst
thing about it is that configuration is not written in background -- instead
it is a blocking operation causing very uncomfortable lag in user interface.

Also it seems that often configuration file is unnecessary (re-)written when
nothing has changed.

What can be done to minimise rewrites of "registrymodifications.xcu" or reduce
frequency of configuration save?

An ugly workaround may be to disable configuration changes completely by
setting profile folder read-only (e.g. `chmod -c u-w
~/.config/libreoffice/4/user`) but I hope that better solution may be
available.

Thanks.

Hello,

Not Debian specific and very general. Please follow this bug at :

https://bugs.documentfoundation.org/show_bug.cgi?id=81640

Regards,

--
St├ęphane Aulery

signature.asc (836 bytes) Download Attachment