CentOS 7 Plesk server DNS not starting

On a CentOS 7 Plesk server DNS failed to start. Plesk on CentOS 7 use named-chroot.service for starting DNS.

I tried to start DNS with

On checking status, it shows DNS failed to start

I removed Bind DNS server using command

Removed all bind related packages with yum. Removed all DNS configs from /etc and /var/named folder.

Reinstalled Bind DNS and run plesk repair to fix DNS entry

But it did not resolve the problem. I checked named.conf with

It showned error is related with

Problem is fixed by removing the entry “” from

You can use IP or CIDR here. But you don’t need this if you don’t have secondary DNS servers.


Redirect site from www to non-www

It is better to make web site available with one URL. Many sites work with both wwww and non-www (naked domain) urls.

Using www or non-www is personal choice. One advantage of using wwww for URL is when you have lot of sub domains. If you use non-www url, cookies set by the domain will be available to sub domains. This will increase bandwidth usage as cookie need to be sent with every request browser make to web server.


If you are using Apache web server, you can redirect wwww to non-www url by adding following code in .htaccess file


If you use Nginx, it is better create a server entry for www URL, then set a redirect

If you want to use same server entry for www and non-www, add following code to nginx server entry for the web site.

Redirect www domain to non-www

If you use custom ports, use

Redirect Naked Domain to www

Related Posts



Squid Proxy Server allow connection to all ports

By default Squid proxy only allow out going connection to white listed ports that are used commonly. When you visit a site with non standard ports with Squid proxy, it won’t work. To fix this, edit squid configuration file


Replace with

Restart squid with

Related Posts

Install Squid Proxy Server


Install Elasticsearch on Debian for Magento

To install Elasticsearch for Magento on Debian, install Java 1.8 and apt-transport-https

Add key

Add repository

Install Elasticsearch

Enable and start Elasticsearch

Restart Services in Xampp Linux

You can restart services on xampp linux using

To restart, use

Here are other available options

See Auto start XAMPP on Boot

AWS Elastic Beanstalk

Here are some useful command working with AWS Elastic Beanstalk

Application get stored in folder