Results 1 to 4 of 4

Thread: Db2cmd on Linux

  1. #1
    Join Date
    Jul 2014
    Posts
    294

    Unanswered: Db2cmd on Linux

    Hi,

    In one of my Db2 java procedure I am using a command like this & this

    db2cmd -c -w -i db2 list database directory.

    As I m using this command on windows. It is working good.
    According to docs it is applicable only on windows.

    Can someone tell me is there any exact same command , so that I can use that on LINUX.
    I mean db2cmd on linux environment.


    Thanks

  2. #2
    Join Date
    Apr 2012
    Posts
    1,034
    Provided Answers: 18
    The db2cmd does not exist on Linux. (It's connection-maintenance functionality is done by db2bp).
    Your sproc should not contain operating-system-specific code hard-coded inside it - that is bad design.
    On Linux shell-level you run the correct db2profile for the relevant db2-instance then simply issuse db2 list db directory.

  3. #3
    Join Date
    Jul 2014
    Posts
    294
    Hi Mark ,

    Thanks for the reply. I never worked on linux . Can u kindly provide me any reference link or docs for doing this.

  4. #4
    Join Date
    Apr 2012
    Posts
    1,034
    Provided Answers: 18
    The db2 Knowledge centre has enough information about db2profile, so study that first.
    But the docs won't show you how to design correctly for multiple operating-system platforms - that comes from experience.
    Remember that there are some kinds of data processing that is suitable for use inside sprocs, but anything that is operating-system or platform-specific should never be inside sprocs - that is just asking for maintenance and support troubles.

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •