Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 289849 - sys-apps/openrc-0.5.x cleans wtmp on every boot
Summary: sys-apps/openrc-0.5.x cleans wtmp on every boot
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] baselayout (show other bugs)
Hardware: All Linux
: High critical (vote)
Assignee: Gentoo's Team for Core System packages
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2009-10-20 10:16 UTC by Jan Psota
Modified: 2009-11-10 20:36 UTC (History)
4 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
patch not to clean wtmp on every bootup (bootmisc-wtmp.patch,339 bytes, patch)
2009-10-20 10:18 UTC, Jan Psota
Details | Diff
0001-Don-t-wipe-wtmp.patch (0001-Don-t-wipe-wtmp.patch,684 bytes, text/plain)
2009-10-29 02:15 UTC, William Hubbs
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Jan Psota 2009-10-20 10:16:39 UTC
I think that this behavior is dangerous and it's only bootmisc typo:
-               [ -e /var/log/wtmp ] && mkutmp /var/log/wtmp
+               [ -e /var/log/wtmp ] || mkutmp /var/log/wtmp
Patch follows.

Is there a special program, that searches filesystem looking for wtmp records?
I had no backup... :-/
Comment 1 Jan Psota 2009-10-20 10:18:06 UTC
Created attachment 207654 [details, diff]
patch not to clean wtmp on every bootup
Comment 2 Giacomo Perale 2009-10-25 22:19:40 UTC
Can we please fix this disgraceful bug? OpenRC destroyed my more than 6 years old wtmp and I'm royally pissed off...
Comment 3 William Hubbs gentoo-dev 2009-10-26 18:20:46 UTC
Roy,

is openrc supposed to wipe this file on every reboot or is this a typo?

Thanks,

William
Comment 4 William Hubbs gentoo-dev 2009-10-29 02:15:45 UTC
Created attachment 208600 [details]
0001-Don-t-wipe-wtmp.patch

This version of the patch can be applied using git am.

This is a regression that was introduced between 0.4.3 and 0.5.1.

Thanks,

William
Comment 5 Wolfram Schlich (RETIRED) gentoo-dev 2009-11-01 14:10:54 UTC
can we please add files/9999/0003-dont-wipe-wtmp.patch to files/0.5.2/ as well?
Comment 6 Roy Marples 2009-11-10 20:11:27 UTC
(In reply to comment #1)
> Created an attachment (id=207654) [details]
> patch not to clean wtmp on every bootup
> 

http://roy.marples.name/projects/openrc/changeset/ebb49805fca3d53b02c3eaa992e4bed49eca365c

Thanks!
Comment 7 Jan Psota 2009-11-10 20:15:04 UTC
You are welcome :-)
Comment 8 William Hubbs gentoo-dev 2009-11-10 20:36:50 UTC
This has been fixed upstream.