[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Program run at startup hogs cpu?


On Tuesday, March 11th, 2025 at 12:17, Bruce Steers bsteers4@xxxxxxxxx wrote:

> [Desktop Entry]
> Type=Application
> Exec=/media/bonus/SSDiskspace/git/Desktop-ish/Desktop-ish.gambas -s
> Hidden=false
> Name=Desktop-ish
>
> X-MATE-Autostart-Enabled=true
> X-MATE-Autostart-Delay=3
> X-GNOME-Autostart-Enabled=true
> X-GNOME-Autostart-Delay=3

I do use this autostart on a user level as well in some situations (at work that is) and it has always worked for me. It is pretty straight forward and not much can go wrong, so I wonder what is happening here. I can't check my .desktop file at work now, but I can do some testing.

So, I just made a .desktop file on my system for some application. On my mate desktop I can go to menu System/Preferences/Personal/Startup Applications. Using this will make the .desktop file in ~/.config/autostart. A big difference is that I distribute my applications making .deb files in IDE and next installing them. I do this on all my systems, so I never use the executables made by IDE. I run my applications from IDE during development, create a .deb and install it for further testing on other systems and eventually distributions.

So here is my just made .desktop (from Mate menu for autostart).
It looks like this and it works:

[Desktop Entry]
Type=Application
Exec=DevelopManager -c
Hidden=false
Name=DevelopManager
Comment=To monitor development
X-MATE-Autostart-Delay=3

Some possible thought I came up with:

- Because mine has been installed as a .deb my systems knows to look in /usr/bin (where installed applications reside), so no long path references there. Could that be an issue in case of autostart?
- I have only X-MATE mentioned and not X-GNOME in my .desktop file. I have no idea if it is related, so I tested it in my situation by adding X-GNOME-Autostart-Delay=3 to my .desktop file and it still worked. So, that is a NON issue, but I do mention it here.
- If you execute the EXEC path '/media/bonus/SSDiskspace/git/Desktop-ish/Desktop-ish.gambas -s' from terminal, does it launch as expected? And I mean copy/paste the path from .desktop file to terminal so you are 100% sure there is NO typo (believe me I have been there).
- Try making it from menu and check what .desktop file Mate comes up with (it will store it in ~/.config/autostart) and if that one will run.
- Try with another application with full path to an executable and see what happens there
- Can the application function properly under the user rights it is run as (-> run with rights of the user where ~/.config/autostart/Desktop-ish.desktop file resided)

Just some troubleshooting I would do, to figure out if it is environmental/circumstantial or something in the application.

gbWilly

[Gambas3 for Debian/Ubuntu](https://gitlab.com/gbWilly/gambas3-debian-repository)

Sent with [Proton Mail](https://proton.me/mail/home) secure email.

References:
Program run at startup hogs cpu?Bruce Steers <bsteers4@xxxxxxxxx>