小編給大家分享一下怎么\通過計劃任務定期釋放PHP占用的內(nèi)存,希望大家閱讀完這篇文章后大所收獲,下面讓我們一起去探討吧!

\
通過計劃任務定期釋放PHP占用的內(nèi)存
在計劃任務中添加任務,選擇周期,如每周一 3時30分執(zhí)行
選執(zhí)行Shell腳本,粘貼以下Shell腳本
if [ -f /etc/init.d/php-fpm-52 ];then
service php-fpm-52 reload
fi
if [ -f /etc/init.d/php-fpm-53 ];then
service php-fpm-53 reload
fi
if [ -f /etc/init.d/php-fpm-54 ];then
service php-fpm-54 reload
fi
if [ -f /etc/init.d/php-fpm-55 ];then
service php-fpm-55 reload
fi
if [ -f /etc/init.d/php-fpm-56 ];then
service php-fpm-56 reload
fi
if [ -f /etc/init.d/php-fpm-70 ];then
service php-fpm-70 reload
fi
myDate=`date +"%Y-%m-%d %H:%M:$S"`
echo "★[$myDate] PHP內(nèi)存回收成功!"
echo '------------------------------------------------------------------------------';看完了這篇文章,相信你對怎么\通過計劃任務定期釋放PHP占用的內(nèi)存有了一定的了解,想了解更多相關知識,歡迎關注創(chuàng)新互聯(lián)行業(yè)資訊頻道,感謝各位的閱讀!
網(wǎng)頁標題:怎么\通過計劃任務定期釋放PHP占用的內(nèi)存-創(chuàng)新互聯(lián)
文章源于:http://chinadenli.net/article26/cejccg.html
成都網(wǎng)站建設公司_創(chuàng)新互聯(lián),為您提供靜態(tài)網(wǎng)站、用戶體驗、小程序開發(fā)、品牌網(wǎng)站制作、網(wǎng)站設計、定制網(wǎng)站
聲明:本網(wǎng)站發(fā)布的內(nèi)容(圖片、視頻和文字)以用戶投稿、用戶轉(zhuǎn)載內(nèi)容為主,如果涉及侵權請盡快告知,我們將會在第一時間刪除。文章觀點不代表本網(wǎng)站立場,如需處理請聯(lián)系客服。電話:028-86922220;郵箱:631063699@qq.com。內(nèi)容未經(jīng)允許不得轉(zhuǎn)載,或轉(zhuǎn)載時需注明來源: 創(chuàng)新互聯(lián)
猜你還喜歡下面的內(nèi)容