Batch install or update Logtail on ECS instances by using Operation Orchestration Service (OOS).
Use cases
OOS uses custom or public templates to automate operations on ECS, ApsaraDB RDS, Server Load Balancer (SLB), and VPC resources. What is Operation Orchestration Service?
OOS can install, update, or uninstall Logtail on multiple ECS instances automatically. For ECS instances under a different Alibaba Cloud account, third-party cloud servers, or self-managed servers, install Logtail manually: Install Logtail on a Linux server or Install Logtail on a Windows server.
Prerequisites
-
You have at least one ECS instance.
-
RAM users must have the following permissions:
-
AliyunOOSFullAccess policy attached to the RAM user (Manage RAM user permissions).
-
A custom policy with the following permissions attached to the RAM user (Create a custom policy, Manage RAM user permissions).
{ "Version": "1", "Statement": [ { "Effect": "Allow", "Action": [ "ecs:DescribeTagKeys", "ecs:DescribeTags", "ecs:DescribeInstances", "ecs:DescribeInvocationResults", "ecs:RunCommand", "ecs:DescribeInvocations" ], "Resource": "*" }, { "Effect": "Allow", "Action": [ "oos:ListTemplates", "oos:StartExecution", "oos:ListExecutions", "oos:GetExecutionTemplate", "oos:ListExecutionLogs", "oos:ListTaskExecutions" ], "Resource": "*" } ] }
-
Procedure
-
Log on to the OOS console.
-
In the left-side navigation pane, choose Automated Task > Public Template.
-
On the Public Template page, search for
LogAgent, find the ACS-ECS-BulkyInstallLogAgent template, and then click Create Execution. -
On the Create page, configure the following parameters.
-
In the Basic Information step, keep the default settings and click Next: Set Parameters.
-
In the Set Parameters step, configure the parameters and click Next: OK.
Key parameters:
-
Overwrite: Turn on the Overwrite switch to overwrite Logtail if it already exists on the ECS instance.
ImportantWhen upgrading on a Windows ECS instance, only overwrite updates are supported, and the Overwrite setting is ignored.
Overwrite
install
upgrade
uninstall
On
Uninstalls Logtail and then installs the latest version.
Uninstalls Logtail and then installs the latest version.
Uninstalls Logtail.
Off
Skips the installation and returns a message indicating that Logtail already exists.
Keeps the existing Logtail configuration and installs the latest version. After the installation is complete, Logtail resumes log collection from where it left off.
Uninstalls Logtail.
-
Destination Instance: Select the target ECS instances (Instance selection methods).
-
-
-
Review the settings, then click Create.
-
View the execution result.
In the Execution Result section, check the status of each ECS instance. A successful workflow passes through four nodes: Input, Get ECS Instances, runCommand, and Output. The output and logs show details such as the Logtail installation directory.