OT: Solaris Jumpstart from FreeBSD

Brian J. McGovern bmcgover at cisco.com
Mon Aug 15 19:25:22 GMT 2005


I realize this email is _really_ old, but did anyone ever get jumpstarts
running from FreeBSD? I'm looking at setting up a jumpstart server here, and
have a number of FreeBSD boxes laying around that would be easier to use
than my Solaris sytems.

	-Brian

 > 
 > --Apple-Mail-1--227213988
 > Content-Transfer-Encoding: 7bit
 > Content-Type: text/plain;
 > 	charset=US-ASCII;
 > 	format=flowed
 > 
 > Am 16.01.2004 um 08:20 schrieb Crist J. Clark:
 > 
 > > Before I hack away at the Solaris Jumpstart tools to get them to run
 > > on FreeBSD, I was wondering if anyone here has done or can provide a
 > > pointer to someone who has already done this and is willing to share
 > > scripts, patches, etc.
 > >
 > > Sorry for being off topic, but I figured if any FreeBSD community knew
 > > of something like this, this one would.
 > 
 > I always wanted to do that, but never found the time to fully set up a 
 > server.
 > 
 > One problem that I did need to solve: extract the data from a install 
 > cd image. The standard Solaris CDs have one ISO in the usual location, 
 > but are also labelled and have UFS filesystems on them, which are 
 > neccessary for booting. The attached little tool will print out block 
 > numbers from the image so that one can extract the filesystems with dd. 
 > Sample output:
 > 
 > $ ./prtdklabel </Backup/iso/sol-9-u3-sparc-v1.iso
 > Label:     CD-ROM Disc for SunOS Solaris Installation
 > Cylinders: 2048
 > Heads:     1
 > Sectors:   640
 > VTOC version:    1
 >     Partitions:  8
 >     Volume:
 >     Partition #0: Tag: 0x0004, Flag: 0x0010
 >         Cyls:               0,          951
 >         Blocks:             0,       608640
 >     Partition #1: Tag: 0x0002, Flag: 0x0010
 >         Cyls:             951,          928
 >         Blocks:        608640,       593920
 >     Partition #2: Tag: 0x0000, Flag: 0x0000
 >         Cyls:            1879,            8
 >         Blocks:       1202560,         5120
 >     Partition #3: Tag: 0x0000, Flag: 0x0000
 >         Cyls:            1887,            8
 >         Blocks:       1207680,         5120
 >     Partition #4: Tag: 0x0000, Flag: 0x0000
 >         Cyls:            1895,            8
 >         Blocks:       1212800,         5120
 >     Partition #5: Tag: 0x0000, Flag: 0x0000
 >         Cyls:            1903,            8
 >         Blocks:       1217920,         5120
 >     Partition #6: Tag: 0x0000, Flag: 0x0000
 >         Cyls:               0,            0
 >         Blocks:             0,            0
 >     Partition #7: Tag: 0x0000, Flag: 0x0000
 >         Cyls:               0,            0
 >         Blocks:             0,            0
 > 
 > HTH,
 > Stefan
 > 
 > 
 > --Apple-Mail-1--227213988
 > Content-Transfer-Encoding: 7bit
 > Content-Type: text/plain;
 > 	x-unix-mode=0644;
 > 	name="prtdklabel.c.txt"
 > Content-Disposition: attachment;
 > 	filename=prtdklabel.c.txt
 > 
 > /*
 >  * Print a Sun disklabel structure
 >  *
 >  */
 > 
 > #include <sys/types.h>
 > #include <sys/dklabel.h>
 > #include <stdio.h>
 > 
 > 
 > int
 > compute_cksum(struct dk_label *l)
 > {
 > 	uint16_t *lb = (uint16_t *)l;
 > 	int i;
 > 	uint16_t cksum = 0;
 > 	
 > 	for (i=sizeof(*l)/sizeof(*lb); i; i--) {
 > 		cksum ^= *lb++;
 > 	}
 > 	return cksum;
 > }
 > 
 > 
 > int
 > main(int argc, char*argv[])
 > {
 > 	struct dk_label l;
 > 	int i;
 > 	int bpc;
 > 	
 > 	read(0, &l, sizeof(l));
 > 	
 > 	if (l.dkl_magic != DKL_MAGIC) {
 > 		printf("Invalid magic %x, not a disk label.\n", l.dkl_magic);
 > 		return 1;
 > 	}
 > 	if (compute_cksum(&l) != 0) {
 > 		printf("Correct magic, but incorrect checksum, invalid disk lab
el.\n");
 > 		return 1;
 > 	}
 > 	bpc = l.dkl_nsect*l.dkl_nhead;
 > 	printf("Label:     %-.*s\n", LEN_DKL_ASCII, l.dkl_asciilabel);
 > 	printf("Cylinders: %d\n", l.dkl_ncyl);
 > 	printf("Heads:     %d\n", l.dkl_nhead);
 > 	printf("Sectors:   %d\n", l.dkl_nsect);
 > 	printf("VTOC version:    %d\n", l.dkl_vtoc.v_version);
 > 	printf("    Partitions:  %d\n", l.dkl_vtoc.v_nparts);
 > 	printf("    Volume:      %-.*s\n", LEN_DKL_VVOL, l.dkl_vtoc.v_volume);
 > 	for (i=0; i<l.dkl_vtoc.v_nparts; i++) {
 > 		printf("    Partition #%d: Tag: 0x%04x, Flag: 0x%04x\n", 
 > 			i, 
 > 			l.dkl_vtoc.v_part[i].p_tag, 
 > 			l.dkl_vtoc.v_part[i].p_flag);
 > 		printf("        Cyls:    %12d, %12d\n", l.dkl_map[i].dkl_cylno,
 l.dkl_map[i].dkl_nblk/bpc);
 > 		printf("        Blocks:  %12d, %12d\n", l.dkl_map[i].dkl_cylno*
bpc, l.dkl_map[i].dkl_nblk);
 > 	}
 > 	
 > 	return 0;
 > }
 > 
 > --Apple-Mail-1--227213988
 > Content-Transfer-Encoding: 7bit
 > Content-Type: text/plain;
 > 	charset=US-ASCII;
 > 	format=flowed
 > 
 > 
 > 
 > 
 > -- 
 > Stefan Bethke <stb at lassitu.de>   Fon +49 170 346 0140
 > 
 > --Apple-Mail-1--227213988
 > Content-Type: text/plain; charset="us-ascii"
 > MIME-Version: 1.0
 > Content-Transfer-Encoding: 7bit
 > Content-Disposition: inline
 > 
 > _______________________________________________
 > freebsd-sparc64 at freebsd.org mailing list
 > http://lists.freebsd.org/mailman/listinfo/freebsd-sparc64
 > To unsubscribe, send any mail to "freebsd-sparc64-unsubscribe at freebsd.org"
 > 
 > --Apple-Mail-1--227213988--
 > 


More information about the freebsd-sparc64 mailing list