Operating System - HP-UX
1856511 Members
29857 Online
104113 Solutions
New Discussion

Re: How to rebuild kernel?

 
SOLVED
Go to solution
Teck Sim
Frequent Advisor

How to rebuild kernel?

I am doing a cold-install of HP-UX 11, and I want to keep the same old kernel parameters after the cold-installation.
How can I rebuild/re-configure back to the same kernel parameters?
I did ftp a copy of /stand/system files to my c drive.
Thanks.
5 REPLIES 5
Pete Randall
Outstanding Contributor

Re: How to rebuild kernel?

I use the /stand/system file to go through SAM and change all the parameters one by one.

Pete

Pete
PIYUSH D. PATEL
Honored Contributor

Re: How to rebuild kernel?

Hi,

You can make a copy of /stand/system amd /stand /vmunix and then use SAM.

You can also use command line :

Make any kernel parameter changes with 'kmtune':

# kmtune -s = -S /stand/build/system

#cd /stand/build
# /usr/lbin/sysadm/system_prep -s system
( Prepares new system file )
# /usr/sbin/mk_kernel -s system
( Prepares new kernel )
# mv /stand/system /stand/system.prev
( Move old system file )
# mv /stand/vmunix /stand/vmunix.prev
( Move old kernel file )
# mv /stand/dlkm /stand/dlkm.vmunix.prev
# mv /stand/build/system /stand/system
( Move new system file to /stand )
# kmupdate /stand/build/vmunix_test
( Moves new kernel into place )
# shutdown -ry 0

Piyush
Martin Johnson
Honored Contributor

Re: How to rebuild kernel?

Copy the file back to /stand/system, the run /usr/sbin/mk_kernel. See "man mk_kernel" for more info.

HTH
Marty
PIYUSH D. PATEL
Honored Contributor
Solution

Re: How to rebuild kernel?

Hi,

You can always move the old system.prev and vmunix.prev to the /stand directory as system and vmunix and then reboot the system. You machine will run with the old kernel.

Do this in single user mode :

#cp /stand/vmunix /stand/vmunix.old ( Make copy of new kernel )

#mv /stand/vmunix.prev /stand/vmunix

#cp /stand/system /stand/system.old
#mv /stand/system.prev /stand/system

Piyush
James Wang_3
Occasional Advisor

Re: How to rebuild kernel?

Hi Mr. Patel,

I found you command line kernel update to be usefule.

I am challenged to write an automation script to rebuild kernel for orcle 9i installation over 4 dozen production lx 3000. My question is:

1. For tunable parameters part, can one just update /stand/system for it to take effect without rebuild the kernel or using kmtune?

2. If kernel must be rebuild, then is it ok for me just to use unix editor to make change over system files? Do I still have to use system_prep -s system.

3. What is the difference between /stand/system and /stand/build/system?

4. What if new kernel built on my automation script don't work but the server was told to reboot. Use cd?

Thanks in advance.