Date: Sun, 2 Dec 2012 01:37:56 +0200 From: Konstantin Belousov <kostikbel@gmail.com> To: Hiroki Sato <hrs@freebsd.org> Cc: yanegomi@gmail.com, rc@freebsd.org, current@freebsd.org Subject: Re: RFC: sysctl -f filename Message-ID: <20121201233756.GS3013@kib.kiev.ua> In-Reply-To: <20121202.082150.896017277887885294.hrs@allbsd.org> References: <20121202.015048.1122480556487090170.hrs@allbsd.org> <CAGH67wTC50X1M2uUo0g=Nm6PmpOXPzYnp4tbXDCQyA9eOKB%2B7Q@mail.gmail.com> <CAGH67wShpcmOKhc09%2BMP5c-AOm7EAPG%2BGqv=J0PRq0sGuTzKRQ@mail.gmail.com> <20121202.082150.896017277887885294.hrs@allbsd.org>
next in thread | previous in thread | raw e-mail | index | archive | help
--lfL9iWt62hyVv4Jn Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Sun, Dec 02, 2012 at 08:21:50AM +0900, Hiroki Sato wrote: > Garrett Cooper <yanegomi@gmail.com> wrote > in <CAGH67wShpcmOKhc09+MP5c-AOm7EAPG+Gqv=3DJ0PRq0sGuTzKRQ@mail.gmail.co= m>: >=20 > ya> On Sat, Dec 1, 2012 at 2:10 PM, Garrett Cooper <yanegomi@gmail.com> w= rote: > ya> > Why change the tool when we can change the rc script to do the > ya> > right thing? I have a patch I'm working on to resolve this (you hit= an > ya> > itch I've been meaning to scratch for a little while). > ya> > ya> This should work. I also refactored the script to get it down to > ya> 80 columns. I've attached the debug output and the diff for the debug > ya> version of the script. >=20 > You will find out the following test case does not work (this is one > of the test strings I used): >=20 > kern.domainname=3D"c$EDITOR.\"\ hoge\ \"\#hoge2\\$ \# h$$\#oge"# >=20 > The reason why I changed sysctl(8) was that the rc.d/sysctl script > was too complex and slow even if it could support meta characters in > shell script syntax. I created several prototypes as script but > noticed that keeping consistency was quite difficult and > maintainability was poor due to tricky handling of variables. >=20 > Although my patch in the previous email does not support meta > characters completely, I still think it is more reasonable to > implement this functionality on the sysctl(8) side. >=20 > -- Hiroki I fully agree with the proposal to add the -f switch to the sysctl(8). This is consistent with several other administrative tools. Putting the ability to parse and apply arbitrary sysctl.conf-like file into=20 the rc script is weird. --lfL9iWt62hyVv4Jn Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.19 (FreeBSD) iQIcBAEBAgAGBQJQupTTAAoJEJDCuSvBvK1BSLEQAIKuOn4rfK6jKjfEL1dbQV5k Ioqan+cvl4GoDZVBfF+NL6U22qBQdbuRa0rV8V1SnG8UYc/hjqd65Xxl00G6CRAb zhuR1kccpxjp2IN4wyYdGecXi00iRqdJeWGinL03Z/NpCr0zrgMR9RA5zM9KcJrZ vofQbkY/28VqsxxS6S/i8avbV3060T81EeupzFW5olv8Gf97M3nDiRJbP0S4EwXV QXs3rIONv+Y8+Ny00sVDfyBxfQ66nRYbmvlJcs/5SNW7cfk6BGg+4g81hNhmGlCb L4SKBMoiW+1Ls1AxhFOFUSFCL4xVINP6px4LqL/TJYR0mTrIYe7YCPDih4KYkIL4 U8DTbCbZTwBegnExNyDNeDgBug/JyIMrjBfFJeoNhKc6Kqw2inL5eO5lY49bE0hB ypiy8FXNjU0cW0OwrC8TvANstJ4Gif98DKjc9OufoatK7LKCDLgxPJ0gtV6mL+V4 605dXtURT6sIWgrrmSbYWVukUlEF7IOgCU/S2OZzz3mrsFC1kTlpOKboH+TLvLd8 OWaDJMnNEj5IOyQUJJ5RSAAKD9K9Pyy2StOLQOtoMCa5FdFANtVLnY3IXfh+wP2+ dqb2Wxg6r9h1iseaETCKxsDtroIw5GDqnYx1qZIUozD26q0hoiF5POn26jZKIMZ9 R7ym6rVAvCTGZlxULVyk =2uEK -----END PGP SIGNATURE----- --lfL9iWt62hyVv4Jn--
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20121201233756.GS3013>