Linux下使用rsync最快速删除海量文件
- font size decrease font size increase font size
- Print Email
1、先安装rsync:
yum install rsync
2、建立一个空的文件夹:
mkdir /tmp/test
3、用rsync删除目标目录:
rsync --delete-before -a -H -v --progress --stats /tmp/test log
这样我们要删除的log目录就会被清空了,删除的速度会非常快。
Last modified onSunday, 14 October 2012 04:07
( ! ) Warning: count(): Parameter must be an array or an object that implements Countable in /var/www/vhosts/shan.info/httpdocs/templates/gk_publisher/html/com_k2/templates/default/item.php on line 169 | ||||
---|---|---|---|---|
Call Stack | ||||
# | Time | Memory | Function | Location |
1 | 0.0003 | 412288 | {main}( ) | .../index.php:0 |
2 | 0.0916 | 4270824 | Joomla\CMS\Application\SiteApplication->execute( ) | .../index.php:49 |
3 | 0.0916 | 4270824 | Joomla\CMS\Application\SiteApplication->doExecute( ) | .../CMSApplication.php:196 |
4 | 0.3372 | 11393032 | Joomla\CMS\Application\SiteApplication->dispatch( ) | .../SiteApplication.php:233 |
5 | 0.3378 | 11417376 | Joomla\CMS\Component\ComponentHelper::renderComponent( ) | .../SiteApplication.php:194 |
6 | 0.3384 | 11472704 | Joomla\CMS\Component\ComponentHelper::executeComponent( ) | .../ComponentHelper.php:377 |
7 | 0.3387 | 11499672 | require_once( '/var/www/vhosts/shan.info/httpdocs/components/com_k2/k2.php' ) | .../ComponentHelper.php:402 |
8 | 0.3469 | 11896160 | K2ControllerItem->execute( ) | .../k2.php:64 |
9 | 0.3469 | 11896160 | K2ControllerItem->display( ) | .../BaseController.php:710 |
10 | 0.3568 | 12540568 | K2ControllerItem->display( ) | .../item.php:78 |
11 | 0.3568 | 12540568 | K2ControllerItem->display( ) | .../controller.php:19 |
12 | 0.3605 | 12907624 | Joomla\CMS\Cache\Controller\ViewController->get( ) | .../BaseController.php:663 |
13 | 0.3614 | 12927992 | K2ViewItem->display( ) | .../ViewController.php:102 |
14 | 0.4349 | 15661840 | K2ViewItem->display( ) | .../view.html.php:742 |
15 | 0.4349 | 15661840 | K2ViewItem->loadTemplate( ) | .../HtmlView.php:230 |
16 | 0.4371 | 15834144 | include( '/var/www/vhosts/shan.info/httpdocs/templates/gk_publisher/html/com_k2/templates/default/item.php' ) | .../HtmlView.php:701 |
- Published in CentOS 6
- Read 4080 times
( ! ) Notice: Only variables should be assigned by reference in /var/www/vhosts/shan.info/httpdocs/templates/gk_publisher/html/com_k2/templates/default/item.php on line 478 | ||||
---|---|---|---|---|
Call Stack | ||||
# | Time | Memory | Function | Location |
1 | 0.0003 | 412288 | {main}( ) | .../index.php:0 |
2 | 0.0916 | 4270824 | Joomla\CMS\Application\SiteApplication->execute( ) | .../index.php:49 |
3 | 0.0916 | 4270824 | Joomla\CMS\Application\SiteApplication->doExecute( ) | .../CMSApplication.php:196 |
4 | 0.3372 | 11393032 | Joomla\CMS\Application\SiteApplication->dispatch( ) | .../SiteApplication.php:233 |
5 | 0.3378 | 11417376 | Joomla\CMS\Component\ComponentHelper::renderComponent( ) | .../SiteApplication.php:194 |
6 | 0.3384 | 11472704 | Joomla\CMS\Component\ComponentHelper::executeComponent( ) | .../ComponentHelper.php:377 |
7 | 0.3387 | 11499672 | require_once( '/var/www/vhosts/shan.info/httpdocs/components/com_k2/k2.php' ) | .../ComponentHelper.php:402 |
8 | 0.3469 | 11896160 | K2ControllerItem->execute( ) | .../k2.php:64 |
9 | 0.3469 | 11896160 | K2ControllerItem->display( ) | .../BaseController.php:710 |
10 | 0.3568 | 12540568 | K2ControllerItem->display( ) | .../item.php:78 |
11 | 0.3568 | 12540568 | K2ControllerItem->display( ) | .../controller.php:19 |
12 | 0.3605 | 12907624 | Joomla\CMS\Cache\Controller\ViewController->get( ) | .../BaseController.php:663 |
13 | 0.3614 | 12927992 | K2ViewItem->display( ) | .../ViewController.php:102 |
14 | 0.4349 | 15661840 | K2ViewItem->display( ) | .../view.html.php:742 |
15 | 0.4349 | 15661840 | K2ViewItem->loadTemplate( ) | .../HtmlView.php:230 |
16 | 0.4371 | 15834144 | include( '/var/www/vhosts/shan.info/httpdocs/templates/gk_publisher/html/com_k2/templates/default/item.php' ) | .../HtmlView.php:701 |