Thursday, January 27, 2011

Informix Tips

Informix command-line tips:

export CLIENT_LOCALE=EN_US.UTF8
export DB_LOCALE=EN_US.UTF8
: ensures any client can correctly connect to the server (see: UNIX setup guide)

oninit
: starts the server

onmode -ky
: kills the server

onstat -
: display server online status

oncheck -pr
: displays detailed status including dataspace info

onstat -g env all
: displays database server start-up environment settings

Executing:
cd /opt/IBM/informix
mkdir dbspaces
cd dbspaces
touch chunk1
chmod 660 chunk1
onspaces -c -d datadbs -p /opt/IBM/informix/dbspaces/chunk1 -o 0 -s 204800

will create a data space named chunk1 with size 204800 but will give a warning message like below which you can ignore.

Verifying physical disk space, please wait ...
Space successfully added.

** WARNING ** A level 0 archive of Root DBSpace will need to be done.


UPDATE: Here's a useful IBM article on Informix usage: http://www.ibm.com/developerworks/data/zones/informix/library/techarticle/0305parker/0305parker.html

2 comments:

  1. "oninit -iy" will initialize disk space.
    Note that this initialization process will destroy all data that your database server currently manages[1] so be careful with the "-i" option!

    [1] http://publib.boulder.ibm.com/infocenter/idshelp/v115/index.jsp?topic=%2Fcom.ibm.adref.doc%2Fids_adr_0395.htm

    ReplyDelete