[X-Unix] URL remapped to .local address
Kevin Stevens
kevin_stevens at pursued-with.net
Wed May 5 13:09:46 PDT 2004
On May 5, 2004, at 07:24, Stephen Jonke wrote:
>
> On May 4, 2004, at 3:59 PM, Kevin Stevens wrote:
>> It's not the port mapping, it's a hostname issue. I was able to
>> override
>> it by forcing the host name in the httpd.conf file, but that's an ugly
>> workaround.
>
> Ugly, but can you explain what I need to do to do this ugly fix? I'll
> take ugly until there's a real fix.
>
> Looking through httpd.conf... do I set the ServerName to
> "mydomain.com" ?
Yes, that's the most recent change I made, and it seems to be working
so far. Note that I'm not a web guy, I only ever even run Apache to
share the occasional file/picture. A month ago I edited ServerName
(/etc/httpd/httpd.conf) to the FQDN, in my case www.pursued-with.net.
My machine knows that is one of its aliases because it is running DNS
for pursued-with.net, if you aren't doing that your results may vary.
I'm uncertain if that truly fixed the problem because it's so
inconsistent, but so far, so good. I should *really* be using virtual
domains, since I also own kevinstevens.info at the same address, but as
I say I don't run a serious web server.
Note that hardcoding the server name into every freaking application
(mail, mysql, openssl) is a PITA, and I'd really like to resolve the
underlying problem. For the person asking that this be opened as a bug
report, I haven't done that for the same reason - I don't have a
reproducible event sequence that causes the hostname to change. Below
are some note/links I've accumulated on the issue:
One Apple definition of hostname:
http://docs.info.apple.com/article.html?
artnum=107868&sessionID=anonymous|883669&kbhost=kbase.info.apple.com%3a8
0%2f
A different Apple definition of hostname:
http://docs.info.apple.com/article.html?
artnum=25356&sessionID=anonymous|883669&kbhost=kbase.info.apple.com%3a80
%2f
Using ncutil to change hostnames:
http://discussions.info.apple.com/WebX?13@209.ct7kaS1NlPB.2@.6891cf00/0
Instance report of 10.3 multiple hostname entries (my G5 has done this
on occasion):
http://www.lam-mpi.org/MailArchives/lam/msg07094.php
Older comments about setting hostname in hostconfig (but note different
interpretations of hostname by Apple in first links):
http://www.geektimes.com/macintosh/os/x/10_0/core/hostname.html
http://www.osxfaq.com/tips/dokushoka/index.ws
Changing initial hostname in rc.boot (I DON'T recommend this, it is an
ugly hack and won't prevent it from being changed dynamically later
anyway):
http://www.macobserver.com/comments/commentindivdisplay.shtml?id=12935
> Or do I just put in "mydomain"? What about the port mapping? How does
> that effect what I set ServerName to? Do I need to include the
> external (outside the airport base station) port: "mydomain.com:1234"
> ?
No, the base station should be port translating that for you, so what
the computer sees is a request on the standard port. I don't have an
Airport station (use third party), so I have a question. In your
initial message you say "port mapping of port 1234 to port 80 on
mylocalmachine". Isn't this port translation actually done by IP
address, not name? If not, it should be. I've never seen a device
that does name-based translation, probably for good reason. ;)
KeS
More information about the X-Unix
mailing list