From owner-freebsd-questions Wed Apr 24 8:38: 4 2002 Delivered-To: freebsd-questions@freebsd.org Received: from icarus.slightlystrange.org (icarus.slightlystrange.org [62.190.193.173]) by hub.freebsd.org (Postfix) with ESMTP id 2E49737B62C for ; Wed, 24 Apr 2002 08:33:45 -0700 (PDT) Received: from danielby by icarus.slightlystrange.org with local (Exim 3.12 #1 (Debian)) id 170Olg-0002Zw-00 for ; Wed, 24 Apr 2002 16:33:16 +0100 Date: Wed, 24 Apr 2002 16:33:16 +0100 From: Daniel Bye To: freebsd-questions@FreeBSD.org Subject: Re: Existing Kernel Options Message-ID: <20020424153315.GB9479@icarus.slightlystrange.org> Reply-To: dan@slightlystrange.org Mail-Followup-To: freebsd-questions@FreeBSD.org References: <000101c1eb9d$33014a80$6401a8c0@intranet.toomuch.com.au> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <000101c1eb9d$33014a80$6401a8c0@intranet.toomuch.com.au> User-Agent: Mutt/1.3.27i 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 On Wed, Apr 24, 2002 at 10:34:52PM +0800, Michael Watson wrote: > Hi All > > I am looking to do my first kernel build, so this may be a silly question > but hopefully somebody can help. > Excellent! Get stuck in! It's easy - ever tried to do a kernel rebuild under Linux? I only ever got one to work, and that for only 10 minutes before locking solid. That's why I moved to FreeBSD, almost three years ago, and I have never regretted it. > I don't think the kernel distributed on my CD-ROM was compiled with the same > kernel options as in the GENERIC configuration file. I don't want to lose > any existing options when I build my new kernel. > I can almost guarantee that the kernel installed when you built the system was made from the GENERIC config file. (Provided you got an "official" CDROM, of course...) If your GENERIC kernel config file has been edited since, there will be a mismatch. > Is there a way to find out what kernel options the existing kernel was > compiled with? Not sure - without the file it's hard to say. Try this, to see if the config file was compiled into the finished image (not the case for the GENERIC kernel, but it may shed some light): strings -n 3 /kernel | sed -n 's/^___//p' > MYKERNEL Then look at MYKERNEL - if there's anything in it, that's the config that was used to build your kernel. Try building a kernel from the GENERIC file - if it is the same size etc as your running kernel, you can be fairly certain it was built with the GENERIC config. If anyone knows how to "reverse engineer" the kernel to reconstruct the config file, I would be interested in seeing how... Dan To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message