Results 1 to 5 of 5
  1. #1
    Join Date
    Jan 2008
    Posts
    45

    Unanswered: PHP and db2diag command

    Hi friends,

    I am writing a PHP script to monitor db..Does any one know if we can call db2diag command or list history command inside php??

    I know there is ADMIN_CMD proc but it does not allow for db2diag command or list history

    Thanks in advance

  2. #2
    Join Date
    Jan 2008
    Posts
    88
    check out in application development guide...

  3. #3
    Join Date
    Jan 2007
    Location
    Jena, Germany
    Posts
    2,721
    db2diag is not a DB2 command but rather a program. Thus, you cannot invoke it through ADMIN_CMD.
    Knut Stolze
    IBM DB2 Analytics Accelerator
    IBM Germany Research & Development

  4. #4
    Join Date
    Jan 2008
    Posts
    45
    Can we invoke using C code??If so can you provide me some inputs as to how can i do that

    thanks a lot

  5. #5
    Join Date
    Jan 2007
    Location
    Jena, Germany
    Posts
    2,721
    You could write a UDF or stored procedure with LANGUAGE C. Inside the routine, I would open a simple pipe (see "man popen") to invoke "db2diag" with the desired options and get its output.
    Knut Stolze
    IBM DB2 Analytics Accelerator
    IBM Germany Research & Development

Posting Permissions

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