1 |
On Fri, Mar 25, 2011 at 9:16 AM, Philip Webb <purslow@××××××××.net> wrote: |
2 |
> 110325 Alex Schuster wrote: |
3 |
>> Philip Webb writes: |
4 |
>>> In /var/log/ there is a file wtmp , which is 24 MB & owned by utmp |
5 |
>>> . It is in binary format & is updated when I reboot. |
6 |
>>> Can anyone explain what it's for & whether it cb safely deleted ? |
7 |
>> It tracks logins, you can use the 'last' command to show its contents. |
8 |
>> I'm pretty sure it's safe to delete it, |
9 |
>> but you should create it as empty file afterwards |
10 |
>> -- 'touch /var/log/wtmp' -- , |
11 |
>> otherwise the system will not make use of it again. |
12 |
>> If wou want to get the space, I suggest compressing the file, |
13 |
>> it will be much much smaller then: |
14 |
>> |
15 |
>> bzip2 -v /var/log/wtmp |
16 |
>> touch /var/log/wtmp |
17 |
>> |
18 |
>> Also see the man pages for wtmp and last. |
19 |
> |
20 |
> Thanks & to the other respondent. I'll decide how to handle it. |
21 |
|
22 |
"man wtmp" will also give you much detailed info about what's in the |
23 |
file, which programs write to it, how to use it in your own programs, |
24 |
etc. in case you're interested in that. |