Flash Media Server Resources
|
Clearing the edge server cache
Deleting files from the edge server cacheEdge
servers do not delete content automatically; you must delete unused
files to manage disk usage. Edge servers update the timestamp of
a file each time the file is used. You can use the timestamp to
determine when a cached file was used.
Manage the edge server cache in WindowsYou
can create a weekly scheduled task to clear the edge server cache.
Create a cache.bat file to empty the cache directory.
The entry in the cache.bat file has the following syntax:
del /Q /S <cache_directory>\*.*
Run the cache.bat file and verify that it deletes files in
the cache directory.
The directory structure remains and any
files currently locked by the edge server are not deleted; this
is expected behavior.
Select Control Panel > Scheduled Tasks >
Add Scheduled Task.
Select cache.bat as the new file to run.
Replicate this procedure on each edge server.
Manage the edge server cache in LinuxCreate
a shell script named cache.sh to empty the cache directory. The cache.sh
script has the following syntax:
find <cache_directory> -name "*.flv" -exec rm-f{}\;
find <cache_directory> -name "*.mp3" -exec rm-f{}\;
find <cache_directory> -name "*.mp4" -exec rm-f{}\;
Note: You can add any additional file types to the script.
Verify that the script is executable by running the following
command:
$ chmod 700 cache.sh
Run cache.sh to verify that it deletes the correct files
in the cache directory.
Use the cron utility to schedule cache.sh to run. (For details
about the cron utility, see the documentation for your Linux distribution.)
|