I was initially using google docs to write the e-book, but then was too lost in formatting the book, or proof reading it again and again. Also I could not update it using my phone, which is pretty much my hand held computer now. I was reading someone else's book online, when using the blog as an ebook sounded reasonable, so I've gone ahead and ported some chapters over to a new blog.
As of now the access is restricted, but if you want access, just comment to this post and I shall be glad to add you as a proof reader to my book.
Showing posts with label virtualization. Show all posts
Showing posts with label virtualization. Show all posts
Nobel Gases
Finally after successfully setting up OpenVPN with Linux server and XP/Ubuntu clients (Vista is evil), we decided to create the final network, but were stalled with the general problem of names (wonder what will I do when I have to name my kids!!). Looked around for tips and there is an RFC on it RFC 1178 which gives a few tips for names.
Without much ado the names helium, neon, argon, krypton clicked. Nobel Gases I say...
Without much ado the names helium, neon, argon, krypton clicked. Nobel Gases I say...
Labels:
computer names,
hardware configuration,
virtualization,
VMWare
Book progress
I've finished the first chapter and have been able to rope in a few friends help me proof read and correct me along the way. I had never thought writing a book would be so much fun, but there is a lot of thought process also put in to make it as simple yet professional for anyone and everyone to understand.
There are many references from wikipedia for definitions of certain terms and terminologies. For those who don't trust wikipedia can search up their favourite reliable resources for further explanation and review.
Another interesting problem I'm facing as I go ahead is, how much detailed should the explanation be. What is the level of assumption I should consider while explaining a topic. Hopefully my friends will be able to point that out, if you are interested to participate in the proof reading, just drop me an email and I'll be glad to send you an invite.
There are many references from wikipedia for definitions of certain terms and terminologies. For those who don't trust wikipedia can search up their favourite reliable resources for further explanation and review.
Another interesting problem I'm facing as I go ahead is, how much detailed should the explanation be. What is the level of assumption I should consider while explaining a topic. Hopefully my friends will be able to point that out, if you are interested to participate in the proof reading, just drop me an email and I'll be glad to send you an invite.
Labels:
ebook,
Practical Implementation,
virtualization,
VMWare,
Xen
My first E-Book: Kick Start a software start-up
Ok after all the configuration and working of the VM server with 4 virtual machines, I found it too much info to blog (lazy me..) with all the steps and configuration (I have some 3 posts still as draft yet to be published). There were some random thoughts on how this process and infrastructure can be used by others (start-ups or low budgets) for thier benefit.
Since most of the blog postings are enlightenments that occured to time once in a while, I've decided to consolidate all this information and jott them down like a step-by-step guide on how can we use the VM infrastructure for small shops or small projects in large shops. The table of contents for this book will look something like this.
Table of Contents
If you have anything else you would like to consider let me know if practically possible I'll try to include it into the book. I hope to get the book out in 2-3 months (provided I can give it one hour a day). People volunteering for proof-reading are most welcome.
Since most of the blog postings are enlightenments that occured to time once in a while, I've decided to consolidate all this information and jott them down like a step-by-step guide on how can we use the VM infrastructure for small shops or small projects in large shops. The table of contents for this book will look something like this.
Table of Contents
- Preface
- Who should read this book
- What are the technologies we'll cover
- Introduction
- Analyzing & Building the server
- Software selection.
- RAID & LVM
- Setup & Configure your first VM
- VPN Applicance
- Creating more Appliances I: Webserver, Database
- Creating more Applicanes II: Version Control, Continious Integration Servers
- Timed VNC sessions (iTalc or vncthumbnailviewer)
- Appendix A: Configure your Linksys router with DDNS
If you have anything else you would like to consider let me know if practically possible I'll try to include it into the book. I hope to get the book out in 2-3 months (provided I can give it one hour a day). People volunteering for proof-reading are most welcome.
Setting up a PHP development environment on your local system
This is an old post I had written on google docs, before VMware Server was free for the general user. Thought could be still more relevant to the general developer for testing in Linux envoirment. VMPlayer I beleive is lighter than VMware Server.
There are 2 stages of setting up the development & testing environment for yourself. The preferred work environment is Linux. If you already on Linux then you can safely skip Stage I, you can directly proceed to Stage II, also if you have Linux already installed, just cross check if you have the LAMP (Linux + Apache + MySQL + PHP) server installed.
Pre Installation Software Download Links
Now we'll check if PHP and Apache have been successfully installed on your system. Go the /var/www folder, you should be seeing a apache2-default folder out there. If you see these then apache seems to be installed. Just open the browser and type http://localhost you should be able to see the apache-default folder over there. If you a receive a page not found then apache is not running or installed properly.
If things look good, next stage is to check PHP installation. Create a file named index.php and type the following there.
Just refresh the localhost (place the file in /var/www) That should give you loads of PHP info on the screen in blue, purple and a huge table. If that happens you are good to go!!! Else something is wrong!!!.
MySQL Check
Open the command line and type
If it opens up with a mysql> prompt then it's good else something is wrong. Your mysql password is blank.
If all sounds good, now go to Stage III
STAGE III: Applications to setup.
Download
How to go about setting them, start the index.php or read the readme file and you should be good to go.
There are 2 stages of setting up the development & testing environment for yourself. The preferred work environment is Linux. If you already on Linux then you can safely skip Stage I, you can directly proceed to Stage II, also if you have Linux already installed, just cross check if you have the LAMP (Linux + Apache + MySQL + PHP) server installed.
Pre Installation Software Download Links
- http://www.vmware.com/download/player/ [VMPlayer]
- http://www.ubuntu.com/getubuntu/download [Ubuntu]
- Download Ubuntu/Xubuntu/Kubuntu Desktop edition ISO, what ever you like... all the same just different filemanagers (Gnome/Xfe/KDE resp.). If you are comfortable with command line, then you can also install the Server edition with no XWindows and only commandline.
- Download and install VMPlayer for your system.
- Download qemu for your operating system and extract in any directory you like.
- Open your commandline to go ahead to bin folder of qemu and type
qemu-img create -f vmdk ubuntu.vmdk 3G
- Here we are creating a 3GB, virtual hard drive in VMWare format. This file will now act as our hard drive for VMWare to install an OS on it. The name of the file is ubuntu.vmdk, you can name it what ever you wish to.
- Now the main vmx file (The VMWare configuration file). change the highlighted paths as per your system.
#!/usr/bin/vmware
config.version = "8"
virtualHW.version = "4"
ide0:0.present = "TRUE"
ide0:0.filename = "ubuntu.vmdk"
# The amount of RAM you want to allot to the Operating system. For Desktop use 512 and server just 256.
memsize = "512"
MemAllowAutoScaleDown = "FALSE"
ide1:0.present = "TRUE"
#ide1:0.fileName = "auto detect"
#ide1:0.deviceType = "cdrom-raw"
ide1:0.fileName = "ubuntu-7.04-server-i386.iso"
ide1:0.deviceType = "cdrom-image"
ide1:0.autodetect = "TRUE"
floppy0.present = "FALSE"
ethernet0.present = "TRUE"
usb.present = "TRUE"
sound.present = "TRUE"
displayName = "Ubuntu LAMP Server"
guestOS = "ubuntu"
nvram = "ubuntu-server-three.nvram"
MemTrimRate = "-1"
ide0:0.redo = ""
ethernet0.addressType = "generated"
uuid.location = "56 4d ce 99 e0 d2 2b bf-73 47 ac 62 65 13 57 86"
uuid.bios = "56 4d ce 99 e0 d2 2b bf-73 47 ac 62 65 13 57 86"
tools.syncTime = "TRUE"
ide1:0.startConnected = "TRUE"
uuid.action = "create"
checkpoint.vmState = "ubuntu-lamp-server.vmss"
isolation.tools.hgfs.disable = "TRUE"
virtualHW.productCompatibility = "hosted"
tools.upgrade.policy = "manual"
tools.remindInstall = "TRUE"
usb.autoConnect.device0 = ""
- After setting all the paths correctly, if you have VMPlayer installed, just save the vmx file, (call it ubuntu.vmx) and double click on the file.
- If all the paths are set correctly, the VMPlayer will boot up the virtual drive and show the ubuntu installation menu. This is easier than windows a million times.
- At the end of the installation (server or desktop) the process will ask you, if you want to install LAMP server. Select it and let it install the LAMP server.
- Reboot the system, and you are good to go. You have successfully installed Ubuntu on VMWare.
Now we'll check if PHP and Apache have been successfully installed on your system. Go the /var/www folder, you should be seeing a apache2-default folder out there. If you see these then apache seems to be installed. Just open the browser and type http://localhost you should be able to see the apache-default folder over there. If you a receive a page not found then apache is not running or installed properly.
If things look good, next stage is to check PHP installation. Create a file named index.php and type the following there.
<?php phpinfo(); ?>
Just refresh the localhost (place the file in /var/www) That should give you loads of PHP info on the screen in blue, purple and a huge table. If that happens you are good to go!!! Else something is wrong!!!.
MySQL Check
Open the command line and type
mysql -uroot
If it opens up with a mysql> prompt then it's good else something is wrong. Your mysql password is blank.
If all sounds good, now go to Stage III
STAGE III: Applications to setup.
Download
- JOOMLA
- WORDPRESS
How to go about setting them, start the index.php or read the readme file and you should be good to go.
Labels:
database,
joomla,
linux,
mysql,
php,
Varun Mehta,
virtualization,
VMWare,
wordpress
Virtualization: The Practical Implementation - I
I'm helping my friend Nitin at his firm Star4ce Technologies put up a virtualization server as their in-house development environment. To begin with we went ahead and ordered some hardware from newegg.
Here is a brief on the hardware we've picked;
A few after thoughts about the hardware choices
Intel Core 2 Quad Q9300
45nm consumes less power compared to predecessors and can be over clocked to 3.2GHz.
ASUS P5K-E
It's not a high end server, but can be used for a low end server. We did see a few other motherboards but opted for this, as they had SLI and were more geared towards being gaming PC's.
Seagate Barracuda 7200.11 ST3500320AS
32MB cache, and I trust Seagate. 5 pieces: 1- OS and 4- RAID 01
CORSAIR 4GB (2 x 2GB) 240-Pin DDR2 800
Nice & reliable.
ZOTAC GeForce 7300GT 256MB
There was no onboard video, this was the lowest and best
So we wait and watch for the parts to arrive. I'll be posting in intermittently the progress, issues & accomplishments along the way.
UPDATE: The shipping was quick, the parts should be arriving today afternoon.
Here is a brief on the hardware we've picked;
- Intel Core 2 Quad Q9300 Yorkfield 2.5GHz LGA 775 95W Quad-Core Processor
- ASUS P5K-E LGA 775 Intel P35 ATX Intel Motherboard
- (5) Seagate Barracuda 7200.11 ST3500320AS 500GB 7200 RPM SATA 3.0Gb/s Hard Drive
- (2) CORSAIR 4GB (2 x 2GB) 240-Pin DDR2 800 (PC2 6400) SDRAM Dual Channel
- LITE-ON 20X DVD±R DVD Burner with LightScribe SATA
- Antec 850W ATX12V / EPS12V Power Supply
- Antec P182 Gun Metal Black 0.8mm cold rolled steel ATX Mid Tower Computer Case
- ZOTAC GeForce 7300GT 256MB 128-bit GDDR2 PCI Express x16
- Logitech USB + PS/2 Cordless Standard Desktop EX110 Mouse Included
A few after thoughts about the hardware choices
Intel Core 2 Quad Q9300
45nm consumes less power compared to predecessors and can be over clocked to 3.2GHz.
ASUS P5K-E
It's not a high end server, but can be used for a low end server. We did see a few other motherboards but opted for this, as they had SLI and were more geared towards being gaming PC's.
Why no Server Motherboards
This is an interesting find we dug into, we decided to hit the server motherboards for the system, as they supported 32GB of RAM quite easily as compared to the 8GB max of the above mentioned. The price was not that different approx $150.00 higher (with dual processors -physical) but it had FB-RAM which took the toll on the price of the system. 4GB on FB-RAM goes to approx $250.00 to $550.00 for 8GB. Yes now that's a whopping high number we are talking about.
So we are back to reality with a lower end system (recall the first article) it was aimed towards start-ups and low budget development teams.
Seagate Barracuda 7200.11 ST3500320AS
32MB cache, and I trust Seagate. 5 pieces: 1- OS and 4- RAID 01
CORSAIR 4GB (2 x 2GB) 240-Pin DDR2 800
Nice & reliable.
ZOTAC GeForce 7300GT 256MB
There was no onboard video, this was the lowest and best
So we wait and watch for the parts to arrive. I'll be posting in intermittently the progress, issues & accomplishments along the way.
UPDATE: The shipping was quick, the parts should be arriving today afternoon.
Agile environment using virtualization
(This document is aimed more towards Java & VMWare, but the same can be replicated for any other language & environment)
Abstract
You have a team of developers working on different modules for a project-product which are inter-dependant. Each developer diligently writes unit & integration tests supporting their code. You want to set-up an agile test environment to run the unit tests & staging server for integration test, but purchasing hardware for multiple machines is a constraint.
The following article provides a guide on how virtualization tools like VMware can be used to set-up staging or QA environment (Agile), with approximate minimum hardware & time investment.
Hardware Sizing
The hardware sizing performed here is not an exact calculation, but an educated guess at the approximate system requirement to run the application.
*MySQL on VMware has some serious performance issues for production environments, if your application is very database intensive with thousands to millions of I/O per second, you might want to avoid virtualization all together. For testing purpose (application sanity, NOT performance) VM is decent.
Considering the above list of applications, and the assumption, each physical core can support 2 virtual cores.
Hardware configuration
The approximate cost of the above system is roughly $2,500.00 - $3,500.00 (as the date of this article)
Set-up
You can either install Windows or Linux (we are on an Ubuntu system) as the HostOS. Since you have 8GB of RAM on the physical machine, 32 bit OS's are not capable of using above 3-4GB. Use 64-bit distributions.
Download VMWare server from [http://www.vmware.com/products/server] select the distribution type depending on your OS. The guest and the host OS can be completely different, they need not be same there is no relation between them.
eg: You can install Windows as host and Linux as guest or vice-versa.
You can either create the virtual machines all by yourself using the VMware step-by-step wizard, or download 'appliances' created by others from the VMware site [http://www.vmware.com/appliances], this saves you the initial installation effort.
When you create a new VM, you are also asked the default networking connection type. NAT and Bridged are the most common options one selects from. Use NAT if you want the VM to talk within its own subnet only, or Bridged if you want other machines on the same subnet as the host access them.
eg: Your host machine is on 192.168.10.50
Pitfalls
You can use the Xen too for virtualization. I've heard pretty good things about it too, with a few short comings & advantages over VMServer (that's a separate topic all together).
There is an article dedicated to Virtual Machines on Wikipedia, you can refer that depending on your needs and fix upon a solution that suits your needs better
Glossary
Virtualization - The virtual machine simulates enough hardware to allow an unmodified "guest" OS (one designed for the same CPU) to be run in isolation
Continuous Integration - Continuous integration describes a set of software engineering practice's that speed up the delivery of software by decreasing integration times
Revision Control - Revision control (also known as version control (system) (VCS), source control or (source) code management (SCM)) is the management of multiple revisions of the same unit of information
Host OS - The operating system installed on the physical machine running VMware Server.
Guest OS - The operating system installed on the virtual machine.
Bibliography
Abstract
You have a team of developers working on different modules for a project-product which are inter-dependant. Each developer diligently writes unit & integration tests supporting their code. You want to set-up an agile test environment to run the unit tests & staging server for integration test, but purchasing hardware for multiple machines is a constraint.
The following article provides a guide on how virtualization tools like VMware can be used to set-up staging or QA environment (Agile), with approximate minimum hardware & time investment.
Hardware Sizing
The hardware sizing performed here is not an exact calculation, but an educated guess at the approximate system requirement to run the application.
Application | RAM | CPU |
Revision Control (SVN or CVS) | 512MB - 1GB | Single |
Continuous Integration (Cruise Control or Bamboo) | 1GB - 2GB | Single |
Database (MySQL*) | 2GB - 4GB | Single-Dual |
Webserver (Wiki, Bugzilla, JIRA) | 1GB | Single |
Considering the above list of applications, and the assumption, each physical core can support 2 virtual cores.
Hardware configuration
- Quad-core processor CPU
- 8GB of RAM
- 5 HDDs (1 OS + 4 HDD with RAID**)
- Other basic required components
The approximate cost of the above system is roughly $2,500.00 - $3,500.00 (as the date of this article)
Set-up
You can either install Windows or Linux (we are on an Ubuntu system) as the HostOS. Since you have 8GB of RAM on the physical machine, 32 bit OS's are not capable of using above 3-4GB. Use 64-bit distributions.
Download VMWare server from [http://www.vmware.com/products/server] select the distribution type depending on your OS. The guest and the host OS can be completely different, they need not be same there is no relation between them.
eg: You can install Windows as host and Linux as guest or vice-versa.
You can either create the virtual machines all by yourself using the VMware step-by-step wizard, or download 'appliances' created by others from the VMware site [http://www.vmware.com/appliances], this saves you the initial installation effort.
When you create a new VM, you are also asked the default networking connection type. NAT and Bridged are the most common options one selects from. Use NAT if you want the VM to talk within its own subnet only, or Bridged if you want other machines on the same subnet as the host access them.
eg: Your host machine is on 192.168.10.50
Tip: If you installing the guest yourself, you can create one master guest, with all the common applications configured (eg: OpenSSH server would be great to have on all the guests for remote management or java), you'll have to change the host name after that.Power up each of the VM's and install the required applications for which they've been set and use them like any other machine on the network.
- Your source files are versioned on the Revision Control Server
- Your tests are run nightly on the Cruise Control Server
- Your team documents the whole project and process on the Wiki, and file bugs in Bugzilla
- Your MySQL server is used for running the DB & the supporting DBs for other apps (bugzilla, wiki)
Pitfalls
- Putting all your eggs in one basket, if the main VMware server fails, all the "machines" (VM's) fail.
- Since the server is dependant on the native OS it sits on, the capabilities of the VMServer is restricted by the OS
- Solution: Use commercial ESX Server or other alternatives
You can use the Xen too for virtualization. I've heard pretty good things about it too, with a few short comings & advantages over VMServer (that's a separate topic all together).
There is an article dedicated to Virtual Machines on Wikipedia, you can refer that depending on your needs and fix upon a solution that suits your needs better
Glossary
Virtualization - The virtual machine simulates enough hardware to allow an unmodified "guest" OS (one designed for the same CPU) to be run in isolation
Continuous Integration - Continuous integration describes a set of software engineering practice's that speed up the delivery of software by decreasing integration times
Revision Control - Revision control (also known as version control (system) (VCS), source control or (source) code management (SCM)) is the management of multiple revisions of the same unit of information
Host OS - The operating system installed on the physical machine running VMware Server.
Guest OS - The operating system installed on the virtual machine.
Bibliography
- http://en.wikipedia.org/wiki/Agile_software_development
- http://en.wikipedia.org/wiki/Xen
- http://en.wikipedia.org/wiki/Comparison_of_virtual_machines
- http://en.wikipedia.org/wiki/Virtualization
- http://en.wikipedia.org/wiki/Continuous_Integration
- http://en.wikipedia.org/wiki/Revision_control
- http://it20.info/blogs/main/archive/2007/11/26/83.aspx
- http://mysql-dba-journey.blogspot.com/2007/11/mysql-and-vmware.html
Labels:
agile,
Continious Integration,
mysql,
NAT,
project planning,
Version control,
virtualization,
VMWare,
Xen
Subscribe to:
Posts (Atom)