35
User Group Informix France Déployer Informix Olivier Bourdin [email protected] Lundi 4 avril 2011 Lundi 4 avril 2011

Ugif 04 2011 déployer informix

  • Upload
    ugif

  • View
    293

  • Download
    2

Embed Size (px)

Citation preview

Page 1: Ugif 04 2011   déployer informix

User Group Informix France

Déployer Informix

Olivier [email protected]

Lundi 4 avril 2011Lundi 4 avril 2011

Page 2: Ugif 04 2011   déployer informix

User Group Informix France

Overview

� What is the Embeddability Toolkit ?� Why do we need the Embeddability Toolkit� Overview of the Embeddability Toolkit Components

• Informix Deployment Assistant (DA)– Overview– Prerequisites– Limitations/Considerations– GUI Usage– Command Line Usage

• Informix Deployment Utility (DU)– Overview– Limitations/Considerations– Usage– Configuration File

Page 3: Ugif 04 2011   déployer informix

User Group Informix France

What is the Embeddability Toolkit ?

�Informix Embeddability Toolkit empowers the customer with the tools and the information they need for easy automation of reduced footprint Informix deployments.

�It includes:• Informix Deployment Assistant (DA)• Informix Deployment Utility (DU)• DU's Configuration File• Additional Scripts for Embedding Informix• A Tutorial on an end to end Deployment Solution

Page 4: Ugif 04 2011   déployer informix

User Group Informix France

Why do we need deployment utility ?

�Quickly and easily deploy pre-configured Informix to multiple locations.

�Upgrade multiple instances to a different fixpack

�Embed an Informix application on multiple computers and want to reduce application installation

Page 5: Ugif 04 2011   déployer informix

User Group Informix France

Why do we need deployment utility ?

�Create a snapshot with initialized dbspaces -> can deploy product+instance with dbspaces

�Tune only first instance as a template and deploy i t on multiple computers

• Perfect to install on mutiple developer systems

Page 6: Ugif 04 2011   déployer informix

User Group Informix France

Limitations

�Difficulty to create a snapshot with dbspaces of 24x7 production instance

– Copy of chunks will block the instance

– Raw devices not supported

Page 7: Ugif 04 2011   déployer informix

User Group Informix France

Deployment Assistant (DA)

Package it.

Deployment Assistant (DA)

Page 8: Ugif 04 2011   déployer informix

User Group Informix France

Deployment Assistant (DA)

�Enables users to take snapshots of Informix instances and / or data spaces for deployment on other target computers.

�Allows for reduction of the packaged instance to the user's minimum desired configuration

�Provides both GUI and Command-Line Interfaces developed using Java/Eclipse SWT

� Snapshots produced by DA are ready for use by the Deployment Utility (DU) for deployment on the target computers

Page 9: Ugif 04 2011   déployer informix

User Group Informix France

DA: Prerequisites

� Java Runtime Edition version 1.6 (6.0) or later.The Informix 11.70 server's Krakatoa JRE can be used to satisfy this requirement. It is located at <INFORMIXDIR>/extend/krakatoa/jre/bin

� In order to package an instance's data, users must have connect privileges to the sysadmin database

Page 10: Ugif 04 2011   déployer informix

User Group Informix France

DA: Limitations/Considerations

� Unsupported Platforms• HP• zLinux

�No current support for data on RAW devices�Currently works with instances on the local system

only�Must be able to make a trusted connection to local

Instance.�Does not resolve dependencies between features

when deselecting feature to exclude from deployment.

Page 11: Ugif 04 2011   déployer informix

User Group Informix France

DA: Limitations/Considerations

�start the Deployment Assistant, run the following command in <INFORMIXDIR>/bin:

• ifxdeployassist

• ifxdeployassist.app/Contents/MacOS/ ifxdeployassist on Mac OS

�Instance must be online

�DA will block instance like external backup

Page 12: Ugif 04 2011   déployer informix

User Group Informix France

DA: GUI Instance Detection�Once automatically

detected, information regarding the instance is displayed

• Yes – DA will create a snapshot based on the displayed instance

• No – prompts for connection information for the instance to create a snapshot of

Page 13: Ugif 04 2011   déployer informix

User Group Informix France

DA: GUI Connection Parameters�Supply connection

information for the instance to create a snapshot of.

�Displayed whenever:• An instance is not

automatically detected• No was selected when an

instance was automatically detected

Page 14: Ugif 04 2011   déployer informix

User Group Informix France

DA: GUI Snapshot Location�Specify the location in

which the snapshot of the Informix instance and/or data will be saved.

�The archive formats available are:

• BZip2 (*.tar.bz2)• GZip (*.tar.gz)• Tar (*.tar)• Zip (*.zip)

Page 15: Ugif 04 2011   déployer informix

User Group Informix France

DA: GUI Instance Features�The features of the

instance for which a snapshot is being created are shown here

�Deselect the features, or even specific files in each feature, that should not be included in the snapshot

Page 16: Ugif 04 2011   déployer informix

User Group Informix France

DA: GUI Instance Data�Select whether or not the

Data Spaces associated with the instance should be included in the snapshot

�Shows the Chunks associated with each Data Space and their locations

�NOTE: Limited to Cooked files only.

Page 17: Ugif 04 2011   déployer informix

User Group Informix France

DA: GUI Snapshot Configuration

�A summary of the snapshot to be created is presented

�Selecting Next will begin creation of the snapshot with the selected features and/or data

Page 18: Ugif 04 2011   déployer informix

User Group Informix France

DA: GUI Packaging Snapshot

�The progress page shows the details of the packaging of the snapshot

Page 19: Ugif 04 2011   déployer informix

User Group Informix France

DA: GUI Packaging Summary

�The summary page shows the result of the snapshot creation

� If DB Spaces were selected for the snapshot, they are saved with the archive name specified, with “ _db”appended to the name

Page 20: Ugif 04 2011   déployer informix

User Group Informix France

DA: CMD Usage

�The Command-Line Interface can be used to perform all the actions mentioned before, exceptselect specific feature

�Pass the -h (--help) option to the ifxdeployassist command to view the syntax

Page 21: Ugif 04 2011   déployer informix

User Group Informix France

DA: CMD Snapshot Creation

�The -c option is required to execute in command-line mode

�Once the required options have been provided, the snapshot is created automatically

Page 22: Ugif 04 2011   déployer informix

User Group Informix France

DA: CMD Examples

� ifxdeployassist -cvi infmx22:dana:9444 -f snapshot1.zipCreates a snapshot of the infmx22 instance only and saves it to <current dir>/snapshot1.zip

� ifxdeployassist -cvdi informix11:dana:9344:DRDA -a TARCreates a snapshot of the informix11 instance and its data and saves the following files: <current dir>/informix11.tar

� ifxdeployassist -cdnf /tmp/snapshot12 -i server3:dana:9945Creates a snapshot of the server3 instance's data only and saves it to /tmp/snapshot12_db.tar.gzip

Page 23: Ugif 04 2011   déployer informix

User Group Informix France

Deployment Utility (DU)

Deploy it.

Deployment Utility (DU)

Page 24: Ugif 04 2011   déployer informix

User Group Informix France

DU: Overview

�Standalone tool to rapidly deploy packaged Informix instances in an embedded environmen

� Introduced in 11.50.xC6

�Configuration file: $INFORMIXDIR/etc/ifxdeploy.con f

�Command line tool with customization options during deployment

ifxdeploy

[-config <configfile>] [-clone] [-extractcmd <command>][-verbose] [-l <logfile>] [-p <password>] [-silent] [-sqliport <port>][-drdaport <port>] [-servernum <num>] [-rootpath <rootdbs>][-file <tgz file>] [-relocate <path>] [-force] [-keepdis][-start [<secs>] [-autorecommend] [-y]

Page 25: Ugif 04 2011   déployer informix

User Group Informix France

DU: Typical usage

1. Install and configure a template Informix instance

2. Use Deployment Assistant (DA) to Package the contents of $INFORMIXDIR/* and the relevant directory containing the dbspaces, tempdbspaces, etc.

3. Update $INFORMIXDIR/etc/ifxdeploy.conf

4. Use $INFORMIXDIR/bin/ifxdeploy to rapidly deploy the template Informix instances on the target

Page 26: Ugif 04 2011   déployer informix

User Group Informix France

DU: Configuration File

� All dbspaces, tempdbspaces should reside in one dire ctory

� No support for raw devices

� $ONCONFIG.autorec file is an alternate configuration file which may require server initialization for certain param eters to comeinto effect

� The “ -autorecommend” option leverages new technology in 11.70 which takes into account hardware performance for c alculating parameter values (for example: disk read/write spee ds)

Page 27: Ugif 04 2011   déployer informix

User Group Informix France

DU: Limitations/Considerations

� With DU, you can use a config file ifxdeploy.conf as an alternative to command-line arguments and environment variables

� If the same options are in the config file and on th e command line, the command line takes precedence

� If the same options are in the config file and in th e environment, the config file takes precedence

� A sample config file ifxdeploy.conf is included on the Infomix server at $INFORMIXDIR/etc on Linux and UNIX and at %INFORMIXDIR%\etc on Windows.

Page 28: Ugif 04 2011   déployer informix

User Group Informix France

DU: ifxdeploy.conf usage example

� Deploys an instace from demo_on.tgz� Relocates data spaces to /data/demo_on� New rootpath is set to /data/demo_on/online_root� Starts the instance after deployment� Additional parameters are passed via ifxdeploy.conf

file� Prints verbose messages

./ifxdeploy -verbose -config ifxdeploy.conf -f demo_on.tgz

-rootpath /data/demo_on/online_root -relocate /data/demo_on

-start

Page 29: Ugif 04 2011   déployer informix

User Group Informix France

DU: autorecommendfeature

� Section for “-autorecommend” option in ifxdeploy.conf

BEGIN AUTORECOMMENDMAXCPUS (Max number of CPUs to use, Default = 1)

MAXDISK (Max amount of disk space to use, Default = 2048 MB )

MAXMEM (Max amount of memory to use, Default = 512 MB)

MAXUSERS (Max number of OLTP users, Default = 32)

MAXDSUSERS (Max number of DSS users, Default = 4)

RTO_SERVER_RESTART (Real time objective, Default = 60 secs)

END AUTORECOMMEND

� The alternate configuration file is saved as $INFORMIXDIR/etc/$ONCONFIG.autorec

Page 30: Ugif 04 2011   déployer informix

User Group Informix France

DU: Example for -autorecommend

$INFORMIXDIR/etc/$ONCONFIG.autorec will have the calculated settings for...

Rootdbs (ROOTSIZE)Physical log (PHYSFILE, PHYSBUFF)Logical log (LOGFILES, LOGSIZE, LOGBUFF)CPU parameters (MULTIPROCESSOR, VPCLASS cpu, VP_MEMORY_CACHE_KB)AIO/Cleaners (CLEANERS, DIRECT_IO)Locks (LOCKS)Shared memory (SHMVIRTSIZE, SHMADD)Online Index Memory (ONLIDX_MAXMEM)PDQ parameters (DS_MAX_QUERIES, DS_TOTAL_MEMORY, DS_MAX_SCANS,

DS_NONPDQ_QUERY_MEM)Logical Recovery parameters (ON_RECVRY_THREADS,OFF_RECVRY_THREADS)Bufferpool/LRU parameters (BUFFERPOOL)

Page 31: Ugif 04 2011   déployer informix

User Group Informix France

ifx_silent_deploy

SHHHHHHH!

ifx_silent_deploy

Page 32: Ugif 04 2011   déployer informix

User Group Informix France

ifx_silent_deploy

https://www -304.ibm.com/support/docview.wss?uid=swg21446737

Page 33: Ugif 04 2011   déployer informix

User Group Informix France

ifx_silent_deploy

� Silent deployment of Informix server instance and i ts data spaces is a two-step process:

– Deploy data spaces from the snapshot that was creat ed using DA.

– Deploy the Informix server instance, optionally rel ocate the data spaces, and start the instance by using DU.

� ifx_silent_deploy.sh and ifx_silent_deploy.cmd are example scripts that show you how to perform these tasks silently.

Page 34: Ugif 04 2011   déployer informix

User Group Informix France

ifx_silent_deploy.sh <relocate_option> <srvpkg> <dbspkg>

<currloc> [<newloc>]

relocate_option - relocate to relocate data spaces; norelocate not to relocate data

spaces

srvpkg - Name of the server package

dbspkg - Name of the data spaces package

currloc - Current location of data spaces

newloc - New deployment location of the data spaces when relocating.

This argument is not required if you are not relocating data spaces.

ifx_silent_deploy.sh relocate demo_on.tgz demo_on_db.tgz

/data/IBM/demo/server /data/demo_on

ifx_silent_deploy.sh usage

Page 35: Ugif 04 2011   déployer informix

User Group Informix France

MerciMerci

Olivier [email protected]

Lundi 4 avril 2011Lundi 4 avril 2011