cvs commit: src/etc/rc.d hostid
Pawel Jakub Dawidek
pjd at FreeBSD.org
Mon May 21 18:51:15 UTC 2007
On Mon, May 21, 2007 at 11:10:12AM -0700, Doug Barton wrote:
> Ralf S. Engelschall wrote:
> >rse 2007-05-21 11:44:13 UTC
> > FreeBSD src repository
> > Modified files:
> > etc/rc.d hostid Log:
> > Adjust UUID lower-case translation from straight-forward tr(1)
> > usage to an equivalent csh(1) usage as tr(1) stays in /usr/bin and
> > /etc/rc.d/hostid has just the root filesystem (and this way mainly the
> > tools in /bin) available.
> > I've chosen csh(1) here as the string manipulation tools available in
> > /bin is extremely limited and the (only) alternative ed(1) usage would
> > have been a lot more complicated or even might require a temporary file.
> > Revision Changes Path
> > 1.4 +2 -1 src/etc/rc.d/hostid
> >http://www.FreeBSD.org/cgi/cvsweb.cgi/src/etc/rc.d/hostid.diff?&r1=1.3&r2=1.4&f=h
>
> I really don't like the idea of having an rc.d script depend on csh. We don't have any other examples of that, and I don't really want to start down that road. I would
> appreciate it if you'd do a little more research into ways that this could be done with the tools available.
>
> Meanwhile, I've attached a patch that simplifies the hostid_hardware() quite a bit, and has the added virtue of only calling csh if it's needed.
The main purpose of this script is to use UUID given via SMBIOS when
it's valid and you just removed the code responsible for correctness
checking.
I also don't really see the win of using csh(1) only sometimes - you
still have to use it, but now when there is a bug or will be a bug, it
will be harder to identify.
I'm also not happy with using csh(1), but I agree with rse@'s change in
general.
--
Pawel Jakub Dawidek http://www.wheel.pl
pjd at FreeBSD.org http://www.FreeBSD.org
FreeBSD committer Am I Evil? Yes, I Am!
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 187 bytes
Desc: not available
Url : http://lists.freebsd.org/pipermail/cvs-src/attachments/20070521/a997e78d/attachment.pgp
More information about the cvs-src
mailing list