On Monday 08 April 2002 12:04 am, Kenny Simpson wrote:
<snip>
>
> This gets the system up and running just fine, but for
> some reason /oldroot will not unmount.  It says it is
> still in use.  Any ideas?
>
Kenny,

Ask and ye shall receive.

The reason is that the dhclient script has the leases file open. I ran across 
the same issue while developing the rc.local script for the Power Mac 
project. I rearranged the order in which things were done in order to 
copy the old leases file to the /tmp filesystem, but you may be able to 
simply kill the dhclient process and restart it on the new filesystem.

The excerpt from my rc.local script is attached.

Hope this helps!
--Skip 

#========================================================
#
# we need to kill dhclient before we can free the RAMDRIVE
#
PID=`ps -ae|grep dhclient|head -n 1 -|cut -c 1-5`
kill -9 $PID

#
# We have two ramdisks now. we need to copy the lease imfo from the old
# RAMDRIVE to the new one, so we can free up the old one.
#
mkdir /tmp/compiled
mkdir /tmp/var
mkdir /tmp/var/run
mkdir /tmp/var/state
mkdir /tmp/var/state/dhcp
mkdir /tmp/var/log
mkdir /tmp/var/lock
mkdir /tmp/var/lock/subsys
mkdir /tmp/var/lib
mkdir /tmp/var/lib/xkb
mkdir /tmp/mnt

cp /oldroot/var/state/dhcp/dhclient.leases /tmp/var/state/dhcp

umount /oldroot

# Following command should be on one line!
dhclient -sf /etc/dhclient-script -cf /etc/dhclient.conf -lf  
/tmp/var/state/dhcp/dhclient.leases eth0 1>/tmp/junk 2>&1

#==========================================================

_____________________________________________________________________
Ltsp-discuss mailing list.   To un-subscribe, or change prefs, goto:
      https://lists.sourceforge.net/lists/listinfo/ltsp-discuss
For additional LTSP help,   try #ltsp channel on irc.openprojects.net

Reply via email to