LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices


Reply
  Search this Thread
Old 03-21-2005, 07:16 PM   #1
Sapient
Member
 
Registered: Oct 2003
Location: San Luis Obispo, CA
Distribution: SuSE
Posts: 196

Rep: Reputation: 30
Question Another Apache 2. and DNS Question SuSE Enterpr


I have gone through all the threads (most) and have modified everything several times. I have been dealing with this for a couple of days and this thread is the end result. I moved from RedHat to SuSE Enterprise 9 Server. I have listed all the configurations below. I might also add that everything works from local. This is loaded on a Dell Edge Server.
ISSUE

When I try to connect from anywhere else but local (internet) I just get page not found.


############################################
-httpd.config (Apache2)-
# forbid access to the entire filesystem by default
<Directory />
Options None
AllowOverride None
Order allow,deny
Allow from all
</Directory>

# use .htaccess files for overriding,
AccessFileName .htaccess
# and never show them
<Files ~ "^\.ht">
Order allow,deny
Deny from all
</Files>

# Server status
<Location /server-status>
SetHandler server-status

Order Deny,Allow
Deny from all
Allow from 192.168.254. 127.0.0.1
</Location>

############################################
-'Main' server configuration-
(Include /etc/apache2/default-server.conf)

ServerName Linux
DocumentRoot "/home/hingedmind/hmhome"
ServerAdmin root@localhost

<Directory />
Options Includes FollowSymLinks
AllowOverride None
</Directory>

<Directory "/srv/www/htdocs">
Options +Indexes Includes FollowSymLinks
AllowOverride None
</Directory>

<Directory "/home/hingedmind/hmhome">
Options +Indexes Includes FollowSymLinks
AllowOverride None
Order allow,deny
Allow from all
</Directory>

# YaST auto define section
<IfDefine SSL>
SSLEngine off
</IfDefine>

############################################
-Virtual Host File -
Virtual server configuration (Include /etc/apache2/vhosts.d/hingedmind.conf )

NameVirtualHost *

<VirtualHost *>
ServerName localhost
ServerAlias hingedmind
ServerAdmin root@localhost.com
DocumentRoot /srv/www/htdocs
</VirtualHost>

<VirtualHost www(spam checker).hingedmind.com:80>
ServerName Linux
ServerAdmin root@localhost.com
DocumentRoot "/home/hingedmind/hmhome"
HostnameLookups Off
UseCanonicalName Off
ServerSignature On
ScriptAlias /cgi-bin/ "/srv/www/cgi-bin/"

<Directory "/srv/www/cgi-bin">
AllowOverride None
Options +ExecCGI -Includes
Order allow,deny
Allow from all
</Directory>

<Directory /home/hingedmind/hmhome/public_html>
Order allow,deny
Allow from all
</Directory>

<IfModule mod_userdir.c>
UserDir public_html
Include /etc/apache2/mod_userdir.conf
</IfModule>

<Directory "/home/hingedmind/hmhome">
Options Indexes FollowSymLinks
AllowOverride None
Order allow,deny
Allow from all
</Directory>
</VirtualHost>

############################################
-Host File-
127.0.0.1 localhost hingedmind www(spam checker).hingedmind.com Linux localhost.localdomain

# special IPv6 addresses
::1 localhost ipv6-localhost ipv6-loopback

fe00::0 ipv6-localnet

ff00::0 ipv6-mcastprefix
ff02::1 ipv6-allnodes
ff02::2 ipv6-allrouters
ff02::3 ipv6-allhosts

############################################
-named.conf

options {

directory "/var/lib/named";
dump-file "/var/log/named_dump.db";
statistics-file "/var/log/named.stats";

listen-on-v6 { any; };
notify no;
forwarders { 24.93.40.62; 24.93.40.63; 24.93.40.75; 66.68.68.32; 66.68.64.1; };
};

zone "." in {
type hint;
file "root.hint";
};

zone "0.0.127.in-addr.arpa" in {
type master;
file "127.0.0.zone";
};

zone "254.168.192.in-addr.arpa" in {
type master;
file "master/254.168.192.in-addr.arpa.zone";
};

zone "localhost" in {
type master;
file "localhost.zone";
};

zone "hingedmind.com.zone" in {
type master;
file "master/hingedmind.com.zone";
};


include "/etc/named.conf.include";
logging {
category default { default_syslog; };
category queries { default_syslog; };
category xfer-in { default_syslog; };
category xfer-out { default_syslog; };
};

############################################
-Reverse Zone File

$TTL 2d
@ IN SOA Linux.root.localhost (
2005032102 ; serial
3h ; refresh
1h ; retry
1w ; expiry
1d ) ; minimum


@. IN NS Linux.
############################################
-Zone File

$TTL 2d
@ IN SOA @.root.localhost (
(
2005032100 ; serial
3h ; refresh
1h ; retry
1w ; expiry
1d ) ; minimum


Linux. IN NS Linux.
@. IN MX 10 mail.hingedmind.com

############################################
-Resolve File

nameserver 24.93.40.62
nameserver 24.93.40.63
nameserver 24.93.40.75
nameserver 127.0.0.1
search www(prevent spam checker).hingedmind.com



ISSUE

When I try to connect from anywhere else but local (internet) I just get page not found.

Thanks for the help.
 
Old 03-23-2005, 12:26 PM   #2
david_ross
Moderator
 
Registered: Mar 2003
Location: Scotland
Distribution: Slackware, RedHat, Debian
Posts: 12,047

Rep: Reputation: 79
Moved: This thread is more suitable in Networking and has been moved accordingly to help your thread/question get the exposure it deserves.

When I traceroute to your domain it just times out. Can the server see the internet ok?
Can you see LQ with:
lynx www.linuxquestions.org
or:
wget www.linuxquestions.org
 
Old 03-23-2005, 03:26 PM   #3
Sapient
Member
 
Registered: Oct 2003
Location: San Luis Obispo, CA
Distribution: SuSE
Posts: 196

Original Poster
Rep: Reputation: 30
Thank you David.

Yes, the server is down. I have reinstalled SuSE. I felt like it was getting ugly and wanted to start from scratch. Should have it back up in a few.

Let me give you some detail around the network architecture and perhaps that will help. I am sitting on an internal network that has several Windows machines and a SuSE Enterprise 9 server. They each route either through hard-line or wireless connection through a Linksys Router.

The Router in turn has a gateway IP address, its own IP address and three DNS IP Addresses.

I go to Network Solutions where I registered this Domain and put the Router Gateway Address in their A Records DNS section. So when someone goes to www.hingedmind.com they are routed to the Router.

On the router, I have a port forwarding address on port 80 to the SuSE server (httpd (UDP/TCP)).

I used this with RedHat and had no problems. The got-you’s are pretty obvious. The router is DHCP and if anything changes from the provider (gateways, IP addresses, DNS Servers) I have to go back out to Network Solutions and change the DNS A Entry.

The only time this really happens is when they pull maintenance or an electrical storm hits them. In the past year, only a couple of times.


-Thanks

Last edited by Sapient; 03-23-2005 at 03:28 PM.
 
Old 03-23-2005, 03:40 PM   #4
redir
Member
 
Registered: May 2004
Location: Virginia USA
Distribution: Debian_Ubuntu_FreeBSD
Posts: 122

Rep: Reputation: 16
Sapient

I am in the same boat, maybe we can figure something out.

My network is

VerizonDSL -> Westell router gateway and 4 port switch -> IP Forwarding to Debian Sarge Apache2 static , 1 dual boot Win2k/Fedora and 2 win98 boxes with DHCP.

I can see the internet on the debian box and see the server as localhost; hostname(which is www) and 127.0.0.1.

I can see the web server from the other networked boxes.

I can see the web server from the internet outside of my lan via the dynamic ip: 151.199.90.135:8080 (this will probably change tonight)

Strangely I cannot ping this address.

using zone edit I have the domaine name http://www.hereweare.us with the 8080 forwarded.
This address gives me the error you have?

I will probably be up all night working on this.

Incedentially you may want to try some of the dynamic dns services provided. I am going to experiment with one called zoneclient.

I think I may upgrade my service to a static ip.
 
Old 03-23-2005, 03:52 PM   #5
Sapient
Member
 
Registered: Oct 2003
Location: San Luis Obispo, CA
Distribution: SuSE
Posts: 196

Original Poster
Rep: Reputation: 30
redir, thanks for the reply.


I have not had a problem with this in the past. I think it is just a difference between RedHat and SuSE. I use Time Warner.

When you set your IP Address at your Register (Network Solutions, etc...) be sure it is the correct address from the router. It will be the Gateway Address, or the router address (This is not the local IP address, which is usually something like 192.168.1.1).

Then be sure to turn on port forwarding back into your network. This is usually a section called applications and games. I am not sure about your router. I have to note the application and the port it will be using. In this case HTTP and port 80.

From the Linux Server side it is a matter of DNS. I think the Apache setup is straight forward (I say that with a big chunck of salt in my throat).

If your provider is changing the IP address daily then yes, it will be difficult. I thought they usually were static except when a reset takes place.

Let me know what you find out on the DHCP setup. I know very little about it and would like to go that route myself.

Otherwise static IP address start at about $200 a month.


-Thanks
 
Old 03-23-2005, 06:42 PM   #6
Sapient
Member
 
Registered: Oct 2003
Location: San Luis Obispo, CA
Distribution: SuSE
Posts: 196

Original Poster
Rep: Reputation: 30
David,
I have the server back up and can access the site via localhost. The same issue on any other system, even on the same subnet, no page found.

I am thinking DNS

-Thanks
 
Old 03-24-2005, 03:28 AM   #7
Sapient
Member
 
Registered: Oct 2003
Location: San Luis Obispo, CA
Distribution: SuSE
Posts: 196

Original Poster
Rep: Reputation: 30
redir,
Re-read your post. On the port forwarding use just http and usually on Linux it is listening on port 80.

_thanks
 
Old 03-24-2005, 07:23 AM   #8
redir
Member
 
Registered: May 2004
Location: Virginia USA
Distribution: Debian_Ubuntu_FreeBSD
Posts: 122

Rep: Reputation: 16
The problem with my connection is that Verizon blocks 80 so I had to set it up on the router manually to forwart to 8080 and I have apache listening on 8080. I am stumped, this works fine http://151.199.90.135:8080 but when I go to http://www.hereweare.us or http://www.hereweare.us:8080 it refuses the connection. In the former address without the 8080 I get the message: The connection was refused when attempting to contack www.hereweare.us:8080 so Zone Edit is doing it's job forwarding the name and port.

It's like Verizon has some way of blocking http requests that have been resolved through DNS but some how does not block the raw IP. Is that possible?

Thanks again
 
Old 03-24-2005, 08:38 AM   #9
Sapient
Member
 
Registered: Oct 2003
Location: San Luis Obispo, CA
Distribution: SuSE
Posts: 196

Original Poster
Rep: Reputation: 30
redir,
Did you add the address at your domain provider? I bought my domain from Network Solutions and have to add the router gateway or ip address into their DNS section.

Just a thought...


Now you have me wondering if Time Warner has started blocking 80... hmmmm

How is Zone Edit working for you? How does that work? Do they assign you a static address and then manage the dynamic addresses from Verizon? How do they know when it changes?

What did you do on the backend? Did you shutdown dhcp on your server?

How did you setup your zones? Perhaps these are key. I know you need the fully qualified domain name in your host file. Also did you try logging into the url from the server itself?

Could you please post your zone information and host file?
 
Old 03-24-2005, 09:37 AM   #10
redir
Member
 
Registered: May 2004
Location: Virginia USA
Distribution: Debian_Ubuntu_FreeBSD
Posts: 122

Rep: Reputation: 16
I think you may have just answered my question with:

"How did you setup your zones? Perhaps these are key. I know you need the fully qualified domain name in your host file. Also did you try logging into the url from the server itself?"

I forgot to add the FQDN in the host file. I'll have to give that a try.

As far as zone edit here is how it works. I got my name from GoDaddy.com. Then I registered up with zone edit for dynamic dns which is free for up to 5 domains.

Then you need to basically remove the name server that your registrar gave you which in your case is Network Solutions and put in the one's that Zone Edit gives you.

They say it takes about 72 hours I guess for all the name servers to update.

Log into Zone Edit and put all your information in. You need to know what the IP of your router is at that given time and put that in Zone Edit (http://www.whatismyip.com/). Then you need to install a dynamic ip client on one of your networked machines that will basically communicate to zone edit like every 5 minutes or something to just check and see weather or not the ip has changed. It will update automatically and the change will propagate within a minute(not another 72 hours).

Zone Edit seems so far to be doing it’s job just fine. I am not sure about the dynamic ip client I chose however because I have not really gotten a chance to test it. I plan on getting a good power supply and never rebooting my router so hopefully I wont really ever need it but it is nice just in case.

This site has an interesting tool called Shields Up: http://www.grc.com/default.htm It is kind of weird because it showed me that port 22 for ssh was blocked however I can ssh to my server now so I guess use it with a grain of salt.

More to come…

Thanks
 
Old 03-24-2005, 09:47 AM   #11
Sapient
Member
 
Registered: Oct 2003
Location: San Luis Obispo, CA
Distribution: SuSE
Posts: 196

Original Poster
Rep: Reputation: 30
redir,
Great information. Just signed up with ZoneEdit. Let me know how it works for you.

-Thanks
 
Old 03-24-2005, 04:42 PM   #12
Sapient
Member
 
Registered: Oct 2003
Location: San Luis Obispo, CA
Distribution: SuSE
Posts: 196

Original Poster
Rep: Reputation: 30
redir,
Here is what changes. Because of the DHCP issue I was having Network Solutions host my domain email. i.e. name@hingedmind.com. In changing this, I lose it.

What was your work around?

Thanks
 
Old 03-24-2005, 06:43 PM   #13
Sapient
Member
 
Registered: Oct 2003
Location: San Luis Obispo, CA
Distribution: SuSE
Posts: 196

Original Poster
Rep: Reputation: 30
redir,
What changes need to take place on your local server? What do they need to look like? i.e.

DNS
host file
forward zone
reverse zone

Also, what IP address is it asking for? Is this the IP address that the router assigns to the client. the router IP address or the gateway IP address?



-Thanks

Last edited by Sapient; 03-24-2005 at 06:45 PM.
 
Old 03-25-2005, 04:37 AM   #14
Sapient
Member
 
Registered: Oct 2003
Location: San Luis Obispo, CA
Distribution: SuSE
Posts: 196

Original Poster
Rep: Reputation: 30
redir,

I signed up for zoneclient, changed my dns servers. Just did a forward on the email.

I am still a little confused about the correct IP address.

The linksys router notes the following addresses:

Login Type: Automatic Configuration - DHCP
IP Address: 70.113.22.183
Subnet Mask: 255.255.248.0
Default Gateway: 70.113.16.1
DNS 1: 24.26.193.63
DNS 2: 24.93.40.68
DNS 3: 24.93.40.70

Router IP Local IP Address: 192.168.1.1
Subnet Mask: 255.255.255.0

________________________________________


The range I have set for this is 192.168.1.100 – 192.168.1.149. The
router assigns a specific IP address to the Linux server often. i.e
192.168.1.101 etc...


I am still not understanding the specifics as to how the local server zones and host file needs to look.
 
Old 03-25-2005, 09:39 AM   #15
redir
Member
 
Registered: May 2004
Location: Virginia USA
Distribution: Debian_Ubuntu_FreeBSD
Posts: 122

Rep: Reputation: 16
I'm still pretty confused my self

I am pretty sure you want to set a static ip on your linux server that is below the dhcp range that your router assigns so for example :

192.168.1.50

and then <ipconfig eth0 192.168.1.50> to configure your eth card to have that ip. Also edit the etc/network/interfaces (at least thats what it is on Debian) file to have eth0 be static.

It looks like the ip you want to give zoneedit is 70.113.22.183 thats the ip of your router provided by your isp.

Your router should have a local dns for you to set up your local zones in. If your lan is going to be dhcp than don't worry about a host file. The host file is really just a short cut for your local machine to point quickly to another one on the lan but since they are dhcp then as soon as the ip changes locally then the host file is worthless.

If how ever you do set up the server to be static from your router you wil want to enter in the host file something like:

ip.ip.ip.ip hostname hostname.localhost

I believe?????

also you need to have:

127.0.0.1 localhost.localdomain localhost

in there but it probably is already in there.



Anyway the struggle goes on. I am travelling for the weekend but will be back at it next week. I still have not played around with zoneclient enough to really know anything about it.
 
  


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
Another Apache(2) and DNS Question Sapient Linux - Networking 13 03-22-2005 06:42 PM
upgrade RHV3.0 Enterpr from ES to AS jhnsegers Red Hat 1 03-02-2005 03:33 PM
Apache DNS hostnames lookup; SuSE 9.2 Carlee SUSE / openSUSE 0 01-29-2005 03:04 PM
Question about apache in SuSe 9.2 pro Hockeyfan SUSE / openSUSE 8 01-14-2005 05:57 PM
n00b dns/postfix/apache question m61 Linux - Networking 5 11-05-2003 09:02 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Networking

All times are GMT -5. The time now is 08:31 AM.

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