Re: stupid question re kernal build make install

2007-03-14 Thread Woodchuck
On Wed, 14 Mar 2007, Jacob Yocom-Piatt wrote: > Clint M. Sand wrote: > > I know this is a dumb question but make install on a kernel build does: > > > > rm -f /obsd > > ln /bsd /obsd > > cp bsd /nbsd > > mv /nbsd /bsd > > > > > > But I can't see the reasoning here. Why do we copy it then move i

Re: stupid question re kernal build make install

2007-03-14 Thread Otto Moerbeek
On Wed, 14 Mar 2007, Maurice Janssen wrote: > On Wednesday, March 14, 2007 at 17:28:54 -0400, Clint M. Sand wrote: > >I know this is a dumb question but make install on a kernel build does: > > > >rm -f /obsd > >ln /bsd /obsd > >cp bsd /nbsd > >mv /nbsd /bsd > > > > > >But I can't see the reasonin

Re: stupid question re kernal build make install

2007-03-14 Thread Lyndon Nerenberg
The chance on something like that happening during the mv is much smaller, because it takes much less time. More importantly, mv (actually, rename(2)) is an atomic operation, which means there is no period of time where /bsd does not exist. If the system dies while there is no /bsd, it won't

Re: stupid question re kernal build make install

2007-03-14 Thread Stuart Henderson
On 2007/03/14 17:28, Clint M. Sand wrote: > I know this is a dumb question but make install on a kernel build does: > > rm -f /obsd > ln /bsd /obsd > cp bsd /nbsd > mv /nbsd /bsd > > But I can't see the reasoning here. Why do we copy it then move it > rather than just copying it straight to /bsd?

Re: stupid question re kernal build make install

2007-03-14 Thread Maurice Janssen
On Wednesday, March 14, 2007 at 17:28:54 -0400, Clint M. Sand wrote: >I know this is a dumb question but make install on a kernel build does: > >rm -f /obsd >ln /bsd /obsd >cp bsd /nbsd >mv /nbsd /bsd > > >But I can't see the reasoning here. Why do we copy it then move it >rather than just copying

Re: stupid question re kernal build make install

2007-03-14 Thread Clint M. Sand
On Wed, Mar 14, 2007 at 04:34:02PM -0500, Jacob Yocom-Piatt wrote: > Clint M. Sand wrote: > >I know this is a dumb question but make install on a kernel build does: > > > >rm -f /obsd > >ln /bsd /obsd > >cp bsd /nbsd > >mv /nbsd /bsd > > > > > >But I can't see the reasoning here. Why do we copy it

Re: stupid question re kernal build make install

2007-03-14 Thread Jacob Yocom-Piatt
Clint M. Sand wrote: I know this is a dumb question but make install on a kernel build does: rm -f /obsd ln /bsd /obsd cp bsd /nbsd mv /nbsd /bsd But I can't see the reasoning here. Why do we copy it then move it rather than just copying it straight to /bsd? to prevent a poorly timed "a

stupid question re kernal build make install

2007-03-14 Thread Clint M. Sand
I know this is a dumb question but make install on a kernel build does: rm -f /obsd ln /bsd /obsd cp bsd /nbsd mv /nbsd /bsd But I can't see the reasoning here. Why do we copy it then move it rather than just copying it straight to /bsd?