Home > Sun Microsystems > HOWTO — clearcase under a solaris 10 zone

HOWTO — clearcase under a solaris 10 zone

February 7th, 2006 Leave a comment Go to comments

I had the sit­u­a­tion at work where I wanted to run Clearcase under a Solaris 10 zone. With a bit of coerc­ing it’s pos­si­ble to do, and doesn’t impact much of the global zone at all. If you don’t know what Clearcase is, then this still may be handy infor­ma­tion to know. Undoubt­edly, there are other appli­ca­tions that rely on load­able mod­ules.

Pre-requisites

  • You need a stock Solaris 10 install.
  • You need to have a Clearcase release repos­i­tory with at least patch 2003.06.00–29 applied.

Clearcase zone

If you don’t know how to setup a Solaris 10 zone, then you can start off with a basic one by doing the fol­low­ing. Take par­tic­u­lar note of the LOFS mount­ing of /kernel. That’s important.

% zonecfg -z zone-clearcase zone-clearcase: No such zone configured Use 'create' to begin configuring a new zone. zonecfg:zone-clearcase> create zonecfg:zone-clearcase> set autoboot=true zonecfg:zone-clearcase> set zonepath=/mnt/zone/zone-clearcase zonecfg:zone-clearcase> add net zonecfg:zone-clearcase:net> set address=10.0.0.5 zonecfg:zone-clearcase:net> set physical=hme0 zonecfg:zone-clearcase:net> end zonecfg:zone-clearcase> add fs zonecfg:zone-clearcase:fs> set dir=/kernel zonecfg:zone-clearcase:fs> set special=/kernel zonecfg:zone-clearcase:fs> set type=lofs zonecfg:zone-clearcase:fs> set options ro,nosuid zonecfg:zone-clearcase:fs> end zonecfg:zone-clearcase> info zonepath: /mnt/zones/zone-clearcase autoboot: true pool: inherit-pkg-dir: dir: /lib inherit-pkg-dir: dir: /platform inherit-pkg-dir: dir: /sbin inherit-pkg-dir: dir: /usr fs: dir: /kernel special: /kernel raw not specified type: lofs options: [ro,nosuid] net: address: 10.0.0.5 physical: hme0 zonecfg:zone-clearcase> verify zonecfg:zone-clearcase> commit zonecfg:zone-clearcase> exit %

Now install the zone, that has just been configured.

% mkdir -p /mnt/zones/zone-clearcase % chmod 700 /mnt/zones/zone-clearcase % zoneadm -z zone-clearcase install Preparing to install zone . Creating list of files to copy from the global zone. Copying <143885> files to the zone. Initializing zone product registry. Determining zone package initialization order. Preparing to initialize <1025> packages on the zone. Initialized <1025> packages on zone. Zone is initialized. Installation of <1> packages was skipped. Installation of these packages generated warnings: The file contains a log of the zone installation.

Now you can boot up the zone, login to it’s con­sole, and fin­ish off the install.

% zoneadm list -cv % zoneadm list -cv ID NAME STATUS PATH 0 global running / - zone-clearcase installed /mnt/zones/zone-clearcase % zoneadm -z zone-clearcase boot % zlogin -C zone-clearcase [Connected to zone 'zone-clearcase' console] 100/100 What type of terminal are you using? 1) ANSI Standard CRT 2) DEC VT52 3) DEC VT100

etc etc etc

Now you need to setup the clearcase repos­i­tory. I gather you have done this before, so I won’t spell it out here. Every­thing is stan­dard issue — install what you want leave out the bits you don’t want.

Once you have your clearcase repos­i­tory you will need to install clearcase first in the global zone. Don’t worry — you will be dis­abling this later on. I also gather that you have per­formed this before, so I’ll leave that out as well.

Now the fun begins. Shut­down clearcase in the global zone.

% /etc/init.d/clearcase stop

Edit the /etc/init.d/clearcase and put the fol­low­ing entries right at the start.

% /usr/sbin/modload /opt/rational/clearcase/sun5/kvm/5.10/sparcv9/mvfs % exit

Now startup ‘clearcase’ in the global zone. All this will do is load up the ker­nel mod­ule ‘mvfs’

Next you will have to restart your clearcase zone. This will ensure that this zone will be able to see the mvfs mod­ule loaded up.

% zoneadm -z zone-clearcase reboot

Now you can install clearcase into the zone you have cre­ated above. Do the nor­mal things, install what you want leave out the bits you don’t. How­ever, right at the end of the install you will pos­si­bly get some errors. You can ignore these.

And that’s it! You have one work­ing clearcase server in a zone. You can setup as many as you want as well.

No related posts.

Categories: Sun Microsystems Tags:
  1. No comments yet.
  1. No trackbacks yet.
You must be logged in to post a comment.