3- Add website files under /var/www/vhost/site_name
4 - Enable them with a2ensite site_name.
5 - Restar Apache2
6 - In Rackspace.com they say the only way to add the domain is to add it via cpanel under DNS tab. Is there anyways I could do it via shell so i don't have to use the Rackspace Ubuntu?

Please explain how I can do step 6 from shell. WHy Rackspace support say "Use control panel to do it, it's the best way".

Are you talking about using Rackspace for the nameserver and adding the domain to that? Or something else?

Yes. I have changed the nameservers on GO Daddy to Rackspace namespaces. There is a DNS section in Racksapce control panel and I need to follow these steps so the site gets available.

Create a domain->Add Record (A/AAAA) -> Add Ip address

I want to be able to do this without Rackspace control panel so I see every step. Before /etc/apache2 was scary and I didnt know anything about it. Now I am familiar and know the purpose of directories in it. But I don't know how to do the Add Domain part in Shell. I am sure it is possible isn't it?

If these are rackspace-controlled nameservers that you do not have any direct access to, then you likely will have to go through their control panel to modify their DNS settings.

If on the other had this is just a control panel for one of your servers that you do have direct access to, then you'd just modify your DNS software's configuration files to add the A record and reload the service.

If these are rackspace-controlled nameservers that you do not have any direct access to, then you likely will have to go through their control panel to modify their DNS settings.

If on the other had this is just a control panel for one of your servers that you do have direct access to, then you'd just modify your DNS software's configuration files to add the A record and reload the service.

About the structure of the file. I need some straight forward information on this. Can someone please explain how this is structured and which of these are compulsory and which optional?

I added 2 comments in the example below:

Code:

NameVirtualHost zend:80 #This is just a name
<VirtualHost zend:80> #Host name and port number. Must begin with <VirtualHost name
DocumentRoot "/Applications/XAMPP/htdocs/zend"
ServerName zend.loc
ErrorLog "/Applications/XAMPP/htdocs/zend/local-error.log"
<Directory "/Applications/XAMPP/htdocs/zend">
Allow from all
AllowOverride All
Order Allow,Deny
Allow from all
Require all granted
</Directory>
</VirtualHost>

your above post has absolutely nothing to do with virtualhosts on UBUNTU Linux!

that info you posted is from your MACBOOK...

Since you are using Xampp, you should not mess with any of the apache-type conf files under your /private folder.....everything you need to have access to , for editing, will be under your /Applications/XAMPP/ folder.