Results 1 to 18 of 18
  1. #1

    Apache configuration problem

    Hello,

    I received my new FreeBSD server yesterday (yay! cheers myles! ) , and I'm trying to properly configure Apache 1.3.26 on it.

    At the first Apache wouldn't even start, and I tried looking at /var/log/httpd-error.log , and saw the following line:

    [Tue Jul 9 19:23:02 2002] [alert] mod_unique_id: unable to gethostbyname("")

    So I disabled mod_unique_id, and it did start then. However, as you might understand, I'm not quite happy with this solution and want to know the cause of this problem. Why is this problem happening? I tried looking in httpd.conf for "empty" host names specified, but could not find anything.

    I also just plainly specified the IP address of my machine instead of the hostname, since my hostname still links to my old IP.

    Anyway, anyone has any idea where this problem is coming from and how to fix it?

    Thanks in advance.

    Regards,

    Leon Mergen
    Leon Mergen
    leon@antrophia.com
    http://www.antrophia.com/

  2. #2
    Join Date
    Sep 2001
    Location
    Sirkali Rural Tamilnadu
    Posts
    738
    You need to specify a hostnaem for the server that resolves to the desired IP on the server. If 1.2.3.4 is your server IP and foo.xanadu.com is the hostname, put an A record mapping foo.xanadu.com to 1.2.3.4 in xanadu.com's zone records

    Alternately use your IP directly in httpd.conf
    I am now happily selling Natural Herbal Hair Oil - happy to be so far removed from technology!

  3. #3
    Problem is, like I stated in my first post, I used my direct IP instead of a hostname to avoid this problem.

    But the strange thing is, it seems like it tries to resolve an empty hostname ...
    Leon Mergen
    leon@antrophia.com
    http://www.antrophia.com/

  4. #4
    Join Date
    Sep 2001
    Location
    Sirkali Rural Tamilnadu
    Posts
    738
    Have you put anything in httpd.conf like ServerName ?

    Also turn HostnameLookups Off [mind the case]
    I am now happily selling Natural Herbal Hair Oil - happy to be so far removed from technology!

  5. #5
    These were already set :

    ServerName 66.250.86.124
    HostNameLookups Off

    Any idea what another problem could be that's causing this?
    Leon Mergen
    leon@antrophia.com
    http://www.antrophia.com/

  6. #6
    Hmmmm... I tried installing proftpd too, but that gives me this problem:

    # ./proftpd
    - Fatal: unable to determine IP address of ''.
    #


    Basically, especially due to this, I have the feeling something is terribly misconfigured on my server.... anyone has any idea what the problem could be?

    Thanks in advance...
    Leon Mergen
    leon@antrophia.com
    http://www.antrophia.com/

  7. #7
    Join Date
    Apr 2001
    Location
    Palm Beach, FL
    Posts
    1,097
    When you type 'hostname' from the command prompt, what do you get? Similarly, what's the 'hostname' line in your /etc/rc.conf?
    Alex Llera
    Professional Server Management
    FreeBSD|Linux|HSphere|Cpanel|Plesk

  8. #8
    PHP Code:
    hostname

    cd /etc
    cat rc.conf

    # -- sysinstall generated deltas -- # Tue Jul  9 02:41:21 2002
    # Created: Tue Jul  9 02:41:21 2002
    # Enable network daemons for user convenience.
    # Please make all changes to this file, not to /etc/defaults/rc.conf.
    # This file now contains just the overrides from /etc/defaults/rc.conf.
    addhostname="localhost.localdomain"
    ifconfig_xl0="inet 66.250.86.124 netmask 255.255.255.128"
    defaultrouter="66.250.86.1"
    kern_securelevel_enable="NO"
    nfs_reserved_port_only="YES"
    sendmail_enable="YES"
    sshd_enable="YES"
    usbd_enable="YES"

    hostname empty.... doesn't look too good to me... any idea how I can fix this?
    Leon Mergen
    leon@antrophia.com
    http://www.antrophia.com/

  9. #9
    Join Date
    Apr 2001
    Location
    Palm Beach, FL
    Posts
    1,097
    Give your box a name. It needs a name.

    # hostname host.domain.com

    and put

    hostname="host.domain.com"

    in your /etc/rc.conf (take out that addhostname line). If your domain.com doesn't have any dns so that the host.domain.com can resolve to an IP properly, use your /etc/hosts file:

    IP HOSTNAME

    ex: 1.2.3.4 host.domain.com

    Hope that makes sense and helps!
    Alex Llera
    Professional Server Management
    FreeBSD|Linux|HSphere|Cpanel|Plesk

  10. #10
    so if I am going to host the domain foobarwombat.com on my box, and it currently is registered with its dns to the ip 4.3.2.1 ...

    And if I add it to /etc/hosts , it will not lookup the IP with its DNS anymore, right?
    Leon Mergen
    leon@antrophia.com
    http://www.antrophia.com/

  11. #11
    nvm, already fixed it...

    thanks a lot allera, I really appreciate it (since it saves me a few hours before my host wakes up )
    Leon Mergen
    leon@antrophia.com
    http://www.antrophia.com/

  12. #12
    Join Date
    Apr 2001
    Location
    Palm Beach, FL
    Posts
    1,097
    Good stuff.

  13. #13
    Join Date
    Nov 2001
    Location
    India, US, Germany
    Posts
    1,609
    HI!
    allera you have really solved this issue very well..
    I'm very impressed by the way you suggested the entire solution to leon....

    Have a great day

    Regards
    Amar
    A student once asked his teacher, "Master, what is enlightenment?"
    The master replied, "When hungry, eat. When tired, sleep. When you need care, come to bobcares....
    https://bobcares.in

  14. #14
    Yes, I must say, it was a really good way...

    Thumbs up!
    Leon Mergen
    leon@antrophia.com
    http://www.antrophia.com/

  15. #15
    Join Date
    Dec 2001
    Location
    Toronto, Ontario, Canada
    Posts
    6,896
    *yawns* *stretches* (late nite, customer needed cpanel help till 4 am), man, i gotta start using WHT as my tech forum obviously
    Myles Loosley-Millman - admin@prioritycolo.com
    Priority Colo Inc. - Affordable Colocation & Dedicated Servers.
    Two Canadian facilities serving Toronto & Markham, Ontario
    http://www.prioritycolo.com

  16. #16
    Join Date
    Apr 2001
    Location
    Palm Beach, FL
    Posts
    1,097
    Thanks, guys.
    Alex Llera
    Professional Server Management
    FreeBSD|Linux|HSphere|Cpanel|Plesk

  17. #17
    Originally posted by porcupine
    *yawns* *stretches* (late nite, customer needed cpanel help till 4 am), man, i gotta start using WHT as my tech forum obviously
    Lol, nothing against your forums, Myles, but I just tought that I would have my problem fixed sooner this way...
    Leon Mergen
    leon@antrophia.com
    http://www.antrophia.com/

  18. #18
    Join Date
    Dec 2001
    Location
    Toronto, Ontario, Canada
    Posts
    6,896
    oh definatly, like 11 users on our forums, compared to what, 16200 or so on WHT, no question about it there , and no complaints about it here, it's the logical choice for free tech support, the more that see it, the faster you get your answers.
    Myles Loosley-Millman - admin@prioritycolo.com
    Priority Colo Inc. - Affordable Colocation & Dedicated Servers.
    Two Canadian facilities serving Toronto & Markham, Ontario
    http://www.prioritycolo.com

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •