如何定期清理服务器里面的垃圾?

如何定期清理服务器里面的垃圾?,第1张

清理服务器里面的垃圾用了不少软件还是自己设置的方式好用

下面几个方法绝对让你服务器飞起来,不借助任何软件就可以达到一劳永逸的结果

1找清理程序

找一些清理和优化系统的批处理程序,这个网上很多,直接搜索就可以了,如果对dos命令

熟悉也可以自己写批处理程序,我这里有一份直接粘贴这里,把下面命令指令全部复制到自己新建的文本文档中,改文本文档的txt后缀为bat,这样我们就制作完成一个系统清理批处理程序了

@echo off

echo 服务优化正在处理,请稍等

echo 正在清除系统垃圾文件,请稍等

del /f /s /q %systemdrive%\tmp

del /f /s /q %systemdrive%\_mp

del /f /s /q %systemdrive%\log

del /f /s /q %systemdrive%\gid

del /f /s /q %systemdrive%\chk

del /f /s /q %systemdrive%\old

del /f /s /q %systemdrive%\recycled\

del /f /s /q %windir%\bak

del /f /s /q %windir%\prefetch\

rd /s /q %windir%\temp & md %windir%\temp

del /f /q %userprofile%\cookies\

del /f /q %userprofile%\recent\

del /f /s /q "%userprofile%\Local Settings\Temporary Internet Files\"

del /f /s /q "%userprofile%\Local Settings\Temp\"

del /f /s /q "%userprofile%\recent\"

echo 清除系统完成 开始优化系统! 

sc config ALG start= DEMAND

sc config AppMgmt start= DEMAND

sc config AudioEndpointBuilder start= AUTO

sc config Audiosrv start= AUTO

sc config BFE start= AUTO

sc config BITS start= AUTO

sc config Browser start= AUTO

sc config CertPropSvc start= DEMAND

sc config clr_optimization_v2050727_32 start= DEMAND

sc config COMSysApp start= DEMAND

sc config CryptSvc start= AUTO

sc config DcomLaunch start= AUTO

sc config Dhcp start= AUTO

sc config Dnscache start= AUTO

sc config dot3svc start= DEMAND

sc config EapHost start= DEMAND

sc config EventSystem start= AUTO

sc config fdPHost start= DEMAND

sc config FDResPub start= DEMAND

sc config FontCache3000 start= DEMAND

sc config gpsvc start= AUTO

sc config hidserv start= DEMAND

sc config hkmsvc start= DEMAND

sc config idsvc start= DEMAND

sc config IKEEXT start= AUTO

sc config IPBusEnum start= DEMAND

sc config KeyIso start= DEMAND

sc config LanmanServer start= AUTO

sc config LanmanWorkstation start= AUTO

sc config lltdsvc start= DEMAND

sc config lmhosts start= AUTO

sc config MMCSS start= AUTO

sc config MpsSvc start= AUTO

sc config msiserver start= DEMAND

sc config napagent start= DEMAND

sc config Netlogon start= DEMAND

sc config Netman start= DEMAND

sc config netprofm start= AUTO

sc config NetTcpPortSharing start= DISABLED

sc config NlaSvc start= AUTO

sc config NOD32krn start= AUTO

sc config nsi start= AUTO

sc config PlugPlay start= AUTO

sc config ProfSvc start= AUTO

sc config RasAuto start= DEMAND

sc config RasMan start= DEMAND

sc config RemoteAccess start= DISABLED

sc config RpcLocator start= DEMAND

sc config RpcSs start= AUTO

sc config SamSs start= AUTO

sc config SCardSvr start= DEMAND

sc config SCPolicySvc start= DEMAND

sc config SENS start= AUTO

sc config SharedAccess start= DISABLED

sc config ShellHWDetection start= AUTO

sc config slsvc start= AUTO

sc config SLUINotify start= DEMAND

sc config SNMPTRAP start= DEMAND

sc config SSDPSRV start= DEMAND

sc config SstpSvc start= DEMAND

sc config SysMain start= AUTO

sc config TapiSrv start= DEMAND

sc config TBS start= AUTO

sc config Themes start= AUTO

sc config THREADORDER start= DEMAND

sc config TrustedInstaller start= DEMAND

sc config upnphost start= DEMAND

sc config UxSms start= AUTO

sc config vds start= DEMAND

sc config W32Time start= AUTO

sc config wcncsvc start= DEMAND

sc config WcsPlugInService start= DEMAND

sc config Win>一般三至五年更换一次。传统服务器更新周期大约每五年一次,但在过去的十年里由于新技术的发展,加速了服务器更新换代的速度。那么现在服务器更新周期是多少呢?答案可能不是很简单,但有很多重要的因素促使服务器进行更新。

服务器和pc其实是两个不同的概念,首先来说下pc吧! pc就是个人电脑对吧! 那么个人的电脑的硬件配置是可以根据个人的不同来配置的,有好有坏。服务器呢,就是一个笼统的概念了,其实好的pc也是可以做为服务器来使用的,只要你们公司的访问量不大都是可以的。至于说是什么关机不关机的,那就是有关硬件的问题了,你这样想,在网吧里面的电脑工作的时间其实是很多的,这样的话就和没有关就没有区别了。希望我这样说能帮到你

对存储在服务器上的数据进行更改时,就可以备份,同时,服务器级备份应该每24小时到48小时运行一次。如果用塔迈备份一体机的话,可以自己设置备份的时间、内容,到时间了就会自动备份。也可以差异备份,当数据发生变化时就会自动备份。

服务器是专门设计的不用关机开半年都没事
但是服务器慢下来的时候
你就要重启一次就好!
这个你放心不会有事的!
不知道你的HP有多少个处理器
假如两个以上那就一直开着都会没事

在服务器没有问题的情况下:
Windows
2003系统的内存管理已经改进的很大了 一般半个月~两个月重新启动一次就可以了
Linux
需要重新启动的时间间隔就可以比较长了一般3个月到5个月
这些都得根据你的实际使用情况来看,如果客户访问速度慢了,或者服务器出问题了就需要重新启动了
我发现好像长时间不重启,系统就会出现莫名其妙的情况
比如有时候mysql突然就不能远程连接了,在服务器上重启mysql服务还是不行,但是重启下服务器就好
或者有时候一些ASP程序打开特别的慢,重启IIS也没用,但重启一下服务器就好


欢迎分享,转载请注明来源:内存溢出

原文地址: https://outofmemory.cn/zz/13379577.html

(0)
打赏 微信扫一扫 微信扫一扫 支付宝扫一扫 支付宝扫一扫
上一篇 2023-07-25
下一篇 2023-07-25

发表评论

登录后才能评论

评论列表(0条)

保存