Posts

This blog will be getting seriously and interesting on my following posts!!!

Hi All, I have just resigned from my previous work. The reason of my resignation is a decision that I am fully confident to pave my way into the real world of programming and technology. I am now hailing this time to be getting serious and create technologies that I am interested into. I blogged this out so that I could not forget the day I promised to do hard work and always push myself to achieve my goal and make people happy with my work. I hope I will be getting into my finish line, if God will provide, as I do trust him and I hope he'll always be with me and with my love ones. God bless us all!!! Regards, ToytoyGogie

LVM: How to remove a volume using pvremove

First, I encountered this error "Can't pvremove physical volume "/dev/sdc1" of volume group "nova-volumes" without -ff" (I'm actually using OpenStack but it's another story). So to remove this, do first, ~# pvscan   PV /dev/sdb1   VG nova-volumes    lvm2 [1.82 TiB / 1.82 TiB free]   PV /dev/sda5   VG cloudmaster     lvm2 [297.85 GiB / 12.00 MiB free]   PV /dev/sdc1                      lvm2 [1.82 TiB]   Total: 3 [3.93 TiB] / in use: 2 [2.11 TiB] / in no VG: 1 [1.82 TiB] Then, when I do, ~# pvremove /dev/sdc1  Can't pvremove physical volume "/dev/sdc1" of volume group "nova-volumes" without -ff So I need to, ~# vgreduce nova-volumes /dev/sdc1   Removed "/dev/sdc1" from volume group "nova-volumes" Then do `pvscan` again, ~# pvscan   PV /dev/sdb1   VG nova-volumes    lvm2 [1.82 TiB / 1.82 TiB free]   PV /dev/sda5   VG clou...

Resizing Disk Images in Linux

To resize the disk image in Linux, do # sudo fsck.ext4 -f DISK_IMAGE_FILE # sudo resize2fs DISK_IMAGE_FILE This is very helpful specially if you are having an instance in the cloud and wanted to resize an image.

Mounting an EBS in Eucalyptus

First, do # fdisk -l to list the device available. You can identify what's the current device the Eucalyptus have avail for the current block storage given. Now, to mount this, do # mkfs.ext4 /dev/sda where my current filing system is ext4 and the availed virtual device is /dev/sda. Then afterwards, you can do # mount -t ext4 /dev/sda /path/to/mounted/directory Hope this helps.

Eucalyptus - Save current Instance as backup with the power of "dd" command

The current setup for this is that, I have this current instance in Eucalyptus and was already customized while its being in the cloud. This means like, installing packages and added extra configurations to some packages. While its time wasting if to go back and install those packages, doing a dd (disk dump) tool is very helpful. Below is the command I issued, #> dd if=/dev/vda1 of=jenkins.img conv=noerror,sync  I use the conv=noerror,sync which the sync to sync every input block and also its meta data. I've tried w/o that option and it didn't work.  After I run this into the cloud, I can ssh and I see the state before dd finished, it was there. It's really great! Hope this helps!

Delete a file with a leading "dash" or (-) in Linux

To delete a file with a leading dash, for example, # ls -al total 36195068 drwxr-xr-x  3 toor toor        4096 2011-06-15 16:46 . drwxrwxrwx 12 toor toor        4096 2011-06-21 14:11 .. -rw-r--r--  1 toor toor        6887 2011-06-10 13:01 -C do # unlink -- -C Hope this helps

Don't be a hypocrite! - One of my favorite gospel in the Holy Bible

Holy Gospel of Jesus Christ  according to Saint Matthew  6: 1-6.16 -18. Jesus said to his disciples: «Take care not to perform righteous deeds in order that people may see them; otherwise, you will have no recompense from your heavenly Father. When you give alms, do not blow a trumpet before you, as the hypocrites do in the synagogues and in the streets to win the praise of others. Amen, I say to you, they have received their reward. But when you give alms, do not let your left hand know what your right is doing, so that your almsgiving may be secret. And your Father who sees in secret will repay you. When you pray, do not be like the hypocrites, who love to stand and pray in the synagogues and on street corners so that others may see them. Amen, I say to you, they have received their reward. But when you pray, go to your inner room, close the door, and pray to your Father in secret. And your Father who sees in secret will repay you. When you fast, do not look gloomy li...