Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win


Apache2 httpd.conf problem

Posted on 2004-10-22
Medium Priority
Last Modified: 2012-08-14
My dishwasher just blew up and the power in the whole house switched off. My webserver down stairs was running apache2 fine before. When I try to start apache2 now on the machine I get the error

Syntax error on line 292 of /usr/local/apache2/conf/httpd.conf:
The port number "http://mysite.com" is outside the appropriate range (i.e., 1..65535).

Even though on line 292 in httpd.conf

ServerName http://mysite.com

And above that is

Listen 80

So why is it doing this?
Question by:confusedmoron
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
  • 2

Expert Comment

ID: 12387666
>The port number "http://mysite.com" is outside the appropriate range (i.e., 1..65535).

The "http://mysite.com" is not regular port number i think :)

>Even though on line 292 in httpd.conf
>                               ServerName http://mysite.com
>And above that is
>                               Listen 80

Maybe something wrong hapend to your config file, edit something in it and save. If it doesn~t work try put a blank line betwen above lines.


Author Comment

ID: 12387957
I commented that line out and it starts fine...  It's trying to read a port number from ServerName?
LVL 15

Accepted Solution

periwinkle earned 1000 total points
ID: 12392456
ServerName shouldn't include the http:// part, and you can specify the port there;  try either:

ServerName mysite.com

(without the http://), or:

ServerName mysite.com:80

Author Comment

ID: 12396411
That worked. Thanks! What confused me was that it was working fine before, with the http:// part. So why would it just start complain about it now?
LVL 15

Expert Comment

ID: 12399622
I don't think that it ever should have worked...

Featured Post

Efficient way to get backups off site to Azure

This user guide provides instructions on how to deploy and configure both a StoneFly Scale Out NAS Enterprise Cloud Drive virtual machine and Veeam Cloud Connect in the Microsoft Azure Cloud.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction As you’re probably aware the HTTP protocol offers basic / weak authentication, which in combination with the relevant configuration on your web server, provides the ability to password protect all or part of your host.  If you were not…
If your site has a few sections that need to be secure when data is transmitted between the server and local computer, such as a /order/ section for ordering or /customer/ which contains customer data, etc it would of course be recommended to secure…
Is your data getting by on basic protection measures? In today’s climate of debilitating malware and ransomware—like WannaCry—that may not be enough. You need to establish more than basics, like a recovery plan that protects both data and endpoints.…
Despite its rising prevalence in the business world, "the cloud" is still misunderstood. Some companies still believe common misconceptions about lack of security in cloud solutions and many misuses of cloud storage options still occur every day. …
Suggested Courses
Course of the Month7 days, 18 hours left to enroll

610 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question