boot loader

2007-10-26 Thread Thomas Ching
Hi, I am trying to do the following with existing systems running 4.5.
I'd really appreciate if anyone has any hints, pointers, opinions, or
even just you should talk to this other group for me.

 

1.  Existing system: FreeBSD 4.5 based with FreeBSD boot loader
(boot0) in MBR
2.  I am trying to install a new software based on either FreeBSD
6.2 or later, or LINUX with the following restrictions:

a.  No console access
b.  No media access other than serial port, Ethernet,
existing HD with 4.5 installed (i.e. NO CD/DVD, floppy, USBetc)

3.  The hard drive (1) has enough empty space (currently not
partitioned/used) so I can create a new slice to put the new OS/software
in and boot from the new OS, but I am not sure how I can achieve that.

 

So I guess my questions are:

 

1.  Is it possible for me to boot of FreeBSD 4.5 and run an
installation over Ethernet/ftp?
2.  Is it possible for me to tar up a FreeBSD 6.2 partition, put
onto the 4.5 disk (new partition) then sysinstall (or something like
that) to make the system boot from the new partition?
3.  How would I even start thinking about doing the same with LINUX
as the new OS? :-)

 

Any information you can provide is highly appreciated. Thanks !! 

 

Thomas

 

___
freebsd-hackers@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: boot loader

2007-10-26 Thread Doug Barton
FYI, for future reference this question is really more appropriate for 
[EMAIL PROTECTED]


On Fri, 26 Oct 2007, Thomas Ching wrote:


Hi, I am trying to do the following with existing systems running 4.5.
I'd really appreciate if anyone has any hints, pointers, opinions, or
even just you should talk to this other group for me.

1.  Existing system: FreeBSD 4.5 based with FreeBSD boot loader
(boot0) in MBR


You're not planning to dual-boot anything, right? Just boot and run one 
operating system?



2.  I am trying to install a new software based on either FreeBSD
6.2 or later, or LINUX with the following restrictions:

a.  No console access
b.  No media access other than serial port, Ethernet,
existing HD with 4.5 installed (i.e. NO CD/DVD, floppy, USBetc)

3.  The hard drive (1) has enough empty space (currently not
partitioned/used) so I can create a new slice to put the new OS/software
in and boot from the new OS, but I am not sure how I can achieve that.


You definitely can't use any of the standard installation methods without 
console access. You also can't dual boot without console access.



1.  Is it possible for me to boot of FreeBSD 4.5 and run an
installation over Ethernet/ftp?


No.


2.  Is it possible for me to tar up a FreeBSD 6.2 partition, put
onto the 4.5 disk (new partition) then sysinstall (or something like
that) to make the system boot from the new partition?


You could theoretically install onto a local system, tar it up, then 
unpack it in the unused partition on your remote machine, yes. However in 
order to set the new slice bootable you'd have to then use the disk 
editor, and if you get even one thing the tiniest bit wrong, you've 
bricked it.


If I were in your position I'd do this with make world, but that's going 
to take a long time because you'll first have to update to the 
latest RELENG_4, then 5-stable, then 6-stable (at least) and then if you 
don't want to have to do this again for a while I'd update to 7.0 when it 
is released.


The other alternative is to bribe someone who is local to do the 
installation for you, which all things considered would probably be easier 
all around.


hope this helps,

Doug

--

This .signature sanitized for your protection

___
freebsd-hackers@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: Creating install CD with custom ports - how to massage INDEX file?

2007-10-26 Thread Ulrich Spoerlein
On Sun, 14.10.2007 at 09:38:14 -1000, Clifton Royston wrote:
   I've been building my own install CDs for a planned multi-server
 upgrade to 6.2Rp8 and ran into one last stumbling block this week.  I
 understand the process a lot better now than I did a few years back
 when I was doing it for 4.8, but I'm still having trouble pieceing
 together how I get my own package set onto the CD in a usable form.
 
   I built the release with NO_PORTS=yes, because I'm building the ports
 from my own CVS tree, which is a tightly pared down subset of the
 /usr/ports CVS, plus locally written software in ports format.  I've
 ensured that the tree is closed under the dependency operation (to use
 some math jargon) - essentially that means that my ports subset includes
 all the dependencies of every port I'm including and all of *its*
 run/build dependencies in the tree, even if not being built.  That
 allows the dependency graph to be calculated and the INDEX-6 file to be
 built properly.
 
   However, copying the INDEX-6 file and my private packages hierarchy
 into the CD build area doesn't work; I can read them off the CD
 post-install but sysinstall doesn't see them.  It's not a disaster
 because I can always put the CD back in after booting and install them
 then, but it would would be nice to get them all zapped in with the
 initial install.

I'm doing something similar. I work with a complete ports tree and then build a
subset of interesting packages (plus required packages). The problem with
sysinstall is, that it requires the number of the CD, where the package
resides. Since I make sure, that my ISO never exceeds one volume I decided to
drop the volume number from the sysinstall INDEX altogether

Here's the Makefile targets creating the packages and ISO

packages:
# prepare lots of stuff
# ...
.for pkg in ${PACKAGES}
chroot ${TLR} /create_packages.sh ${pkg}
.endfor
## Build a stripped down INDEX file, usually done by 
/usr/ports/Tools/scripts/release/scrubindex.pl, yet it would
## require manual handling. We assume all dependant packages are there (we just 
built them after all), so we simply
## take all lines where we have a package for it.
## First we grab the name of the indexfile (can be INDEX, INDEX-5, INDEX-6, 
etc.), then we loop over all entries of
## of the global index and test -f if the package was built, if so, we print 
the line.
(INDEX=`sh -c chroot ${TLR} /usr/bin/make -f /usr/ports/Makefile -V 
INDEXFILE`; \
awk -F| '{if (system(test -f ${TLR}/usr/ports/packages/All/ $$1 
.tbz) == 0) print $$0}' \
${TLR}/usr/ports/$$INDEX  ${TFR}/packages/INDEX)
cd ${TFR}  find -d packages | cpio --quiet -dumpl ${TRR}/R/cdrom/disc1

iso:
# Remove CD_VOLUME from the cdrom.inf, we only ship 'disc 0'
echo CD_VERSION = ${RELEASE}  ${TRR}/R/cdrom/disc1/cdrom.inf
mkisofs -r -J -V '${RELEASE}' -publisher 'Distribution made for 
1822direkt' -o ${TFR}.iso \
-b boot/cdboot -no-emul-boot ${TRR}/R/cdrom/disc1
md5 ${TFR}.iso  ${TFR}.iso.md5

hth,
Ulrich Spoerlein
-- 
It is better to remain silent and be thought a fool,
than to speak, and remove all doubt.
___
freebsd-hackers@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: A more tenuously package-related question

2007-10-26 Thread Ulrich Spoerlein
On Tue, 23.10.2007 at 15:47:40 -1000, Clifton Royston wrote:
   I got a request to summarize my results to the list, so here's a
 quick write-up.  Based on my preliminary testing last week, pkg_replace
 looks like the right tool for package-based server maintenance.

Interesting, as I'm facing the same problem.

   One invaluable feature which was not immediately obvious from the
 description and man page is that if you give it a list of binary
 packages on the command line, it orders the updates correctly based on
 the dependencies between those packages.

Does it take the dependency graph from the already installed packages?

   Thus updating my test server with the recently security-fixed
 versions of the packages for png and ImageMagick was just a matter of
 executing:
   sudo pkg_replace png-1.2.22.tbz ImageMagick-nox11-6.3.5.10_1.tbz 
 in my package repository directory.

Where is your package repository? Does pkg_replace work by simply
setting PKG_PATH=ftp://foo/bar ?

Cheers,
Ulrich Spoerlein
-- 
It is better to remain silent and be thought a fool,
than to speak, and remove all doubt.
___
freebsd-hackers@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
To unsubscribe, send any mail to [EMAIL PROTECTED]


RE: boot loader

2007-10-26 Thread Thomas Ching
Thanks Doug for your help. I am cc'ing freebsd-questions and I will drop
freebsd-hackers from the next email on.

A few things:
1. it's not a requirement, but I'd like to keep the current partitions
(therefore dual boot) just in case anything goes wrong.
2. can you point me to more readings regarding how I might perform the
following:  However in order to set the new slice bootable you'd have
to then use the disk editor
3. I guess what you are saying is that if I go with the upgrade path
release 4-5-6, I can do in place upgrade over network.

Again appreciate your help.

Thomas 

-Original Message-
From: Doug Barton [mailto:[EMAIL PROTECTED] 
Sent: Friday, October 26, 2007 1:47 PM
To: Thomas Ching
Cc: freebsd-hackers@freebsd.org
Subject: Re: boot loader

FYI, for future reference this question is really more appropriate for 
[EMAIL PROTECTED]

On Fri, 26 Oct 2007, Thomas Ching wrote:

 Hi, I am trying to do the following with existing systems running 4.5.
 I'd really appreciate if anyone has any hints, pointers, opinions, or
 even just you should talk to this other group for me.

 1.Existing system: FreeBSD 4.5 based with FreeBSD boot loader
 (boot0) in MBR

You're not planning to dual-boot anything, right? Just boot and run one 
operating system?

 2.I am trying to install a new software based on either FreeBSD
 6.2 or later, or LINUX with the following restrictions:

   a.  No console access
   b.  No media access other than serial port, Ethernet,
 existing HD with 4.5 installed (i.e. NO CD/DVD, floppy, USBetc)

 3.The hard drive (1) has enough empty space (currently not
 partitioned/used) so I can create a new slice to put the new
OS/software
 in and boot from the new OS, but I am not sure how I can achieve that.

You definitely can't use any of the standard installation methods
without 
console access. You also can't dual boot without console access.

 1.Is it possible for me to boot of FreeBSD 4.5 and run an
 installation over Ethernet/ftp?

No.

 2.Is it possible for me to tar up a FreeBSD 6.2 partition, put
 onto the 4.5 disk (new partition) then sysinstall (or something like
 that) to make the system boot from the new partition?

You could theoretically install onto a local system, tar it up, then 
unpack it in the unused partition on your remote machine, yes. However
in 
order to set the new slice bootable you'd have to then use the disk 
editor, and if you get even one thing the tiniest bit wrong, you've 
bricked it.

If I were in your position I'd do this with make world, but that's going

to take a long time because you'll first have to update to the 
latest RELENG_4, then 5-stable, then 6-stable (at least) and then if you

don't want to have to do this again for a while I'd update to 7.0 when
it 
is released.

The other alternative is to bribe someone who is local to do the 
installation for you, which all things considered would probably be
easier 
all around.

hope this helps,

Doug

-- 

 This .signature sanitized for your protection

___
freebsd-hackers@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: boot loader

2007-10-26 Thread Matthew D. Fuller
On Fri, Oct 26, 2007 at 01:47:04PM -0700 I heard the voice of
Doug Barton, and lo! it spake thus:
 
 You could theoretically install onto a local system, tar it up, then
 unpack it in the unused partition on your remote machine, yes.
 However in order to set the new slice bootable you'd have to then
 use the disk editor, and if you get even one thing the tiniest bit
 wrong, you've bricked it.

Actually, you may be able to talk the 4.x loader into loading and
booting off the created 6.x partition.  That would save disk editing.
Still, you only get one shot at it without console access.  But you
said you have a serial port, so you could stuff a serial console on
it, which gives you lots more safety.  I moved a couple 4.x machines
to 6.x remotely with just a serial console, and I think I only ended
up needing to use the serial console on one machine where I didn't
properly nudge the loader to look in the right place.  Sure was glad
to have it there, though.


-- 
Matthew Fuller (MF4839)   |  [EMAIL PROTECTED]
Systems/Network Administrator |  http://www.over-yonder.net/~fullermd/
   On the Internet, nobody can hear you scream.
___
freebsd-hackers@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
To unsubscribe, send any mail to [EMAIL PROTECTED]


RE: boot loader

2007-10-26 Thread Thomas Ching
Thanks for sharing your thoughts/opinions; I am glad that there are at
least some things that I can try.

Thomas

-Original Message-
From: Matthew D. Fuller [mailto:[EMAIL PROTECTED] 
Sent: Friday, October 26, 2007 3:48 PM
To: Doug Barton
Cc: Thomas Ching; freebsd-hackers@freebsd.org
Subject: Re: boot loader

On Fri, Oct 26, 2007 at 01:47:04PM -0700 I heard the voice of
Doug Barton, and lo! it spake thus:
 
 You could theoretically install onto a local system, tar it up, then
 unpack it in the unused partition on your remote machine, yes.
 However in order to set the new slice bootable you'd have to then
 use the disk editor, and if you get even one thing the tiniest bit
 wrong, you've bricked it.

Actually, you may be able to talk the 4.x loader into loading and
booting off the created 6.x partition.  That would save disk editing.
Still, you only get one shot at it without console access.  But you
said you have a serial port, so you could stuff a serial console on
it, which gives you lots more safety.  I moved a couple 4.x machines
to 6.x remotely with just a serial console, and I think I only ended
up needing to use the serial console on one machine where I didn't
properly nudge the loader to look in the right place.  Sure was glad
to have it there, though.


-- 
Matthew Fuller (MF4839)   |  [EMAIL PROTECTED]
Systems/Network Administrator |  http://www.over-yonder.net/~fullermd/
   On the Internet, nobody can hear you scream.
___
freebsd-hackers@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
To unsubscribe, send any mail to [EMAIL PROTECTED]