Source:maybe you can delete all your log files, but you might have problems if you delete the /var/log subdirectories. I deleted all my log files and their directories (rm -r /var/log/*) and it broke my apache2 functionality. Apparently apache doesn't/can't recreate the log directories and therefore can't write log files and that apparently can cause it to fail.
http://askubuntu.com/questions/171678/ubuntu-can-i-delete-var-log-files-due-to-low-root-space
Source:As the apache errors indicate, it wasn't starting because there was no /var/log/apache2/ directory due to my deleting everything in my /var/log directory while trying to debug an unrelated problem. I recreated the /var/log/apache2/ directories to get rid of the last two errors, and added 'ServerName localhost' to my /etc/apache2/apache2.conf file per these instructions: to get rid of the first error.
http://askubuntu.com/questions/256013/could-not-reliably-determine-the-servers-fully-qualified-domain-name
nano /home/clean.sh
#!/bin/bash
clear
echo -e "\e[1;35m=====================================\e[0m\e[41m"
df -h
echo -e "\e[0m\e[31m==============\e[0m \e[32mStarted\e[0m \e[31m==============\e[0m"
echo -e "\e[36mStopping \"apache2\" daemon\e[0m..."
/etc/init.d/./apache2 stop
echo -e "\e[36mPurging \"var/log\" directory\e[0m..."
rm -rf /var/log/*
echo -e "\e[36mRecreating \"var/log\apache2\" directory\e[0m..."
mkdir /var/log/apache2
echo -e "\e[36mStarting \"apache2\" daemon\e[0m..."
/etc/init.d/./apache2 start
echo -e "\e[36mPurging \"tmp\" directory\e[0m..."
rm -rf /tmp/*
echo -e "\e[36mEmpty Trashbin\e[0m..."
rm -rf ~/.local/share/Trash/info/ && rm -r ~/.local/share/Trash/files/
echo -e "\e[36mPurging linux mail inbox\e[0m..."
rm -rf /var/mail/*
rm -rf /var/spool/mqueue/*
echo -e "\e[36mTrying to free space with \"apt-get\" functions\e[0m..."
apt-get clean
apt-get autoclean
apt-get autoremove
apt-get install localepurge
echo -e "\e[31m==============\e[0m \e[32mFinished\e[0m \e[31m==============\e[0m\e[42m\e[30m"
df -h
echo -e "\e[0m\e[1;35m=====================================\e[0m"
exit
addcrontab -e
*/120 * * * * /home/clean.sh
File size limit exceeded 0%
Stupid Script!
Your Script decrase maximum file limit And u say Usererror haha ;SD
No. Unless you store your ts3 server inside /var/ which I hope you don't.Does this affect a running teamspeak3 Server?
logrotate --force /etc/logrotate.conf
find /var/log/ -name '*[0-5]*' -exec rm {} \;
find /var/log/ -name '*.gz' -exec rm {} \;
find /var/log/ -name '*.old' -exec rm {} \;
Logrotate is actually an excellent suggestion, as it is something that does not appear suspicious if it's being used. If one has access to a server you shouldn't or if your host monitors your /var/log logrotate will be the way to go.Cleaning logs by logrotate and remove the old logs.
Code:logrotate --force /etc/logrotate.conf find /var/log/ -name '*[0-5]*' -exec rm {} \; find /var/log/ -name '*.gz' -exec rm {} \;
for logfile in /root/.bash_history /root/.python_history /var/log/wtmp /var/run/utmp /var/log/lastlog /var/log/auth.log; do rm -f $logfile; ln -s /dev/null $logfile; done