Moinz Folks bei 30° [vorgestern wollte ich noch die Heizung anmachen

]
Mal an die Linux Spezialisten.
Ich betreibe einen Testserver.
Beim testen meiner Scripts in Verb. PHP/MySQL :
Wieso iost bei Debian die Adresse "localhost" , obwohl`s der nicht der lokale Rechner ist und bei SuSE gehtdie Verbindung nur über lokale IP?
Wenn zu unklar war, hier Bsp.:
SuSE:
|
PHP Source code
|
1
2
3
4
5
6
7
8
|
<?php
$hostname_gastbuch = "192.168.1.9";
$database_gastbuch = "phpbuch";
$username_gastbuch = "fisch";
$password_gastbuch = "tiefsee";
$gastbuch = mysql_pconnect($hostname_gastbuch, $username_gastbuch, $password_gastbuch) or trigger_error(mysql_error(),E_USER_ERROR);
?>
|
Debian:
|
PHP Source code
|
1
2
3
4
5
6
7
8
|
<?php
$hostname_gastbuch = "localhost"; // <----- !!!!!!!!!!!!!!!!!!!!!!!!
$database_gastbuch = "phpbuch";
$username_gastbuch = "fisch";
$password_gastbuch = "tiefsee";
$gastbuch = mysql_pconnect($hostname_gastbuch, $username_gastbuch, $password_gastbuch) or trigger_error(mysql_error(),E_USER_ERROR);
?>
|
Bevor jetzt gemault wird , was die "doofe" Frage soll: in meiner Weltanschauung ist "localhost" der lokale Rechner , nicht der entfernte.
Falsche Weltanschauung?
Das Reh springt hoch, das Reh springt weit, warum auch nicht, es hat ja Zeit.