Pages

Monday 13 May 2013

Virtualbox 4+

How to mount  shared folder ?


$ sudo mount -t vboxsf  SHARED_FOLDER_NAME /mount/paths

example:
Define shared folder , from vbox interface.  Remember the Machine Name.

Inside linux/Guest machine, run following command to mount the shared folder identified by it's machine name.

$sudo mkdir /home/f_drive

$ sudo mount -t vboxsf  F_DRIVE  /home/f_drive

You're done.


How to  increase or resize installation?
To resize your guest OS disc size, use VBoxmanage utility shipped with virtualbox.


VBoxManage modifyhd YOUR_HARD_DISK.vdi --resize SIZE_IN_MB  

replace YOUR_HARD_DISK.vdi with your OS vdi and SIZE_IN_MB with the size you want to re-allocate.


How to resize root/extended/swap partition inside ubuntu?

Change your guest OS settings and make it boot from ubunut live cd/iso .
Choose "try ubunut"
run gparted
$sudo gparted
now, right click on partition which you want to resize.

You may not be able to resize few. For that, expand your extended partition to fill the remaining unallocated space. After that, move the logical partitions within the extended partition to the end. Then you should be able to shrink the extended partition at it's beginning, thus allowing you to expand your root partition.


Monday 6 May 2013

Browser is downloading .php file, instead of showing it

This case happened with me, when i created a new vhost entry in my server.
I looked around and found few solution.
In the end, i found php mod wasn't installed on my vps.

I then, installed ' libapache2-mod-php5 '
sudo apt get install   libapache2-mod-php5

And, on refreshing the page, i get it working.

Named Based routing or Virtual Host configuration

Ever wonder to run single IP address over multiple domains?
Rephrasing:  Run multiple site/domain on single ip?

Well, here comes name based routing into picture.
You can create virtual host entry in your apache's or nginx's site-available folder, and the you can enable it to point your domain to your vps/server ip address.

Here is how a typical vhost entry look like:

Wednesday 1 May 2013

Mod-wsgi: Installation on Apache2



sudo apt-get install libapache2-mod-wsgi
This should install the module. Now to activate it:

        sudo a2enmod mod-wsgi

Now to restart Apache2:
        sudo /etc/init.d/apache2 restart

Virtualmin: Open-source cpanel alternative

Few days back, I installed EHCP and gave it a try. Though it has the feature which a little literate hosting provider would neeed. However, its interface and feature organisation wasn't appealing. It really need work here . Beacause, after installing when i log into it, it looked totally  perplexed me.  However, it's features were suffice to fill  this gap.
Being said that i would also like to say Big Thank to ehcp developers for coming this far and giving a product that does what it made for.

Next, after googling little more I come across one more open-source cpanel alternative: Virtualmin.
It's based on webmin, So, it may look same for webmin users, but here they have provided support as well. That comes with virutalmin-pro version. Pro version has cool new features like support for Rails hosting, which i really miss in Virutalmin-GPL.