View Full Version : does my host have a static ip?
Please forgive me being a rookie at networking...
I have a travel agent website hosted on powweb. I'm creating a hotel reservation system on this website that will be accessing a web service to search for hotels. The web service provider is asking me to have a static ip and to register this ip with him. This for them to make sure that only my website is accessing their web service as requests originating from other ips will be discarded.
Any idea if my host has a static ip and if yes, where can I find it (it would be somewhere in OPS i presume)
Thanks in advance
alphadesk
3-8-05, 07:38 AM
I believe this is what they will see depending on what cluster the site will be on ...
cluster01 (www01-www05) 66.152.98.201
cluster02 (www11-www15) 66.152.98.202
cluster03 (www06-www10) 66.152.98.203
cluster04 (www16-www20) 66.152.98.204
cluster05 (www21,24,25,26) 66.152.98.205
cluster06 (www22,23,27) 66.152.98.206
Your individual website does not have it's own static IP.
I don't care so much if my website has an 'individual' ip. I just need to know that the ip will not be changing
If you are talking about the IP of outgoing connection from the site (via cgi or PHP, etc..),
it changes. Within very small range, though.
For the incoming requests, it's always the same, unless PowWeb modifies configuration.
Can you explain the difference between 'incoming' and 'outgoing' requests? I'm wonder if the web service will 'see' the same ip when a php script hosted on powweb sends an xml request over http.
When someone makes a request to your site http://domain.com/,
it will be translated to an IP of cluster0x.powweb.com.
As the request reaches load-balancer, each request is directed to
one of actual web server of that cluster, such as clust0x-www03.powweb.com.
Each cluster may have several web servers, and that's the IPs you will see
if your php script makes an OUTGOING request to other http servers anywhere.
Just test, and you will see.
However, please note that from time to time, this IP changes. Powweb has changed its IP number 2 or 3 times in the last 3 years.
artemide
3-28-05, 06:00 AM
Just test, and you will see.
How do I test this?
RTH10260
3-28-05, 10:54 AM
How do I test this?run this php webpage, it's slightly overkill, but pulled as I used it elsewhere (to test servers running with misaligned clocks:().
Creates a logfile in the same directory as the script, and a test file). The logfile you get to see on the webpage, and it refreshes at intervals.
untested at Powweb !<html><head>
<title>Test Server Farm Timing</title>
<?php
$fd = "testServerFarm.dat";
$fl = "testServerFarm.log";
if ($_SERVER['QUERY_STRING'] != "stop") {
echo "<meta http-equiv=\"refresh\" content=\"10\">" ;
}
if ($_SERVER['QUERY_STRING'] == "start") {
unlink ($fd) ;
unlink ($fl) ;
}
?>
</head><body>
<?php
$now = date ("Y/m/d H:i:s");
$host = $_SERVER['SERVER_ADDR'];
//$host = $_SERVER['HTTP_HOST'];
//$host = $_ENV['COMPUTERNAME'];
$srvr = substr($_SERVER['APPL_PHYSICAL_PATH'],2) ;
$srvr = substr($srvr,0,strcspn($srvr,"\\")) ;
$self = $_SERVER["PHP_SELF"] ;
switch ($_SERVER['QUERY_STRING']) {
case "start" :
echo "<p><a href=\"$self?stop\" target=\"_top\">Stop</a></p>\n" ;
break ;
case "stop" :
echo "<p><a href=\"$self?cont\" target=\"_top\">Continue</a></p>\n" ;
echo "<p><a href=\"$self?start\" target=\"_top\">Restart</a></p>\n" ;
break ;
case "cont" :
echo "<p><a href=\"$self?stop\" target=\"_top\">Stop</a></p>\n" ;
break ;
default :
echo "<p><a href=\"$self?stop\" target=\"_top\">Stop</a></p>\n" ;
}
if (!file_exists($fd)) {
$txt = "$now $host Test file created\n";
$datfile = fopen($fd,"w");
fwrite ($datfile,$txt);
fclose ($datfile);
$oldc = date ("Y/m/d H:i:s", filectime($fd));
$oldm = date ("Y/m/d H:i:s", filemtime($fd));
$logfile = fopen($fl,"w");
fwrite ($logfile,"<table border=\"1\"><caption>Testing Clock Settings $host</caption>\n");
fwrite ($logfile,"<thead><td>time</td><td>IP</td><td>old</td><td>new</td></thead>\n");
fwrite ($logfile,"<tbody>\n");
fwrite ($logfile,"<tr><td>$now</td> <td>$srvr</td><td>created</td><td>$oldc</td></tr>\n");
fclose ($logfile);
} else {
$oldm = date ("Y/m/d H:i:s", filemtime($fd));
clearstatcache () ;
if (touch ($fd)) {
$newm = date ("Y/m/d H:i:s", filemtime($fd));
$logfile = fopen($fl,"a");
fwrite ($logfile,"<tr><td>$now</td> <td>$srvr</td><td>$oldm</td><td>$newm</td></tr>\n");
fclose ($logfile);
} else {
$logfile = fopen($fl,"a");
$txt = "<tr><td>$now</td><td>$srvr</td><td col=\"2\">touch failed</td></tr>\n";
fwrite ($logfile,$txt);
fclose ($logfile);
}
}
readfile($fl);
echo "</tbody></table>"
?>
</body></html>
vBulletin v3.6.0, Copyright ©2000-2009, Jelsoft Enterprises Ltd.