#ORA-00371: not enough shared pool memory, should be atleast 62198988 bytes
solution
edit init.ora
#ORA-00205: error in identifying control file, check alert log for more info
Friday, February 25, 2011
ORA-01078: LRM-00109 :
-> hari minggu pagi ini dapet sarapan
#ORA-01078: failure in processing system parameters
#LRM-00109: could not open parameter file '/u01/app/oracle/product/10.2.0/db_1/dbs/initTSH1.ora'
di vbox gw,, karna gw mo yobail biki simulasi oracle to oracle replicte..
tdi mlm gw install oracle di RHEL 05 di vbox, pass beres install oracle na gw startup ehh
keluar error tdi..
ngembah google dulu....
nie solutionnya
-> cari init,pfile atau spfile
[oracle@redhost ~]$ find $ORACLE_BASE -name init*.ora
/u01/app/oracle/product/10.2.0/db_1/srvm/admin/init.ora
/u01/app/oracle/product/10.2.0/db_1/dbs/init.ora <--
/u01/app/oracle/product/10.2.0/db_1/dbs/initdw.ora
/u01/app/oracle/product/10.2.0/db_1/hs/admin/inithsodbc.ora
-> start database
SQL> startup pfile ='/u01/app/oracle/product/10.2.0/db_1/dbs/init.ora'
#ORA-01078: failure in processing system parameters
#LRM-00109: could not open parameter file '/u01/app/oracle/product/10.2.0/db_1/dbs/initTSH1.ora'
di vbox gw,, karna gw mo yobail biki simulasi oracle to oracle replicte..
tdi mlm gw install oracle di RHEL 05 di vbox, pass beres install oracle na gw startup ehh
keluar error tdi..
ngembah google dulu....
nie solutionnya
-> cari init,pfile atau spfile
[oracle@redhost ~]$ find $ORACLE_BASE -name init*.ora
/u01/app/oracle/product/10.2.0/db_1/srvm/admin/init.ora
/u01/app/oracle/product/10.2.0/db_1/dbs/init.ora <--
/u01/app/oracle/product/10.2.0/db_1/dbs/initdw.ora
/u01/app/oracle/product/10.2.0/db_1/hs/admin/inithsodbc.ora
-> start database
SQL> startup pfile ='/u01/app/oracle/product/10.2.0/db_1/dbs/init.ora'
Monday, February 21, 2011
cara menghitung achivelog perhari
# nie cara menghitung perharinya
SQL> select trunc(COMPLETION_TIME) TIME, SUM(BLOCKS * BLOCK_SIZE)/1024/1024 SIZE_MB from V$ARCHIVED_LOG group by trunc (COMPLETION_TIME) order by 1;
TIME SIZE_MB
---------- ----------
2011-02-12 71797.87
2011-02-13 75880.52
2011-02-14 73569.37
2011-02-15 76776.81
2011-02-16 73959.86
2011-02-17 69969.71
2011-02-18 74677.10
2011-02-19 75474.95
2011-02-20 77967.07
2011-02-21 67802.70
# ini perjamnya
SQL> alter session set nls_date_format = 'YYYY-MM-DD HH24';
Session altered.
SQL> select trunc(COMPLETION_TIME,'HH24') TIME, SUM(BLOCKS * BLOCK_SIZE)/1024/1024 SIZE_MB from V$ARCHIVED_LOG group by trunc (COMPLETION_TIME,'HH24') order by 1;
TIME SIZE_MB
------------- ----------
2011-02-21 00 6396.65
2011-02-21 01 2797.31
2011-02-21 02 2010.45
2011-02-21 03 1871.77
2011-02-21 04 1481.5
2011-02-21 05 2868.20
2011-02-21 06 2363.89
2011-02-21 07 4269.26
2011-02-21 08 2469.08
2011-02-21 09 3007.06
2011-02-21 10 3561.97
2011-02-21 11 2530.57
2011-02-21 12 3509.08
2011-02-21 13 3022.5
2011-02-21 14 3514.97
2011-02-21 15 4057.45
2011-02-21 16 3021.27
2011-02-21 17 4014.31
2011-02-21 18 4011.66
2011-02-21 19 4008.10
2011-02-21 20 3015.46
# gimana klo RAC??
SQL> select INST_ID, RECID, NAME, to_char(COMPLETION_TIME,'YYYY-MM-DD HH24:MI:SS'), ARCHIVAL_THREAD# , blocck * block_size from GV$ARCHIVED_LOG order by COMPLETION_TIME;
INST_ID RECID NAME TO_CHAR(COMPLETION_ ARCHIVAL_THREAD#
---------- ---------- -------------------------------------------------- ------------------- ----------------
4 258572 +ARCH/DB/4_73214_617849235.dbf 2011-02-21 20:29:52 4
2 258572 +ARCH/DB/4_73214_617849235.dbf 2011-02-21 20:29:52 4
1 258572 +ARCH/DB/4_73214_617849235.dbf 2011-02-21 20:29:52 4
3 258572 +ARCH/DB/4_73214_617849235.dbf 2011-02-21 20:29:52 4
1 258573 +ARCH/DB/1_55739_617849235.dbf 2011-02-21 20:44:22 1
3 258573 +ARCH/DB/1_55739_617849235.dbf 2011-02-21 20:44:22 1
4 258573 +ARCH/DB/1_55739_617849235.dbf 2011-02-21 20:44:22 1
2 258573 +ARCH/DB/1_55739_617849235.dbf 2011-02-21 20:44:22 1
# klo RAC perhari??
SQL> select trunc(COMPLETION_TIME) TIME, SUM(BLOCKS * BLOCK_SIZE)/1024/1024 SIZE_MB from V$ARCHIVED_LOG group by trunc (COMPLETION_TIME) order by 1;
TIME SIZE_MB
---------- ----------
2011-02-12 71797.87
2011-02-13 75880.52
2011-02-14 73569.37
2011-02-15 76776.81
2011-02-16 73959.86
2011-02-17 69969.71
2011-02-18 74677.10
2011-02-19 75474.95
2011-02-20 77967.07
2011-02-21 67802.70
# klo RAC perjama??
SQL> alter session set nls_date_format = 'YYYY-MM-DD HH24';
Session altered.
SQL> select trunc(COMPLETION_TIME,'HH24') TIME, SUM(BLOCKS * BLOCK_SIZE)/1024/1024 SIZE_MB from V$ARCHIVED_LOG group by trunc (COMPLETION_TIME,'HH24') order by 1;
TIME SIZE_MB
------------- ----------
2011-02-21 00 6396.65
2011-02-21 01 2797.31
2011-02-21 02 2010.45
2011-02-21 03 1871.77
2011-02-21 04 1481.5
2011-02-21 05 2868.20
2011-02-21 06 2363.89
2011-02-21 07 4269.26
2011-02-21 08 2469.08
2011-02-21 09 3007.06
2011-02-21 10 3561.97
2011-02-21 11 2530.57
2011-02-21 12 3509.08
2011-02-21 13 3022.5
2011-02-21 14 3514.97
2011-02-21 15 4057.45
2011-02-21 16 3021.27
2011-02-21 17 4014.31
2011-02-21 18 4011.66
2011-02-21 19 4008.10
2011-02-21 20 3015.46
ada ide lain ??? :)
souce :[http://surachartopun.com]
SQL> select trunc(COMPLETION_TIME) TIME, SUM(BLOCKS * BLOCK_SIZE)/1024/1024 SIZE_MB from V$ARCHIVED_LOG group by trunc (COMPLETION_TIME) order by 1;
TIME SIZE_MB
---------- ----------
2011-02-12 71797.87
2011-02-13 75880.52
2011-02-14 73569.37
2011-02-15 76776.81
2011-02-16 73959.86
2011-02-17 69969.71
2011-02-18 74677.10
2011-02-19 75474.95
2011-02-20 77967.07
2011-02-21 67802.70
# ini perjamnya
SQL> alter session set nls_date_format = 'YYYY-MM-DD HH24';
Session altered.
SQL> select trunc(COMPLETION_TIME,'HH24') TIME, SUM(BLOCKS * BLOCK_SIZE)/1024/1024 SIZE_MB from V$ARCHIVED_LOG group by trunc (COMPLETION_TIME,'HH24') order by 1;
TIME SIZE_MB
------------- ----------
2011-02-21 00 6396.65
2011-02-21 01 2797.31
2011-02-21 02 2010.45
2011-02-21 03 1871.77
2011-02-21 04 1481.5
2011-02-21 05 2868.20
2011-02-21 06 2363.89
2011-02-21 07 4269.26
2011-02-21 08 2469.08
2011-02-21 09 3007.06
2011-02-21 10 3561.97
2011-02-21 11 2530.57
2011-02-21 12 3509.08
2011-02-21 13 3022.5
2011-02-21 14 3514.97
2011-02-21 15 4057.45
2011-02-21 16 3021.27
2011-02-21 17 4014.31
2011-02-21 18 4011.66
2011-02-21 19 4008.10
2011-02-21 20 3015.46
# gimana klo RAC??
SQL> select INST_ID, RECID, NAME, to_char(COMPLETION_TIME,'YYYY-MM-DD HH24:MI:SS'), ARCHIVAL_THREAD# , blocck * block_size from GV$ARCHIVED_LOG order by COMPLETION_TIME;
INST_ID RECID NAME TO_CHAR(COMPLETION_ ARCHIVAL_THREAD#
---------- ---------- -------------------------------------------------- ------------------- ----------------
4 258572 +ARCH/DB/4_73214_617849235.dbf 2011-02-21 20:29:52 4
2 258572 +ARCH/DB/4_73214_617849235.dbf 2011-02-21 20:29:52 4
1 258572 +ARCH/DB/4_73214_617849235.dbf 2011-02-21 20:29:52 4
3 258572 +ARCH/DB/4_73214_617849235.dbf 2011-02-21 20:29:52 4
1 258573 +ARCH/DB/1_55739_617849235.dbf 2011-02-21 20:44:22 1
3 258573 +ARCH/DB/1_55739_617849235.dbf 2011-02-21 20:44:22 1
4 258573 +ARCH/DB/1_55739_617849235.dbf 2011-02-21 20:44:22 1
2 258573 +ARCH/DB/1_55739_617849235.dbf 2011-02-21 20:44:22 1
# klo RAC perhari??
SQL> select trunc(COMPLETION_TIME) TIME, SUM(BLOCKS * BLOCK_SIZE)/1024/1024 SIZE_MB from V$ARCHIVED_LOG group by trunc (COMPLETION_TIME) order by 1;
TIME SIZE_MB
---------- ----------
2011-02-12 71797.87
2011-02-13 75880.52
2011-02-14 73569.37
2011-02-15 76776.81
2011-02-16 73959.86
2011-02-17 69969.71
2011-02-18 74677.10
2011-02-19 75474.95
2011-02-20 77967.07
2011-02-21 67802.70
# klo RAC perjama??
SQL> alter session set nls_date_format = 'YYYY-MM-DD HH24';
Session altered.
SQL> select trunc(COMPLETION_TIME,'HH24') TIME, SUM(BLOCKS * BLOCK_SIZE)/1024/1024 SIZE_MB from V$ARCHIVED_LOG group by trunc (COMPLETION_TIME,'HH24') order by 1;
TIME SIZE_MB
------------- ----------
2011-02-21 00 6396.65
2011-02-21 01 2797.31
2011-02-21 02 2010.45
2011-02-21 03 1871.77
2011-02-21 04 1481.5
2011-02-21 05 2868.20
2011-02-21 06 2363.89
2011-02-21 07 4269.26
2011-02-21 08 2469.08
2011-02-21 09 3007.06
2011-02-21 10 3561.97
2011-02-21 11 2530.57
2011-02-21 12 3509.08
2011-02-21 13 3022.5
2011-02-21 14 3514.97
2011-02-21 15 4057.45
2011-02-21 16 3021.27
2011-02-21 17 4014.31
2011-02-21 18 4011.66
2011-02-21 19 4008.10
2011-02-21 20 3015.46
ada ide lain ??? :)
souce :[http://surachartopun.com]
Friday, February 18, 2011
Installing mysql di fedora 14
#curhat :D
hari nie gw baru install Fedora d labtop Acer tua gw,
tadi nya gw mo install backtrack 4rc eeh cd na rusak gtu, bete :(
akhirnya gw ngubek" barak gw(kamar :p), eh nemu fedora 14, dari pada ga ada yacg daah gw install
daah beres install pertama dapet masalah adalah dia turunan red hat yg ga suport mp3..
ngubek" s embah akhirnya nemu jga cara buat yetel mp3nya :D
karna gw kangen ma java(biarpun ga ada bakat sama sekali ;p) gw download eclipse ma mysql
trus gw coba kan
#yum install mysql-server
daah beres install dan download
gw coba kan command
#mysql
ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/lib/mysq/mysql.sock' (2)
arrrrggggg
gogling lagi....
coba sana sini
yg sukses yg nie nie :D :
[souce tutorial: http://www.if-not-true-then-false.com] cek aja gan ada centos dan kawan"nya :D
---------------
ni step" na :D :
- jadi root supaya bisa install :)
# su -
- Remi Dependency on Fedora 14, 13, 12, 11, 10, 9, 8
# rpm -Uvh http://download1.rpmfusion.org/free/fedora/rpmfusion-free-release-stable.noarch.rpm
# rpm -Uvh http://download1.rpmfusion.org/nonfree/fedora/rpmfusion-nonfree-release-stable.noarch.rpm
-fedora 14
# rpm -Uvh http://rpms.famillecollet.com/remi-release-14.rpm
-check list paket yg tersedia
# yum --enablerepo=remi list mysql mysql-server
-install atau update mysql
# yum --enablerepo=remi install mysql mysql-server
-start servises mysql
# /etc/init.d/mysqld start
-mulai isntall mysql
/usr/bin/mysql_secure_installation
isi dengan kebutuhan anda :). selamat berfedora :)
hari nie gw baru install Fedora d labtop Acer tua gw,
tadi nya gw mo install backtrack 4rc eeh cd na rusak gtu, bete :(
akhirnya gw ngubek" barak gw(kamar :p), eh nemu fedora 14, dari pada ga ada yacg daah gw install
daah beres install pertama dapet masalah adalah dia turunan red hat yg ga suport mp3..
ngubek" s embah akhirnya nemu jga cara buat yetel mp3nya :D
karna gw kangen ma java(biarpun ga ada bakat sama sekali ;p) gw download eclipse ma mysql
trus gw coba kan
#yum install mysql-server
daah beres install dan download
gw coba kan command
#mysql
ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/lib/mysq/mysql.sock' (2)
arrrrggggg
gogling lagi....
coba sana sini
yg sukses yg nie nie :D :
[souce tutorial: http://www.if-not-true-then-false.com] cek aja gan ada centos dan kawan"nya :D
---------------
ni step" na :D :
- jadi root supaya bisa install :)
# su -
- Remi Dependency on Fedora 14, 13, 12, 11, 10, 9, 8
# rpm -Uvh http://download1.rpmfusion.org/free/fedora/rpmfusion-free-release-stable.noarch.rpm
# rpm -Uvh http://download1.rpmfusion.org/nonfree/fedora/rpmfusion-nonfree-release-stable.noarch.rpm
-fedora 14
# rpm -Uvh http://rpms.famillecollet.com/remi-release-14.rpm
-check list paket yg tersedia
# yum --enablerepo=remi list mysql mysql-server
-install atau update mysql
# yum --enablerepo=remi install mysql mysql-server
-start servises mysql
# /etc/init.d/mysqld start
-mulai isntall mysql
/usr/bin/mysql_secure_installation
isi dengan kebutuhan anda :). selamat berfedora :)
Tuesday, February 1, 2011
Purge Oracle 10g
purge sangat berguna "saat anda benar" ingin menghapus table"
dalam 10g, tables bisa d "undropped":
ops$tkyte@ORA10G> desc t;
Name Null? Type
---------------------------------------- -------- ----------------------------
X VARCHAR2(2000)
ops$tkyte@ORA10G> select count(*) from t;
COUNT(*)
----------
0
ops$tkyte@ORA10G> drop table t;
Table dropped.
ops$tkyte@ORA10G> desc t;
ERROR:
ORA-04043: object t does not exist
ops$tkyte@ORA10G> select count(*) from t;
select count(*) from t
*
ERROR at line 1:
ORA-00942: table or view does not exist
ops$tkyte@ORA10G> flashback table t to before drop;
Flashback complete.
ops$tkyte@ORA10G> desc t;
Name Null? Type
---------------------------------------- -------- ----------------------------
X VARCHAR2(2000)
di dalam logic, kita membuat "drop table t" into " tapi sebenarnya kita menyembunyikanya seperti reciclebyn jendela :p
consider:
ops$tkyte@ORA10G> drop table t;
Table dropped.
ops$tkyte@ORA10G> select table_name from user_tables;
no rows selected
ops$tkyte@ORA10G> select object_name from recyclebin;
OBJECT_NAME
------------------------------
BIN$7oTtcup30ZfgMAGK/3hjKw==$0
ops$tkyte@ORA10G> flashback table t to before drop;
Flashback complete.
ops$tkyte@ORA10G> select object_name from recyclebin;
no rows selected
ops$tkyte@ORA10G> select table_name from user_tables;
TABLE_NAME
------------------------------
T
ops$tkyte@ORA10G>
jadi, setiap anda men drop table, sebenarnya kita menyembunyikannya -- tidak seluruhnya menghapusnya (sama dengan
indexes, etc)
anda mungkin ingin agar situasi ini tidak terjadi. kadang kala
(poorly written) aplication yg membuat creates dan drops ratusan "scratch" tables (instead
of using global temporary tables created once...)
itu, bisa membuat banjir data dictionary dengan ratusan atau ribuan object yg di sembunyikan ini
-- ini mengakibatkan queries ke dictionary menjadi slow down. anda mungkin menginginkan table ini benar hilang.
jadi, anda dapate menggunakan drop table T purge:
ops$tkyte@ORA10G> drop table t purge;
Table dropped.
ops$tkyte@ORA10G> select table_name from user_tables;
no rows selected
ops$tkyte@ORA10G> select object_name from recyclebin;
no rows selected
ops$tkyte@ORA10G>
atau anda bisa menggunakan purge untuk purge all dropped objects d database atau table space, scema.
souce asktom.oracle.com
dalam 10g, tables bisa d "undropped":
ops$tkyte@ORA10G> desc t;
Name Null? Type
---------------------------------------- -------- ----------------------------
X VARCHAR2(2000)
ops$tkyte@ORA10G> select count(*) from t;
COUNT(*)
----------
0
ops$tkyte@ORA10G> drop table t;
Table dropped.
ops$tkyte@ORA10G> desc t;
ERROR:
ORA-04043: object t does not exist
ops$tkyte@ORA10G> select count(*) from t;
select count(*) from t
*
ERROR at line 1:
ORA-00942: table or view does not exist
ops$tkyte@ORA10G> flashback table t to before drop;
Flashback complete.
ops$tkyte@ORA10G> desc t;
Name Null? Type
---------------------------------------- -------- ----------------------------
X VARCHAR2(2000)
di dalam logic, kita membuat "drop table t" into " tapi sebenarnya kita menyembunyikanya seperti reciclebyn jendela :p
consider:
ops$tkyte@ORA10G> drop table t;
Table dropped.
ops$tkyte@ORA10G> select table_name from user_tables;
no rows selected
ops$tkyte@ORA10G> select object_name from recyclebin;
OBJECT_NAME
------------------------------
BIN$7oTtcup30ZfgMAGK/3hjKw==$0
ops$tkyte@ORA10G> flashback table t to before drop;
Flashback complete.
ops$tkyte@ORA10G> select object_name from recyclebin;
no rows selected
ops$tkyte@ORA10G> select table_name from user_tables;
TABLE_NAME
------------------------------
T
ops$tkyte@ORA10G>
jadi, setiap anda men drop table, sebenarnya kita menyembunyikannya -- tidak seluruhnya menghapusnya (sama dengan
indexes, etc)
anda mungkin ingin agar situasi ini tidak terjadi. kadang kala
(poorly written) aplication yg membuat creates dan drops ratusan "scratch" tables (instead
of using global temporary tables created once...)
itu, bisa membuat banjir data dictionary dengan ratusan atau ribuan object yg di sembunyikan ini
-- ini mengakibatkan queries ke dictionary menjadi slow down. anda mungkin menginginkan table ini benar hilang.
jadi, anda dapate menggunakan drop table T purge:
ops$tkyte@ORA10G> drop table t purge;
Table dropped.
ops$tkyte@ORA10G> select table_name from user_tables;
no rows selected
ops$tkyte@ORA10G> select object_name from recyclebin;
no rows selected
ops$tkyte@ORA10G>
atau anda bisa menggunakan purge untuk purge all dropped objects d database atau table space, scema.
souce asktom.oracle.com
Subscribe to:
Posts (Atom)