RSS

Monitoring Performance ADOdb

Thu, Mar 19, 2009

Database

Kebetulan ada proyek untuk memonitoring hasil produksi dan server udah siap walau dengan spek pas-pasan..:). Server diinstal pakai RHEL 4 dan menggunakan database Oracle 10g. Berhubung bawaan RHEL 4 masih menggunakan PHP4, saya coba cara instan menggunakan xampp 1.7 for linux. Pada umum xampp-linux tidak disertai dengan ADOdb hal ini beda dengan xampp-windows, untuk itu ADOdb nya dan oracle-instant-client di instal sendiri. Setelah di setting sana – sini akhirnya bisa konek ke oracle.

Untuk melihat performance koneksi ADOdb menggunakan oci8 di PHP5 dan database oracle 10g. Berikut ini script nya :

include_once ‘../adodb/adodb-errorpear.inc.php’;

include_once ‘../adodb/adodb.inc.php’;

session_start();

$tns=’myoracle’;

$usr=’admin’;

$pwd=’test123′;

$db = NewADOConnection(‘oci8′);

$db->Connect(‘localhost’,$usr, $pwd,$tns);

$perf =& NewPerfMonitor($db);

$perf->UI($pollsecs=5);

Lalu script tersebut disimpan misalkan dengan nama koneksi.php

Jika sukses dijalankan akan ditampilkan menu Performance Stats, View SQL, View Tables, Poll Stats, Run SQL seperti ini :

  • Performance Stats

performance-stats

  • View SQL

view-sql

  • View Tables

view-tables

  • Poll Stats

poll-stats

  • Run SQL

run-sql

Sebagai referensi ada link :

http://phplens.com/lens/adodb/docs-perf.htm#usage

Selamat mencoba..



, , ,

This post was written by:

admin - who has written 21 posts on Blog.CSoft39.com.


Contact the author

12 Comments For This Post

  1. catur Says:

    Gak dong mas. Gunanya monitoring performance adodb untuk apa ? Apakah ada kaitannya dengan kecepatan proses query gitu ?

  2. haryis Says:

    Betul mas catur, salah satunya untuk monitoring kecepatan proses query dan monitoring koneksi ke database.

  3. Jinny Says:

    I have already seen it somethere…
    Thanks
    Jinny

  4. Extenze Says:

    Of course, what a great site and informative posts, I will add backlink – bookmark this site? Regards, Reader.

  5. adi Says:

    mo nanya nie,,,
    ko q koneksinya aja blom berhasil y??

    saya pk Zend core, Oracle 10G

    saya juga da adodb.inc. tp ko msh blum berhasil y???

    mohon bantuannya,,

    maaf klo pertanyaannya mendasar skali, harap maklum karna saya masih pemula

    Trimaksh byk…

  6. admin Says:

    Saya belum mencoba pakai Zend core, itu Zend core versi berapa ? biasanya kalo Zend Core terbaru sudah support ke PHP5 sudah menyertakan module OCI tanpa harus menginstall oracle client.
    Coba cek di php.ini apakah OCInya udh diaktifkan pa belum?
    Atau cek user oracle sudah ada belum, caranya lihat isi di /etc/user
    ,jika belum berarti belum terinstall oracle.
    Jika sudah coba login atau su sebagai user oracle.
    Selanjutnya cek apakah $ORACLE_HOME sudah diset? caranya echo $ORACLE_HOME
    Jika belum kemungkinan besar oracle client belum terinstal.
    Jika sudah coba dicek apakah di directory yang disebut $ORACLE_HOME sudah banyak file dan direktori yang dibuat oleh oracle.
    jika sudah berarti oracle client sudah diinstal.
    Berarti tinggal settingan koneksinya yang belum pas..

    Mungkin ada yang bisa membantu..

  7. Josie Says:

    I am really glad I found this blog. Great Job! :)

  8. Caroline Says:

    I was going to write a similar blog concerning this topic, you beat me to it. You did a nice job!

  9. Maribel Says:

    I don’t usually post but I enjoyed your blog a lot.

  10. Buena Englebert Says:

    This an Excellent wordpress post, I will be sure to save this post in my Clipmarks account. Have a awesome evening.

  11. admin Says:

    ok..thank you

  12. Schedule Says:

    Best you could edit the page subject title
    Monitoring Performance ADOdb | Blog.CSoft39.com to more generic for your subject you make. I liked the blog post withal.

Leave a Reply