Data Protector: Object is a mounted filesystem => not restored.

Unexpected mounted filesystems detected when restoring a disk imageWhen restoring a disk image, you get a message that the disk image being restoredis a mounted filesystem and will not be restored:

Object is a mounted filesystem => not restored.

This happens when an application on the disk image leaves some patterns on thedisk image. The patterns confuse the system call that verifies whether the filesystemon the disk image is mounted or not, so the system call reports that there is a mountedfilesystem on the disk image.


1. Try zero out the device

dd if=/dev/zero of=/dev/r[logical volume] bs=8k

2. For AIX, lslv [logical volume] , verify it doesn’t contain DS_LVZ, otherwise, recreate it without -T O
3. For AIX with IBM SAN Volume Controller, run

lquerypr -ph  /dev/vpathX

4. For AIX, try not varyon the volume group in concurrent mode.

Submitting WordPress post from frontend without a plugin

Screen Shot
Screen Shot


This tutorial will guide you to create your own custom post composing form to enable fast blogging with your favorite theme without adding a plugin. I’m looking for any alternative to not porting P2, however…. none.,  finally that’s the reason i wrote it, and It was also inspired by the original development from


I found the code from , but it doesn’t  handle file attachment, indeed most people and I was demand on image uploads for status update,  photo blogging.. whatever . But to get working with build-in WordPress media upload function require a lots of code work,  and if you prefer a fully functional media library, you could base on P2 theme instead.

How it work

  1. It create a post form to allow  the post content inserted by wp_insert_post.
  2. following the post_id, it attach the uploaded files to the post.
  3. Set the first ordered image to the post “featured images”
  4. Lastly, you call get_all_thumbnails before the_content() in order to retrieve the uploaded files.


The critical limitation is lack of media features, unlike build-in media library, you can customize your post images and place it on your desired position. Therefore the images only able to retrieve by the_post_thumbnail() for single image or get_all_thumbnails() for multiple images.

Continue reading “Submitting WordPress post from frontend without a plugin”

Getting ORA-01180 error during database restoration


Having restore database from rman but got a ORA-01180 error, it happen often because your backup file source directory is different then original backup path.

Let’s try

Restore pfile and recreate all necessary directory eg: archive log, admin, a/b/c/udump, datafile… every directory you specified in the pfile

Copy your backup pfile to %ORACLE_HOME%\dbs\

sqlplus / as sysdba
sqlplus> startup nomount pfile='%ORACLE_HOME%\dbs\initORAINST.ora'

Restore controlfile

rman target /
RMAN> restore controlfile from 'D:\path\to\controlfile.bak'

Restore database

RMAN> alter database mount;
RMAN> restore database;

Then you got a similar message as below, because originally your backup path is somewhere different then your current backup file source path.

creating datafile fno=1 name=D:\ORADATA\ORAINST\SYSTEM01.DBF
RMAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-03002: failure of restore command at 02/18/2011 16:55:06
ORA-01180: can not create datafile 1
ORA-01110: data file 1: 'D:\ORADATA\ORAINST\SYSTEM01.DBF'

Try this to re-catalog your backup files then re-run the restore

rman> catalog start with 'D:\backup\source'

Convert XML to CSV using xml2

What you need

  • Red Hat Linux 4, 5
  • gcc
  • libxml2
  • libxml2-devel
  • xml2

Compiling xml2

1. Extract xml2 tar ball

 tar zxvf ./xml2-0.4.tar.gz

2. Modify compiling option in “configure” file

search line between 3428-3470, replace “libxml” with “libxml-2.0”

for example:


    { (echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \"libxml\"") >&5
  ($PKG_CONFIG --exists --print-errors "libxml") 2>&5
  echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; then
  pkg_cv_XML_CFLAGS=`$PKG_CONFIG --cflags "libxml" 2>/dev/null`


    { (echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \"libxml-2.0\"") >&5
  ($PKG_CONFIG --exists --print-errors "libxml-2.0") 2>&5
  echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; then
  pkg_cv_XML_CFLAGS=`$PKG_CONFIG --cflags "libxml-2.0" 2>/dev/null`

3. Run configure


4. Modify the “Makefile”

Change the “XML_CFALGS” var to
Continue reading “Convert XML to CSV using xml2”

Ubuntu 10.10 Maverick with HP Elitebook 2540p – Updated


After thousand time try and errors with linux distribution, opensuse, fedora, ubtuntu… etc, finally get it work perfectly on ubtuntu 10.10 Alpha 2 installation.

There is some changes since 10.04, /etc/X11/xorg.conf is no more present after installation, Xorg now communicate with dbus to get best configure for your hardware.

You may experience blank screen, screen flicking, screen can’t turn on after system suspend, Xorg hang for few mins randomly. So here is the workaround for me to install ubuntu on this laptop.


1. Grab the Maverick CD image, ( Alpha 2 for my case)
2. During CD boot, hit any button to interrupt autoboot
3. Press [F6] to append boot parameters
Continue reading “Ubuntu 10.10 Maverick with HP Elitebook 2540p – Updated”

Pacemaker non-clones resource restart when clones stop/start on other nodes


Node alpha holds resource groups rg_vg01.

Node beta holds the corresponding resources as same as alpha

Both nodes hold instances of the CLVM DLM clone.

As beta is switched into standby mode, the clone
instance on beta correctly transition to the Stopped state.
However, the rg_vg01 resource groups are
restarted in-place on alpha needlessly.


It was caused by resource-stickness score INFINITY order was defined between clone and standalone resource.

order order-clvm-vg inf: clvm-dlm-clone rg_vg01

To solve that, you should change the score to 0 between standalone and clones.

order order-clvm-vg 0: clvm-dlm-clone rg_vg01

A related bug fix.

Connect with local sysdba failed when database start up by CRS

What happen?

A database started up by CRS successfully, but you can’t connect it by local sysdba “sqlplus / as sysdba”, however tnsping or connect with connection string “sqlplus system@prddb” works fine.
Later, you tried to start the database alone manually, it works fine with both connection method.

You inspected every crs log and alertlog but it look seems fine.

Oops, why it inconsistent?

When clusterware trying to startup your oracle, it’ll use $ORACLE_HOME/bin/racgwrap , so make sure your system environment setting is same as the ORACLE_HOME setting in racgwrap script.