[GH-ISSUE #1521] If agent is offline have one-off commands/scripts/tasks be queued thru the "pending actions" mechanism #2895

Open
opened 2026-03-14 05:52:46 +03:00 by kerem · 6 comments
Owner

Originally created by @silversword411 on GitHub (May 25, 2023).
Original GitHub issue: https://github.com/amidaware/tacticalrmm/issues/1521

If an agent is offline at the time of a command/script run is manually triggered it dies and disappears because the agent is offline

Have those items get put into the "pending actions" queue for when they come online

Also add more data to pending actions, like date/time and agent doing the task.

Originally created by @silversword411 on GitHub (May 25, 2023). Original GitHub issue: https://github.com/amidaware/tacticalrmm/issues/1521 If an agent is offline at the time of a command/script run is manually triggered it dies and disappears because the agent is offline Have those items get put into the "pending actions" queue for when they come online Also add more data to pending actions, like date/time and agent doing the task.
Author
Owner

@ghost commented on GitHub (May 29, 2023):

Scheduled scripts too would be good.

<!-- gh-comment-id:1566608635 --> @ghost commented on GitHub (May 29, 2023): Scheduled scripts too would be good.
Author
Owner

@asasin114 commented on GitHub (Jun 14, 2023):

Would love to see this implemented!

<!-- gh-comment-id:1591394747 --> @asasin114 commented on GitHub (Jun 14, 2023): Would love to see this implemented!
Author
Owner

@Treawlony commented on GitHub (Nov 25, 2023):

A must have for non-corporate environments (like schools) where laptops are not always online

<!-- gh-comment-id:1826258015 --> @Treawlony commented on GitHub (Nov 25, 2023): A must have for non-corporate environments (like schools) where laptops are not always online
Author
Owner

@dfr-fands commented on GitHub (Dec 12, 2024):

Seconding this, right now the most important feature in TacticalRMM we miss in our environment by far, as we have many sites in different timezones (we are paying the sponsor) and endpoints aren't always online. Would be great to have it in bulk scripts too (as per issue https://github.com/amidaware/tacticalrmm/issues/1060).

<!-- gh-comment-id:2538946164 --> @dfr-fands commented on GitHub (Dec 12, 2024): Seconding this, right now the most important feature in TacticalRMM we miss in our environment by far, as we have many sites in different timezones (we are paying the sponsor) and endpoints aren't always online. Would be great to have it in bulk scripts too (as per issue https://github.com/amidaware/tacticalrmm/issues/1060).
Author
Owner

@LeoDJ commented on GitHub (Jul 16, 2025):

I think I've found a workaround (for Linux agents):

You can create a "run once" task via the policies, if you want to apply it to multiple agents. (And via the normal "Tasks" tab for a single agent, probably)
tl;dr: Create a policy, assign it to a site (if you don't have one already) and create a task with an "onboarding" schedule.

Step-by-step:

  • Settings > Automation Manager
  • Select (or create) policy
  • Go to the "tasks" tab below
  • Add Task
    • Give it a name
    • Add the action you want to perform (command / script, don't forget to press the add button at the end of the row)
    • Select "Onboarding" schedule
    • ->Add Task

This should now run the task after a few minutes on all online agents as well as offline agents after they're booted and checked in.
(At least from my preliminary tests on Linux agents. Will see if it works reliably in the next weeks.
Not sure if this works for Windows aswell, probably depends on the new task scheduling system, idk if it's already activated for Windows agents.)

<!-- gh-comment-id:3080681739 --> @LeoDJ commented on GitHub (Jul 16, 2025): I think I've found a workaround (for Linux agents): You can create a "run once" task via the policies, if you want to apply it to multiple agents. (And via the normal "Tasks" tab for a single agent, probably) tl;dr: Create a policy, assign it to a site (if you don't have one already) and create a task with an "onboarding" schedule. Step-by-step: - Settings > Automation Manager - Select (or create) policy - Go to the "tasks" tab below - Add Task - Give it a name - Add the action you want to perform (command / script, don't forget to press the add button at the end of the row) - Select "Onboarding" schedule - ->Add Task This should now run the task after a few minutes on all online agents as well as offline agents after they're booted and checked in. (At least from my preliminary tests on Linux agents. Will see if it works reliably in the next weeks. Not sure if this works for Windows aswell, probably depends on the new task scheduling system, idk if it's already activated for Windows agents.)
Author
Owner

@dfr-fands commented on GitHub (Jul 17, 2025):

I think I've found a workaround (for Linux agents)

@LeoDJ I've been using this method for Windows as well, but it's extremely unreliable, sometimes it can take up to a day after the agents boot, other times the task does not run at all. I would say about a 50% success rate in getting the task to actually run when the computer boots. It's also quite cumbersome since it requires creating an automation policy. It's really not a viable alternative, for Windows at least.

I understand that maintainers' time is probably very limited, but in my opinion this needs to be given priority, it's a basic RMM feature that has been the sole reason some of the people I recommended TacticalRMM to (which were paying the sponsorship) have switched to other products.

<!-- gh-comment-id:3083643472 --> @dfr-fands commented on GitHub (Jul 17, 2025): > I think I've found a workaround (for Linux agents) @LeoDJ I've been using this method for Windows as well, but it's extremely unreliable, sometimes it can take up to a day after the agents boot, other times the task does not run at all. I would say about a 50% success rate in getting the task to actually run when the computer boots. It's also quite cumbersome since it requires creating an automation policy. It's really not a viable alternative, for Windows at least. I understand that maintainers' time is probably very limited, but in my opinion this needs to be given priority, it's a basic RMM feature that has been the sole reason some of the people I recommended TacticalRMM to (which were paying the sponsorship) have switched to other products.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/tacticalrmm#2895
No description provided.