<div dir="ltr"><div>Here is the bug <a href="https://github.com/linuxmint/nemo/issues/3306">https://github.com/linuxmint/nemo/issues/3306</a> . Unfortunately nemo-desktop is a very important dependency for my regular work. </div><div><br></div><div>Currently I manually restart it. Restarting this is not as bad as it sounds like. Just the desktop icons go away and come back.</div><div><br></div><div>Here is the service file I am currently at:</div><div><br></div><div>[Unit]<br>Description=Nemo Desktop Bug Workaround<br>Wants=xdg-desktop-autostart.target<br>PartOf=graphical-session.target<br>BindsTo=graphical-session.target<br><br>[Service]<br>Type=forking<br>StartLimitIntervalSec=3<br>ExecStart=/usr/bin/nemo-desktop<br># MemoryHigh=50000K<br>MemoryMax=100000K<br>Restart=always<br>KillMode=process<br>KillSignal=SIGKILL<br><br>[Install]<br>WantedBy=graphical-session.target xsession.target gnome-session.target<br>END<br></div><div><br></div><div>I have run:</div><div><br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">> systemctl --user list-dependencies xdg-desktop-autostart.target<br>xdg-desktop-autostart.target<br>○ ├─app-geoclue\x2ddemo\x2dagent@autostart.service<br>○ ├─app-gnome\x2dinitial\x2dsetup\x2dfirst\x2dlogin@autostart.service<br>○ ├─app-gnome\x2dshell\x2doverrides\x2dmigration@autostart.service<br>○ ├─app-im\x2dlaunch@autostart.service<br>○ ├─app-nemo\x2ddesktop@autostart.service<br>○ ├─app-nm\x2dapplet@autostart.service<br>○ ├─app-orca\x2dautostart@autostart.service<br>○ ├─app-org.gnome.Evolution\x2dalarm\x2dnotify@autostart.service<br>○ ├─app-org.gnome.SettingsDaemon.DiskUtilityNotify@autostart.service<br>○ ├─app-org.gnome.Software@autostart.service<br>○ ├─app-user\x2ddirs\x2dupdate\x2dgtk@autostart.service<br>○ ├─app-xdg\x2duser\x2ddirs\x2dkde@autostart.service<br>○ └─app-yandex\x2ddisk@autostart.service</blockquote><div><br></div><div>Here app-nemo\x2ddesktop@autostart.service is most probably generated by systemd-xdg-autostart-generator using:</div><div><br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">[Desktop Entry]<br>Type=Application<br>Name=Nemo<br>Comment=Start Nemo desktop at log in<br>Exec=nemo-desktop<br>X-GNOME-AutoRestart=true<br>NoDisplay=true</blockquote><div><br></div><div>How can I view app-nemo\x2ddesktop@autostart.service ? If I can view this file then would like to copy the contents and edit it then remove app-nemo\x2ddesktop@autostart.service and install the custom service. On that note, would be glad to know how to remove these auto-generated files when i have a new one.</div><div dir="ltr"><br></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Mon, Sep 18, 2023 at 11:12 PM Michal Koutný <<a href="mailto:mkoutny@suse.com">mkoutny@suse.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">Hello Ahmad.<br>
<br>
On Sat, Sep 16, 2023 at 09:29:07PM +0600, Ahmad Ismail <<a href="mailto:ismail783@gmail.com" target="_blank">ismail783@gmail.com</a>> wrote:<br>
> The file in ~/.config/autostart which autostart the service is:<br>
^^^<br>
<br>
> So, I came up with a systemd service which will restart nemo-desktop when<br>
> memory usage is 100MB.<br>
<br>
Is the bug you mention a memory leak? (A restart at arbitrary moment<br>
doesn't sound like the best user experience.)<br>
<br>
Or is it another cause? Nevertheless, you may want to report it to<br>
the respective upstream or upgrade to its latest version.<br>
<br>
> sudo tee /etc/systemd/system/nemo-desktop-bug-workaround.service << END<br>
^^^^^^<br>
<br>
> [Service]<br>
> User=ismail<br>
> Group=ismail<br>
...<br>
> ExecStart=/usr/bin/nemo-desktop<br>
...<br>
> What am I doing wrong here?<br>
<br>
Maybe you conflate a system service (running with changed User=/Group=)<br>
and a user instance service (spawned under user@$UID.service) and some<br>
necessary settings are missing in the nemo-dektop's environment (I'm not<br>
familiar with that particular program, hence a guess only).<br>
<br>
HTH,<br>
Michal<br>
</blockquote></div></div>