Support » Networking WordPress » Azure WP Network Install : 404 Server Error on Subdomains

  • Resolved nant


    Hello. I am trying to set up a network (MU) install of WordPress as an Azure Website. I have completed the following steps. The main site works fine but all subdomain sites give me a 404 Serer error.

    To be specific, I have completed the following steps:

    • Created Azure WordPress website using the gallery. This installed v3.4.
    • Configured it in Shared mode and configured the domains with an A record for
    • Add a *.wp DNS A record. nslookup for <any> yields the IP address of Azure Website. So, it feels like this is ok.
    • Created network install per

    Key lines from my wp-config.php are as follows:
    /** Multisite */
    define(‘WP_ALLOW_MULTISITE’, true);

    define(‘MULTISITE’, true);
    define(‘SUBDOMAIN_INSTALL’, true);
    $base = ‘/’;
    define(‘DOMAIN_CURRENT_SITE’, ‘’);
    define(‘PATH_CURRENT_SITE’, ‘/’);
    define(‘SITE_ID_CURRENT_SITE’, 1);
    define(‘BLOG_ID_CURRENT_SITE’, 1);

    Web.config are as follows:
    <?xml version=”1.0″ encoding=”UTF-8″?>
    <rule name=”WordPress Rule 1″ stopProcessing=”true”>
    <match url=”^index\.php$” ignoreCase=”false” />
    <action type=”None” />

    <rule name=”WordPress Rule 2″ stopProcessing=”true”>
    <match url=”^files/(.+)” ignoreCase=”false” />
    <action type=”Rewrite” url=”wp-includes/ms-files.php?file={R:1}” appendQueryString=”false” />

    <rule name=”WordPress Rule 3″ stopProcessing=”true”>
    <match url=”^” ignoreCase=”false” />
    <conditions logicalGrouping=”MatchAny”>
    <add input=”{REQUEST_FILENAME}” matchType=”IsFile” ignoreCase=”false” />
    <add input=”{REQUEST_FILENAME}” matchType=”IsDirectory” ignoreCase=”false” />
    <action type=”None” />

    <rule name=”WordPress Rule 4″ stopProcessing=”true”>
    <match url=”.” ignoreCase=”false” />
    <action type=”Rewrite” url=”index.php” />

    I have also created the blog.dir. These were the only instructions in the Network Setup page. It appears .htaccess is not required for this version/Azure.

    I am able to navigate the main site ( I also created a site. Whenever I got to that site, however, I get a Server Error 404 File or Directory not found. I get the same error if I type <random_word>

    I am at a loss of how to debug this further. Any help is greatly appreciated.

Viewing 1 replies (of 1 total)
  • Never mind! I just figured it out. Turns out that with Azure, creating a wildcard A record is not sufficient. The request gets to Azure but it never passes it on the website. The 404 appears to be coming from Azure.

    As soon as I added the hosts explicitly to the domain manager, the subdomains work!

    I need to figure out how I can do this without having to add each site to the domain manager.

Viewing 1 replies (of 1 total)
  • The topic ‘Azure WP Network Install : 404 Server Error on Subdomains’ is closed to new replies.