Since Cloud Assistant Agent 2.x.3.704, commands are no longer saved to disk by default. Enable automatic saving to retain scripts for auditing or troubleshooting.
Procedure
Run the commands for your operating system.
Linux / FreeBSD instances
Run these commands on your instance.
-
Set the configuration item
aliyun-service configure set --item task.keepScriptFile=enabled -
Reload the configuration
aliyun-service configure reload
Windows instances
Open PowerShell as an administrator and run these commands.
Note: Replace {version} with the actual Cloud Assistant Agent version number. See View the Cloud Assistant Agent information for an ECS instance.
-
Set the configuration item
C:\ProgramData\aliyun\assist\{version}\aliyun_assist_service.exe configure set --item task.keepScriptFile=enabled -
Reload the configuration
C:\ProgramData\aliyun\assist\{version}\aliyun_assist_service.exe configure reload
View saved scripts
Cloud Assistant saves command scripts to the following paths:
-
Linux:
/usr/local/share/aliyun-assist/work/script/ -
CoreOS:
/opt/local/share/aliyun-assist/work/script/ -
Windows:
C:\ProgramData\aliyun\assist\work\script\