What command clears all logs on FreeBSD 8.1?

Hi, I would like to know what commands in terminal that will clear all logs on the system.

Also, is their any good software out there that optimize the system?

I am looking for the same effect that a program called bleachbit does.
 
hockey97 said:
Hi, I would like to know what commands in terminal that will clear all logs on the system.
There isn't any. If anything it's done with rm(1).

Also, is their any good software out there that optimize the system?
Most of the tuning is done automatically. Have a read through tuning(7).
 
SirDice said:
There isn't any. If anything it's done with rm(1).


Most of the tuning is done automatically. Have a read through tuning(7).

So then how do you guys manage to keep the logs from taking over your hard drive?

I notice that once it fills a emtpy text file. It then stores that into a compressed file.
Then creates a new empty text file. The process repeats.

I seen like 20 logs for my mail server. I then deleted them all. Then after like 2 weeks. Found the mail logs at 5 logs compressed.

I then looked at more logs like system logs, gnome logs etc. I notice there are a bunch of logs. so, I deleted them manually. I thought there might be a command to delete all logs or some way to either config the logs so it dosen't log things often.

I just don't want my server to get cluttered with logs. I notice with my windows xp computer. using, bleachbit and glary utilities. I am able to keep my computer running smooth. I never was able to do this until I found these programs which mostly just deletes log files and temp files and internet history etc.

So, I assumed that freebsd FreeBSD needs the same kind of programs to keep the computer running smooth.
 
hockey97 said:
I just don't want my server to get cluttered with logs. I notice with my windows xp computer. using, bleachbit and glary utilities. I am able to keep my computer running smooth. I never was able to do this until I found these programs which mostly just deletes log files and temp files and internet history etc.

So, I assumed that freebsd FreeBSD needs the same kind of programs to keep the computer running smooth.

FreeBSD is not Windows. If the logs are taking up too much space, tweak the configuration file, but generally the logs are small.

I've had servers running for multiple years without having to go manually deleting log files, just letting the log rotation do its thing.

Just because Windows slows down and acts randomly at the drop of a hat, it doesn't mean proper operating systems do.
 
throAU said:
FreeBSD is not Windows. If the logs are taking up too much space, tweak the configuration file, but generally the logs are small.

I've had servers running for multiple years without having to go manually deleting log files, just letting the log rotation do its thing.

Just because Windows slows down and acts randomly at the drop of a hat, it doesn't mean proper operating systems do.

Oh, ok thanks. So Freebsd FreeBSD manages the logs by itself? The reason I ask is that I built my own server. I put freebsd FreeBSD 8.1 and I created two websites. I am trying to get into the hosting business. I got a UPS system. I only got one hard drive for now. I plan to going into the hosting business and one of my websites is a social network type site.

I only have a server graded 1 TB hard drive. I think I got like 993 GB of space. So, I have the room. It's just that right now trying to get the system ready to go live. I am just nervious about the hosting space. I am thinking right now to get a NAS external hard drive. Then start using that external hard drive to save all user information on there.

So, do you guys think I shouldn't worry too much about the logs? It won't have any huge effect not like windows. I notice windows they don't compress them. They just have one file that keeps going and going. I do know on windows machines there are many logs and each set of logs can slow down the computers performance. That is why I have bleachbit and glary utilities. Keeps my windows machine fast like a brand new computer.
 
Code:
[jrose@proxy ~]$ df -h

Filesystem     Size    Used   Avail Capacity  Mounted on
/dev/da0s1a    495M    277M    178M    61%    /
devfs          1.0K    1.0K      0B   100%    /dev
/dev/da0s1e    495M    2.7M    453M     1%    /tmp
/dev/da0s1f     35G     17G     15G    53%    /usr
/dev/da0s1d    1.4G    895M    454M    66%    /var
devfs          1.0K    1.0K      0B   100%    /var/named/dev

[jrose@proxy ~]$ uname -a
FreeBSD proxy.wa.xxxxxxx.com.au 7.4-STABLE FreeBSD 7.4-STABLE #5: Tue Jan  3 16:33:57 WST 2012     
root@proxy.wa.xxxxxx.com.au:/usr/obj/usr/src/sys/GENERIC  i386
[jrose@proxy ~]$

This machine above has been running continuously as a squid proxy (it's a VM, on a SAN, its not a single 40gb disk :D lol) for about 3 years now.

I've never had to go manually delete log files. I think I may have needed to add apache's (for WPAD serving) and SQUID's log files to the log rotation, but other than that, it's been a largely hands-off affair.
 
Keep an eye on the sizes of the log files. If they look like they are growing too fast for your comfort, change the settings in /etc/newsyslog.conf so that the rotation happens more often.
 
Also: never manually remove logfiles, because it doesn't remove the space referenced by them. Either use the system tools (newsyslog) or copy /dev/null to a logfile to zero it, e.g.

[cmd=]cp /dev/null /var/log/biglogfile[/cmd]
 
Yes, thanks guys for the inputs. I am just kind of nervous. I am trying to get into the hosting business. I am using freeBSD FreeBSD 8.1 on my server. I have to start learning the system. I been a heavy windows user. Then started to get into linux via ubuntu. Had fun with that. Then I bought a high end server well parts dirt cheap. Then assembled them. Then when it came to installing the OS. I wanted to put ubuntu server on the server. Yet, failed since I found out ubuntu dosen't support the hardware that I have. Then I looked at my options. The only best one was to use FreeBSD 8.1.

I never was 100% interested in learning freeBSD FreeBSD 8.1 but now since I notice starting a hosting business. I need to know the ins and out of this OS since I have really no choice but to use it. The logs right now aren't that big. Just need to know how to manage them. I mean if I get a lot of users to go on my websites and I host many websites. I need to know how to keep logs neat and not have them take over too much space on my hard drive.

Right now I got at least 900 GB of space. I own a 1 terabyte server type hard drive. So, I got a lot of room but websites will be saved on this server mostly. I never really think I ever seen in my life any website being at least 100 GB. So I do got alot of space.

I just thought now is the time to know if logs will be a huge problem. I do know with windows it's a huge performance problem. You need to delete them. Otherwise your computer starts to slow down performance wise.
 
Back
Top