HowtoForge Forums | HowtoForge - Linux Howtos and Tutorials

HowtoForge Forums | HowtoForge - Linux Howtos and Tutorials (http://www.howtoforge.com/forums/index.php)
-   Installation/Configuration (http://www.howtoforge.com/forums/forumdisplay.php?f=4)
-   -   Need help ISPConfig and NAT weird domain problems (http://www.howtoforge.com/forums/showthread.php?t=8220)

nightshade2109 15th November 2006 10:17

Need help ISPConfig and NAT weird domain problems
 
hi i need some help i have ispconfig installed perfectly without any hickups..
but im having weird problems i have 2 connections one being dsl and the other being cdma when i try access a vhost on my site from the dsl on mysite.co.za it connects but times-out, but then i cant access it at all on www.mysite.co.za if i try ping that address it times-out but it still shows my external ip, but if i try ping mysite.co.za it gets a reply from my external ip, but then i cant access it through a web browser.

i think it might have something to do with nat ,how my ispconfig is setup and my firewall because my server has an internal ip address and any request to my external ip goes through nat to my internal one.

any ideas the other thing is if i change the ispconfig's ip's to my external ip everything works, but www.mysite.co.za or mysite.co.za goes to /var/www and the vhosts stop working. any idea? maybe i need to setup my bind config for nat or something im pretty new to linux so if anyone could help i would appreciate it thanks in advance :)

edge 15th November 2006 11:01

It's working fine for me..

I guess you are trying to access the site within you LAN.
If so, add the server IP and domain to the hosts file of the PC that you are using to view the site with

nightshade2109 15th November 2006 12:58

nope im not using lan
 
nope im not using lan ive been testing this over 2 different connections

nightshade2109 15th November 2006 13:52

is this correct ?
 
/etc/bind/pri.exactweb.co.za

TTL 86400
@ IN SOA ct5.ctni.co.za. admin.exactweb.co.za. (
2006111512 ; serial, todays date + todays serial #
28800 ; refresh, seconds
7200 ; retry, seconds
604800 ; expire, seconds
86400 ) ; minimum, seconds
;
NS ct5.ctni.co.za. ; Inet Address of name ser$
NS ns0.xname.org. ; Inet Address of name serv$
;

mail MX 10 exactweb.co.za.

exactweb.co.za. A 196.15.247.77
www A 196.15.247.77
mail A 196.15.247.77


/etc/bind/zones/master_ct5.ctni.co.za

$TTL 3D
@ IN SOA ct5.ctni.co.za. hostmaster.ct5.ctni.co.za. (
199802151 ; serial, todays date + todays serial #
8H ; refresh, seconds
2H ; retry, seconds
4W ; expire, seconds
1D ) ; minimum, seconds
;
TXT "ct5.ctni.co.za, serving YOUR domain :)"
NS ct5.ctni.co.za ; Inet Address of name server
NS ns0.xname.org
MX 10 mail ; Primary Mail Exchanger
localhost A 127.0.0.1
ns1 A 196.15.247.77
ns2 A 195.234.42.1
www CNAME ct5
ftp CNAME ct5
mail CNAME ct5

-------------------------------------------------------------------
/nano/etc/apache2/Vhosts_ispconfig.cond

###################################
#
# ISPConfig vHost Configuration File
# Version 1.0
#
###################################
#
NameVirtualHost 196.15.247.77:80
<VirtualHost 196.15.247.77:80>
ServerName localhost
ServerAdmin root@localhost
DocumentRoot /var/www/sharedip
</VirtualHost>
#
#
######################################
# Vhost: www.exactweb.co.za:80
######################################
#
#
<VirtualHost 196.15.247.77:80>
ServerName www.exactweb.co.za:80
ServerAdmin webmaster@exactweb.co.za
DocumentRoot /var/www/web1/web
ServerAlias exactweb.co.za
DirectoryIndex index.html index.htm index.php index.php5 index.php4 index.php3 $
ScriptAlias /cgi-bin/ /var/www/web1/cgi-bin/
AddHandler cgi-script .cgi
AddHandler cgi-script .pl
ErrorLog /var/www/web1/log/error.log
AddType application/x-httpd-php .php .php3 .php4 .php5
<Files *.php>
SetOutputFilter PHP
SetInputFilter PHP
</Files>
<Files *.php3>
SetOutputFilter PHP
SetInputFilter PHP
</Files>
<Files *.php4>
SetOutputFilter PHP
SetInputFilter PHP
</Files>
<Files *.php5>
SetOutputFilter PHP
SetInputFilter PHP
</Files>
php_admin_flag safe_mode Off
AddType text/html .shtml
AddOutputFilter INCLUDES .shtml
AddType application/vnd.wap.wmlscriptc .wmlsc .wsc
AddType text/vnd.wap.wml .wml
AddType text/vnd.wap.wmlscript .ws .wmlscript
AddType text/vnd.wap.wmlscript .ws .wmlscript
AddType image/vnd.wap.wbmp .wbmp
Alias /error/ "/var/www/web1/web/error/"
ErrorDocument 400 /error/invalidSyntax.html
ErrorDocument 401 /error/authorizationRequired.html
ErrorDocument 403 /error/forbidden.html
ErrorDocument 404 /error/fileNotFound.html
ErrorDocument 405 /error/methodNotAllowed.html
ErrorDocument 500 /error/internalServerError.html
ErrorDocument 503 /error/overloaded.html
AliasMatch ^/~([^/]+)(/(.*))? /var/www/web1/user/$1/web/$3
AliasMatch ^/users/([^/]+)(/(.*))? /var/www/web1/user/$1/web/$3
</VirtualHost>

edge 15th November 2006 14:22

images removed as requested..

nightshade2109 15th November 2006 14:39

its all working
 
thanks found the problem

edge 15th November 2006 14:53

Quote:

Originally Posted by nightshade2109
thanks found the problem

Maybe you can post the fix here, so that other users can learn from it?

nightshade2109 15th November 2006 15:45

post fix
 
sure thing i will post the fix but would you mind removing the pics and links to my site i dont want anyone to see the address and what it looks like :)

nightshade2109 15th November 2006 15:46

post fix
 
i dont mind the ip being there but just not the www.exactweb.co.za

nightshade2109 15th November 2006 16:57

ok how i solved it
 
ok first of all im behind a firewall and im using NAT to translate my internal ip 192.168.111.77 address to my external one 196.15.247.77 now in ispconfig --> management --> settings i set this ip address to my internal one and all other ips like DNS records etc to my external one...

now another problem it seems is that when i ping exactweb.co.za it gets the ip address 192.168.111.77 but times out because im not on the internal network and if i ping www.exacthost.co.za it comes back with the ip address 196.15.247.77 and reply's if there a fix for this issue anywhere on the forums? or does anyone know howto fix it?


All times are GMT +2. The time now is 14:40.

Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2014, vBulletin Solutions, Inc.