Sorry, my bad - I assumed that it was only natural for newcomers to copy the file and edit it afterwards instead of creating it from scratch to override some values. Obviously, this assumption was based on my ignorance and therefore wrong. You are also right to point out that to "copy the lines" is not the same as "copy the whole file" - I must have missed this particular distinction.
The only thing I can put in my defense is that I might have been mislead to some extent by a particular piece of text - http://www.openbsd.org/faq/upgrade47.html#rc.conf. Of course, it is outdated and should not be taken for granted in regards to version 5.4, but it was one of few leads I've found when trying to fix my problem with rc.conf.local file. Nevertheless, please forgive me for my foolish assumptions and for taking your time. And thanks for clearing things up. V. On Sun, Feb 9, 2014 at 9:14 PM, Peter N. M. Hansteen <pe...@bsdly.net> wrote: > VaZub <vasyl.zu...@gmail.com> writes: > >> Both the man page for rc.conf(8) as well as the official OpenBSD FAQ >> (10.3) suggest to avoid editing /etc/rc.conf directly and instead copy >> it to /etc/rc.conf.local and edit afterwards. > > rc.conf(8) says > > > It is advisable to leave rc.conf untouched, and instead create and edit a > new rc.conf.local file. Variables set in this file will override > variables previously set in rc.conf. > > I suppose it's possible to interpret that as an instruction to copy > /etc/rc.conf, but I think this is the first time I've heard anybody > admit to doing that. > > Leaving rc.conf alone is good advice, it's a "treat as binary" > file. When its content changes some variable the startup scripts > depend on has been added or changed, it's for a good reason that you > will find documented in the man pages, release notes and the FAQ. > > It never occured to me to create rc.conf.local by copying the entire > rc.conf, mainly because it makes perfect sense that a file with > override values only needs to contain your local customizations, > anything else is noise that is likely to be a source of trouble > later. This may or may not have been due to actually reading rc.conf > and finding the line sourcing rc.conf.local at some point, but anyway > it's been a while since my first contact with any of this. Once you > have actually read rc.conf (if not earlier) it should be fairly > obvious that rc.conf.local only needs to contain the variables you > actually need to change from the default values. > >> Yet it seems both fail to mention, that in order to prevent your >> system from going ballistic after doing this, you should also >> comment out or delete a particular line of code in >> /etc/rc.conf.local, namely this one: "[ -f /etc/rc.conf.local ] && >> . /etc/rc.conf.local". Not good, especially for those who do follow >> official instructions and still suddenly find themselves with a >> broken system on their hands for no apparent reason. > > You did not in fact read the FAQ too carefully, did you? > http://www.openbsd.org/faq/faq10.html says > > "We strongly suggest you do not alter /etc/rc.conf itself. Instead, > create or edit the file /etc/rc.conf.local, copy just the lines you > need to change from /etc/rc.conf and adjust them as you like. This > makes future upgrades easier -- all the changes are in the one file > that isn't touched during upgrade." > > "copy just the lines you need" -- how can this be made any clearer? > > - Peter > > -- > Peter N. M. Hansteen, member of the first RFC 1149 implementation team > http://bsdly.blogspot.com/ http://www.bsdly.net/ http://www.nuug.no/ > "Remember to set the evil bit on all malicious network traffic" > delilah spamd[29949]: 85.152.224.147: disconnected after 42673 seconds.