From owner-freebsd-questions Thu Apr 4 16:18:26 2002 Delivered-To: freebsd-questions@freebsd.org Received: from albatross.prod.itd.earthlink.net (albatross.mail.pas.earthlink.net [207.217.120.120]) by hub.freebsd.org (Postfix) with ESMTP id 3BF2E37B41B; Thu, 4 Apr 2002 16:18:17 -0800 (PST) Received: from pool0517.cvx21-bradley.dialup.earthlink.net ([209.179.194.7] helo=mindspring.com) by albatross.prod.itd.earthlink.net with esmtp (Exim 3.33 #1) id 16tHQk-0006lY-00; Thu, 04 Apr 2002 16:18:15 -0800 Message-ID: <3CACED2E.475367F2@mindspring.com> Date: Thu, 04 Apr 2002 16:17:50 -0800 From: Terry Lambert X-Mailer: Mozilla 4.7 [en]C-CCK-MCD {Sony} (Win98; U) X-Accept-Language: en MIME-Version: 1.0 To: Koroush Saraf Cc: freebsd-questions@FreeBSD.ORG, freebsd-hackers@FreeBSD.ORG Subject: Re: Help: FreeBSD 4.3 to 4.5 upgrade problem using sysinstall script References: <001001c1dc02$11f15b00$3017c581@BSDWIN2KKOROUSH> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Koroush Saraf wrote: > Can someone please tell me what I'm doing wrong and also tell me how to > script this? You have a number of bad assumptions. Here is the correct procedure: 1) Upgrade one system. This is necessary to obtain the correct /stand/sysinstall program and the /dev/MAKEDEV and /dev/MAKEDEV.local scripts, which will not come in automatically, if you do not boot from the install media. 2) Copy these files and make a tarball, e.g.: cd /tmp mkdir terry cd terry cp /stand/sysinstall . cp /dev/MAKEDEV* . tar cvf ../terry.tar . 3) Mount and NFS export the CDROM; this will be more efficient. If you don't want to do that, then you will need to mount the CDROM on a directory named "4.5-RELEASE", and export its *parent* as your FTP export directory on the machine. The main problem here is that the sysinstall looks for the subdirectory named after the release for the sysinstall version you are running. It is a lot easier to just use NFS. 4) Mount the CDROM via NFS on the machine to be upgraded. 5) Copy over the tarball and unpack it on the target system, e.g.: cd /tmp mkdir terry cd terry tar xvf ~/terry.tar 6) Run the sysinstall from the tarball, e.g.: ./sysinstall THIS IS VERY IMPORTANT! 7) If you need local sources, and don't have any local modifications that you care about losing, then empty /usr/src; otherwise, the sources will be left alone, and will be old and stale. 8) Upgrade using the sysinstall "upgrade" option; tell it you are using locally mounted media, and point it to where you mounted the CDROM via NFS. DO NOT REBOOT YET! 9) Modify /etc/pam.conf to add the ssh lines (refer to the system you updated using the normal process). A failure to this means that SSH will stop working; if you are updating rack-mount equipment, this could lock you out! 10) Update and run the MAKDEV scripts. A sysinstall based upgrade done this way will not properly update things; so: cp MAKEDEV* /dev cd /dev sh MAKEDEV all 11) Reboot. This system should be done. Go on to the next system. In theory, you can script the sysinstall upgrade process, along with the MAKEDEV and the pam.conf stuff. Whether this is worthwhile depends on the number of systems that you have to deal with this way (the sysinstall scripting is dark and mysetrious, IMO). -- Terry To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message