Operating System - HP-UX
1833056 Members
2302 Online
110049 Solutions
New Discussion

Re: make dev kernel same as production kernel?

 
SOLVED
Go to solution
justin_83
Advisor

make dev kernel same as production kernel?

I have two N-class boxes running 11.0. They both have the same hardware config and same patch level. How do I take the kernel from the production box and make the development box the same kernel config?
Is it as simple as ftp the /stand/vmunix and reboot?
10 REPLIES 10

Re: make dev kernel same as production kernel?

Hi,

The best way to take output using kmtune
and compare the production with dev use
perl / sh scripts to compare both, and
make changes dev kernel as of production
server.

I will try to send the perl scripts, which
one I used for comparision.

Regards

sekar.
William Wong_2
Trusted Contributor
Solution

Re: make dev kernel same as production kernel?

If they are the same exact hardware and software then you can create a system file from the production system with the
/usr/lbin/sysadm/system_prep -v -s system and
copy that file to your development system and
use mk_kernel to create a new kernel with the
same exact kernel values as your production system and reboot that system.
Uday_S_Ankolekar
Honored Contributor

Re: make dev kernel same as production kernel?

Best way is to use ignite tape. Create make_tape_recovery from prodcution box and use it on deve box

-USA..
Good Luck..
Caesar_3
Esteemed Contributor

Re: make dev kernel same as production kernel?

Steven E. Protter
Exalted Contributor

Re: make dev kernel same as production kernel?

I would not ftp the vmunix file.

Even on identical systems there are differences there.

what /stand/vmunix > /tmp/vmdiff

Do it on both systems and you may find differences.

Certainly the serial number on the machines is different.

What I would do is open sessions on both machines, and go through the kernel parameters one by one and make sure they all match, formulas included.

Then you can generate a kernel with some degree of confidence.

SEP
Steven E Protter
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
Massimo Bianchi
Honored Contributor

Re: make dev kernel same as production kernel?

Hi,
a little trick.


If, besides all other wise suggestion, you do want do make the kernel alike (which i don't suggest, prod server always have different needs), here is a fast way:


rcp PROD:/stand/system PROD:/stand/system.good
rcp PROD:/stand/vmunix PROD:/stand/vmunix.good
rcp DEV:/stand/system PROD:/stand/system

go to PROD server

cd stand
mk_kernel
kmupdate
shutdown -r now


This way we will take with us the kernel parameter.


HTH,
Massimo
twang
Honored Contributor

Re: make dev kernel same as production kernel?

I do this through manual rebuilding kernel method:
on the prod env:
# cd /stand/build
# /usr/lbin/sysadm/system_prep -s system

# vi system
(make your changes if required on dev env)

save the file and ftp to the dev server,
on dev env:
# mk_kernel -s system
# kmupdate
# cd /
# shutdown -r -y now

Hope this can help!
Bruno Vidal
Respected Contributor

Re: make dev kernel same as production kernel?

Hi,
Another solution to retrive the configuration file of a kernel is to retrieve it directly from the kernel you want to duplicate itself:
#echo 'system_data?X
.+4
.?s' | adb /stand/vmunix > /tmp/system.orig

Then use this system file to create a new kernel on the other system.

Btw, I don't recommant to ftp the kernel to the other system, because it can need some patched libraries that the other system don't have (example: ps command, ipcs, nfs, etc...)

Cheers.
justin_83
Advisor

Re: make dev kernel same as production kernel?

Thank you all for your input... I'm going to go with Twang's suggestion.
justin_83
Advisor

Re: make dev kernel same as production kernel?

I also see that Wong had the same suggestion earlier so i adjusted his points....
so you could say i'm going with Twang Wong answer...