Bug 140578 - Poor performance when running LibreOffice programs as another user in KDE
Summary: Poor performance when running LibreOffice programs as another user in KDE
Status: RESOLVED NOTOURBUG
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: LibreOffice (show other bugs)
Version:
(earliest affected)
unspecified
Hardware: All Linux (All)
: medium normal
Assignee: Not Assigned
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: KDE, KF5
  Show dependency treegraph
 
Reported: 2021-02-21 10:02 UTC by Dan Dascalescu
Modified: 2024-03-13 12:20 UTC (History)
2 users (show)

See Also:
Crash report or crash signature:


Attachments
Unstyled look (116.17 KB, image/png)
2021-02-21 10:02 UTC, Dan Dascalescu
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Dan Dascalescu 2021-02-21 10:02:37 UTC
Created attachment 169939 [details]
Unstyled look

I'm using KDE neon 5.21. If I'm logged in as user `one` and run LibreCalc (or LibreWriter etc.) as user `two`, they look unstyled (please see the screenshot).

If I log in as user `two` and launch the applications, they look as expected.

The way I'm running them as a different user is through Plasma's "Run as different user". The command line is `libreoffice7.0 --calc %U`. If I try to run `su two libreoffice7.0`, I get "/usr/local/bin/libreoffice7.0: line 191: /home/two/oosplash: No such file or directory".
Comment 1 Roman Kuznetsov 2021-07-30 17:52:15 UTC
One from those users is a root?
Comment 2 QA Administrators 2022-01-28 03:58:17 UTC Comment hidden (obsolete)
Comment 3 Dan Dascalescu 2022-01-28 04:21:16 UTC
(In reply to Roman Kuznetsov from comment #1)
> One from those users is a root?

None of the users was root.

As of KDE Neon 5.23, the styling problem is solved, but performance for the second user is extremely poor. I have a spreadsheet with a few color ranges, and typing anything in a cell takes half a second per character.

For more details, including reproduction steps and a screencast, please see https://bugs.kde.org/show_bug.cgi?id=448322.
Comment 4 QA Administrators 2022-01-29 03:55:13 UTC Comment hidden (obsolete)
Comment 5 Michael Weghorn 2022-10-30 15:46:41 UTC
This sounds more like an issue on a different layer(like KDE Plasma) than a LibreOffice one to me. https://bugs.kde.org/show_bug.cgi?id=448322 also mentions that it's generally slow and with LO it is "just" most easily visible.

I'll close this as NOTOURBUG for now. Please feel free to reopen in case further discussion/information in the KDE bug should suggest otherwise or you have any other additional information.
Comment 6 Dan Dascalescu 2024-03-10 02:04:04 UTC
I found out what reproduces the bug: not having the terminal window open.

In the meantime I've upgraded to using the LibreOffice-fresh.basic-24.2.0.3.AppImage

To recap,

- If I run LibreCalc as my user, either from its desktop shortcut or from the terminal, performance is normal.
- If I launch a termina window, `su` to the second user, then run the .AppImage, performance is normal.
- But if I create a .desktop file like the one below, performance is extremely slow when I launch "Alc":

```
[Desktop Entry]
Exec=LibreOffice-fresh.basic-24.2.0.3.AppImage --calc
GenericName=AlterEgo Spreadsheet
InitialPreference=5
Name=Alc
NoDisplay=false
StartupNotify=true
StartupWMClass=libreoffice-calc
Terminal=false
TerminalOptions=
Type=Application
Version=1.0
X-GIO-NoFuse=true
X-KDE-RunOnDiscreteGpu=true
X-KDE-SubstituteUID=true
X-KDE-Username=alterego
```

If I set `Terminal=true` performance is normal, but I end up with an extra window I don't want. The window shows these messages:


Password: 
Failed to create wl_display (Permission denied)
qt.qpa.plugin: Could not load the Qt platform plugin "wayland" in "" even though it was found.
QStandardPaths: runtime directory '/run/user/1000' is not owned by UID 1001, but a directory permissions 0700 owned by UID 1000 GID 1000
QStandardPaths: runtime directory '/run/user/1000' is not owned by UID 1001, but a directory permissions 0700 owned by UID 1000 GID 1000
Comment 7 Michael Weghorn 2024-03-13 12:20:42 UTC
(In reply to Dan Dascalescu from comment #6)
> I found out what reproduces the bug: not having the terminal window open.
> (...)
> 
> If I set `Terminal=true` performance is normal, but I end up with an extra
> window I don't want.

Thanks for the additional analysis!


> The window shows these messages:
> 
> 
> Password: 
> Failed to create wl_display (Permission denied)
> qt.qpa.plugin: Could not load the Qt platform plugin "wayland" in "" even
> though it was found.
> QStandardPaths: runtime directory '/run/user/1000' is not owned by UID 1001,
> but a directory permissions 0700 owned by UID 1000 GID 1000
> QStandardPaths: runtime directory '/run/user/1000' is not owned by UID 1001,
> but a directory permissions 0700 owned by UID 1000 GID 1000

Do you see similar messages when running another Qt application than LO?
To me, this looks more like a general issue w/ Qt plugins/libraries not working as expected in that setup for some reason. But then, do I understand correctly that the scenario where you see these messages is the "good" one, i.e. with the `Terminal=true` ?