View Source

h2. Boot into the 32-bit Kernel on a 64-bit Platform

Sometimes you need to boot into the 32-bit kernel on a 64-bit platform. Perhaps you want to develop and test a 32-bit application. Or perhaps you have developed a device driver for the Solaris OS. In general, Solaris device drivers must work both in 32-bit mode and in 64-bit mode.

To boot into the 32-bit kernel on a 64-bit platform, edit the GRUB menu. Either edit the file {{/boot/grub/menu.lst}} and reboot, or reboot and enter {{e}} at the grub menu.

For Solaris 10, the lines in the {{menu.lst}} file look something like this:

{code}title Solaris 10 11/06 s10x_u3wos_10 X86
root (hd0,2,a)
kernel /platform/i86pc/multiboot
module /platform/i86pc/boot_archive{code}

Change the {{kernel}} line to this:

{code}kernel /platform/i86pc/kernel/unix{code}

For Solaris Express (nevada, SXDE, SXCE, OpenSolaris), the lines in the {{menu.lst}} file look something like this:

{code}title Solaris Express Community Edition snv_79 X86
kernel$ /platform/i86pc/kernel/$ISADIR/unix
module$ /platform/i86pc/$ISADIR/boot_archive{code}

Change the {{kernel}} and {{module}} lines to this:

{code}kernel$ /platform/i86pc/kernel/unix
module$ /platform/i86pc/boot_archive{code}

Save and reboot.

To make this change persistent across reboots, become the super user and make this change using:

{code}eeprom boot-file="kernel/unix"{code}

For more information on the GRUB menu, see [GRUB's user interface|http://www.gnu.org/software/grub/manual/grub.html#Interface] on the GNU web site.

If you are using a 64-bit system and you are not certain whether you are currently running the 64-bit kernel or the 32-bit kernel, use the {{-k}} option of the {{isainfo}}(1) command. The {{-v}} option reports all instruction set architectures of the system. The {{-k}} option reports the instruction set architecture that is currently in use.

{code}$ isainfo -v
64-bit amd64 applications
sse4.1 ssse3 cx16 mon sse3 sse2 sse fxsr mmx cmov amd_sysc cx8 tsc fpu
32-bit i386 applications
sse4.1 ssse3 ahf cx16 mon sse3 sse2 sse fxsr mmx cmov sep cx8 tsc fpu
$ isainfo -k
amd64{code}

The individuals who post here are part of the extended Sun Microsystems community and they might not be employed or in any way formally affiliated with Sun Microsystems. The opinions expressed here are their own, are not necessarily reviewed in advance by anyone but the individual authors, and neither Sun nor any other party necessarily agrees with them.

Copyright 1994-2009 Sun Microsystems, Inc.
Powered by Atlassian Confluence
Sun Guidelines on Public Discourse Privacy Policy Terms of Use Trademarks Site Map Employment Investor Relations Contact