Monthly Archives: March 2017

Parse html as PHP is easyapache 4

 

Normal rule in .htaccess to parse html files as php on easyapache 3 are not working on easyapache 4

#AddType application/x-httpd-php .php .htm .html

#<FilesMatch “\.(htm|html|php)$”>
#SetHandler application/x-httpd-php56
#</FilesMatch>

 

Below is the code which will need to be added In cpanel, multiphp manager will add the following for force a specific
version of php:

# php — BEGIN cPanel-generated handler, do not edit
# Set the “ea-php54” package as the default “PHP” programming language.

AddType application/x-httpd-ea-php54 .php .php5 .phtml

# php — END cPanel-generated handler, do not edit

Make sure the AddType and the selected php version matches! So there we go, simple when you know how.

 

 

DNS error bad owner name (check-names) /tmp/cpanel

While working with one client I was getting below error in DNS

DNS error bad owner name (check-names) /tmp/cpanel

So I went ahead and checked DNS zone file using below command

 

root@vps [/var/named]# named-checkzone onlinecsource.com /var/named/onlinesource.com.db
/var/named/onlinesource.com.db:56: _autodiscover._tcp.cheapsalesleads.onlinesource.com: bad owner name (check-names)
/var/named/onlinesource.com.db:57: _autodiscover._tcp.cheapsalesleads.onlinesource.com: bad owner name (check-names)
zone onlinesource.com/IN: loaded serial 2017030209
OK

So the error pointed to line 56 and 57 in zone file

Went ahead and deleted the line 56 and 57 and reload DNS zone file

All works good now

 

 

 

Sorry, the domain xx.xx.104.in-addr.arpa is owned by another user (nobody)

While adding rDNS file in cpanel server I was getting below mentioned error

Sorry, the domain xx.xx.104.in-addr.arpa is owned by another user (nobody)

I have found that at one point in the past this domain was present on this server.

I have removed remnants of the domain from /var/cpanel/users/system and removed references to it from /etc/userdomains and /etc/remotedomains.

I then rebuilt the various caches:

====
/scripts/updateuserdatacache
/scripts/updateuserdomains
====

I am now able to add zone file without any issues