[Solaris] Check CPU Speed & Memory Size

Posted by cikul | Posted in Linux, Technology | Posted on 26-09-2012-05-2008


SUN OS based on UNIX, but has different structure with another linux system. For example in Linux, you can easily check CPU & Memory info using /proc/cpuinfo and /proc/meminfo, or you can check hardware information using lspci or dmidecode.

And how in SunOS?

Read the rest of this entry »

[Oracle] Setting ArchiveLog mode

Posted by cikul | Posted in Oracle, SQL | Posted on 25-09-2012-05-2008


What Is Archive Log?

As a DBA, you are responsible to recover any failures to a point of failure and also to perform your backup while online. Your organization is a 24×7 shop and you are not able to shutdown the database. Therefore, the database has to be in an archive mode.

For example you have severe corruption or a database crash that required you to restore some datafiles from several hours ago. If you have all the archived logs from that pint in time up until the moment of the crash, you can roll forward all the changes contained in those archived logs against the restored datafiles.

This process will replays all the changes in the database over the past hours. After recovering the last archived log, Oracle will then look to roll forward even more by using the online redo logs. If those online redo logs contain changes necessary, Oracle will apply those changes also.

Read the rest of this entry »

[Oracle] Troubleshoot “Connected to an idle instance.”

Posted by cikul | Posted in Linux, Oracle, SQL, Windows | Posted on 24-09-2012-05-2008


Problem : You have an Oracle instance, and you know it’s running on the system, when you’re trying to connect using “/ as sysdba” it says the instance is idle. You know the database is up and opened, because your application’s talking to it.

[oracle@server db_1]$ sqlplus / as sysdba
SQL*Plus: Release - Production on Mon Sep 24 15:22:47 2012
Copyright (c) 1982, 2005, Oracle.  All rights reserved.
Connected to an idle instance.

Read the rest of this entry »

[CentOS] Change SSH Port and create multiple port SSH Linux

Posted by cikul | Posted in Linux | Posted on 03-08-2012-05-2008


Default port for SSH is port 22, for security reason sometimes we need to change port for SSH to another port or maybe for some reason, system administrator need add more port for SSH access. The following steps will explain how this can be done.

SSH configuration located at /etc/ssh/, and file that holds current SSH setting can be found at /etc/ssh/sshd_config. 

Read the rest of this entry »

[PHP] Extract XML Data

Posted by cikul | Posted in PHP, Programming | Posted on 24-07-2012-05-2008


XML was designed to transport and store data. The design goals of XML emphasize simplicity, generality, and usability over the Internet.

It is a textual data format with strong support via Unicode for the languages of the world. Although the design of XML focuses on documents, it is widely used for the representation of arbitrary data structures, for example in web services.

Read the rest of this entry »

[PHP] Excel, Word, PowerPoint Libraries

Posted by cikul | Posted in PHP, Programming | Posted on 20-07-2012-05-2008


Need export your data in XLS Format? maybe DOC format or PPT format. It’s can be frustrating to PHP programmer converting data to these formats.

No worry, there are several libraries/classes available for PHP to simplify your process to export data. let’s discuss one by one :

Read the rest of this entry »

[Oracle] Startup & Shutdown Oracle Instance

Posted by cikul | Posted in Oracle, SQL | Posted on 17-07-2012-05-2008


For DBA,  starting up and shutting down database is a routine operation. How to start and stop Oracle database (windows & Unix base)

Starting Up Oracle Database

To starting up Oracle Database,  you must connect using SQLPLUS /as sysdba or an oracle account that has DBA privilege.

Read the rest of this entry »

[Cpanel] Edit httpd.conf and save the configuration changed

Posted by cikul | Posted in cpanel | Posted on 12-07-2012-05-2008


If you simply comment/change configuration in httpd.conf and distill those changes, they will return whenever you recompile Apache again or rebuild Apache again.

After removing the entries in httpd.conf, you can do the following commands to ensure they are properly distilled into the new configuration:

cp /usr/local/apache/conf/httpd.conf /usr/local/apache/conf/httpd.conf.bak
/usr/local/cpanel/bin/apache_conf_distiller --update
/etc/init.d/httpd restart

The commands above will copy a backup of the existing httpd.conf, distill the changes you’ve made, rebuild Apache configuration, and restart Apache to ensure the new changes take effect.

Restrict who can use php.ini SuPHP

Posted by cikul | Posted in cpanel, Linux | Posted on 09-07-2012-05-2008


There are several methods that can be used to disallow users to have their own php.ini files under suPHP. The path you take will depend on whether you want to allow users to have their own in some circumstances or to restrict all accounts on the server to the global php.ini file at /usr/local/lib/php.ini location.

Restrict all accounts to the global php.ini file

Read the rest of this entry »

[SQL-Oracle] Copying data from one table to another

Posted by cikul | Posted in SQL | Posted on 29-06-2012-05-2008


How to simply copy data from one Oracle table into another one? There is several ways to copy data, the common usage is exporting the data and then reupload the data to new table.

Read the rest of this entry »