Manual:pruneFileCache.php
Appearance
| MediaWiki バージョン: | ≧ 1.19 |
| MediaWiki ファイル: pruneFileCache.php | |
|---|---|
| 場所: | maintenance/ |
| ソース コード: | master • 1.46.0 • 1.45.4 • 1.43.9 |
| クラス: | PruneFileCache |
詳細
pruneFileCache.php file is a maintenance script to prune file cache for pages, objects, resources, etc.
This script requires $wgUseFileCache = true; to be set in LocalSettings.php in order to prune the file cache from $wgFileCacheDirectory.
オプション/引数
| オプション | 説明 | 必須かどうか |
|---|---|---|
| --agedays | How many days old files must be in order to delete | 必須 |
| --subdir | Prune one $wgFileCacheDirectory subdirectory name | 省略可能 |
使用法
php maintenance/run.php pruneFileCache --agedays days [ --subdir ]
Terminal
$ php maintenance/run.php pruneFileCache --agedays 7 Pruning `/var/www/html/wiki/images/cache` directory... Done pruning `/var/www/html/wiki/images/cache` directory
MediaWiki バージョン MediaWiki 1.39 以前では、メンテナンス スクリプトを
php maintenance/run.php スクリプト名 ではなく php maintenance/スクリプト名.php を使用して実行する必要があります。