Home > php教程 > php手册 > body text

清空文件的内容 和 统计文件的大小的命令,清空统计

WBOY
Release: 2016-06-13 08:48:38
Original
765 people have browsed it

清空文件的内容 和 统计文件的大小的命令,清空统计

清空文件的内容:true > 文件名  (或 echo “”> 文件名) 

统计文件的大小:du -h --max-depth=1 /usr/local/nginx/logs/* (*表示logs文件夹里的所有文件)

统计文件夹的大小:du -sh 文件夹

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Recommendations
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template