Archive for the ‘English’ Category

X Server access control problems

Monday, January 7th, 2008

If you tried to run db2cc as a user diferent from the one who started the X server, you’ll probably get the error below:

Xlib: connection to ":0.0" refused by server
Xlib: No protocol specified

Assume x as the user that started the X server and y the other.

To avoid this you should run the folowing as x to give X server access to y:

xhost local:y

xForms Resources

Friday, January 4th, 2008

We will post a xForms/METS/DB2 screen-cast in this website soon. To get you prepared for this I advice you to download this firefox plugin and read the following articles:

In case you are looking for good examples you can visit this wikibook or better yet… Open your console, and create a directory in your home folder. Enter the folder and write this:

svn checkout http://xforms-examples.googlecode.com/svn/trunk/ xforms-examples-read-only

These are some great samples from Google Code. Believe me I’m saving you time with this advice. You won’t need to spend hours on badly executed examples from companies that are supposed to be building xForms implementations. Outch!?

Featured University DB2 User Group

Saturday, December 15th, 2007

It’s a great pleasure to announce that we have been elected as “Featured University DB2 User Group” by IBM. This is a great incentive to our work.

We just sorry for the small errors in the article like that fact that Marcelo is missing and I’m with the president title. There’s no president in this group just fellow students!

Anyway we hope this can bring more students to us and therefor improve even further the quality of this DB2 University User Group.

Related Link:

Express-C: Starting

Thursday, December 6th, 2007

1. Introduction

I’m writing this to help newbies starting Express-C.

First of all you’ll need to install a free version of DB2. You can get an old but functional deb here or you can click here to get an up to date how-to installation guide.

To start using Express-C and DB2 in general you need to know something about it’s hierarchy: the master’s name is DAS and the databases admins are known as instances. As you can see in the figures below, you can have multiple instances with several databases inside. There is only and only one DAS per installation and one or multiple instances (database managers).

Instances

Domain

(you should click to enlarge them)

2. Starting

In UNIX installations DAS and instances are just ordinary UNIX users with some profile specifications. So, you will need to switch to one of those users and load the profile:

geko@hydra:~$ ls /home/
cesium  dasusr1  db2fenc1  db2inst1 geko
geko@hydra:~$ su db2inst1
Password:
hydra:~$ . sqllib/db2profile
hydra:~$

Note that the creation of instances is not covered in this tutorial, however if you have installed the deb one instance was created.

Before we can work in a valid instance, we need to start one. In the deb installation you can run:

hydra:~$ /opt/ibm/db2exc/V9.1/adm/db2start
SQL1063N  DB2START processing was successful.

…and to stop it:

hydra:~$ /opt/ibm/db2exc/V9.1/adm/db2stop
SQL1064N  DB2STOP processing was successful.

3. Just a tip

If you are a smart guy (ok, lazy) you can change where you shell looks for programs. You can do that editing instance’s profile. In our case:

hydra:~$ echo "PATH=$PATH:/home/db2inst1/sqllib/bin:/home/db2inst1/sqllib/adm" \
>> ~/sqllib/db2profile

4. DB2 interpreter

This is the situation: we are logged as a valid instance and we have started it. To use the db2 interpreter and start testing db2/sql commands you should type:

hydra:~$ db2
(c) Copyright IBM Corporation 1993,2002
Command Line Processor for DB2 ADCL 9.1.2

-- omited output --

To exit db2 interactive mode, type QUIT at the command prompt. Outside
interactive mode, all commands must be prefixed with 'db2'.
To list the current command option settings, type LIST COMMAND OPTIONS.

For more detailed help, refer to the Online Reference Manual.

db2 =>

Just as an introduction I’ll show you some valid commands.

4.1 Create database

In DB2 Express-C, only Unicode databases can store both XML documents and more traditional forms of SQL. Although this tutorial doesn’t cover XML stuff you should keep that in mind because that’s the exact reason why DB2 is so powerful. All commands are similar to SQL syntax. For instance:

create database test using codeset UTF-8 territory us

and

connect to test;

create table items (

  id          int primary key not null, 

  name   varchar(30),

  stuff    xml

  );

5. Conclusion

As I’m just learning, this is all i can give you. All i can promise you is that the more i learn the more i teach.

Get in touch for more advanced tutorials.

Ubuntu 7.10 Gutsy Workarround for IBM DB2 Express-C

Sunday, November 11th, 2007

Some users are getting the following error when installing DB2 Express-C in Ubuntu 7.10

ERROR:
The required library file libstdc++.so.5 is not found on the system.
ERROR:
The required library file libaio.so.1 is not found on the system.
Check the following web site for the up-to-date system requirements
of IBM DB2 9.5

http://www.ibm.com/software/data/db2/udb/sysreqs.html

http://www.software.ibm.com/data/db2/linux/validate

/home/antonio/Desktop/exp/db2/linux/install/../bin/db2usrinf:
error while loading shared libraries: libstdc++.so.5:
cannot open shared object file: No such file or directory
[: 609: 0: unexpected operator
/home/antonio/Desktop/exp/db2/linux/install/../bin/db2langdir:
error while loading shared libraries: libstdc++.so.5:
cannot open shared object file: No such file or directory
/home/antonio/Desktop/exp/db2/linux/install/../bin/db2langdir:
error while loading shared libraries: libstdc++.so.5:
cannot open shared object file: No such file or directory
DBI1055E The message file db2install.cat cannot be found.

Explanation: The message file required by this
script is missing from the system; it may have been
deleted or the database products may have been loaded
incorrectly.

User Response: Verify that the product option containing
the message file is installed correctly. If there are
verification errors; reinstall the product option.

To fix this you only need to get libstdc++5.
Just put this 3 lines in your console and your ready to go. :)

sudo apt-get install libstdc++5
sudo apt-get install libaio-dev
sudo ./db2setup

Install DB2 Express-C in Ubuntu Gutsy

Thursday, November 8th, 2007

Ubuntu logo with some rain drops

If you usually read Simão’s Blog you probably already saw this guide.

For all of you that didn’t but wish to install DB2 on Linux just follow this link.

DB2 Express-C 9.5 Released

Thursday, November 1st, 2007

A new version of DB2 Express-C was made available by IBM today. As you might already know DB2 Express-C is a free dataserver without any limits on database size or number of users.

We got this news from

We still didn’t tested the new DB2 but according to Antonio

Version 9.5 brings to the table a great deal of new enhancements and features. Among these there is also the reduced amount of memory requirements and the improved efficiency of operations on Linux. Oh and it will also make you rich and more beautiful. I mean, pureXML support has been greatly improved and it is a release that is sure to please many people on both Windows and Linux.

About the T-Shirt, we know it’s great. Hopefully Vítor will send us some few. :)

Website Pre-Released

Sunday, October 28th, 2007

A preview of our website is now available. We hope to finish it soon enough.

Related Links: