From owner-freebsd-questions Thu Jan 14 13:13:55 1999 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id NAA09253 for freebsd-questions-outgoing; Thu, 14 Jan 1999 13:13:55 -0800 (PST) (envelope-from owner-freebsd-questions@FreeBSD.ORG) Received: from oolong.camellia.org (oolong.camellia.org [206.119.96.100]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id NAA09244 for ; Thu, 14 Jan 1999 13:13:51 -0800 (PST) (envelope-from alan@oolong.camellia.org) Received: (from alan@localhost) by oolong.camellia.org (8.8.8/8.8.8+Erasmus) id QAA08368; Thu, 14 Jan 1999 16:12:36 -0500 (EST) (envelope-from alan) Date: Thu, 14 Jan 1999 16:12:36 -0500 (EST) References: <8Jan1999.042549.Alan@LCS.MIT.EDU> <19990108192746.B63511@scientia.demon.co.uk> <9Jan1999.220116.Alan@LCS.MIT.EDU> <19990110041754.A94335@scientia.demon.co.uk> <14Jan1999.003932.Alan@LCS.MIT.EDU> <19990114081649.4801.qmail@alice.gba.oz.au> Message-Id: <14Jan1999.130537.Alan@LCS.MIT.EDU> From: Alan Bawden To: gjb@acm.org CC: freebsd-questions@FreeBSD.ORG In-reply-to: <19990114081649.4801.qmail@alice.gba.oz.au> (message from Greg Black on Thu, 14 Jan 1999 18:16:48 +1000) Subject: Re: messing with /etc/rc.conf Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG Date: Thu, 14 Jan 1999 18:16:48 +1000 From: Greg Black > OK, so I've now established that the first guy to try answering my > question didn't actually know that something other than `sh' > occasionally reads and re-writes the contents of /etc/rc.conf. No, you've established that you asked an ambiguous question. I have included my original question below. I confess it seems very clear to me. The only fault I can find is that I neglected to mention that I was running version 2.2.6. It was not clear in the original that the actual file was modified, I wrote: "something will occasionally re-write this to read". I intended the word "re-write this" to mean "modified the file" -- sorry if that wasn't clear. (No irony here, I really -am- sorry -- if I had thought of that mis-interpretation of my words, I would certainly have written it differently.) rather it seemed that some process that parsed the file was making a mistake -- but since only sh parses the file in normal operation, there was a mystery. Since I had observed that something -did- occasionally modify the file, I just wanted to know what that was. I wrote my question under the assumption that somebody on freebsd-questions would actually know what that program was, when it ran, and how it parsed the file. And in fact, to someone who knows what program it is that mungs rc.conf, my two questions were no-brainers -- the answers are: (1) /stand/sysinstall, and (2) rc.conf.local is not touched. I expected to get a few bogus answers from people who thought that rc.conf was just a shell script, but I figured that eventually my question would be noticed by someone who actually knew what the program was. After waiting six days, I tried again. At the start I tried to remind people that I wasn't just confused by shell syntax. My reference to the previous fellow who tried to help me out was not intended to be offensive, just a statement of fact. He tried to be helpful, for which I am grateful, but ultimately he admitted that he had no idea what program it was that modified it. ... lots of people would have instantly said: "either some malicious human used an editor on the file or some ill-advised human used some other program that felt it had the right to modify the file -- find out which it was and don't let it happen again." Well, something like that. Given that the program in question was written by Jordan Hubbard, they probably would have left out the "ill-advised" part. ----- Begin ----- Message-Id: <8Jan1999.042549.Alan@LCS.MIT.EDU> From: Alan Bawden Sender: Alan@LCS.MIT.EDU To: freebsd-questions@freebsd.org Subject: messing with /etc/rc.conf There is a comment at the front of /etc/rc.conf that says: # All arguments must be in double or single quotes. It's not clear exactly what the restriction here is, but I recently learned that if rc.conf contains the following: ntpdate_flags="-bs $(awk '$1 == "server" || $1 == "peer" {print $2}' /etc/ntp.conf)" something will occasionally re-write this to read: ntpdate_flags="-bs $(awk '$1 == " So I have two questions: 1. What is it that makes this change. And what exactly are the rules it applies when parsing/rewriting the file? 2. If I move the setting of ntpdate_flags into /etc/rc.conf.local, will whatever this thing is leave it alone there? ----- End ----- To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message