• Resolved Dan & Jennifer

    (@danstuff)


    Hi guys!

    I’ve scoured the forums here looking for the specific issue I’m facing and have not found it… so here goes.

    Just upgraded our main 3.5 year-old WordPress website to 3.0.1 (which went great). Then tried to enable MultiSite on it – which went great but it’s not quite “working”.

    The “enable MultiSite” process worked fine, then I actually created a couple of sub-sites. No errors, all good, I see the sites under WP Admin -> Sites. but I’m not sure the sub-sites are actually getting “fully created”…

    Because when I go to “Super Admin -> Sites” in the listing of sites the links to “visit” and “backend” for any of the sub-sites aren’t correct – they literally all just go to the main MultiSite admin dashboard. i don’t even have to click on them, I see that’s where the link goes by hovering over it.

    The main website is working just fine – https://www.dan-and-jennifer.com/
    But the sub-site I’m testing with isn’t working – https://www.dan-and-jennifer.com/zztest/ – it just says “error establishing database connection”. but i think the problem’s deeper than that, since I don’t even see a working link to “visit” or “backend” for this subsite under “Super Admin -> Sites” (see above)

    Also this may or may not help, but I noticed there are NO files whatsoever being created in wp-content/blogs.dir – in contrast, in our other wordpress multisite installs I see a directory immediately created in there with what I think is the ID of the sub-site created.

    Just to qualify, I’m only having this problem on our main website, a WordPress install that’s been upgraded many times since before WP 2.3. I’ve installed several other brand new Worpress 3.0.1 installs just for testing, enabled MultiSite and created sub-sites that all worked great, no problems whatsoever… so I’ve seen this work flawlessly.. it’s only having problems on this one more established site.

    I also upgraded one of our other “main” established WordPress sites (albeit a newer one – this one started around WP 2.5) to 3.0.1, enabled MultiSite, and created a perfectly working SubSite for it, no problems… working great. same process – changed “SUBDOMAIN_INSTALL” to false after enabling MultiSite.
    here it is: https://www.TodayIsThatDay.com – and here’s the Sub-site: https://www.TodayIsThatDay.com/inspirational-quotes/

    I’ve seen others mention similar symptoms in a few other MultiSite support threads, but the solution each time was the person saying “nevermind, I just deleted the wordpress install, re-installed, and it’s fine now”. But for us that’s not an option, we’re talking about our main website so we have to enable Multisite for this installation, can’t start fresh.

    Has anyone seen something like this? Ideas?

    Thanks!!
    Dan

    ——— More Config details for site having issues —————

    test website URL (main blog in MultiSite install) – https://www.dan-and-jennifer.com/
    Test sub-site URL (site set up under main MultiSite blog) – https://www.dan-and-jennifer.com/zztest/

    * Since this was a “over 30 days” wordpress install, the MultiSite enable function chose “subDomain” for me. no problem, after it finished I updated wp-config.php and changed “define( ‘SUBDOMAIN_INSTALL’, true );todefine( ‘SUBDOMAIN_INSTALL’, false );`

    WordPress: 3.0.1
    MultiSite config: all are subDirectory based, no subDomains

    Here’s the relevant section of wp-content:

    define( ‘MULTISITE’, true );
    define( ‘SUBDOMAIN_INSTALL’, false );
    $base = ‘/’;
    define( ‘DOMAIN_CURRENT_SITE’, ‘www.dan-and-jennifer.com’ );
    define( ‘PATH_CURRENT_SITE’, ‘/’ );
    define( ‘SITE_ID_CURRENT_SITE’, 1 );
    define( ‘BLOG_ID_CURRENT_SITE’, 1 );

    and .htaccess:

    # BEGIN WordPress
    <IfModule mod_rewrite.c>
    RewriteEngine On
    RewriteBase /
    RewriteRule ^index.php$ – [L]

    # uploaded files
    RewriteRule ^([_0-9a-zA-Z-]+/)?files/(.+) wp-includes/ms-files.php?file=$2 [L]

    # add a trailing slash to /wp-admin
    RewriteRule ^([_0-9a-zA-Z-]+/)?wp-admin$ $1wp-admin/ [R=301,L]

    RewriteCond %{REQUEST_FILENAME} -f [OR]
    RewriteCond %{REQUEST_FILENAME} -d
    RewriteRule ^ – [L]
    RewriteRule ^([_0-9a-zA-Z-]+/)?(wp-(content|admin|includes).*) $2 [L]
    RewriteRule ^([_0-9a-zA-Z-]+/)?(.*.php)$ $2 [L]
    RewriteRule . index.php [L]
    </IfModule>
    # END WordPress

    ** This will probably make no difference to anything, but the URLs above (on the domain dan-and-jennifer.com) and all the config info are a fully functionaly duplicate of our actual production website (AskDanAndJennifer.com), since this debugging was causing us production downtime. ?? “luckily” so to speak, the duplicate site is having the exact same issues the production site is having…

    ——— Config details ——————————

Viewing 15 replies - 1 through 15 (of 45 total)
  • Also this may or may not help, but I noticed there are NO files whatsoever being created in wp-content/blogs.dir – in contrast, in our other wordpress multisite installs I see a directory immediately created in there with what I think is the ID of the sub-site created.

    But the blogs themselves don’t live in there – those folders are purely for media uploads, that’s it.

    the blogs are all *virtual* through the magic of htaccess (in the case of subfolder blogs). The htaccess is slightly different for subfolder setups.

    (ipstenu, where are you? I know you have a copy handy…)

    Thread Starter Dan & Jennifer

    (@danstuff)

    Hi Andrea, thanks for replying.

    The htaccess is slightly different for subfolder setups.

    Yeah, noticed that… but all my sites are directory-based and that section of the htaccess file in the broken site is exactly the same as in the working sites – for example the TodayIsThatDay site which is also WP301 upgraded and multisited and has a fully functional sub-site.

    (Re: blogs.dir directories being created for sub-sites but not in the site that’s having issues)

    blogs themselves don’t live in there – those folders are purely for media uploads, that’s it.

    yes, i was just thinking this may be a clue of some sort, because I noticed all the other multisite installs – and they’re all subdirectory based – they all automatically create a directory under blogs.dir as soon as I add a sub-site. except on the site I’m having issues with… there’s nothing in blogs.dir. and the file permissions are all fine.

    I hope it’s just something silly and obvious that I may be missing… ??

    Thanks!
    Dan

    Your website is having the exact same problem as my website. Please eMail or call me if you get a solution. If you send me your contact info then I will do the same.

    <deleted – please do not post personal contact info>

    For the db error, and the link in the backend, it’s most likely a plugin interfering. You’ll have to turn them off, create a new site, then see if it works.

    The db error on a new site means it didn’t get created in the db itself.

    Moderator Ipstenu (Mika Epstein)

    (@ipstenu)

    ?????? Advisor and Activist

    I was on the train ?? That .htaccess looks good for a subfolder install.

    yes, i was just thinking this may be a clue of some sort, because I noticed all the other multisite installs – and they’re all subdirectory based – they all automatically create a directory under blogs.dir as soon as I add a sub-site. except on the site I’m having issues with… there’s nothing in blogs.dir. and the file permissions are all fine.

    I have had that problem (and still do on one site) because I seriously jiggered with the install (blog #1 doesn’t exist, renamed database tables, blog #3 is my MAIN site, etc etc – DO NOT do what I did!).

    Try the plugins. If that doesn’t help, I’d consider exporting everything from your current site, making a fresh install of 3.0.1, and importing the posts from your current site. Overkill, perhaps, but it may help.

    Thread Starter Dan & Jennifer

    (@danstuff)

    For the db error, and the link in the backend, it’s most likely a plugin interfering. You’ll have to turn them off, create a new site, then see if it works.

    The db error on a new site means it didn’t get created in the db itself.

    @andrea hmm, i wondered about that. but all the plugins were off when I created the test sub-site. just to test again i just disabled all of them, deleted this sub-site and created a new sub-site. with all plugins off.

    Result: Same situation exactly… created the sub-site fine, but “backend” just goes to the main admin and “visit” does too. if i manually enter the URL that “should” belong to the sub-site I see the same error on that page: “Database error: Error establishing a database connection”. here it is: https://www.dan-and-jennifer.com/yytest

    Any idea what else – other than plugins – could keep the sub-sites from actually being created? ??

    @ipstenu this site I’m debugging now (dan-and-jennifer.com) IS a fresh WP 301 install – and a PHPMyAdmin table-based import of the actual content of our production site (AskDanAndJennifer.com). I was having these same problems on our production site and the debugging was causing us downtime so did the fresh install and imported the actual posts/comments/categories/users into this one. and it’s doing the exact same thing the production site was…

    Thoughts?

    Thanks!
    Dan

    Moderator Ipstenu (Mika Epstein)

    (@ipstenu)

    ?????? Advisor and Activist

    How odd… I get a 404 on https://www.dan-and-jennifer.com/zztest/ and the db error on https://www.dan-and-jennifer.com/yytest

    Is there anything in your server logs?

    Also, you didn’t create folders on the server for yytest, right?

    Any idea what else – other than plugins – could keep the sub-sites from actually being created? ??

    Go look in the database itself – got any tables in there being created with the new blog info?

    stab in the dark: does the db user have ALL permissions on the db?

    Thread Starter Dan & Jennifer

    (@danstuff)

    @andrea

    stab in the dark: does the db user have ALL permissions on the db?

    Yes… i doublechecked wp-config against phpmyadmin for that database. also i just created a draft post in the main dan-and-jennifer.com site with no problems, so it’s writing to the database fine.

    Go look in the database itself – got any tables in there being created with the new blog info?

    Yep… the “Multisite” tables are there, and specifically wp_blogs has 2 entries: an entry for the main site and one for the sub-site. just like in my perfectly working https://www.TodayIsThatDay.com/inspirational-quotes/ database…

    Thread Starter Dan & Jennifer

    (@danstuff)

    @ipstenu

    How odd… I get a 404 on https://www.dan-and-jennifer.com/zztest/ and the db error on https://www.dan-and-jennifer.com/yytest

    LOL sorry, in the test with Andrea above I disabled all plugins, deleted the sub-site zztest and created a new one yytest.

    OK now I just re-created zztest so both test cases exist… it’s no longer 404, back to db error for both sub-sites:
    https://www.dan-and-jennifer.com/yytest
    https://www.dan-and-jennifer.com/zztest/

    Is there anything in your server logs?

    nope, only complaints about the disabled plugins since they’re ALL off so only half the homepage works… but the main site does function fine.

    Also, you didn’t create folders on the server for yytest, right?

    hmm, no… since the folders are all virtual i’m not creating any folders at all. although i do expect to see a new folder auto created in blogs.dir for each new “sub-site” as is happening on the other directory-based multisite installs we have running… but for this one it’s not…

    is that what you were asking – i.e. making sure I’m not creating a real folder that’s somehow conflicting with the URL of the sub-site?

    that’s why i went with these odd sub-site names just to be sure – yytest and zztest…

    Thanks!
    Dan

    Thread Starter Dan & Jennifer

    (@danstuff)

    *** Guys, found something new…

    For all the new sub-sites on dan-and-jennifer.com…
    In Super Admin -> Sites -> “Edit” (sub-site) – the “Site info” section is populated fine, but the REALLY LONG “Site Options” section is totally empty for all the broken sub-sites.

    again comparing with our working TodayIsThatDay… that one shows a fully populated “Site Options” under each of the sub-sites…

    but in the problematic install, that section is empty for the sub-sites…

    so any idea what that part is not getting populated when the sub-sites are being created?

    Thanks!
    Dan

    Moderator Ipstenu (Mika Epstein)

    (@ipstenu)

    ?????? Advisor and Activist

    is that what you were asking – i.e. making sure I’m not creating a real folder that’s somehow conflicting with the URL of the sub-site?

    That was what I was asking ?? Sometimes it’s the silly things that nail us.

    but the REALLY LONG “Site Options” section is totally empty for all the broken sub-sites.

    Okay! At the top of that section it should say ‘Site Options (wp_2_options)’ or such. Does it?

    Thread Starter Dan & Jennifer

    (@danstuff)

    @ipstenu cool.

    That was what I was asking ?? Sometimes it’s the silly things that nail us.

    LOL! indeed. ??

    Okay! At the top of that section it should say ‘Site Options (wp_2_options)’ or such. Does it?

    OK… here it is. answer is yes; here’s what I see:

    for /yytest/, it says “Site Options (wp_4_options)”
    and for /zztest its ays “Site Options (wp_5_options)”

    numbers make sense, I’ve created and deleted a few sub-sites in trying to figure out what’s happening….

    Another thing I notice which is weird, for say /yytest/. in the “Site Users” and “Add New User” sections of Site Edit the “role” drop-down is empty.

    Compared to the working site / multisite (sub-site) on https://www.TodayIsThatDay.com – where the roles drop-down in the “Site Users” and “Add New User” sections actually is a full drop-down of valid wordpress roles.

    I am still thinking the creation of sub-sites is somehow only going half way, just don’t know where it’s getting wedged…

    Thanks!
    Dan

    Thread Starter Dan & Jennifer

    (@danstuff)

    P.S. @ipstenu and @andrea_r, I really appreciate your help!!

    LOL been banging my head on this same wall for nearly a week and after trying “everything” i could think of finally reached out for help. ??

    Dan

    Moderator Ipstenu (Mika Epstein)

    (@ipstenu)

    ?????? Advisor and Activist

    Go into the database and see if the tables for wp_4_options and wp_5_options exist.

    We’re on to something. I think Andrea hit the nail on the head when she said ‘stab in the dark: does the db user have ALL permissions on the db?’

    See, just because you can add entries to the table does NOT mean the ID can create new tables! SQL is tricksy. You need to make sure the ID has all privileges

    From my site, the sql ID I use has these:
    SELECT
    CREATE
    INSERT
    ALTER
    UPDATE
    DROP
    DELETE
    LOCK TABLES
    INDEX
    REFERENCES
    CREATE TEMPORARY TABLES
    CREATE ROUTINE

Viewing 15 replies - 1 through 15 (of 45 total)
  • The topic ‘Multisite (sub-directories): Sub-Sites get created but don't work’ is closed to new replies.