Forum Discussion
Using iControlREST to list entries in ramcache
I'm trying to build a bash script to query the F5 so that we can see what entries are on the ramcache profile. I am able to delete entries with:
curl -sk -u $USERNAME:$PASSWORD -X DELETE
but I can't find out how to do something like that but for getting info:
curl -sk -u $USERNAME:$PASSWORD -X GET
I see cryptic mentions online and in the docs that this is possible, but I can't figure it out. Am I going about this the wrong way?
- Satoshi_Toyosa1Ret. Employee
In tmsh, you need to use
command to view the LTM ramcache profile data: e.g.,show
tmsh show ltm profile ramcache webacceleration
Fot the iControl REST equivalent, then, add
to the endpoint (an endpoint withoutstats
is for tmsh'sstats
command). So,list
curl -sku : https:///mgmt/tm/ltm/profile/ramcache/webacceleration/stats
should show the current cache.
Similarly, to remove the cache completely (
equivalent):tmsh delete ltm profile ramcache webacceleration
curl -sku : https:///mgmt/tm/ltm/profile/ramcache/webacceleration -X DELETE
See also K13255: Displaying and deleting HTTP cache entries from the command line (11.x - 13.x).
- Satoshi_Toyosa1Ret. Employee
Here's a tmsh command example for removing the specific cache entry from the webacceleration ramcache by URI. In this case,
./foo.html
tmsh delete ltm profile ramcache webacceleration uri /foo.html
The iControl REST equivalent is
curl -sku : -X DELETE \ https:///mgmt/tm/ltm/profile/ramcache/webacceleration?options=uri,/foo.html
There are many ways to manipulate the cache entries. Please refer to the tmsh help (from the tmsh prompt,
).help ltm profile ramcache
By the way, please consider posting the equivalent tmsh command you wish to perform if possible. That way, people can know exactly what you would like to do.
Recent Discussions
Related Content
* Getting Started on DevCentral
* Community Guidelines
* Community Terms of Use / EULA
* Community Ranking Explained
* Community Resources
* Contact the DevCentral Team
* Update MFA on account.f5.com