adb_file_chown
Change Android file or directory ownership through ADB by specifying user:group IDs; root is required, and recursive mode includes depth protection.
Instructions
Change file ownership on the device. Requires root. Supports both numeric UID:GID (e.g., '10150:10150') and symbolic user:group (e.g., 'system:system'). Recursive mode uses depth-based protection: refuses at depth ≤ 2 from root. Note: sdcardfs/FAT32 ignore ownership changes.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"path": "<path>",
"owner": "<owner>"
},
"name": "adb_file_chown"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| path | Yes | File or directory path | |
| owner | Yes | Owner in user:group format (e.g., '0:0', 'system:system', '10150:10150') | |
| device | No | Device serial | |
| recursive | No | Apply recursively to directory contents. Depth-protected. |