Topic
15 replies Latest Post - ‏2013-01-16T10:37:44Z by mwandishi
lliang
lliang
15 Posts
ACCEPTED ANSWER

Pinned topic Where is bldrtn in DB2

‏2013-01-15T05:23:15Z |
Hi there,

I am using DB2 10.1 LUW on linux, and have the need to build some C routine code. I am recommanded to use 'bldrtn' script which should be located in sqllib/samples/c/ per db2 inforcenter.

But in sqllib/samples/c/ in my linux env., there are only following 3 files, no 'bldrtn' is found.
db2uext2.cdisk
db2uext2.ctape
db2uext2.ctsm

Anyone can give me a hint as to where 'bldrtn' might be missing there?

Thanks.
Updated on 2013-01-16T10:37:44Z at 2013-01-16T10:37:44Z by mwandishi
  • mwandishi
    mwandishi
    47 Posts
    ACCEPTED ANSWER

    Re: Where is bldrtn in DB2

    ‏2013-01-15T07:13:56Z  in response to lliang
    Hi lliang,

    You should have many more files in $HOME/sqllib/samples/c & ~/cpp including bldrtn:

    db2v10: pwd
    /db2data/db2v10/sqllib/samples/c

    ls -la bld*
    -r-xr-xr-x 1 bin bin 2403 30 Nov 22:14 bldapp
    -r-xr-xr-x 1 bin bin 1359 30 Nov 22:15 bldevm
    -r-xr-xr-x 1 bin bin 2301 30 Nov 22:14 bldmc
    -r-xr-xr-x 1 bin bin 1881 30 Nov 22:15 bldmt
    -r-xr-xr-x 1 bin bin 2096 30 Nov 22:14 bldrtn

    Sometime people copy them to a working directory, has this happened?
    Try a find: find $HOME -follow -name bldrtn -print

    For example:

    db2v10: find $HOME -follow -name bldrtn -print| egrep -i "/c/"
    /db2data/db2v10/scripts/c/bldrtn
    /db2data/db2v10/sqllib/samples/c/bldrtn
    /db2data/db2v10/sqllib/samples/xml/c/bldrtn
    /db2data/db2v10/sqllib/samples/xml/xquery/c/bldrtn

    Either they have been moved or perhaps they weren't created during the installation.

    Is this a new install? Any errors during the installation?

    Best regards,
    Stephen Levett
    • lliang
      lliang
      15 Posts
      ACCEPTED ANSWER

      Re: Where is bldrtn in DB2

      ‏2013-01-15T07:44:22Z  in response to mwandishi
      Thanks Stephen for your reply.

      This is a new install (DB2 10.1 LUW), and I don't seem to rememeber any errors occured during the installation, and I don't think any of the files were ever moved after installation.

      pwd
      /home/db2inst1/sqllib/samples/c

      ls
      -r--r--r--. 1 bin bin 73246 Dec 5 00:23 db2uext2.cdisk
      -r--r--r--. 1 bin bin 94830 Dec 5 00:23 db2uext2.ctape
      -r--r--r--. 1 bin bin 108598 Dec 5 00:23 db2uext2.ctsm

      find $HOME -follow -name bldrtn -print
      <Nothing is printed>

      find $HOME -follow -name bldrtn -print| egrep -i "/c/"
      <Nothing is printed>

      And under /home/db2inst1/sqllib/samples/, there is even no cpp folder as follows:
      drwxr-xr-x. 2 bin bin 4096 Dec 5 00:47 autoloader
      drwxr-xr-x. 2 bin bin 4096 Dec 5 00:23 automaintcfg
      drwxr-xr-x. 2 bin bin 4096 Dec 5 00:23 c
      drwxr-xr-x. 2 bin bin 4096 Dec 5 00:23 db2sampl
      drwxr-xr-x. 3 bin bin 4096 Dec 5 00:23 federated
      drwxr-xr-x. 3 bin bin 4096 Dec 5 00:23 ha
      drwxr-xr-x. 14 bin bin 4096 Dec 5 00:48 repl
      drwxr-xr-x. 3 bin bin 4096 Dec 5 00:23 selinux
      • mwandishi
        mwandishi
        47 Posts
        ACCEPTED ANSWER

        Re: Where is bldrtn in DB2

        ‏2013-01-15T08:20:32Z  in response to lliang
        Hi lliang,

        I can only assume either something went wrong or they weren't installed, possibly the option was deselected during the installation. db2ls -q -b <install_path> can be used to see what features were / weren't installed. For example:

        db2v10: /usr/local/bin/db2ls -q -b /opt/IBM/db2/V10.1

        Install Path : /opt/IBM/db2/V10.1

        Feature Response File ID Level Fix Pack Feature Description

        BASE_CLIENT 10.1.0.2 2 Base client support
        JAVA_SUPPORT 10.1.0.2 2 Java support

        .....contd....

        And this is definitely a server installation not a client?

        Can you provide the following please ( as the instance owner ):

        1) db2level
        2) db2licm -l
        3) From $HOME/sqllib: ls -la samples
        This should show a soft link to the prod install directory. Can you cd to the directory identified by the link and see if the files are in there please. For example:

        db2v10: pwd
        /db2data/db2v10/sqllib

        db2v10: ls -la samples
        lrwxrwxrwx 1 root db2v10g 26 11 Dec 16:46 samples -> /opt/IBM/db2/V10.1/samples

        cd /opt/IBM/db2/V10.1/samples
        find . -follow -name bldrtn -print

        cd c
        ls -la
        etc...

        If they aren't in the product install path then the instance owner won't see them. If there are in there then perhaps the link is broken.

        Best regards,
        Stephen Levett
        • lliang
          lliang
          15 Posts
          ACCEPTED ANSWER

          Re: Where is bldrtn in DB2

          ‏2013-01-15T08:58:04Z  in response to mwandishi
          I re-ran the DB2 installer, and found the 'Base application development tools' feature under 'Applicatoin development tools' is by defect not selected in 'Typical' installation type, which I believed choosed when I installed DB2.

          I am going to install 'Applicatoin development tools' feature and see if this can fix it.
          • mwandishi
            mwandishi
            47 Posts
            ACCEPTED ANSWER

            Re: Where is bldrtn in DB2

            ‏2013-01-15T09:07:43Z  in response to lliang
            Hi lliang,

            Yes, I am sure it will. If they aren't in the path listed in db2level ( Product is installed at "/opt/IBM/db2/V10.1". ) then they haven't been installed.

            Best regards,Stephen Levett
            • lliang
              lliang
              15 Posts
              ACCEPTED ANSWER

              Re: Where is bldrtn in DB2

              ‏2013-01-15T10:48:28Z  in response to mwandishi
              Hi mwandishi,

              I have my DB2 upgraded to fp2 version after the first install of DB2 10.1. Now when I am trying to install this missing feature with the DB2 10.1 install image, the installer acutally blocked me and indicating that I have to download the install image at the same code level as the one installed in this DB2 copy (which is 10.1.0.2)

              The problem is it doesn't seem to be a DB2 10.1.0.2 install image available out there (Searched on XL, no 10.1.0.2 install image is available). I trying to understand that is that to say I have to uninstall fp2 and fp1 before I can install that missing feature with DB2 10.1 install image?

              Or in other word, what is the recommend way to re-install that feature?

              Thanks.
              • mwandishi
                mwandishi
                47 Posts
                ACCEPTED ANSWER

                Re: Where is bldrtn in DB2

                ‏2013-01-15T11:51:45Z  in response to lliang
                Hi Lliang,,

                You will need to go back to the fp1 or GA level. I assume you: Installed v10 GA ( no fixpacks ) but ommitted the app dev features, then applied fp2. Now, as you point, out db2setup detects 10.1.2 is applied and it stops.

                You'll need to go back to GA, re-run db2setup, select the app dev features then re-apply fp2. I don't think there is any alternative. However, it does rather depend on whether you installed fp2 into the base GA path?

                I refer you to: http://publib.boulder.ibm.com/infocenter/db2luw/v10r1/topic/com.ibm.db2.luw.qb.server.doc/doc/t0024971.html

                Best regards,Stephen Levett
                • nivanov1
                  nivanov1
                  231 Posts
                  ACCEPTED ANSWER

                  Re: Where is bldrtn in DB2

                  ‏2013-01-15T15:48:53Z  in response to mwandishi
                  > You'll need to go back to GA, re-run db2setup

                  I believe it's not necessary. DB2 fix packs are cumulative (that is, each fix pack contains the base product image), so I think all you need to do is to run db2setup from where you unpacked the fix pack 2.
                  • mwandishi
                    mwandishi
                    47 Posts
                    ACCEPTED ANSWER

                    Re: Where is bldrtn in DB2

                    ‏2013-01-15T19:08:22Z  in response to nivanov1
                    Hi,

                    My apologies, I didn't think it through. Nivanov1 has a point, running db2setup from 10.1.2 should allow you to selectivity install whatever you need.

                    Have you tried this? It sounds like you ran db2setup from GA or fp1 previously.

                    Best regards,Stephen Levett
                    • lliang
                      lliang
                      15 Posts
                      ACCEPTED ANSWER

                      Re: Where is bldrtn in DB2

                      ‏2013-01-16T02:30:00Z  in response to mwandishi
                      Hi mwandishi,

                      Yes, I ran the db2setup from DB2 10.1 GA version.

                      I also assumed running db2setup from 10.1.0.2 (I assumed you meant 10.1.0.2) should work, but as I mentioned, It seems to me that there is no DB2 10.1.0.2 install image available on XL.

                      Or could you point to the correct place to download it if it's already available? Thanks.
                  • lliang
                    lliang
                    15 Posts
                    ACCEPTED ANSWER

                    Re: Where is bldrtn in DB2

                    ‏2013-01-16T02:37:24Z  in response to nivanov1
                    Hi nivanov1 and mwandishi,

                    I have the fp2 pacakge , but I can not find the db2setup in it.

                    In pacakge, here is what I see,
                    drwxr-xr-x. 6 bin bin 4096 Dec 5 03:03 db2
                    -r-xr-xr-x. 1 bin bin 5349 Dec 5 03:03 db2ckupgrade
                    -r-xr-xr-x. 1 bin bin 5136 Dec 5 03:02 db2ls
                    -r-xr-xr-x. 1 bin bin 5154 Dec 5 03:02 db2prereqcheck
                    -r-xr-xr-x. 1 bin bin 5190 Dec 5 03:03 installFixPack

                    Did I download the wrong package (v10.1fp2_linuxx64_universal_fixpack.tar)?

                    Thanks
                    • mwandishi
                      mwandishi
                      47 Posts
                      ACCEPTED ANSWER

                      Re: Where is bldrtn in DB2

                      ‏2013-01-16T09:15:05Z  in response to lliang
                      Hi,

                      That was the concern I had and why I thought you may have to go right back. Unfortunately, I can't easily test possible options as I don't have the base code.

                      I will have a think about other options but going back to GA may be the only one here.

                      Best regards,Stephen Levett
                      • lliang
                        lliang
                        15 Posts
                        ACCEPTED ANSWER

                        Re: Where is bldrtn in DB2

                        ‏2013-01-16T09:27:16Z  in response to mwandishi
                        Hi mwandishi,

                        I've followed the link you attached (http://publib.boulder.ibm.com/infocenter/db2luw/v10r1/topic/com.ibm.db2.luw.qb.server.doc/doc/t0024971.html) to go back to the GA version, and then successfully installed 'Base application development tools' feature with db2setup from GA install image, and then installed fp2 back.

                        And then I finally found the blnrtn in the sqllib/sample/c

                        All works well.

                        Thanks so much for your help!
                        • mwandishi
                          mwandishi
                          47 Posts
                          ACCEPTED ANSWER

                          Re: Where is bldrtn in DB2

                          ‏2013-01-16T10:37:44Z  in response to lliang
                          Hi Iiiang,

                          Excellent news, glad it is all working and you are able to move on.

                          Best regards,Stephen Levett
                    • SystemAdmin
                      SystemAdmin
                      17917 Posts
                      ACCEPTED ANSWER

                      Re: Where is bldrtn in DB2

                      ‏2013-01-16T09:55:30Z  in response to lliang
                      If you had db2 server fix pack, you could run db2setup.
                      DB2 Server Fix Pack contains the DB2 Universal Fix Pack, plus the base code for all DB2 products.

                      Please check this link for more details. http://www-01.ibm.com/support/docview.wss?uid=swg24033997