Solved

Plesk - DNS (BIND)

Posted on 2009-04-10
13
1,960 Views
Last Modified: 2013-11-16
I have a PLESK issue.

I am recieving a critical message from mcafee about my DNS.

All I need to do is find out where in PLESK I change the following:
Your DNS under your VPS is using BIND service and default port.
I require this to be disabled.

Thanks.
0
Comment
Question by:wownetwork
  • 8
  • 4
13 Comments
 
LVL 35

Expert Comment

by:torimar
ID: 24120973
You do not say what version of Plesk you are running on what kind of Linux.
Generally, this should do the trick though:

1.) From the panel:
-login to Plesk
-select Virtuozzo > System Services
-now select the "named" service
-click "Stop", then disable Autostart

2.) From the root shell:
-type
/etc/init.d/named stop
chmod 644 /etc/init.d/named
0
 
LVL 16

Expert Comment

by:ai_ja_nai
ID: 24121932
Run from command line: dnsmng --named-disable
0
 

Author Comment

by:wownetwork
ID: 24124264
Plesk version      9.0.0
Operating system      Linux 2.6.9-023stab048.4-smp
CPU      GenuineIntel, Intel(R) Xeon(R)CPU E5335 @ 2.00GHz

Sorry about that.
I'll give it a go guys, let you know my results.  I will try ai ja nai first, since his seems quickest.

Thanks!
0
 

Author Comment

by:wownetwork
ID: 24124304
From my mac (home) I went to Terminal window and access my site via root@whatever

I tried this below:

2.) From the root shell:
-type
/etc/init.d/named stop
chmod 644 /etc/init.d/named

[root@02c1~]# /etc/init.d/named stop
Stopping named:                                       [  OK  ]
[root@02c1~]# chmod 644 /etc/init.d/named
[root@02c1 ~]#

This is what turned up.  Now I went back into McAfee and am re-running their script scan.

I will let you know how it turns out.

I seem to be lacking the savvy'ness approach for running from a command line ... Just for future reference, how do I access the command line via Plesk/Virtuozzo?

Thanks.
0
 

Author Comment

by:wownetwork
ID: 24124435
Hi again,

2.) From the root shell:
-type
/etc/init.d/named stop
chmod 644 /etc/init.d/named

This caused my sub domain (oscommerce) to not load: error:
Unknown MySQL Server Host

So i re-started it. and reset the chmod to 755

QUOTE
ai_ja_nai:
Run from command line: dnsmng --named-disable

Will this have the same effect as what torimar said?

I am going to try:
1.) From the panel:

Since I don't know how to access my command line -- which is probably EXTREMELY simple, but I am not savvy with the lingo, is this the same as root (which I access through putty on my PC?)  else please advise.

Thanks.
0
 
LVL 35

Expert Comment

by:torimar
ID: 24124576
The "command line" is basically the same as the root shell, but the command given by ai_ja_nai will most likely not work, as it is is for Plesk for Windows, not Plesk for Linux.

The command I suggested obviously worked because it disabled your DNS. But now your website cannot be found - which means: there is no other DNS server taking care of your site, so you simply should keep your own server running, not disable it.

The real question here seems to be: Why do you wish to disable your DNS server, and what does McAfee have to do with this??

Unless your site is registered with some other DNS server (like that of the provider of your VPS), you will need your own server up and running. And McAfee is not a firm known for their competence in Linux and Server security - in fact, I don't even trust them for Windows security. So I assume the fault may very well lie in a false alarm given by their "script scan".
0
Free Trending Threat Insights Every Day

Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

 

Author Comment

by:wownetwork
ID: 24125926
Very interesting.

I found that your solution actually worked!  I received my badge back.

I ran the script after I turned off the named server.

I lied to you, my Subdomain works, it is not even that.  This is the catch, my main site works fine when I stop named.  productionsite.com works fine. Just, i have a oscommerce running on my site as well, called productionsite/catalog.com.  This uses a separate database called productionsite_shop.  However, my productionsite: www.productionsite.com and my subdomain site development.production.com both have seperate databases and both work fine.

It is the mysql error confuses me:

Warning: mysql_connect() [function.mysql-connect]: Unknown MySQL server host 'productionsite.com' (2) in /var/www/vhosts/productionsite.com/httpdocs/catalog/includes/functions/database.php on line 19
Unable to connect to database server!

It seems the error is, that the database is no longer accessible.  But I don't see why?  If I have a subdomain still able to call on a seperate database, why would oscommerce not be able to call its specific database?  I am also curious to why there is a (2) in brackets in the error?
0
 
LVL 35

Accepted Solution

by:
torimar earned 500 total points
ID: 24126064
The error message is quite clear in stating that the database is no longer accessible because the database server host is unknown.

Why this is, I can only guess.
It seems that "www.productionsite.com" and "development.production.com" are DNS entries registered via the domain services of your VPS provider - that's why they still work. Whereas the oscommerce shop seems to have been set up via Plesk, and in the course of this setup the DNS record for "productionsite.com" has been registered via the Plesk DNS service.
You must know that technically, "productionsite.com" and "www.productionsite.com" are two different DNS records that both need to expressly point to the same IP (not to talk about "production.com" here which is a completely different TLD).

Since your oscommerce database is expected to be found on "productionsite.com", not "www.productionsite.com", you will either have to adjust the MySQL settings in oscommerce, or you will have to make sure the DNS record "productionsite.com" is registered with your hosts DNS services.
I'd recommend the latter.

Please do not forget that new DNS entries may require a couple of hours, sometimes even a day, in order to start working properly.
0
 

Author Comment

by:wownetwork
ID: 24126620
Thank-you very much.

So for trouble shooting, I attempted to just type in:

www.productionsite/catalog.com -- error

http://productionsite/catalog.com -- error

I didn't install the application via application vault in Plesk, I simply uploaded via FTP myself and installed it.

I truly appreciate your assistance, it has been very helpful.  I think now I will attempt to see what the configuration.php file is set to, and also try some other trouble shooting techniques.

I'll post the answer when I figure it out.  Thank-you again!
0
 

Author Closing Comment

by:wownetwork
ID: 31568993
Thank-you torimar!  Your expertise is greatly appreciated.  Your knowledge is extremely accurate and you have been very kind in taking time to assist me.

Have yourself a great week.

Jonathon.

0
 
LVL 35

Expert Comment

by:torimar
ID: 24127821
I wish you good luck in your further troubleshooting.

You should take note of the fact, however, that both domain names you refer to above are no valid domain names. Slashes inside domain names are illegal characters.

www.productionsite.com/catalog is legal,
www.productionsite/catalog.com is illegal and will never work, nor will http://productionsite/catalog.com.

(When I first saw this in one of your posts above, I thought it was just a typing error, so I did not comment on it.)
0
 

Author Comment

by:wownetwork
ID: 24130138
oops it was a typo.
Thank-you.  I was just retyping after, and wasn't attention, thank-you very much my bad.

http://www.productionsite.com/catalog
http://productionsite.com/catalog

I am going to post my Q's here and see if we have an oscommerce pro on hand.

Thanks.
0
 

Author Comment

by:wownetwork
ID: 24132280
Solution.

oscommerce

catalog/includes/configure.php

change:
define('DB_SERVER', 'productionsite.com');

to:
define('DB_SERVER', 'localhost');

As thought this was a very simple solution.

Thanks!
0

Featured Post

Windows Server 2016: All you need to know

Learn about Hyper-V features that increase functionality and usability of Microsoft Windows Server 2016. Also, throughout this eBook, you’ll find some basic PowerShell examples that will help you leverage the scripts in your environments!

Join & Write a Comment

Suggested Solutions

The purpose of this article is to demonstrate how we can use conditional statements using Python.
Ransomware continues to be a growing problem for both personal and business users alike and Antivirus companies are still struggling to find a reliable way to protect you from this dangerous threat.
Learn how to get help with Linux/Unix bash shell commands. Use help to read help documents for built in bash shell commands.: Use man to interface with the online reference manuals for shell commands.: Use man to search man pages for unknown command…
Get a first impression of how PRTG looks and learn how it works.   This video is a short introduction to PRTG, as an initial overview or as a quick start for new PRTG users.

744 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

15 Experts available now in Live!

Get 1:1 Help Now