Search Posts

How to host domain on VPS without Control Panel

Once you got the server or Vps,Login to the server through SSH using the tool called putty.Once you have logged in type in the bellow command.For CENTOS:Installing Apache with Mysql support

#yum install httpd php php-mysql

Set the Apache Service to start automatically when you restart

#chkconfig httpd on
#service httpd start

Set the mysql service to start automatically when you restart

#chkconfig mysqld on
#service mysqld start


If you want to load any other scripts through the ip address,just upload the file to var/www/html.If you want to host a website and load through a website or domain name.follow the bellow steps just edit the httpd.conf file using nano text editor.

#nano /etc/httpd/conf/httpd.conf
  •        Go to very bottom of the configuration file and add this below lines and replace domain name instead of “”
 NamevirtualHost *:80
<VirtualHost *:80>
ServerAlias *
ErrorLog /var/log/htpd/error_log
CustomLog /var/www/
DocumentRoot /var/www/
<Directory /var/www/>
ordr allow,deny
allow from all
  • Save File
  • Restart the apache server by “service httpd restart”
  • Test for run

Apache setup is complete

Leave a Reply

Your email address will not be published. Required fields are marked *

Social media & sharing icons powered by UltimatelySocial

Enjoy this blog? Please spread the word :)