The MU forums have moved to WordPress.org

Sub blogs not working in WPMU server migration... (24 posts)

  1. rajsinghuk
    Member
    Posted 14 years ago #

    Hi,

    I'm migrating a wordpress MU installation from one server to another. Both servers are linux, but bar that, they're completely different.

    I've managed to get the main blog to function perfectly as on the old server, my process was essentially:
    - Transfer files via FTP and do a find in files / replace on all host names, user names and passwords
    - Export SQL db to file
    - Remap all domains in the db to the new domain
    - Import SQL db to new server

    And this process has worked fantastically on every feature of the site bar a single sub-blog used on the site.

    The original site is http://fi-mech.tv/ and the sub-blog in question is hosted at: http://fi-mech.tv/financial-modeling-jobs/

    The new site is http://www.financialmechanics.tv/ and the sub-blog is supposed to be at http://www.financialmechanics.tv/http://www.financialmechanics.tv/financial-modelling-jobs/

    Yes, there's a double ll in modeling this time, but this isn't the cause, I'm sure of that as because if I create a new sub-blog on the old site called "test", it appears correctly at fi-mech.tv/test but if I create a new sub-blog on the new site, this does not load :(

    My htaccess file is the standard:

    RewriteEngine On
    RewriteBase /

    #uploaded files
    RewriteRule ^(.*/)?files/$ index.php [L]
    RewriteCond %{REQUEST_URI} !.*wp-content/plugins.*
    RewriteRule ^(.*/)?files/(.*) wp-content/blogs.php?file=$2 [L]

    # add a trailing slash to /wp-admin
    RewriteCond %{REQUEST_URI} ^.*/wp-admin$
    RewriteRule ^(.+)$ $1/ [R=301,L]

    RewriteCond %{REQUEST_FILENAME} -f [OR]
    RewriteCond %{REQUEST_FILENAME} -d
    RewriteRule . - [L]
    RewriteRule ^([_0-9a-zA-Z-]+/)?(wp-.*) $2 [L]
    RewriteRule ^([_0-9a-zA-Z-]+/)?(.*\.php)$ $2 [L]
    RewriteRule . index.php [L]

    <IfModule mod_security.c>
    <Files async-upload.php>
    SecFilterEngine Off
    SecFilterScanPOST Off
    </Files>
    </IfModule>

    and I've reinstalled wordpress MU aswell to ensure none of the mu file's were corrupted etc.

    I'm really lost to even where to look now, any ideas?

  2. hydrastudio
    Member
    Posted 14 years ago #

    Hello!
    I'm experiencing this exactly problem.

    I've installed and configured a website in a test domain and, after migrating to prodution server, sub-blogs stopped to work.
    I cant see users blogs pages and even cant login in their backends. When I try that, I still see main blog panel.
    .htaccess is a standard one and mod_rewrite is fine. I think that it can be a kind of DB misconfiguration, specially in wp_1_options, but I cant solve this by my own.

    Any help?
    Regards!

  3. rajsinghuk
    Member
    Posted 14 years ago #

    Thank god I'm not alone.. this has been driving me nutts! ANY suggestions and help would be appreciated!

  4. rajsinghuk
    Member
    Posted 14 years ago #

    Error logs aren't showing anything either btw.

  5. andrea_r
    Moderator
    Posted 14 years ago #

    The blogs are all *virtual*, not matter what option you chose.

    So, if you have subdomain blogs on one server, you need the subdomain records on the other server too.

    If they are subfolder blogs, on some servers mod_rewrite is enabled, but hasn't been allowed to read the .htaccess file on the new account. You need:

    AllowOverride FileInfo Options

    in the vhost entry for that web account.

    @rajsinghuk - you also went from the non-www to the www, which mu currently doesn't support.

  6. rajsinghuk
    Member
    Posted 14 years ago #

    Oh... is that the problem? Okay, will try and fix, thank you!

  7. rajsinghuk
    Member
    Posted 14 years ago #

    andrea_r, thank you so much, switched the url to http://financialmechanics.tv/ and everything is working fantastically again! Is there no work around for the www issue as I'd prefer www if I could

  8. hydrastudio
    Member
    Posted 14 years ago #

    If they are subfolder blogs, on some servers mod_rewrite is enabled, but hasn't been allowed to read the .htaccess file on the new account.

    .htaccess is working fine. For example, if I change 'rewrite engine' key to 'off', it stops to deliver correct posts.
    I forgot to say that we are using subfolders. Is there a chance that permalinks are not working correctly, to process blogs URLs?

  9. andrea_r
    Moderator
    Posted 14 years ago #

    So, it's serving actual posts correctly off the main blog?

    Edit: note it loads the correct theme for that blog.

    shot-in-the-dark: login to the backend of that blog, resave the permalinks.

  10. hydrastudio
    Member
    Posted 14 years ago #

    So, it's serving actual posts correctly off the main blog?

    Ya, main blog works fine, even frontend as backend. But users blogs not.
    Users blogs frontend returns a "not found page" and backend always shows main blog backend. I only can reach main blog.
    I gave up to solve this problem and I'll try reinstall WPMU directly in prodution server and mix with main blog data.
    I think that it can be a misconfiguration in mod_rewrite or some kind of DB fault. Checking these results no errors, but as I said, I gave up.

    Thanks for your help. Soon I'll post results here.

  11. hydrastudio
    Member
    Posted 14 years ago #

    As I said, I have gave up to solve that problem without a new fresh installation...
    So I did. New installation works fine. Server problem was not the problem. Next step was trying config files. I've changed several files like .htaccess, wp-config.php and others, and nothing, blogs were not redirecting correctly.
    Then I've started to recheck DB and, finally, I found the problem. Really, really easy!

    On table 'wp_blog', collumn 'domain', when I've migrated DB, I've updated to www.mydomain.com. It's wrong. Right config is mydomain.com, WITHOUT www. Just it.
    Blogs are working fine now! Hope that it can help people who face same problem.

  12. truck808
    Member
    Posted 14 years ago #

    We are having the same issue but are unable to solve it.
    See sub blog: http://www.nya.org/dadams
    Main blog: http://www.nya.org

    Please help if you any ideas - Thanks!

  13. truck808
    Member
    Posted 14 years ago #

    Let me know what details I can give to help you help me.

    We've tried removing the www in the database table'wp_blog', column 'domain', and also re-saved the permalinks.

  14. truck808
    Member
    Posted 14 years ago #

    We feel as though we've tried everything here. If anyone has some insight or experience with a similar issue it would be much appreciated.

    Thank you.

  15. truck808
    Member
    Posted 14 years ago #

    We didn't migrate from one server to another. We simply just changed IP's within the same server. Then find/replace to the correct domain in the database.

    development site sub blog: http://www2.nya.org/dadams/
    live site sub blog: http://www.nya.org/dadams/

  16. andrea_r
    Moderator
    Posted 14 years ago #

    Make sure
    AllowOverride FileInfo Options
    is in the vhost entry for that account on the server.

  17. truck808
    Member
    Posted 14 years ago #

    Thanks Andrea - we did - but now double checking.

  18. truck808
    Member
    Posted 14 years ago #

    Andrea, According to our server person (and what what saw) it has been there the whole time as a global variable. We see it under the first directory entry which means it applies to all directories.

    I have a long piece of code but, I will only cut and paste the part where I see it:

    <Directory />
    Options FollowSymLinks
    AllowOverride FileInfo Options
    </Directory>

  19. truck808
    Member
    Posted 14 years ago #

    This server automatically redirects domain.org to http://www.domian.org. We were wondering if this had anything to do with it?

  20. tdjcbe
    Member
    Posted 14 years ago #

    Probably. Having the server force the www has caused an issue previously since wpmu is setup to strip it. In this case, it;s probably trying to do subdomain.www.domain.tld. At least that's what it did the last time I saw this.

  21. truck808
    Member
    Posted 14 years ago #

    OK, so we've made progress. But now we have a larger problem.
    WPMU strips the www. so when we removed the www from everywhere (database, etc.) we are able to see the blogs. The problem is, we need to keep the site URL http://www.domain.org because that is the address that is in all printed material and how prople access the site internally. domian.org (without the www) will not work.

    Any solutions?

    here is the site: http://www.nya.org/

  22. andrea_r
    Moderator
    Posted 14 years ago #

    domian.org (without the www) will not work.

    You need to set the server to answer to the non www in Apache. If you don't know how to do this, then your webhost will.

  23. truck808
    Member
    Posted 14 years ago #

    What I meant to write is that domain.org will not work as a solution long term because of how the internal computers of the organization are configured. What we've decided to do is to point the web site at www2.nya.org as a temporary fix until wp 3.0 comes out and we can fix it permanently. I understand that v3.0 will not strip out the www.

  24. mrjeany
    Member
    Posted 14 years ago #

    hydrastudio - your fix worked perfectly for me, thank you so much!

    by the way, for me, it only worked if I set the main domain with the www in fron and the subsites without. No idea why that is, but it worked, phew!

About this Topic

  • Started 14 years ago by rajsinghuk
  • Latest reply from mrjeany