
Alibabacloud Oss Manage Network Probe
- 186 installs
- 208 repo stars
- Updated August 4, 2026
- aliyun/alibabacloud-aiops-skills
Configure and interpret OSS network probes to detect latency, packet loss, and routing issues between clients and object storage endpoints before outages spread.
About
alibabacloud-oss-manage-network-probe helps agents configure and read Alibaba Cloud OSS network probes that watch latency, loss, and reachability to buckets and endpoints. SRE and storage teams use it to catch CDN or VPC routing issues early and shorten incidents affecting downloads, backups, and static asset delivery.
- OSS network probe setup and targets
- Latency and loss metric interpretation
- Endpoint reachability troubleshooting
- Alerting on storage path degradation
- Diagnostic workflows for multi-region OSS
Alibabacloud Oss Manage Network Probe by the numbers
- 186 all-time installs (skills.sh)
- Ranked #466 of 1,039 Cloud & Infrastructure skills by installs in the Skillselion catalog
- Data as of Aug 5, 2026 (Skillselion catalog sync)
npx skills add https://github.com/aliyun/alibabacloud-aiops-skills --skill alibabacloud-oss-manage-network-probeAdd your badge
Show developers this skill is listed on Skillselion. Paste this into your README.
| Installs | 186 |
|---|---|
| repo stars | ★ 208 |
| Last updated | August 4, 2026 |
| Repository | aliyun/alibabacloud-aiops-skills ↗ |
What it does
Configure and interpret OSS network probes to detect latency, packet loss, and routing issues between clients and object storage endpoints before outages spread.
Files
Detailed description of the scenario's application and purpose.
Diagnose network connectivity, upload/download bandwidth, download time, and local symlink anomalies between the local workstation and OSS using ossutil 2.0 integrated with the Alibaba Cloud CLI.
Architecture: Local Workstation + Alibaba Cloud CLI 3.3.3+ + aliyun ossutil + OSS Bucket + Optional target object or presigned URL + Optional probe domain
| Scenario | Recommended Command | Output |
|---|---|---|
| Upload connectivity probe | aliyun ... ossutil probe --upload | Upload duration, object name, log file |
| Download connectivity probe | aliyun ... ossutil probe --download | Download duration, local file path, log file |
| Upload bandwidth suggestion | aliyun ... ossutil probe --probe-item upload-speed | Suggested concurrency value |
| Download bandwidth suggestion | aliyun ... ossutil probe --probe-item download-speed | Suggested concurrency value |
| Download time measurement | aliyun ... ossutil probe --probe-item download-time | Concurrency/part-size/duration statistics |
| Symlink anomaly check | aliyun ... ossutil probe --probe-item cycle-symlink | Whether abnormal symlinks exist |
Important implementation boundary
-probeis a composite client-side diagnostic command provided byaliyun ossutil; there is no equivalentaliyun oss api probe.
- cycle-symlink can only detect abnormal symlinks — it cannot safely auto-fix target paths.- Probe output can locate symptoms and suggest concurrency, but cannot guarantee an automatic precise root cause for all network anomalies.
-download-speedrequires a real existing object, and the official recommendation is objects larger than 5 MiB. If no suitable object exists, the user must first confirm an existing object path, or confirm a local file to upload viaaliyun ossutil cpbefore probing.
Installation
Pre-check: Aliyun CLI >= 3.3.3 required
Run aliyun version to verify >= 3.3.3. If not installed or version too low,see references/cli-installation-guide.md for installation instructions.Then run the credential gate aliyun configure list.Only after `configure list` shows a valid profile, runaliyun configure set --auto-plugin-install trueandaliyun ossutil version.
Run the version and credential gate first:
aliyun version
aliyun configure listOnly after configure list confirms a valid profile, proceed:
aliyun configure set --auto-plugin-install true
aliyun configure ai-mode enable
aliyun configure ai-mode set-user-agent --user-agent "AlibabaCloud-Agent-Skills/alibabacloud-oss-manage-network-probe"
aliyun ossutil version
aliyun plugin updateAI safety mode: configure ai-mode enable activates the CLI's built-in safety guard, which blocks dangerous operations (e.g. deleting critical resources) at the CLI level. This must be enabled before executing any ossutil commands.[MUST] CLI User-Agent — Every aliyun CLI command invocation must include: --user-agent AlibabaCloud-Agent-Skills/alibabacloud-oss-manage-network-probe
Environment Variables
| Environment Variable | Required/Optional | Description | Default Value |
|---|---|---|---|
ALIBABA_CLOUD_PROFILE | Optional | Specify which CLI profile to use | Current default profile |
HTTP_PROXY | Optional | HTTP proxy address in proxied environments | None |
HTTPS_PROXY | Optional | HTTPS proxy address in proxied environments | None |
NO_PROXY | Optional | Proxy bypass list | None |
Parameter Confirmation
IMPORTANT: Parameter Confirmation — Before executing any command or API call,
ALL user-customizable parameters (e.g., RegionId, instance names, CIDR blocks,
passwords, domain names, resource specifications, etc.) MUST be confirmed with the
user. Do NOT assume or use default values without explicit user approval.
| Parameter Name | Required/Optional | Description | Default Value |
|---|---|---|---|
profile | Optional | CLI profile to use | Current default profile |
region_id | Optional | Region where the bucket is located; use when auto-detection is unreliable or explicit specification is needed | None |
bucket_name | Required for bucket-based probes | Target bucket name | None |
object_name | Required for download-speed and download-time; optional for other bucket-based probes | Full object path, e.g. dir/example.txt; for download-speed, objects larger than 5 MiB are recommended for stable results | None |
local_path | Optional | Local upload file path, symlink scan directory, or download save path | None |
download_url | Required for URL-based download probe | Public-read URL or signed private URL | None |
endpoint | Optional | Use only when the user explicitly provides it or the error message clearly points to a specific endpoint | None |
addr | Optional | Domain for --addr network connectivity check | www.aliyun.com only if user explicitly accepts |
upmode | Optional | Upload probe mode | normal |
runtime | Optional | Max runtime in seconds for upload-speed / download-speed | CLI default |
parallel | Optional | Single-file concurrency for download-time | 1 |
part_size | Optional | Part size in bytes for download-time | CLI auto/default |
Authentication
Pre-check: Alibaba Cloud Credentials Required
>
Security Rules:
- NEVER read, echo, or print AK/SK values (e.g., echo $ALIBABA_CLOUD_ACCESS_KEY_ID is FORBIDDEN)- NEVER ask the user to input AK/SK directly in the conversation or command line
- NEVER use aliyun configure set with literal credential values- NEVER read credential files such as ~/.aliyun/config.json, or dump environment variables to inspect credentials- NEVER write a full presigned URL with query-string signature parameters into logs or final output; if you must mention it, redact everything after ?- ONLY use aliyun configure list to check credential status>
```bash
aliyun configure list
```
Check the output for a valid profile (AK, STS, or OAuth identity).
>
If no valid profile exists, STOP here.
1. Obtain credentials from Alibaba Cloud Console
2. Configure credentials outside of this session (via aliyun configure in terminal or environment variables in shell profile)3. Return and re-run after aliyun configure list shows a valid profileIf multiple profiles exist, explicitly add --profile <profile> in subsequent commands, placed after aliyun and before ossutil, e.g. aliyun --profile <profile> ossutil version.
RAM Policy
The minimum OSS permissions required by this skill depend on the probe mode. Refer to references/ram-polices.md for per-scenario permission tables and policy examples.
- Upload probes, upload bandwidth probes, temporary object probes: require at least
oss:GetObject,oss:PutObject,oss:DeleteObject - Download probes, download bandwidth probes, download time probes: require at least
oss:GetObject - If using
aliyun ossutil cpto pre-upload a test object: requiresoss:PutObject - If using
aliyun ossutil rmto clean up an explicitly specified test object: requiresoss:DeleteObject
Core Workflow
1. Validate the CLI environment
Execute in the following order — do not skip steps:
1. Check CLI version first:
aliyun version2. Then check credentials/profile:
aliyun configure list3. If `configure list` does not show a valid profile, or reports a missing config file, STOP immediately.
- Do NOT proceed with
configure set --auto-plugin-install true - Do NOT proceed with
ossutil version - Do NOT fabricate bucket, object, profile, region, or probe success results
4. Only after the profile is valid, proceed to prepare the plugin, enable AI safety mode, and verify ossutil:
aliyun configure set --auto-plugin-install true
aliyun configure ai-mode enable
aliyun configure ai-mode set-user-agent --user-agent "AlibabaCloud-Agent-Skills/alibabacloud-oss-manage-network-probe"
aliyun ossutil version1.1 Log file naming and command substitution
- When saving execution logs, use static strings for filenames (e.g.
probe_download_time.log). Do not use `$(date ...)`, `$(...)`, or backtick shell command substitutions in filenames, because different execution environments have inconsistent shell interpolation support, which can easily cause syntax errors. - Some execution environments block
$()command substitution entirely. When you need to capture command output into a variable (e.g. for presigned URLs), use the file+script pattern: redirect output to a temporary file, then create a shell script that reads the file and uses the value. See §B for a concrete example.
2. Choose the probe mode
A. Upload connectivity probe
- If the user only wants network/upload connectivity diagnostics without keeping the object, omit
local_pathandobject_nameand letprobeuse a temporary file that is auto-cleaned after completion. - If the user wants to verify a specific real file's upload path, confirm
local_path. - If the upload probe returns
AccessDenied, quote the error as-is and explain that at leastoss:GetObject,oss:PutObject,oss:DeleteObjectare required; do not enumerate buckets, regions, or fall back to legacy command forms.
aliyun ossutil probe \
--upload "<LOCAL_PATH_IF_ANY>" \
--bucket "<BUCKET_NAME>" \
--object "<OBJECT_NAME_IF_USER_WANTS_TO_KEEP_IT>" \
--addr "<ADDR_IF_CONFIRMED>" \
--upmode "<UPMODE_IF_CONFIRMED>" \
--region "<REGION_ID_IF_NEEDED>" \
--user-agent AlibabaCloud-Agent-Skills/alibabacloud-oss-manage-network-probeWhen LOCAL_PATH_IF_ANY is not provided, remove that positional parameter entirely — do not pass an empty string.
B. Download probe via URL
- Public-read objects: have the user confirm a directly accessible URL.
- Private objects: generate a presigned URL first, then run
probe --download --url.
Generate a presigned URL, save it to a temporary file, then run the probe via a shell script. This two-step approach avoids exposing the full URL in command history and works in environments where $() command substitution is blocked.
Step 1 — Generate the presigned URL and redirect output to a temporary file:
aliyun ossutil presign \
"oss://<BUCKET_NAME>/<OBJECT_NAME>" \
--expires-duration 1h \
--region "<REGION_ID_IF_NEEDED>" \
--user-agent AlibabaCloud-Agent-Skills/alibabacloud-oss-manage-network-probe > /tmp/_presign_url.txtStep 2 — Create a probe script that reads the URL from the file and runs the download probe:
cat > /tmp/_run_presign_probe.sh << 'PROBE_SCRIPT'
#!/bin/bash
PRESIGN_URL=$(cat /tmp/_presign_url.txt)
aliyun ossutil probe \
--download \
--url "$PRESIGN_URL" \
"<LOCAL_PATH_IF_USER_WANTS_TO_RENAME>" \
--user-agent AlibabaCloud-Agent-Skills/alibabacloud-oss-manage-network-probe
PROBE_SCRIPT
bash /tmp/_run_presign_probe.shImportant — you MUST use `probe --download --url` with the presigned URL:
- Never copy-paste the full presigned URL directly into the --url parameter — use the file+script pattern above so the URL is never exposed in command history or execution logs.- If /tmp/ is not writable, use the current workspace directory for the temporary file and script instead.--url only accepts HTTP/HTTPS URLs — it cannot take oss://bucket/object.
- A successful
ossutil presignonly means the signed URL was generated; it does not guarantee the bucket or object exists, nor that the subsequent download will succeed. - If you need to log the execution, do not persist the full presigned URL; at most keep the object address without the query string, or redact all signature parameters after
?. - If
probe --download --urlreturns 404/403, quote the raw HTTP error first; if the bucket/object was already confirmed input, you may do oneossutil statvalidation with the samebucket + object + region. Do not try to "guess" the root cause by listing buckets, trying random regions, or reading local credential files.
C. Download probe via Bucket/Object
- If the user confirmed
object_name, the command will download that object directly. - If the user does not provide
object_name,probewill create a temporary object, download it, and delete the temporary object after completion.
aliyun ossutil probe \
--download \
--bucket "<BUCKET_NAME>" \
--object "<OBJECT_NAME_IF_ANY>" \
--addr "<ADDR_IF_CONFIRMED>" \
"<LOCAL_PATH_IF_USER_WANTS_TO_RENAME>" \
--region "<REGION_ID_IF_NEEDED>" \
--user-agent AlibabaCloud-Agent-Skills/alibabacloud-oss-manage-network-probe- If the command reports
NoSuchBucket,NoSuchKey, or other object-level errors, prefer runningossutil stat "oss://<BUCKET_NAME>/<OBJECT_NAME>" --region "<REGION_ID_IF_NEEDED>"for same-target validation. - Do not list all buckets, try unconfirmed regions, or switch to
aliyun oss api/GetBucketLocationor other commands outside this skill's scope to confirm whether the object exists.
D. Local symlink anomaly probe
This mode only checks local directory/file paths — it does not access OSS.
aliyun ossutil probe \
--probe-item cycle-symlink \
"<LOCAL_DIRECTORY_OR_FILE>" \
--user-agent AlibabaCloud-Agent-Skills/alibabacloud-oss-manage-network-probe- If the command returns
stat <path>: no such file or directory, explicitly state that the local path does not exist in the current execution environment; this is still a local-only flow with no OSS access. - When the local path does not exist, you must NEVER:
- Interpret it as "this is a containerized/sandbox environment limitation"
- Automatically rewrite it as "the user should run on another machine/production environment"
- Generate a script file saying "run this command in the correct environment"
- Check the parent directory with
lsand then give up
Correct approach: Quote the raw error stat <path>: no such file or directory, explicitly tell the user the path does not exist in the current environment, and ask whether they provided the correct path. Unless the user proactively states the current session is not on the target machine, do not make that judgment for them.
When reporting results of this probe, include at minimum:
- This is a local-only flow — no OSS access occurred
- Which symlinks are abnormal and which link chains were directly verified; if only partial chains can be verified, clearly distinguish "confirmed chain segments" from "anomaly points proven by probe errors", e.g.
loop-b -> loop-a, and resolvingloop-areportstoo many levels of symbolic links - If the probe output contains raw errors, quote at least one key error, e.g.
too many levels of symbolic links - Minimum fix prerequisites, e.g. break one of the cyclic links or re-point the abnormal link to a real target before retrying
If you need to clarify the abnormal link chain, you may perform read-only local forensics on the same path (e.g. readlink, stat -f "%N -> %Y"). Only write precise chains when these supplementary results are actually readable; if the supplementary forensics itself fails, report only verified segments — do not fabricate a complete cycle.
If the output lists abnormal symlinks, the user or a local script must fix them according to business semantics; this skill does not auto-rewrite symlink targets.
E. Upload bandwidth probe with suggested concurrency
Basic command:
aliyun ossutil probe \
--probe-item upload-speed \
--bucket "<BUCKET_NAME>" \
--region "<REGION_ID_IF_NEEDED>" \
--user-agent AlibabaCloud-Agent-Skills/alibabacloud-oss-manage-network-probeTo limit runtime, add:
aliyun ossutil probe \
--probe-item upload-speed \
--bucket "<BUCKET_NAME>" \
--runtime "<RUNTIME_IF_CONFIRMED>" \
--region "<REGION_ID_IF_NEEDED>" \
--user-agent AlibabaCloud-Agent-Skills/alibabacloud-oss-manage-network-probeSuccessful output will contain suggest parallel is <N>.
F. Download bandwidth probe with suggested concurrency
object_nameis required.- Official recommendation: target object should be larger than 5 MiB.
- If the user has no suitable object, first confirm a local file path, then upload a cleanable test object via
aliyun ossutil cp.
Optional preparation step:
aliyun ossutil cp \
"<LOCAL_FILE_TO_UPLOAD>" \
"oss://<BUCKET_NAME>/<OBJECT_NAME>" \
--region "<REGION_ID_IF_NEEDED>" \
--user-agent AlibabaCloud-Agent-Skills/alibabacloud-oss-manage-network-probeRun download bandwidth probe:
aliyun ossutil probe \
--probe-item download-speed \
--bucket "<BUCKET_NAME>" \
--object "<OBJECT_NAME>" \
--runtime "<RUNTIME_IF_CONFIRMED>" \
--region "<REGION_ID_IF_NEEDED>" \
--user-agent AlibabaCloud-Agent-Skills/alibabacloud-oss-manage-network-probeG. Download time probe
Basic command:
aliyun ossutil probe \
--probe-item download-time \
--bucket "<BUCKET_NAME>" \
--object "<OBJECT_NAME>" \
--region "<REGION_ID_IF_NEEDED>" \
--user-agent AlibabaCloud-Agent-Skills/alibabacloud-oss-manage-network-probeTo explicitly control concurrency and part size, add:
aliyun ossutil probe \
--probe-item download-time \
--bucket "<BUCKET_NAME>" \
--object "<OBJECT_NAME>" \
--parallel "<PARALLEL_IF_CONFIRMED>" \
--part-size "<PART_SIZE_IF_CONFIRMED>" \
--region "<REGION_ID_IF_NEEDED>" \
--user-agent AlibabaCloud-Agent-Skills/alibabacloud-oss-manage-network-probe--parallel and --part-size are only meaningful in the download-time scenario; do not misuse them with upload-speed.
3. Interpret the output
- When upload/download probes succeed, the output will contain
upload file:successordownload file:success - When bandwidth probes succeed, the output will contain multiple
parallel:<N>statistics andsuggest parallel is <N> - When download time probes succeed, the output will contain
total bytes,cost,avg speed - All probe modes typically generate a
logOssProbe*.loglocal log file; *after probe execution, you must check whether `logOssProbe.log` was generated in the current directory** and report the log path in the final answer - If a real command returns an error or has no success marker, the final conclusion must explicitly state failure/blocked and quote the raw error message — do not write "task completed successfully" or describe a failure as successful verification
- When a command fails, the final answer must explicitly state the termination reason (e.g. "stopped due to AccessDenied", "stopped due to path not found") — do not end silently
- For errors like
The bucket you are attempting to access must be addressed using the specified endpoint, this only means the current access endpoint does not match the bucket's requirements; stop immediately, ask the user to confirm the correct region/endpoint — do not infer or try other region/endpoints on your own
See references/verification-method.md for more detailed verification steps.
Success Verification Method
Follow the steps in references/verification-method.md to confirm each item:
1. CLI version and profile are valid 2. Probe output contains success markers or suggested concurrency 3. *You must run `ls logOssProbe.log` to check whether log files were generated locally, and report the log path in the final answer; if no log files were generated, it means the probe may not have reached the actual probing stage 4. If an explicit test object was used, confirm whether it should be retained or enter the cleanup step 5. If any of the above steps fail, the final answer must explicitly state failure** and quote the raw error with termination reason
Cleanup
- Upload/download connectivity probes without an explicit
--objectwill auto-clean temporary objects - If you explicitly uploaded a test object in the
download-speedpreparation step, decide whether to delete it based on user confirmation after probing
Delete an OSS test object:
aliyun ossutil rm \
"oss://<BUCKET_NAME>/<OBJECT_NAME>" \
--user-agent AlibabaCloud-Agent-Skills/alibabacloud-oss-manage-network-probeIf a temporary test file was downloaded locally, it should also be deleted or retained based on user confirmation.
After all probe and cleanup steps are finished, disable AI safety mode:
aliyun configure ai-mode disableAPI and Command Tables
For all commands, underlying OSS capability mappings, and which steps are local client-side logic only, see references/related-apis.md.
Best Practices
1. Always use aliyun ossutil probe — do not fabricate non-existent commands like aliyun oss api probe 2. Confirm all user-variable parameters before execution, especially bucket_name, object_name, download_url, local_path 3. Only retain probe objects when the user explicitly confirms; otherwise prefer temporary objects or explicit cleanup 4. For download-speed, choose a real object larger than 5 MiB for more stable results 5. In proxy, dedicated line, or custom domain scenarios, explicitly confirm --addr, --region, --endpoint 6. Use suggest parallel is <N> as an empirical baseline, then do small-scale validation combined with actual business concurrency 7. For cycle-symlink, only diagnose — do not auto-fix 8. After command failure, prefer same-target validation (e.g. ossutil stat) — do not expand into listing buckets, guessing regions, trying unsupported flags, or reading local credential files 9. Do not expose AK/SK, STS tokens, or full presigned URL query strings in logs or final results 10. A successful presign, resolvable DNS, or reachable ping/traceroute does not guarantee the object exists or that the probe will succeed; conclusions must be based on actual probe/validation results
Reference Links
| Reference | Purpose |
|---|---|
references/cli-installation-guide.md | Installing and upgrading Aliyun CLI |
references/verification-method.md | Checking success by probe mode |
references/related-apis.md | Command to underlying OSS capability/permission mapping |
references/ram-polices.md | RAM permission checklist and policy examples |
references/acceptance-criteria.md | Skill acceptance criteria and counter-examples |
references/implementation-boundaries.md | Boundaries that cannot be fully automated via CLI or code |
Acceptance Criteria: alibabacloud-oss-manage-network-probe
Scenario: Use aliyun ossutil probe to diagnose OSS network state, bandwidth, download time, and symlink issues Purpose: Skill testing acceptance criteria
---
Correct CLI Command Patterns
1. Product and command structure
CORRECT
aliyun ossutil probe --help --user-agent AlibabaCloud-Agent-Skills
aliyun ossutil version
aliyun configure listWhy correct:
- Uses
aliyunplugin-mode command structure - Uses integrated
ossutil 2.0entrypoint - Includes the required
--user-agent AlibabaCloud-Agent-Skills
INCORRECT
aliyun oss Probe
aliyun oss api probe
oss probe --bucket examplebucketWhy incorrect:
Probeis not the supported command formprobeis not analiyun oss apiOpenAPI actionossis the old command family; this skill targetsaliyun ossutil
2. Credential and CLI pre-check
CORRECT
aliyun version
aliyun configure list
aliyun configure set --auto-plugin-install true
aliyun configure ai-mode enableWhy correct:
- Verifies CLI version
- Checks local profile validity without printing secrets
- Enables auto plugin install using a supported CLI flag
- Enables AI safety mode to block dangerous operations
INCORRECT
echo $ALIBABA_CLOUD_ACCESS_KEY_ID
aliyun configure set --access-key-id <ak> --access-key-secret <sk>
cat ~/.aliyun/config.jsonWhy incorrect:
- Exposes or handles secrets directly
- Violates the credential safety gate for this skill
ALSO INCORRECT
aliyun configure list --output json --user-agent AlibabaCloud-Agent-Skills
printenv | grep ALIBABA_CLOUDWhy incorrect:
configure list --output jsonis not a valid command pattern for this skill's documented workflow- Dumping environment variables to inspect credentials is treated as secret handling
3. Upload probe patterns
CORRECT
aliyun ossutil probe \
--upload \
--bucket "examplebucket" --user-agent AlibabaCloud-Agent-Skillsaliyun ossutil probe \
--upload \
"/tmp/test.bin" \
--bucket "examplebucket" \
--upmode multipart --user-agent AlibabaCloud-Agent-SkillsWhy correct:
--uploadis present--bucketis provided- Optional local file path is passed as a positional argument
--upmodeuses a documented enum value
INCORRECT
aliyun ossutil probe --upload --object test.bin --user-agent AlibabaCloud-Agent-Skills
aliyun ossutil probe --upload --bucket examplebucket --upmode parallel --user-agent AlibabaCloud-Agent-SkillsWhy incorrect:
- Upload probe requires
--bucket parallelis not a valid--upmodevalue; valid values arenormal,append,multipart
4. Download probe patterns
CORRECT
aliyun ossutil probe \
--download \
--bucket "examplebucket" \
--object "dir/example.txt" --user-agent AlibabaCloud-Agent-Skillsaliyun ossutil probe \
--download \
--url "https://examplebucket.oss-cn-hangzhou.aliyuncs.com/example.txt" --user-agent AlibabaCloud-Agent-SkillsWhy correct:
- Uses one of the two documented download modes
- URL mode supplies an HTTP/HTTPS URL
- Bucket mode uses bucket/object parameters correctly
INCORRECT
aliyun ossutil probe --download --url "oss://examplebucket/example.txt" --user-agent AlibabaCloud-Agent-Skills
aliyun ossutil probe --download --object "dir/example.txt" --user-agent AlibabaCloud-Agent-SkillsWhy incorrect:
--urldoes not acceptoss://URIs- Bucket-based download probe needs
--bucket
5. Probe-item patterns
CORRECT
aliyun ossutil probe --probe-item cycle-symlink "/data/links" --user-agent AlibabaCloud-Agent-Skills
aliyun ossutil probe --probe-item upload-speed --bucket "examplebucket" --user-agent AlibabaCloud-Agent-Skills
aliyun ossutil probe --probe-item download-speed --bucket "examplebucket" --object "big/test.bin" --user-agent AlibabaCloud-Agent-Skills
aliyun ossutil probe --probe-item download-time --bucket "examplebucket" --object "big/test.bin" --parallel 3 --part-size 10000000 --user-agent AlibabaCloud-Agent-SkillsWhy correct:
cycle-symlink,upload-speed,download-speed,download-timeare documented valid valuesdownload-speedanddownload-timeprovide bucket and object--paralleland--part-sizeare used ondownload-time
INCORRECT
aliyun ossutil probe --probe-item symlink-check "/data/links" --user-agent AlibabaCloud-Agent-Skills
aliyun ossutil probe --probe-item download-speed --bucket "examplebucket" --user-agent AlibabaCloud-Agent-Skills
aliyun ossutil probe --probe-item upload-speed --bucket "examplebucket" --parallel 3 --user-agent AlibabaCloud-Agent-SkillsWhy incorrect:
symlink-checkis not a valid enum valuedownload-speedrequires--object--parallelis only meaningful fordownload-timein this documented workflow
6. Supporting command patterns
CORRECT
aliyun ossutil stat "oss://examplebucket/big/test.bin" --user-agent AlibabaCloud-Agent-Skills
aliyun ossutil presign "oss://examplebucket/private/test.bin" --expires-duration 1h --user-agent AlibabaCloud-Agent-Skills
aliyun ossutil cp "/tmp/test.bin" "oss://examplebucket/probe/test.bin" --user-agent AlibabaCloud-Agent-Skills
aliyun ossutil rm "oss://examplebucket/probe/test.bin" --user-agent AlibabaCloud-Agent-SkillsWhy correct:
- All commands exist in
aliyun ossutil - Positional arguments and flags follow the CLI help
INCORRECT
aliyun ossutil stat --bucket examplebucket --object big/test.bin --user-agent AlibabaCloud-Agent-Skills
aliyun ossutil presign --bucket examplebucket --object private/test.bin --user-agent AlibabaCloud-Agent-Skills
aliyun ossutil ls --bucket examplebucket --user-agent AlibabaCloud-Agent-Skills
aliyun oss api GetBucketLocation --bucket examplebucketWhy incorrect:
statandpresignuseoss://bucket/objectpositional targets, not--bucket/--objectflagsossutil ls --bucket ...is not the documented CLI shapealiyun oss api .../GetBucketLocationis outside this skill's accepted command patterns
---
Correct Common SDK Code Patterns (if applicable)
This skill uses aliyun ossutil as its primary tool; the current workflow does not require a Python Common SDK implementation.
CORRECT
- Clearly state that this scenario is powered by
aliyun ossutil probe - If supplementary scripts are needed, they should only wrap CLI invocations, parse output, and organize logs; do not fabricate a non-existent OSS OpenAPI
probe
INCORRECT
# Non-existent OSS OpenAPI example
client.probe_state(bucket='examplebucket')Why incorrect:
- There is no documented OSS OpenAPI named
probeorprobe_statethat can replaceossutil probe
---
Success Output Expectations
CORRECT
- Upload probe output contains
upload file:success - Download probe output contains
download file:success - Bandwidth probe output contains
suggest parallel is <N> - Download time probe output contains
total bytes,cost,avg speed - After probe execution,
report log file:or a locallogOssProbe*.logfile should be present
INCORRECT
- Only CLI help output is shown without actual probe results
- After an error, still claiming the probe succeeded, or describing a failure as "task completed successfully"
- Retaining or deleting user test objects without confirmation
- Writing the full presigned URL, STS token, or local credential file contents in logs or the final answer
- After
NoSuchBucket/AccessDenied, enumerating unconfirmed regions, buckets, or endpoints and drawing conclusions from them - In a
cycle-symlinkscenario, writing a complete cyclic chain as verified fact when supplementary forensics did not actually read a particular segment's target
---
Boundary Acceptance Criteria
CORRECT
- Clearly state that
cycle-symlinkcan only detect, not auto-fix - Clearly state that
download-speedrequires an existing object; if none exists, a test object must be confirmed and uploaded first - Clearly state that
probeis a composite client-side command, not a standalone OpenAPI
INCORRECT
- Claiming the same workflow can be achieved via
aliyun oss api probe - Claiming all symlink anomalies can be auto-fixed
- Auto-creating and permanently retaining test objects without user confirmation
Aliyun CLI Installation & Configuration Guide
Complete guide for installing and configuring Aliyun CLI.
Aliyun CLI 3.3.3+: Supports installing and using all published Alibaba Cloud product plugins. Make sure to upgrade to 3.3.3 or later for full plugin ecosystem coverage.
Installation
macOS
Using Homebrew (Recommended)
brew install aliyun-cli
# Upgrade to latest
brew upgrade aliyun-cli
# Verify version (>= 3.3.3)
aliyun versionUsing Binary
# Download
wget https://aliyuncli.alicdn.com/aliyun-cli-macosx-latest-amd64.tgz
# Extract
tar -xzf aliyun-cli-macosx-latest-amd64.tgz
# Move to PATH
sudo mv aliyun /usr/local/bin/
# Verify
aliyun versionLinux
Debian/Ubuntu
# Download
wget https://aliyuncli.alicdn.com/aliyun-cli-linux-latest-amd64.tgz
# Extract and install
tar -xzf aliyun-cli-linux-latest-amd64.tgz
sudo mv aliyun /usr/local/bin/
# Verify
aliyun versionCentOS/RHEL
# Download
wget https://aliyuncli.alicdn.com/aliyun-cli-linux-latest-amd64.tgz
# Extract and install
tar -xzf aliyun-cli-linux-latest-amd64.tgz
sudo mv aliyun /usr/local/bin/
# Verify
aliyun versionARM64 Architecture
# Download ARM64 version
wget https://aliyuncli.alicdn.com/aliyun-cli-linux-latest-arm64.tgz
# Extract and install
tar -xzf aliyun-cli-linux-latest-arm64.tgz
sudo mv aliyun /usr/local/bin/Windows
Using Binary 1. Download from: https://aliyuncli.alicdn.com/aliyun-cli-windows-latest-amd64.zip 2. Extract the ZIP file 3. Add the directory to your PATH environment variable 4. Open new Command Prompt or PowerShell 5. Verify: aliyun version
Using PowerShell
# Download
Invoke-WebRequest -Uri "https://aliyuncli.alicdn.com/aliyun-cli-windows-latest-amd64.zip" -OutFile "aliyun-cli.zip"
# Extract
Expand-Archive -Path aliyun-cli.zip -DestinationPath C:\aliyun-cli
# Add to PATH (requires admin privileges)
$env:Path += ";C:\aliyun-cli"
[Environment]::SetEnvironmentVariable("Path", $env:Path, [System.EnvironmentVariableTarget]::Machine)
# Verify
aliyun versionConfiguration
SECURITY WARNING — For manual user setup only
>
The credential configuration commands below are for humans to run manually in their own terminal, outside of any agent session.
Agents MUST NEVER execute `aliyun configure set` with literal credential values (access-key-id, access-key-secret, sts-token).
Within an agent session, only use aliyun configure list to verify that credentials are already configured.Quick Start
Run the following command in your own terminal (not via an agent):
aliyun configure set \
--mode AK \
--access-key-id <your-access-key-id> \
--access-key-secret <your-access-key-secret> \
--region cn-hangzhouAll aliyun configure commands support non-interactive flags, which is the recommended approach — it works in scripts, CI/CD pipelines, and manual terminal setup without hanging on stdin prompts.
Where to Get Access Keys
1. Log in to Aliyun Console: https://ram.console.aliyun.com/ 2. Navigate to: AccessKey Management 3. Create a new AccessKey pair 4. Save the secret immediately — it's only shown once
Configuration Modes
Aliyun CLI supports 6 authentication modes. All examples below use non-interactive flags.
1. AK Mode (Access Key)
Most common mode for personal accounts and scripts.
aliyun configure set \
--mode AK \
--access-key-id LTAI5tXXXXXXXX \
--access-key-secret 8dXXXXXXXXXXXXXXXXXXXXXXXX \
--region cn-hangzhouConfiguration is stored in ~/.aliyun/config.json:
{
"current": "default",
"profiles": [
{
"name": "default",
"mode": "AK",
"access_key_id": "LTAI5tXXXXXXXX",
"access_key_secret": "8dXXXXXXXXXXXXXXXXXXXXXXXX",
"region_id": "cn-hangzhou",
"output_format": "json",
"language": "en"
}
]
}2. StsToken Mode (Temporary Credentials)
For short-lived access (tokens expire in 1-12 hours).
aliyun configure set \
--mode StsToken \
--access-key-id LTAI5tXXXXXXXX \
--access-key-secret 8dXXXXXXXXXXXXXXXXXXXXXXXX \
--sts-token v1.0:XXXXXXXXXXXXXXXX \
--region cn-hangzhouUse cases: CI/CD pipelines, temporary access for external contractors, cross-account access.
3. RamRoleArn Mode (Assume RAM Role)
Assume a RAM role for elevated or cross-account access.
aliyun configure set \
--mode RamRoleArn \
--access-key-id LTAI5tXXXXXXXX \
--access-key-secret 8dXXXXXXXXXXXXXXXXXXXXXXXX \
--ram-role-arn acs:ram::123456789012:role/AdminRole \
--role-session-name my-session \
--region cn-hangzhouUse cases: cross-account resource access, temporary elevated privileges, role-based access control.
4. EcsRamRole Mode (ECS Instance RAM Role)
Use the RAM role attached to an ECS instance — no credentials needed.
aliyun configure set \
--mode EcsRamRole \
--ram-role-name MyEcsRole \
--region cn-hangzhouRequirements: must be running on an ECS instance with a RAM role attached.
Use cases: scripts and automation running on ECS instances.
5. RsaKeyPair Mode (RSA Key Pair)
Use RSA key pair for authentication (generate key pair in Aliyun Console first).
aliyun configure set \
--mode RsaKeyPair \
--private-key /path/to/private-key.pem \
--key-pair-name my-key-pair \
--region cn-hangzhou6. RamRoleArnWithEcs Mode (ECS + RAM Role)
Combine ECS instance role with RAM role assumption for cross-account access from ECS.
aliyun configure set \
--mode RamRoleArnWithEcs \
--ram-role-name MyEcsRole \
--ram-role-arn acs:ram::123456789012:role/TargetRole \
--role-session-name my-session \
--region cn-hangzhouEnvironment Variables
Highest priority - overrides config file
Access Key Mode
export ALIBABA_CLOUD_ACCESS_KEY_ID=your_access_key_id
export ALIBABA_CLOUD_ACCESS_KEY_SECRET=your_access_key_secret
export ALIBABA_CLOUD_REGION_ID=cn-hangzhouSTS Token Mode
export ALIBABA_CLOUD_ACCESS_KEY_ID=your_access_key_id
export ALIBABA_CLOUD_ACCESS_KEY_SECRET=your_access_key_secret
export ALIBABA_CLOUD_SECURITY_TOKEN=your_sts_token
export ALIBABA_CLOUD_REGION_ID=cn-hangzhouECS RAM Role Mode
export ALIBABA_CLOUD_ECS_METADATA=role_nameUse Case:
- CI/CD pipelines
- Docker containers
- Temporary credential override
Managing Multiple Profiles
Create Named Profiles
aliyun configure set --profile projectA \
--mode AK \
--access-key-id LTAI5tAAAAAAAA \
--access-key-secret 8dAAAAAAAAAAAAAAAAAAAAAAAA \
--region cn-hangzhou
aliyun configure set --profile projectB \
--mode AK \
--access-key-id LTAI5tBBBBBBBB \
--access-key-secret 8dBBBBBBBBBBBBBBBBBBBBBBBB \
--region cn-shanghaiUse Specific Profile
aliyun ecs describe-instances --profile projectA
export ALIBABA_CLOUD_PROFILE=projectA
aliyun ecs describe-instances # Uses projectAList and Switch Profiles
aliyun configure list # List all profiles
aliyun configure set --current projectA # Switch default profileCredential Priority
Credentials are loaded in this order (first found wins):
1. Command-line flag: --profile <name> 2. Environment variable: ALIBABA_CLOUD_PROFILE 3. Environment credentials: ALIBABA_CLOUD_ACCESS_KEY_ID, etc. 4. Configuration file: ~/.aliyun/config.json (current profile) 5. ECS Instance RAM Role: If running on ECS with attached role
Verification
Test Authentication
# Basic test - list regions
aliyun ecs describe-regions
# Expected output: JSON array of regionsIf successful, you'll see:
{
"Regions": {
"Region": [
{
"RegionId": "cn-hangzhou",
"RegionEndpoint": "ecs.cn-hangzhou.aliyuncs.com",
"LocalName": "华东 1(杭州)"
},
...
]
},
"RequestId": "..."
}If failed, you'll see error messages:
InvalidAccessKeyId.NotFound- Wrong Access Key IDSignatureDoesNotMatch- Wrong Access Key SecretInvalidSecurityToken.Expired- STS token expired (for StsToken mode)Forbidden.RAM- Insufficient permissions
Debug Configuration
# Show current configuration
aliyun configure get
# Test with debug logging
aliyun ecs describe-regions --log-level=debug
# Check credential provider
aliyun configure get modeSecurity Best Practices
1. Use RAM Users (Not Root Account)
❌ Don't: Use Aliyun root account credentials ✅ Do: Create RAM users with specific permissions
# Create RAM user in console
# Attach only necessary policies
# Use RAM user's access keys2. Principle of Least Privilege
Grant only the minimum permissions needed:
# Example: Read-only ECS access
# Attach policy: AliyunECSReadOnlyAccess3. Rotate Access Keys Regularly
Run in your own terminal (never via an agent):
# Create new access key in RAM Console, then update configuration
aliyun configure set --access-key-id NEW_KEY --access-key-secret NEW_SECRET
# Delete old access key from console4. Use STS Tokens for Temporary Access
aliyun configure set --mode StsToken \
--access-key-id XXXX --access-key-secret XXXX \
--sts-token XXXX --region cn-hangzhou5. Use ECS RAM Roles When Possible
aliyun configure set --mode EcsRamRole --ram-role-name MyRole --region cn-hangzhou6. Never Commit Credentials
# Add to .gitignore
echo "~/.aliyun/config.json" >> .gitignore
# Use environment variables in CI/CD instead7. Secure Config File
# Restrict permissions
chmod 600 ~/.aliyun/config.jsonTroubleshooting
Issue: Command Not Found
# Check installation
which aliyun
# Check PATH
echo $PATH
# Reinstall or add to PATHIssue: Authentication Failed
# Verify configuration
aliyun configure get
# Test with debug
aliyun ecs describe-regions --log-level=debug
# Check credentials in console
# Verify access key is activeIssue: Permission Denied
# Error: Forbidden.RAM
# Check RAM user permissions
# Attach necessary policies in RAM console
# Example: AliyunECSFullAccess for ECS operationsIssue: STS Token Expired
Run in your own terminal (never via an agent):
# Error: InvalidSecurityToken.Expired
# Reconfigure with new token
aliyun configure set --mode StsToken \
--access-key-id XXXX --access-key-secret XXXX \
--sts-token NEW_TOKEN --region cn-hangzhouIssue: Wrong Region
# Some resources may not exist in the specified region
# Check available regions
aliyun ecs describe-regions
# Update default region
aliyun configure set region cn-shanghaiAdvanced Configuration
Custom Endpoint
# Use custom or private endpoint
export ALIBABA_CLOUD_ECS_ENDPOINT=ecs-vpc.cn-hangzhou.aliyuncs.comProxy Settings
# HTTP proxy
export HTTP_PROXY=http://proxy.example.com:8080
export HTTPS_PROXY=http://proxy.example.com:8080
# No proxy for specific domains
export NO_PROXY=localhost,127.0.0.1,.aliyuncs.comTimeout Settings
# Connection timeout (default: 10s)
export ALIBABA_CLOUD_CONNECT_TIMEOUT=30
# Read timeout (default: 10s)
export ALIBABA_CLOUD_READ_TIMEOUT=30Next Steps
After installation and configuration:
1. Install plugins for services you need (v3.3.3+ supports all published product plugins):
aliyun plugin install --names ecs vpc rds
# List all available plugins
aliyun plugin list-remote2. Explore commands:
aliyun ecs --help
aliyun fc --help3. Read documentation:
- Command Syntax Guide
- Global Flags Reference
- Common Scenarios
References
- Official Documentation: https://help.aliyun.com/zh/cli/
- RAM Console: https://ram.console.aliyun.com/
- Access Key Management: https://ram.console.aliyun.com/manage/ak
- Plugin Repository: https://github.com/aliyun/aliyun-cli
Implementation Boundaries: alibabacloud-oss-manage-network-probe
Overview
This skill centers on aliyun ossutil probe and uses the Alibaba Cloud CLI to perform OSS network diagnostics. However, there are clear boundaries: some capabilities are composite client-side behaviors, and some can only detect issues but cannot auto-fix them.
Supported with Aliyun CLI
| Item | CLI/Code Status | Notes |
|---|---|---|
aliyun ossutil probe --upload ... --user-agent AlibabaCloud-Agent-Skills/alibabacloud-oss-manage-network-probe | Supported | Tests local-to-OSS link status via upload or temporary object |
aliyun ossutil probe --download ... --user-agent AlibabaCloud-Agent-Skills/alibabacloud-oss-manage-network-probe | Supported | Supports URL download probe or Bucket/Object download probe |
aliyun ossutil probe --probe-item upload-speed ... --user-agent AlibabaCloud-Agent-Skills/alibabacloud-oss-manage-network-probe | Supported | Outputs upload bandwidth and suggested concurrency |
aliyun ossutil probe --probe-item download-speed ... --user-agent AlibabaCloud-Agent-Skills/alibabacloud-oss-manage-network-probe | Supported | Outputs download bandwidth and suggested concurrency |
aliyun ossutil probe --probe-item download-time ... --user-agent AlibabaCloud-Agent-Skills/alibabacloud-oss-manage-network-probe | Supported | Outputs download time and throughput statistics |
aliyun ossutil probe --probe-item cycle-symlink ... --user-agent AlibabaCloud-Agent-Skills/alibabacloud-oss-manage-network-probe | Supported for detection only | Local symlink anomaly detection only |
aliyun ossutil presign ... --user-agent AlibabaCloud-Agent-Skills/alibabacloud-oss-manage-network-probe | Supported | Generates presigned URL for private object download probe |
aliyun ossutil cp ... --user-agent AlibabaCloud-Agent-Skills/alibabacloud-oss-manage-network-probe | Supported | Prepares test objects for download-speed |
Not a Single OpenAPI Primitive
| Item | Status | Why it matters |
|---|---|---|
probe | Not a single OpenAPI | There is no aliyun oss api probe; probe is a composite client-side diagnostic command in ossutil |
cycle-symlink | Local-only logic | Detection occurs on the local filesystem, not via an OSS remote API |
--addr network probing | Partially environment-dependent | Affected by local DNS, ICMP policies, proxies, and corporate network policies; failure does not necessarily indicate an OSS issue |
Steps That Cannot Be Fully Automated Safely
| Item | CLI/Code Status | Reason |
|---|---|---|
| Auto-fix abnormal symlinks | Not safely supported | Requires knowledge of the correct target path and business intent; cannot be safely guessed |
| Auto-determine root cause of all network issues | Partially supported | probe provides symptoms, throughput, and logs, but manual analysis of the network environment is still needed |
Construct a download-speed test object without an existing object or local file | Not purely CLI-only | download-speed requires an existing object; if none is available, the user must confirm an existing object path or provide a local file to upload via aliyun ossutil cp |
| Auto-decide whether to retain test objects or local downloaded files | Requires user confirmation | This affects user data and cleanup strategy; confirmation is required first |
Practical Guidance
1. If the user only needs link diagnostics, do not force creation of persistent objects; prefer using probe's temporary object capability. 2. If the user wants to test download-speed, prefer asking the user to confirm an existing object larger than 5 MiB. 3. If --addr detection fails but OSS upload/download succeeds, do not conclude an OSS failure; suggest checking local network, proxy, DNS, and security policies. 4. If cycle-symlink detects anomalies, only report the abnormal paths and impact; do not auto-rewrite link targets. 5. If the user requests "implement everything via code", clarify that this scenario is covered by ossutil integrated with the Alibaba Cloud CLI, and there is no standalone OSS OpenAPI probe that can replace this command.
RAM Policies: alibabacloud-oss-manage-network-probe
Overview
The minimum permission set for this skill depends on the probe mode. aliyun ossutil probe may directly access existing objects, or temporarily upload and delete objects for diagnostics. Therefore, permissions should be granted per scenario at the minimum required level, rather than granting oss:*.
Scenario Permission Matrix
| Scenario | Required RAM actions | Why |
|---|---|---|
| CLI version / local config check | None | Local CLI behavior only |
probe --probe-item cycle-symlink <local_path> | None | Local symlink check only |
probe --download --url <signed_or_public_url> | oss:GetObject | Downloads OSS object content |
probe --download --bucket <bucket> --object <object> | oss:GetObject | Downloads the specified object |
probe --download --bucket <bucket> with temporary object | oss:GetObject, oss:PutObject, oss:DeleteObject | Creates a temporary object, downloads it, then cleans up |
probe --upload --bucket <bucket> | oss:GetObject, oss:PutObject, oss:DeleteObject | Official docs require these three for upload bandwidth/upload probe |
probe --probe-item upload-speed --bucket <bucket> | oss:GetObject, oss:PutObject, oss:DeleteObject | Repeatedly uploads for diagnostics and cleans up test objects |
probe --probe-item download-speed --bucket <bucket> --object <object> | oss:GetObject | Repeatedly downloads the object and measures throughput |
probe --probe-item download-time --bucket <bucket> --object <object> | oss:GetObject | Downloads and calculates elapsed time |
ossutil cp <local_file> oss://<bucket>/<object> | oss:PutObject | Prepares test objects |
ossutil rm oss://<bucket>/<object> | oss:DeleteObject | Cleans up explicitly created test objects |
ossutil stat oss://<bucket>/<object> | oss:GetObject | Views object metadata |
ossutil ls oss://<bucket>/<prefix> | oss:ListObjects | Lists objects to confirm paths |
ossutil presign oss://<bucket>/<object> | Usually none extra for single object; oss:ListObjects if recursive/batch | Local signing; listing is required for recursive operations |
Least-Privilege Recommendations
1. For symlink detection only, do not grant any OSS data permissions. 2. For download-only probes, prefer granting only oss:GetObject. 3. Only add oss:PutObject and oss:DeleteObject for upload probes, upload bandwidth probes, or temporary-object download probes. 4. Only add oss:ListObjects when object listing or recursive processing is needed. 5. If the test object is a user-specified business object, grant delete permission cautiously and confirm the cleanup strategy first.
Summary Table by Product
| Product | RAM Action | Resource Scope | Description |
|---|---|---|---|
| OSS | oss:GetObject | acs:oss:*:*:<bucket>/<object-or-prefix> or * | Download objects, read object content, partial probe workflows |
| OSS | oss:PutObject | acs:oss:*:*:<bucket>/<object-or-prefix> or * | Upload probes, prepare test objects, create temporary objects |
| OSS | oss:DeleteObject | acs:oss:*:*:<bucket>/<object-or-prefix> or * | Delete explicit test objects or temporary objects |
| OSS | oss:ListObjects | acs:oss:*:*:<bucket> or * | List objects, recursive presign, or path confirmation |
Example Policy: download-only probing
Applicable to:
aliyun ossutil probe --download --bucket <bucket> --object <object> --user-agent AlibabaCloud-Agent-Skills/alibabacloud-oss-manage-network-probealiyun ossutil probe --probe-item download-speed --bucket <bucket> --object <object> --user-agent AlibabaCloud-Agent-Skills/alibabacloud-oss-manage-network-probealiyun ossutil probe --probe-item download-time --bucket <bucket> --object <object> --user-agent AlibabaCloud-Agent-Skills/alibabacloud-oss-manage-network-probe
{
"Version": "1",
"Statement": [
{
"Effect": "Allow",
"Action": [
"oss:GetObject"
],
"Resource": "*"
}
]
}Example Policy: upload / temporary-object probing
Applicable to:
aliyun ossutil probe --upload --bucket <bucket> --user-agent AlibabaCloud-Agent-Skills/alibabacloud-oss-manage-network-probealiyun ossutil probe --probe-item upload-speed --bucket <bucket> --user-agent AlibabaCloud-Agent-Skills/alibabacloud-oss-manage-network-probealiyun ossutil probe --download --bucket <bucket> --user-agent AlibabaCloud-Agent-Skills/alibabacloud-oss-manage-network-probewithout explicit object
{
"Version": "1",
"Statement": [
{
"Effect": "Allow",
"Action": [
"oss:GetObject",
"oss:PutObject",
"oss:DeleteObject"
],
"Resource": "*"
}
]
}Example Policy: full troubleshooting workflow
Applicable to:
- Listing objects to confirm paths
- Pre-uploading test objects
- Download bandwidth testing
- Cleaning up objects after completion
{
"Version": "1",
"Statement": [
{
"Effect": "Allow",
"Action": [
"oss:GetObject",
"oss:PutObject",
"oss:DeleteObject",
"oss:ListObjects"
],
"Resource": "*"
}
]
}Notes
- Official
probedocumentation states: upload bandwidth probing requires at minimumoss:GetObject,oss:PutObject,oss:DeleteObject; download bandwidth probing requires at minimumoss:GetObject. - The
configure list,configure set --auto-plugin-install true,configure ai-mode enable, andversioncommands in this skill are all local CLI operations and do not correspond to RAM permissions. - If the user requires stricter resource scoping, narrow the
Resourcefrom*to specific bucket/object ARN ranges.
Related APIs and Commands: alibabacloud-oss-manage-network-probe
Overview
aliyun ossutil probe is a composite client-side diagnostic command. It is not a single OSS OpenAPI, but rather a combination of local diagnostic logic and a set of OSS data access capabilities. Therefore, this table lists:
1. The actual Alibaba Cloud CLI commands executed 2. The related underlying OSS capabilities or local behaviors 3. Minimum permission or constraint notes
Command and Capability Table
| Workflow Step | CLI Command | Underlying OSS capability / local behavior | Minimum RAM action / permission | Notes |
|---|---|---|---|---|
| CLI version check | aliyun version | Local CLI behavior | None | Verifies CLI version >= 3.3.3 |
| Enable auto plugin install | aliyun configure set --auto-plugin-install true | Local CLI behavior | None | Not a cloud OpenAPI |
| Enable AI safety mode | aliyun configure ai-mode enable | Local CLI behavior | None | Enables safety mode; dangerous operations are blocked |
| Credential gate | aliyun configure list | Local CLI behavior | None | Only checks whether the local profile is valid |
| Integrated ossutil check | aliyun ossutil version | Local CLI behavior | None | Verifies ossutil 2.0 is integrated |
| Upload connectivity probe | aliyun ossutil probe --upload --bucket <bucket> [<local_file>] --user-agent AlibabaCloud-Agent-Skills | Composite probe using upload workflow and optional temporary object cleanup | Documented minimum: oss:GetObject, oss:PutObject, oss:DeleteObject | --upmode accepts normal / append / multipart |
| Download connectivity probe by URL | aliyun ossutil probe --download --url "<http_url>" [<local_path>] --user-agent AlibabaCloud-Agent-Skills | Download via HTTP/HTTPS URL | oss:GetObject when the URL points to an OSS object | Private objects require a presigned URL first |
| Download connectivity probe by bucket/object | aliyun ossutil probe --download --bucket <bucket> [--object <object>] [<local_path>] --user-agent AlibabaCloud-Agent-Skills | GetObject; if --object is omitted, probe creates and deletes a temporary object | With explicit object: oss:GetObject; with temporary object workflow: oss:GetObject, oss:PutObject, oss:DeleteObject | Suitable for directly verifying Bucket/Object paths |
| Symlink detection | aliyun ossutil probe --probe-item cycle-symlink <local_path> --user-agent AlibabaCloud-Agent-Skills | Local filesystem inspection only | None | Does not access OSS |
| Upload bandwidth probe | aliyun ossutil probe --probe-item upload-speed --bucket <bucket> --user-agent AlibabaCloud-Agent-Skills | Repeated upload diagnostics plus concurrency recommendation | Documented minimum: oss:GetObject, oss:PutObject, oss:DeleteObject | Outputs suggest parallel is <N> |
| Download bandwidth probe | aliyun ossutil probe --probe-item download-speed --bucket <bucket> --object <object> --user-agent AlibabaCloud-Agent-Skills | Repeated download diagnostics plus concurrency recommendation | oss:GetObject | Official recommendation: object larger than 5 MiB |
| Download time probe | aliyun ossutil probe --probe-item download-time --bucket <bucket> --object <object> --user-agent AlibabaCloud-Agent-Skills | Timed download with optional part size and parallelism | oss:GetObject | --parallel / --part-size only valid for this mode |
| Optional prep upload | aliyun ossutil cp "<local_file>" "oss://<bucket>/<object>" --user-agent AlibabaCloud-Agent-Skills | Upload local file to OSS | oss:PutObject | Prepares test objects for download-speed |
| Optional presigned URL | aliyun ossutil presign "oss://<bucket>/<object>" --expires-duration 1h --user-agent AlibabaCloud-Agent-Skills | Local signing for a specific OSS object URL | Usually no additional OSS call for a single object URL | May require oss:ListObjects for recursive/batch URL generation |
| Optional cleanup | aliyun ossutil rm "oss://<bucket>/<object>" --user-agent AlibabaCloud-Agent-Skills | Delete probe object | oss:DeleteObject | Only used when the user confirms deletion of explicitly created test objects |
Important Notes
1. probe is not a command under aliyun oss api; do not write aliyun oss api probe. 2. --url mode only accepts HTTP/HTTPS URLs; it cannot take oss://bucket/object. 3. cycle-symlink has no cloud API counterpart; it performs local filesystem inspection. 4. --user-agent AlibabaCloud-Agent-Skills must be added only to API-calling commands (e.g., probe, cp, presign, rm). Local CLI commands (aliyun version, aliyun configure ..., aliyun ossutil version) do not support this flag. 5. For API-calling commands, --user-agent is passed as a trailing flag after all other arguments.
Validated Command Set
The following commands have been validated against their help output during skill generation:
aliyun versionaliyun configure listaliyun configure set --auto-plugin-install truealiyun configure ai-mode enablealiyun ossutil versionaliyun ossutil probe --help --user-agent AlibabaCloud-Agent-Skillsaliyun ossutil cp --help --user-agent AlibabaCloud-Agent-Skillsaliyun ossutil presign --help --user-agent AlibabaCloud-Agent-Skillsaliyun ossutil rm --help --user-agent AlibabaCloud-Agent-Skills
Verification Method: alibabacloud-oss-manage-network-probe
Goal
Verify that the aliyun ossutil probe solution has successfully achieved one of the following objectives:
- Successfully diagnosed the local-to-OSS upload or download link
- Output upload/download bandwidth with a suggested concurrency value
- Output download time statistics
- Detected whether local symlinks have anomalies
Step 1: Verify CLI prerequisites
aliyun version
aliyun configure list
aliyun ossutil versionSuccess indicators:
versionoutputs a version number >= 3.3.3configure listshows at least oneValidprofileossutil versionreturns version information successfully
Failure guardrails:
- If
configure listdoes not show a valid profile, stop immediately; do not proceed withconfigure set --auto-plugin-install true,configure ai-mode enable,ossutil version, or any probe commands - Do not read
~/.aliyun/config.json, do not export environment variables, do not log any plaintext credentials
Step 2: Verify input object or URL when needed
2.1 Verify a bucket/object path before download-speed or download-time
aliyun ossutil stat \
"oss://<BUCKET_NAME>/<OBJECT_NAME>" \
--region "<REGION_ID_IF_NEEDED>" \
--user-agent AlibabaCloud-Agent-Skills/alibabacloud-oss-manage-network-probeSuccess indicator:
- Command returns object metadata, not
NoSuchKeyor a permission error
2.2 Verify download URL mode
For private objects, generate a presigned URL first, then run the URL download probe:
aliyun ossutil presign \
"oss://<BUCKET_NAME>/<OBJECT_NAME>" \
--expires-duration 1h \
--region "<REGION_ID_IF_NEEDED>" \
--user-agent AlibabaCloud-Agent-Skills/alibabacloud-oss-manage-network-probeSuccess indicator:
- Outputs a usable HTTP/HTTPS URL
Security note:
- When logging execution results, do not persist the full presigned URL query string; only keep the base URL, or redact everything after
?
Step 3: Verify each probe mode
3.1 Upload connectivity probe
aliyun ossutil probe \
--upload \
--bucket "<BUCKET_NAME>" \
--region "<REGION_ID_IF_NEEDED>" \
--user-agent AlibabaCloud-Agent-Skills/alibabacloud-oss-manage-network-probeSuccess indicators:
- Output contains
begin upload file - Output contains
upload file:success - Output contains
upload time consuming: - Output contains
report log file:
3.2 Download connectivity probe by bucket
aliyun ossutil probe \
--download \
--bucket "<BUCKET_NAME>" \
--object "<OBJECT_NAME_IF_ANY>" \
--region "<REGION_ID_IF_NEEDED>" \
--user-agent AlibabaCloud-Agent-Skills/alibabacloud-oss-manage-network-probeSuccess indicators:
- Output contains
begin download file - Output contains
download file:success - Output contains
download time consuming: - Output contains
download file is
3.3 Download connectivity probe by URL
aliyun ossutil probe \
--download \
--url "<DOWNLOAD_URL>" \
--user-agent AlibabaCloud-Agent-Skills/alibabacloud-oss-manage-network-probeSuccess indicators:
- Output contains
download file:success - Output contains the target local file path
3.4 Upload bandwidth probe
Basic command:
aliyun ossutil probe \
--probe-item upload-speed \
--bucket "<BUCKET_NAME>" \
--region "<REGION_ID_IF_NEEDED>" \
--user-agent AlibabaCloud-Agent-Skills/alibabacloud-oss-manage-network-probeTo limit runtime, add --runtime:
aliyun ossutil probe \
--probe-item upload-speed \
--bucket "<BUCKET_NAME>" \
--runtime "<RUNTIME_IF_CONFIRMED>" \
--region "<REGION_ID_IF_NEEDED>" \
--user-agent AlibabaCloud-Agent-Skills/alibabacloud-oss-manage-network-probeSuccess indicators:
- Output contains multiple lines of
parallel:<N>,average speed: - Output contains
suggest parallel is <N>
3.5 Download bandwidth probe
aliyun ossutil probe \
--probe-item download-speed \
--bucket "<BUCKET_NAME>" \
--object "<OBJECT_NAME>" \
--runtime "<RUNTIME_IF_CONFIRMED>" \
--region "<REGION_ID_IF_NEEDED>" \
--user-agent AlibabaCloud-Agent-Skills/alibabacloud-oss-manage-network-probeSuccess indicators:
- Output contains multiple lines of
parallel:<N>,average speed: - Output contains
suggest parallel is <N> - If the object is smaller than the recommended size or network fluctuations are significant, results may be unstable, but the command should still complete
3.6 Download time probe
Basic command:
aliyun ossutil probe \
--probe-item download-time \
--bucket "<BUCKET_NAME>" \
--object "<OBJECT_NAME>" \
--region "<REGION_ID_IF_NEEDED>" \
--user-agent AlibabaCloud-Agent-Skills/alibabacloud-oss-manage-network-probeTo explicitly control concurrency and part size, add:
aliyun ossutil probe \
--probe-item download-time \
--bucket "<BUCKET_NAME>" \
--object "<OBJECT_NAME>" \
--parallel "<PARALLEL_IF_CONFIRMED>" \
--part-size "<PART_SIZE_IF_CONFIRMED>" \
--region "<REGION_ID_IF_NEEDED>" \
--user-agent AlibabaCloud-Agent-Skills/alibabacloud-oss-manage-network-probeSuccess indicators:
- Output contains
total bytes: - Output contains
cost: - Output contains
avg speed:
3.7 Symlink detection
aliyun ossutil probe \
--probe-item cycle-symlink \
"<LOCAL_DIRECTORY_OR_FILE>" \
--user-agent AlibabaCloud-Agent-Skills/alibabacloud-oss-manage-network-probeSuccess indicators:
- Command completes normally and outputs elapsed time
- If no anomalies, output should indicate no abnormal symlinks
- If anomalies are found, output should list the abnormal symlink information
Supplementary forensics rules:
- To reconstruct specific link chains, perform read-only local forensics on the same path (e.g.
readlink,stat -f "%N -> %Y") - Only write precise chains when the target is successfully read; if
readlink/statitself fails, report only verified segments and the raw probe error
Step 4: Verify local probe logs
After probe execution, check whether logOssProbe*.log files were generated in the current working directory or the ossutil run directory.
ls -1t logOssProbe*.logSuccess indicator:
- At least one recent
logOssProbe*.logfile exists
Step 5: Optional cleanup verification
If a test object was explicitly uploaded and is planned for deletion, execute:
aliyun ossutil rm \
"oss://<BUCKET_NAME>/<OBJECT_NAME>" \
--user-agent AlibabaCloud-Agent-Skills/alibabacloud-oss-manage-network-probeThen verify the object no longer exists:
aliyun ossutil stat \
"oss://<BUCKET_NAME>/<OBJECT_NAME>" \
--region "<REGION_ID_IF_NEEDED>" \
--user-agent AlibabaCloud-Agent-Skills/alibabacloud-oss-manage-network-probeSuccess indicator:
- Delete command succeeds
- Subsequent
statreturns object not found, or the user confirms retaining the object and this step is skipped
Failure Interpretation
| Symptom | Likely meaning | Next action |
|---|---|---|
configure list shows no valid profile | Credentials are unavailable | Configure credentials outside the session first |
probe --download-speed reports object not found | object_name is wrong or the object has not been prepared | Run ossutil stat on the same target first; do not enumerate unconfirmed regions/buckets |
probe --download --url returns 404/403 | URL is reachable but object, permission, or bucket conditions are not met | Quote the raw HTTP error; if necessary, run a single stat validation on the same bucket/object/region |
probe fails during network detection phase | Local network, DNS, proxy, or link to the target address is abnormal | Continue troubleshooting with --addr, proxy configuration, and local network |
The bucket you are attempting to access must be addressed using the specified endpoint | The current request endpoint does not match the bucket's requirements | Ask the user to confirm the correct region/endpoint or execution environment; do not assert VPC-only on your own |
Only --addr detection fails, but OSS upload/download succeeds | Domain connectivity issue, not necessarily an OSS failure | Use the correct domain or skip this check |
cycle-symlink reports no such file or directory | The local path does not exist in the current execution environment | Clearly state this is a missing local path; do not auto-rewrite it as "expected behavior" |
cycle-symlink reports anomalies | Local symlink target is abnormal or a cyclic link exists | Manually fix the link, then retry |