Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8365205
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 9, 20262026-06-09T12:36:17+00:00 2026-06-09T12:36:17+00:00

I have a problem with ServerAliases not resolving to the corresponding server. My hosts

  • 0

I have a problem with ServerAliases not resolving to the corresponding server.

My hosts file is set up as such (this is part of trying to set up APE so please excuse the extraneous code):

127.0.0.1   localhost
255.255.255.255 broadcasthost
::1             localhost 
fe80::1%lo0 localhost

127.0.0.1 testy.local
127.0.0.1 testsite.local
127.0.0.1 ape-test.local
127.0.0.1 chickens.cluck.com
127.0.0.1 ape.ape-test.local
127.0.0.1 ape2.ape-test.local

And the httpd-vhosts.conf:

NameVirtualHost *:80

<VirtualHost *:80>
        ServerName ape-test.local
        ServerAlias ape.ape-test.local
        ServerAlias test.ape-test.local
        ServerAlias *.ape.ape-test.local

        DocumentRoot "/Library/WebServer/Documents/"
</VirtualHost>

<VirtualHost *:80>
    ServerName testy.local
    ServerAlias testy
    ServerAlias fish.local
    DocumentRoot "/Users/myusername/Sites/testsite"
    <Directory /Users/myusername/Sites/testsite/>
        Order allow,deny
        Allow from all
    </Directory>
</VirtualHost>

Virtual hosts have been enabled in httpd.conf, and testy.local resolves to the correct directory. But using ‘testy/’ or ‘fish.local’ will not resolve.

There appears to be nothing written to the error log or console either, and running sudo bash -x /usr/sbin/apachectl -k start reveals no errors.
Running httpd -S reveals no problems either:

VirtualHost configuration:
wildcard NameVirtualHosts and _default_ servers:
*:80                   is a NameVirtualHost
         default server ape-test.local (/private/etc/apache2/extra/httpd-vhosts.conf:44)
         port 80 namevhost ape-test.local (/private/etc/apache2/extra/httpd-vhosts.conf:44)
         port 80 namevhost testy.local (/private/etc/apache2/extra/httpd-vhosts.conf:53)
Syntax OK

So it appears as just the ServerAlias isn’t working.

Does anybody have any ideas?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-09T12:36:19+00:00Added an answer on June 9, 2026 at 12:36 pm

    By looking at your host file, it doesn’t seem you provided ‘testy’ or ‘fish.local’ in your host file. You just need to enter both of these domains in your host file and you should be all set then.

    You need to add them as I did below,

    127.0.0.1   localhost
    255.255.255.255 broadcasthost
    ::1             localhost 
    fe80::1%lo0 localhost
    
    127.0.0.1 fish.local
    127.0.0.1 testy
    127.0.0.1 testy.local
    127.0.0.1 testsite.local
    127.0.0.1 ape-test.local
    127.0.0.1 chickens.cluck.com
    127.0.0.1 ape.ape-test.local
    127.0.0.1 ape2.ape-test.local
    

    Hope this helps.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have problem with configuring NODE.JS. I was trying to install node.js with this
I have problem with this code..I want to extract data from flat file and
I have problem with my query on C, I’m using the oci8 driver. This
I have problem SIMILAR to preventing form data reposting, but not quite the same
I have problem with TableView its empty. In (.h) file: @interface TableViewController : UITableViewController{
I have problem when I try to set a background to .header - nothing
I have problem with reading buffer, when reading is not completed. If the received
I have one problem. I have EasyPHP server on my local computer. I am
Have problem while getting data from Memcached on .NET MVC solution. I have this
I have problem like this https://dev.twitter.com/discussions/4563 if (webResponse.Headers[Content-Encoding] == gzip) { byte[] bytes =

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.