PDA

View Full Version : Thank you and question (naturally right?)


redherring
5th January 2008, 01:53
First off, I want to thank everyone that contributes to this forum. For the past three days it has been my source of invaluable information to say the least.

However, for the past three days my ignorance has been equally unhelpful. (Whats that about for every action.. lol)

I enjoy programming, I used to program quite actively infact, back when dial up BBS's were standard and the Inet was but a myth. For too many years now, I haven't attempt any type of programming until recently when I decided I'm going to take up PHP/AJAX programming.

Instead of paying for a server rented by a host though, I want to setup a production server locally inside my LAN (that is also available via the Inet for a friend or two to check my progress or otherwise those assisting me with programming along the way) albeit, I can't get much to work.

I currently have Ubuntu 7.10 installed, using the "perfect setup/server" installation instructions (thank you Falko?) and ISPConfig installed (the reason was, I thought it would be similiar to a Cpanel which shamefully is all I'm really used to when it comes to a web server)... but, whether or not it's installed properly is beyond me.

Some information regarding my "setup".

I have Cox communications cable modem with probably every port under the sun blocked by them (thank you Cox). I use a Belkin wireless router model F5D7230-4, 6000 series.

I have a DynDNS account as well, the updater is not on the current copy of Ubuntu (I say "current" because I've installed and reinstalled roughly 4 times now thinking it would go better the "next time").

The router has port forwarding and I understand the functioning of that, so I do not suspect that is where the errors lie.

Instead, I believe it is due to my ignorance of Linux, DNS (overall) and ISPConfig -- the very things I want to get working. Go figure.

I'll provide as much as I can that I think are relevent, granted there will probably be more things that are needed before any assistance can come my way and I'll happily provide it asap. I thank you in advance and appreciate anyones assistance.


root@server1:/# ifconfig
eth0 Link encap:Ethernet HWaddr 00:xx:5B:xx:6D:F5
inet addr:192.168.2.10 Bcast:192.168.2.255 Mask:255.255.255.0
inet6 addr: fe80::209:5bff:fe1f:6df5/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1492 Metric:1
RX packets:160087 errors:0 dropped:0 overruns:0 frame:0
TX packets:116731 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:192270468 (183.3 MB) TX bytes:14317864 (13.6 MB)
Interrupt:11 Base address:0x6000

eth0:0 Link encap:Ethernet HWaddr 00:xx:5B:xx:6D:F5
inet addr:192.168.2.5 Bcast:192.168.2.255 Mask:255.255.255.0
UP BROADCAST RUNNING MULTICAST MTU:1492 Metric:1
Interrupt:11 Base address:0x6000

lo Link encap:Local Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
inet6 addr: ::1/128 Scope:Host
UP LOOPBACK RUNNING MTU:16436 Metric:1
RX packets:718 errors:0 dropped:0 overruns:0 frame:0
TX packets:718 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:109738 (107.1 KB) TX bytes:109738 (107.1 KB)



/etc/network/interfaces


# The loopback network interface
auto lo
iface lo inet loopback

# The primary network interface
auto eth0
iface eth0 inet static
address 192.168.2.10
netmask 255.255.255.0
network 192.168.2.0
broadcast 192.168.2.255
gateway 192.168.2.1

auto eth0:0
iface eth0:0 inet static
address 192.168.2.5
netmask 255.255.255.0
network 192.168.2.0
broadcast 192.168.2.255
gateway 192.168.2.1



/etc/hosts


127.0.0.1 localhost
192.168.2.10 server1.example.com server1
192.168.2.5 virtual-ip1.example.com virtual-ip1


# The following lines are desirable for IPv6 capable hosts
::1 ip6-localhost ip6-loopback
fe00::0 ip6-localnet
ff00::0 ip6-mcastprefix
ff02::1 ip6-allnodes
ff02::2 ip6-allrouters
ff02::3 ip6-allhosts



/etc/resolv.conf


search Echostorm
nameserver 192.168.2.1
nameserver 192.168.2.10
nameserver 68.105.xx.11
nameserver 68.105.xx.11
nameserver 68.105.xx.12


The IP address of my router is 192.168.2.1

Please, help me anyone. I'm not exactly fond of IPSConfig, though if someone feels it would be best for me to run it, then I'll of course run it. Trying to learn Linux, learn PHP/AJAX and wanting to host them from a computer that resides in my house - yeah, not exactly one step at a time I realize, so learning PHP/AJAX is on the back burner right now.

Thank you guys/gals.

sjau
5th January 2008, 09:13
what do you actually want to do or where is your problem?

redherring
5th January 2008, 10:27
Oh, my mistake, I had to step away from the computer for a few minutes to tend to my son, I must have lost track.

If I go to http://192.168.2.10 or http://192.168.2.5 from another computer in the LAN -- I receive the:


This IP address is shared. For access to the web site which you look for, enter its address instead of its IP.

For questions or problems please contact the server administrator.


"IP Shared" error page.

However, if I attempt to go to http://www.production.int or http://production.int (which is a site configured in ISPConfig to IP address 192.168.2.5) I get nothing. Almost as though it's not resolving an IP address for the hostname.

I believe due to my complete ignorance of DNS, that is probably where the problem lies.

sjau
5th January 2008, 10:32
well, how is your computer to know where to find those two domains?

You probably have in your computer set your router as dns server and you router does not know either where those domains are to be found.

There's two ways to accomplish that:

(1) Set your server as your primary dns server in your lan
With this option your server will always first be queried for domains. So when you add more test domains there's nothing you have to worry about, it'll always work (as long as your in your lan)

(2) edit your hosts file and add according entries to it:

192.168.2.10 www.production.int production.in

With this option you will have to add new domains to your hosts files for your lan...

redherring
5th January 2008, 10:39
well, how is your computer to know where to find those two domains?

You probably have in your computer set your router as dns server and you router does not know either where those domains are to be found.

There's two ways to accomplish that:

(1) Set your server as your primary dns server in your lan
With this option your server will always first be queried for domains. So when you add more test domains there's nothing you have to worry about, it'll always work (as long as your in your lan)

(2) edit your hosts file and add according entries to it:

192.168.2.10 www.production.int production.in

With this option you will have to add new domains to your hosts files for your lan...


I have my server 192.168.2.10 as the "preferred DNS" in my NIC settings on my Windows box, which BIND9, that's DNS right? I think.

I figured that combined with running ISPConfig (which I assumed whenever a "site" is added, it integrates in some way with BIND9/DNS), that

production.int <=> 192.168.2.5

But aside from that, which is probably completely wrong (ie. ignorance), I really cannot answer your rhetorical? question, as if I knew, I probably wouldn't be in this situation. :)

redherring
5th January 2008, 10:43
If it's of any consolation, I receive this error when performing a:


/etc/init.d/networking restart



root@server1:/home/administrator# /etc/init.d/networking restart
* Reconfiguring network interfaces... SIOCADDRT: File exists
Failed to bring up eth0.
SIOCSIFFLAGS: Cannot assign requested address


I receive this error when performing a:


/etc/init.d/bind9 restart



root@server1:/# /etc/init.d/bind9 restart
* Stopping domain name service... bind rndc: neither /etc/bind/rndc.conf nor /etc/bind/rndc.key was found
[fail]
* Starting domain name service... bind [ OK ]

sjau
5th January 2008, 10:47
what do you get when you do on the server:


ping www.production.int
?

redherring
5th January 2008, 10:52
PING www.production.int (192.168.2.5) 56(84) bytes of data.
64 bytes from www.production.int (192.168.2.5): icmp_seq=1 ttl=64 time=0.111 ms
64 bytes from www.production.int (192.168.2.5): icmp_seq=2 ttl=64 time=0.129 ms
64 bytes from www.production.int (192.168.2.5): icmp_seq=3 ttl=64 time=0.131 ms


10 characters

sjau
5th January 2008, 10:54
can you also post:


cat /etc/hosts


from the server?

redherring
5th January 2008, 10:57
127.0.0.1 localhost
192.168.2.10 server1.example.com server1
192.168.2.5 www.production.int production.in


# The following lines are desirable for IPv6 capable hosts
::1 ip6-localhost ip6-loopback
fe00::0 ip6-localnet
ff00::0 ip6-mcastprefix
ff02::1 ip6-allnodes
ff02::2 ip6-allrouters
ff02::3 ip6-allhosts

sjau
5th January 2008, 11:04
ok, now you are confusing things:

You have to differentiate between server and "desktop".

Can you access www.production.int from your desktop?
What does its hosts file look like and its /etc/resolv.conf?

Can you ping www.production.int from your server?
What does its hosts file look like and its /etc/resolv.conf?

redherring
5th January 2008, 11:07
ok, now you are confusing things:

You have to differentiate between server and "desktop".

Can you access www.production.int from your desktop?
What does its hosts file look like and its /etc/resolv.conf?

Can you ping www.production.int from your server?
What does its hosts file look like and its /etc/resolv.conf?


Sorry. Desktop is a Windows XP machine, it is on the same LAN (switch/router) as the Ubuntu Server.

I cannot access www.production.int from my desktop or ping my server from my desktop using www.production.int however I can ping 192.168.2.5 from my desktop just fine.

The pinging of www.production.int from my server is below:


PING www.production.int (192.168.2.5) 56(84) bytes of data.
64 bytes from www.production.int (192.168.2.5): icmp_seq=1 ttl=64 time=0.111 ms
64 bytes from www.production.int (192.168.2.5): icmp_seq=2 ttl=64 time=0.134 ms


The server /etc/hosts file is below:


127.0.0.1 localhost
192.168.2.10 server1.example.com server1
192.168.2.5 www.production.int production.in


# The following lines are desirable for IPv6 capable hosts
::1 ip6-localhost ip6-loopback
fe00::0 ip6-localnet
ff00::0 ip6-mcastprefix
ff02::1 ip6-allnodes
ff02::2 ip6-allrouters
ff02::3 ip6-allhosts

sjau
5th January 2008, 11:16
What nameservers does your xp machine use? What does its hosts file look like?

redherring
5th January 2008, 11:21
Here is the hosts file from my desktop (truncated all the comment lines):



#
#

127.0.0.1 localhost



My dekstop is currently using two DNS servers:

192.168.2.10

and

68.105.xx.11

as taken by:


C:\IPCONFIG /ALL

sjau
5th January 2008, 11:25
and which is the primary dns server of your xp computer?

remove the domain.int entry from your server and ping the domain again from your server.

redherring
5th January 2008, 11:30
and which is the primary dns server of your xp computer?

remove the domain.int entry from your server and ping the domain again from your server.

192.168.2.10 is the Primary

I commented out the :


#192.168.2.5 www.production.int production.in


in the servers /etc/hosts file

I issued a

/etc/init.d/networking restart


I received the following after doing so:


root@server1:/# /etc/init.d/networking restart
* Reconfiguring network interfaces... SIOCADDRT: File exists
Failed to bring up eth0.
SIOCSIFFLAGS: Cannot assign requested address
[ OK ]


I then issued the ping command:


root@server1:/# ping www.production.int



Which returned the following:

ping: unknown host www.production.int

redherring
5th January 2008, 21:35
Anyone have any ideas please?

My windows (desktop) will not resolve to www.production.int unless I specifically put an entry in my c:\windows\system32\drivers\etc\hosts file, which, seems to defeat the purpose of a DNS server, right?

For the Primary DNS in my windows settings I have the IP address of the server, specifically 192.168.2.10.

Would this error:


root@server1:/# /etc/init.d/bind9 restart
* Stopping domain name service... bind rndc: neither /etc/bind/rndc.conf nor /etc/bind/rndc.key was found
[fail]
* Starting domain name service... bind [ OK ]


Have anything to do with it? Or does it not matter that the rdnc.key is found or not?

From everything that I was able to find and read, it would seem my DNS server is not working. But I don't know. Everyones help is greatly appreciated, I would love to fix this issue.

falko
6th January 2008, 13:18
Would this error:


root@server1:/# /etc/init.d/bind9 restart
* Stopping domain name service... bind rndc: neither /etc/bind/rndc.conf nor /etc/bind/rndc.key was found
[fail]
* Starting domain name service... bind [ OK ]


Have anything to do with it? Or does it not matter that the rdnc.key is found or not?

From everything that I was able to find and read, it would seem my DNS server is not working. But I don't know. Everyones help is greatly appreciated, I would love to fix this issue.Any errors in /var/log/syslog?
What's the output of
dig @localhost www.production.int
on the Linux server?

redherring
6th January 2008, 16:54
/var/log/syslog


Jan 6 08:09:01 server1 /USR/SBIN/CRON[31005]: (root) CMD ( [ -d /var/lib/php5 ] && find /var/lib/php5/ -type f -cmin +$(/usr/lib$
Jan 6 08:17:01 server1 /USR/SBIN/CRON[31111]: (root) CMD ( cd / && run-parts --report /etc/cron.hourly)
Jan 6 08:29:22 server1 -- MARK --
Jan 6 08:30:01 server1 /USR/SBIN/CRON[31271]: (root) CMD (/root/ispconfig/php/php /root/ispconfig/scripts/shell/check_services.ph$
Jan 6 08:39:01 server1 /USR/SBIN/CRON[31384]: (root) CMD ( [ -d /var/lib/php5 ] && find /var/lib/php5/ -type f -cmin +$(/usr/lib$
Jan 6 08:47:32 server1 named[17878]: lame server resolving 'download212.avast.com' (in 'avast.com'?): 193.85.2.117#53
Jan 6 09:00:01 server1 /USR/SBIN/CRON[31646]: (root) CMD (/root/ispconfig/php/php /root/ispconfig/scripts/shell/check_services.ph$
Jan 6 09:09:01 server1 /USR/SBIN/CRON[31759]: (root) CMD ( [ -d /var/lib/php5 ] && find /var/lib/php5/ -type f -cmin +$(/usr/lib$
Jan 6 09:17:01 server1 /USR/SBIN/CRON[31865]: (root) CMD ( cd / && run-parts --report /etc/cron.hourly)
Jan 6 09:29:22 server1 -- MARK --
Jan 6 09:30:01 server1 /USR/SBIN/CRON[32024]: (root) CMD (/root/ispconfig/php/php /root/ispconfig/scripts/shell/check_services.ph$
Jan 6 09:39:01 server1 /USR/SBIN/CRON[32137]: (root) CMD ( [ -d /var/lib/php5 ] && find /var/lib/php5/ -type f -cmin +$(/usr/lib$
Jan 6 09:49:22 server1 -- MARK --
Jan 6 10:00:01 server1 /USR/SBIN/CRON[32400]: (root) CMD (/root/ispconfig/php/php /root/ispconfig/scripts/shell/check_services.ph$
Jan 6 10:09:01 server1 /USR/SBIN/CRON[32513]: (root) CMD ( [ -d /var/lib/php5 ] && find /var/lib/php5/ -type f -cmin +$(/usr/lib$
Jan 6 10:17:01 server1 /USR/SBIN/CRON[32619]: (root) CMD ( cd / && run-parts --report /etc/cron.hourly)
Jan 6 10:26:09 server1 freshclam[24330]: Received signal: wake up
Jan 6 10:26:09 server1 freshclam[24330]: ClamAV update process started at Sun Jan 6 10:26:09 2008
Jan 6 10:26:09 server1 freshclam[24330]: SECURITY WARNING: NO SUPPORT FOR DIGITAL SIGNATURES
Jan 6 10:26:09 server1 freshclam[24330]: See the FAQ at http://www.clamav.net/support/faq for an explanation.
Jan 6 10:26:14 server1 freshclam[24330]: Your ClamAV installation is OUTDATED!
Jan 6 10:26:14 server1 freshclam[24330]: Local version: 0.91.2 Recommended version: 0.92
Jan 6 10:26:14 server1 freshclam[24330]: DON'T PANIC! Read http://www.clamav.net/support/faq
Jan 6 10:26:14 server1 freshclam[24330]: main.inc is up to date (version: 45, sigs: 169676, f-level: 21, builder: sven)
Jan 6 10:26:14 server1 freshclam[24330]: daily.inc is up to date (version: 5385, sigs: 18552, f-level: 21, builder: ccordes)
Jan 6 10:26:14 server1 freshclam[24330]: --------------------------------------
Jan 6 10:30:01 server1 /USR/SBIN/CRON[310]: (root) CMD (/root/ispconfig/php/php /root/ispconfig/scripts/shell/check_services.php $
Jan 6 10:39:01 server1 /USR/SBIN/CRON[421]: (root) CMD ( [ -d /var/lib/php5 ] && find /var/lib/php5/ -type f -cmin +$(/usr/lib/p$
Jan 6 10:49:22 server1 named[17878]: unexpected RCODE (SERVFAIL) resolving '22.2.168.192.in-addr.arpa/PTR/IN': 192.175.48.6#53
Jan 6 10:49:22 server1 named[17878]: client 192.168.2.10#32861: RFC 1918 response from Internet for 22.2.168.192.in-addr.arpa



The output of performing the following on the linux server:


dig @localhost www.production.int


Is:


; <<>> DiG 9.4.1-P1 <<>> @localhost www.production.int
; (1 server found)
;; global options: printcmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NXDOMAIN, id: 39558
;; flags: qr rd ra; QUERY: 1, ANSWER: 0, AUTHORITY: 1, ADDITIONAL: 0

;; QUESTION SECTION:
;www.production.int. IN A

;; AUTHORITY SECTION:
int. 10800 IN SOA dns1.icann.org. noc.icann.org. 2007110500 3600 1800 604800 86400

;; Query time: 139 msec
;; SERVER: 127.0.0.1#53(127.0.0.1)
;; WHEN: Sun Jan 6 10:53:58 2008
;; MSG SIZE rcvd: 90

falko
7th January 2008, 14:17
Jan 6 10:49:22 server1 named[17878]: unexpected RCODE (SERVFAIL) resolving '22.2.168.192.in-addr.arpa/PTR/IN': 192.175.48.6#53I'm not sure what this means... What's in your named.conf?

redherring
7th January 2008, 14:42
If you mean:


/etc/bind/named.conf


That file doesn't appear to exist.

redherring
7th January 2008, 15:52
In fact, the entire directory:

/etc/bind


Doesnt exist.. But in an attempt to help myself (still need your invaluable assistance though) so that I'm not being totally reliant on you guys, I performed this:


root@server1:/etc# aptitude show bind9


And got this in return:


Package: bind9
State: installed
Automatically installed: yes
Version: 1:9.4.1-P1-3
Priority: optional
Section: net
Maintainer: LaMont Jones <lamont@debian.org>
Uncompressed Size: 799k
Depends: libbind9-30, libc6 (>= 2.6-1), libdns32, libisc32, libisccc30, libisccfg30, liblwres30, libssl0.9.8 (>= 0.9.8e-1),
netbase, adduser, libdns32 (= 1:9.4.1-P1-3), libisccfg30 (= 1:9.4.1-P1-3), libisc32 (= 1:9.4.1-P1-3), libisccc30 (=
1:9.4.1-P1-3), lsb-base (>= 3.0-6)
Suggests: dnsutils, bind9-doc
Conflicts: bind
Replaces: bind, dnsutils (< 1:9.1.0-3)
Description: Internet Domain Name Server
The Berkeley Internet Name Domain (BIND) implements an Internet domain name server. BIND is the most widely-used name server
software on the Internet, and is supported by the Internet Software Consortium, www.isc.org.

This package provides the server and related configuration files.


So bind9 is installed, in fact I -think- I remember it being part of the ISPConfig process, I believe encrypted keys were made for it as well? Unsure, it was a few days ago now.

But, should I go about doing something like this:


http://news.softpedia.com/news/How-to-Host-Your-Own-Domain-With-Bind9-on-Ubuntu-49585.shtml


"My" domain is one of DynDNS' available domains, since my ISP blocks port 80, I have to use their port forwarding/masq service.

But, not to jump the gun, as I still need to be able to simply enter the domain

production.int
Into the browser on my Windows machine and be able to have it resolve to the IP of my server of course.

I'm thinking that following that link (or a similiar/better one if you have it) is the way to go, but will await for you experts to let me know. Thank you once again for your assistance, its appreciated and I feel myself becomming less ignorant every day I read about Linux.

redherring
8th January 2008, 16:16
Well, with no new ideas from anyone, I'm going to be reinstalling Linux using just the LAMP feature and forgetting ISPConfig altogether I suppose.

I figured it would make things easier to have ISPConfig installed, even though I have no intentions on actually becoming an ISP (though was hopeful to serve multiple domains for friends) but it doesn't appear that that is the case. I have no idea why my named.conf and named.conf.local are blank and I certainly have no clue how to build one from scratch (all the examples I can find online suggest modifications and what modifications to make - though they dont show an entire file).

I guess the situation either stumped individuals here or you guys are wanting me to hopefully figure it out on my own, which I wish I could do, I really do, but I'm stumped, no clue on what to do and in what order. I'm still very open to suggestions, clues, etc. and I greatly appreciate the assistance I've been given thus far -- I dont wish to sound ingrateful what-so-ever.

falko
8th January 2008, 18:06
I guess the situation either stumped individuals here or you guys are wanting me to hopefully figure it out on my own, which I wish I could do, I really do, but I'm stumped, no clue on what to do and in what order. I'm still very open to suggestions, clues, etc. and I greatly appreciate the assistance I've been given thus far -- I dont wish to sound ingrateful what-so-ever.
I try to help everyone, it's just that I'm not sitting in front of the forum the whole day waiting for posts to answer. I'm in the forum once per day, I was so yesterday, and now I'm here again. In the meantime I haven't answered anyone's posts.

If /etc/bind doesn't exist - did you follow the "Perfect Setup" for Debian Etch? If so, did you maybe accidentally delete that directory?

redherring
8th January 2008, 19:03
I try to help everyone, it's just that I'm not sitting in front of the forum the whole day waiting for posts to answer. I'm in the forum once per day, I was so yesterday, and now I'm here again. In the meantime I haven't answered anyone's posts.

If /etc/bind doesn't exist - did you follow the "Perfect Setup" for Debian Etch? If so, did you maybe accidentally delete that directory?


No no bro, I honestly just figured guys were wanting to me try to help myself first. Sorta like leading a horse to water.. or "you can teach a man to fish" type of deal. :)

That said, I followed these instructions:

http://www.howtoforge.com/perfect_server_ubuntu7.10

I have no idea how the file got deleted, none what so ever. The only things I've done since the install of ISPConfig (it appeared to be successful) was updating clamav, ubuntu and having those updates applied (ie. freshclam, apt-get update, apt-get upgrade).

Should I proceed with doing an:


apt-get --purge remove bind9


and then a:


apt-get install bind9


Or would that totally mess things over? Or better, what to do next I guess? :/

falko
9th January 2008, 16:48
I have no idea how the file got deleted, none what so ever. The only things I've done since the install of ISPConfig (it appeared to be successful) was updating clamav, ubuntu and having those updates applied (ie. freshclam, apt-get update, apt-get upgrade).Maybe the upgrade messed up things.

Should I proceed with doing an:


apt-get --purge remove bind9


and then a:


apt-get install bind9


Or would that totally mess things over? Or better, what to do next I guess? :/Yes, you can try that. :)