LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 09-07-2008, 02:42 AM   #16
billymayday
LQ Guru
 
Registered: Mar 2006
Location: Sydney, Australia
Distribution: Fedora, CentOS, OpenSuse, Slack, Gentoo, Debian, Arch, PCBSD
Posts: 6,678

Rep: Reputation: 122Reputation: 122

You're going to need better firewalling, so here are a couple of link for you (gentle first)

http://www.linuxhomenetworking.com/w...Using_iptables

http://iptables-tutorial.frozentux.net/

I use a version based on the second link that is called at boot from /etc/rc.local
 
Old 09-07-2008, 07:26 AM   #17
rajendrapoudel
LQ Newbie
 
Registered: Jul 2007
Posts: 28

Original Poster
Rep: Reputation: 15
Hi Billymayday,
I tried to run the command you have given to me, but I am surprised it is not working. here is the out put
[root@web08 ~]# /sbin/iptables -A -p TCP --dport dns -j ACCEPT
Bad argument `TCP'
Try `iptables -h' or 'iptables --help' for more information.
[root@web08 ~]# /sbin/iptables -A -p TCP --dport dns -j ACCEPT
Bad argument `TCP'
Try `iptables -h' or 'iptables --help' for more information.
[root@web08 ~]# /sbin/iptables -A -p UDP --dport dns -j ACCEPT
Bad argument `UDP'
Try `iptables -h' or 'iptables --help' for more information.
 
Old 09-07-2008, 07:29 AM   #18
billymayday
LQ Guru
 
Registered: Mar 2006
Location: Sydney, Australia
Distribution: Fedora, CentOS, OpenSuse, Slack, Gentoo, Debian, Arch, PCBSD
Posts: 6,678

Rep: Reputation: 122Reputation: 122
Sorry - should be

/sbin/iptables -A INPUT -p TCP --dport dns -j ACCEPT

etc (I left out the INPUT)

Note the comment at the bottom of the first link about iptables save overwriting /etc/sysconfig/iptables. Do a search on redhat.com

Last edited by billymayday; 09-07-2008 at 07:31 AM.
 
Old 09-07-2008, 07:30 AM   #19
rajendrapoudel
LQ Newbie
 
Registered: Jul 2007
Posts: 28

Original Poster
Rep: Reputation: 15
I am afraid the given command is not working in my machine.
The output is here.
[root@web08 ~]# /sbin/iptables -A -p TCP --dport dns -j ACCEPT
Bad argument `TCP'
Try `iptables -h' or 'iptables --help' for more information.
[root@web08 ~]# /sbin/iptables -A -p UDP --dport dns -j ACCEPT
Bad argument `UDP'
Try `iptables -h' or 'iptables --help' for more information.
 
Old 09-07-2008, 07:34 AM   #20
rajendrapoudel
LQ Newbie
 
Registered: Jul 2007
Posts: 28

Original Poster
Rep: Reputation: 15
Sorry I paste the old one.. Here is the new command I used I receive following output
Thanks for the link of tutorial I will go through it and will again catch you.

[root@web08 ~]# /sbin/iptables -A INPUT -p TCP --dport dns -j ACCEPT
iptables v1.3.5: invalid TCP port/service `dns' specified
Try `iptables -h' or 'iptables --help' for more information.
 
Old 09-07-2008, 07:38 AM   #21
billymayday
LQ Guru
 
Registered: Mar 2006
Location: Sydney, Australia
Distribution: Fedora, CentOS, OpenSuse, Slack, Gentoo, Debian, Arch, PCBSD
Posts: 6,678

Rep: Reputation: 122Reputation: 122
See http://www.redhat.com/docs/manuals/e...t-act-sav.html
 
Old 09-07-2008, 12:47 PM   #22
chort
Senior Member
 
Registered: Jul 2003
Location: Silicon Valley, USA
Distribution: OpenBSD 4.6, OS X 10.6.2, CentOS 4 & 5
Posts: 3,660

Rep: Reputation: 76
Quote:
Originally Posted by rajendrapoudel View Post
Sorry I paste the old one.. Here is the new command I used I receive following output
Thanks for the link of tutorial I will go through it and will again catch you.

[root@web08 ~]# /sbin/iptables -A INPUT -p TCP --dport dns -j ACCEPT
iptables v1.3.5: invalid TCP port/service `dns' specified
Try `iptables -h' or 'iptables --help' for more information.
"dns" -> "domain".
 
Old 09-07-2008, 02:55 PM   #23
billymayday
LQ Guru
 
Registered: Mar 2006
Location: Sydney, Australia
Distribution: Fedora, CentOS, OpenSuse, Slack, Gentoo, Debian, Arch, PCBSD
Posts: 6,678

Rep: Reputation: 122Reputation: 122
Oops - sorry - did that off memory
 
Old 09-07-2008, 10:49 PM   #24
rajendrapoudel
LQ Newbie
 
Registered: Jul 2007
Posts: 28

Original Poster
Rep: Reputation: 15
Still i am not able to resolve my www.saraadhikari.com (But i can do ping and dig in my own server, it is working well in my sever)
Even I have disable all my firewall and iptables too. Here is all the information about files and output.
Please suggest me how I can solve this?
------
File name: /etc/named.conf
----------------------------
// generated by named-bootconf.pl

include "/etc/rndc.key";

controls {
inet 127.0.0.1 allow { localhost; } keys {"rndckey"; };
};
options {
directory "/var/named";
//dump-file "/var/named/data/cache_dump.db";
//statistics-file "/var/named/data/named_stats.txt";
query-source address * port 53;
// also-notify { ip.address.of.secondary }; // what is mean by this?
// Which IP do I need to write here.
//
};

zone "." IN {
type hint;
file "/var/named/named.ca";
};

zone "179.63.243.221.in-addr.arpa" {
type master;
file "/var/named/179.63.243.221.in-addr.arpa.db";
};
zone "saraadhikari.com" {
type master;
file "/var/named/saraadhikari.com.db";
};
zone "bhakari.com" {
type master;
file "/var/named/bhakari.com.db";
};
---------------------
file name: /var/named/179.63.243.221.in-addr.arpa.db
---------------------
$TTL 14400
@ IN SOA 221.243.63.179. root.web08.linuxdad.com. (
2008090800
14400
3600
1209600
86400 )

179.63.243.221.in-addr.arpa. 14400 IN NS 221.243.63.179.




179.63.243.221.in-addr.arpa. 14400 IN PTR web08.linuxdad.com.
----------------------
File name : /var/named/saraadhikari.com.db
-----------------------
$TTL 14400
@ IN SOA ns1.saraadhikari.com. root.saraadhikari.com. (
2008090800
14400
3600
1209600
86400 )

saraadhikari.com. 14400 IN NS ns1.saraadhikari.com.
saraadhikari.com. 14400 IN NS ns2.saraadhikari.com.

ftp 14400 IN A 221.243.63.179
localhost 14400 IN A 127.0.0.1
mail 14400 IN A 221.243.63.179
pop 14400 IN A 221.243.63.179
saraadhikari.com. 14400 IN A 221.243.63.179
smtp 14400 IN A 221.243.63.179
www 14400 IN A 221.243.63.179

saraadhikari.com. 14400 IN MX 10 mail
--------------------------------
Dig report of www.saraadhikari.com (I tested it from the server itself)
[root@web08 named]# dig www.saraadhikari.com

; <<>> DiG 9.3.4-P1 <<>> www.saraadhikari.com
;; global options: printcmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 49525
;; flags: qr aa rd ra; QUERY: 1, ANSWER: 1, AUTHORITY: 2, ADDITIONAL: 0

;; QUESTION SECTION:
;www.saraadhikari.com. IN A

;; ANSWER SECTION:
www.saraadhikari.com. 14400 IN A 221.243.63.179

;; AUTHORITY SECTION:
saraadhikari.com. 14400 IN NS ns2.saraadhikari.com.
saraadhikari.com. 14400 IN NS ns1.saraadhikari.com.

;; Query time: 0 msec
;; SERVER: 221.243.63.179#53(221.243.63.179)
;; WHEN: Mon Sep 8 12:36:56 2008
;; MSG SIZE rcvd: 90

[root@web08 named]#
--------------------
Ping report of www.saraadhikari.com
--
[root@web08 named]# ping www.saraadhikari.com
PING www.saraadhikari.com (221.243.63.179) 56(84) bytes of data.
64 bytes from web08.saraadhikari.com (221.243.63.179): icmp_seq=1 ttl=64 time=0.015 ms
64 bytes from web08.saraadhikari.com (221.243.63.179): icmp_seq=2 ttl=64 time=0.011 ms
64 bytes from web08.saraadhikari.com (221.243.63.179): icmp_seq=3 ttl=64 time=0.007 ms

--- www.saraadhikari.com ping statistics ---
3 packets transmitted, 3 received, 0% packet loss, time 1999ms
rtt min/avg/max/mdev = 0.007/0.011/0.015/0.003 ms
------------------
Output of iptables -L
----------
[root@web08 named]# iptables -L
Chain INPUT (policy ACCEPT)
target prot opt source destination

Chain FORWARD (policy ACCEPT)
target prot opt source destination

Chain OUTPUT (policy ACCEPT)
target prot opt source destination
[root@web08 named]#
-----
Output of netstat -alnp | grep :53
----
[root@web08 named]# netstat -alnp | grep :53
tcp 0 0 221.243.63.179:53 0.0.0.0:* LISTEN 29205/named
tcp 0 0 221.243.63.180:53 0.0.0.0:* LISTEN 29205/named
tcp 0 0 127.0.0.1:53 0.0.0.0:* LISTEN 29205/named
udp 0 0 0.0.0.0:53 0.0.0.0:* 29205/named
udp 0 0 221.243.63.179:53 0.0.0.0:* 29205/named
udp 0 0 221.243.63.180:53 0.0.0.0:* 29205/named
udp 0 0 127.0.0.1:53 0.0.0.0:* 29205/named
udp 0 0 0.0.0.0:5353 0.0.0.0:* 7116/avahi-daemon:
udp 0 0 :::5353 :::* 7116/avahi-daemon:
[root@web08 named]#
 
Old 09-07-2008, 11:05 PM   #25
billymayday
LQ Guru
 
Registered: Mar 2006
Location: Sydney, Australia
Distribution: Fedora, CentOS, OpenSuse, Slack, Gentoo, Debian, Arch, PCBSD
Posts: 6,678

Rep: Reputation: 122Reputation: 122
Quote:
Still i am not able to resolve my www.saraadhikari.com (But i can do ping and dig in my own server, it is working well in my sever)
What does this mean?
 
Old 09-07-2008, 11:10 PM   #26
billymayday
LQ Guru
 
Registered: Mar 2006
Location: Sydney, Australia
Distribution: Fedora, CentOS, OpenSuse, Slack, Gentoo, Debian, Arch, PCBSD
Posts: 6,678

Rep: Reputation: 122Reputation: 122
Looks like it works to me
Quote:
dig @221.243.63.180 www.saraadhikari.com

; <<>> DiG 9.3.4-P1 <<>> @221.243.63.180 www.saraadhikari.com
; (1 server found)
;; global options: printcmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 57952
;; flags: qr aa rd ra; QUERY: 1, ANSWER: 1, AUTHORITY: 2, ADDITIONAL: 0

;; QUESTION SECTION:
;www.saraadhikari.com. IN A

;; ANSWER SECTION:
www.saraadhikari.com. 14400 IN A 221.243.63.179

;; AUTHORITY SECTION:
saraadhikari.com. 14400 IN NS ns2.saraadhikari.com.
saraadhikari.com. 14400 IN NS ns1.saraadhikari.com.

;; Query time: 158 msec
;; SERVER: 221.243.63.180#53(221.243.63.180)
;; WHEN: Mon Sep 8 14:08:56 2008
;; MSG SIZE rcvd: 90
You will need to supply nameserver information to you registry though, because

dig 221.243.63.180

doesn't work (it doesn't know the nameserver)
 
Old 09-08-2008, 12:32 AM   #27
chort
Senior Member
 
Registered: Jul 2003
Location: Silicon Valley, USA
Distribution: OpenBSD 4.6, OS X 10.6.2, CentOS 4 & 5
Posts: 3,660

Rep: Reputation: 76
Quote:
dig 221.243.63.180

doesn't work (it doesn't know the nameserver)
Why would you expect that to work? You need -x for in-addr.arpa zone.

Any way, you are correct that the nameservers need to be listed with the registrar.

Code:
[chort@horus4 chort]$ whois saraadhikari.com

Whois Server Version 2.0

Domain names in the .com and .net domains can now be registered
with many different competing registrars. Go to http://www.internic.net
for detailed information.

   Domain Name: SARAADHIKARI.COM
   Registrar: ENOM, INC.
   Whois Server: whois.enom.com
   Referral URL: http://www.enom.com
   Name Server: No nameserver
   Status: ok
   Updated Date: 04-sep-2008
   Creation Date: 04-sep-2008
   Expiration Date: 04-sep-2009

>>> Last update of whois database: Mon, 08 Sep 2008 01:28:25 EDT <<<
 
Old 09-08-2008, 12:44 AM   #28
billymayday
LQ Guru
 
Registered: Mar 2006
Location: Sydney, Australia
Distribution: Fedora, CentOS, OpenSuse, Slack, Gentoo, Debian, Arch, PCBSD
Posts: 6,678

Rep: Reputation: 122Reputation: 122
Quote:
Originally Posted by chort View Post
Why would you expect that to work? You need -x for in-addr.arpa zone.
I don't - I simply deleted the wrong bits when I copied and pasted "dig @221.243.63.180 www.saraadhikari.com". Meant to say

dig www.saraadhikari.com
 
Old 09-08-2008, 12:48 AM   #29
rajendrapoudel
LQ Newbie
 
Registered: Jul 2007
Posts: 28

Original Poster
Rep: Reputation: 15
when I am registering www.saraadhikari.com, I have given name server IP address as 221.243.63.180 (previously I was giving 221.243.63.179). I have no 2 Name sever i:e I have only primary name server.
but when I try to ping www.saraadhikari.com or try to do tracert www.saraadhikari.com, it says unable to resolve target system.
 
Old 09-08-2008, 02:50 AM   #30
rajendrapoudel
LQ Newbie
 
Registered: Jul 2007
Posts: 28

Original Poster
Rep: Reputation: 15
Thanks all, I get success for the DNS issues.
Now I am having trouble with browsing my website www.saraadhikari.com I can not access the FtP account of saraadhikari.com too..
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
how to configure master dns in windows2003 server and its slave dns in rhel5 suneellinux Linux - Newbie 1 04-11-2008 05:13 PM
DNS server configuration venki Linux - Networking 3 09-14-2007 05:32 PM
DNS Server: Master/Slave Swakoo Linux - Networking 3 06-30-2006 04:58 AM
Master/Slave server DNS emailssent Linux - Networking 2 10-04-2004 03:21 AM
DNS Server Configuration vinhhv Linux - Networking 1 09-16-2003 07:43 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 09:40 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration