Multi site Warning: An existing WordPress network was detected.
-
Yeah, so…. my problem is a long list of problems due to the fact I can’t get my multisite setup to work. First I installed multi site and added the new site url and was getting a re-loop error .. this was in a sub folder… I moved the site to the public folder and tried again the multisite instale …I was locked out so I re-installed wordpress and I re-installed the second time because I was getting serious errors and the plug weren’t working and now ..I am getting : Warning: An existing WordPress network was detected. … going ahead locks me out again… I think this something to do with the database and table…. at witch I am at a loss… I guess I can’t figure out what the problem is. The first time I finished the install ..except there was a re-looping problem (this was in a sub-folder that no longer exist).. I am in a rabbit hole!
-
Need a bit more detail. Walk us thru the steps you take to get to the Warning. Include the URLs you type in the web browser and those displayed by the browser when you arrive.
Are you still using the wp-config lines you posted above? If not post the lines that are different.
Run this sql against the db in question
SELECT b.domain AS 'blogs-domain', s.domain AS 'site-domain', b.path AS 'blogs-path', s.path AS 'site-path' FROM wp_blogs AS b, wp_site AS s WHERE b.blog_id = 1 AND s.id = 1 LIMIT 1;
and post the result.Hi derek,
I found the cms path when going to the phpadmin. When I look in the browser. https://omnivisiontest.com/cms comes up as a 404… interesting to note the favicon that I put on the site is showing up but not on the https://omnivisiontest.com ( I had not looked into the links as yet- thought it was this) …
Running the sql on the db you get :
SELECT b.domain AS ‘blogs-domain’, s.domain AS ‘site-domain’, b.path AS ‘blogs-path’, s.path AS ‘site-path’
FROM wp_blogs AS b, wp_site AS s
WHERE b.blog_id =1
AND s.id =1
LIMIT 1looking at the “Create a Network of WordPress Sites” I get the Warning .. this is after I have switched back to allowing the multisite: define(‘WP_ALLOW_MULTISITE’, true);
it asks you to ad:
define(‘MULTISITE’, true);
define(‘SUBDOMAIN_INSTALL’, false);
define(‘DOMAIN_CURRENT_SITE’, ‘omnivisiontest.com’);
define(‘PATH_CURRENT_SITE’, ‘/’);
define(‘SITE_ID_CURRENT_SITE’, 1);
define(‘BLOG_ID_CURRENT_SITE’, 1);and to the .htacess :
RewriteEngine On
RewriteBase /
RewriteRule ^index\.php$ – [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]after sql the htaccess file was empty ..trying that again I get Error establishing a database connection.
https://omnivisiontest.com/cms 404 is expected, right?
You posted “Running the sql on the db you get.” Did you mean to repost the sql statement? I wanted the output.
The Site Admin Dashboard->Tools->Network Setup link, that takes you to “Create a Network of WordPress Sites,” should not be available to you. Your db has the ‘Network’; WP does not need to ‘Network Setup.’
Did you try adding the 6 extra lines you posted above to your wp-config? Was the result what you said above, “… trying that again I get Error establishing a database connection?”
Sounds like WP can write your .htaccess. You should tighten file security later. Let’s disable .htaccess for now, by renaming it.
Yes the 404 on the /cms is exspected.
I think you are telling me not to put the : (‘WP_ALLOW_MULTISITE’, true); and have it set to : false); so I have done that. adding the six extra lines above I posted does give me the error establishing a database.
I renamed the .htaccess to .htaccess_not and another .htaccess shows up witch is blank.
I am not sure what is the out put from the sql you gave me after I put the sql code in … another screen comes up with above sql in another colour and =
id select_type table type possible_keys key key_len ref rows Extra
1 SIMPLE b system PRIMARY NULL NULL NULL 1
1 SIMPLE s system PRIMARY NULL NULL NULL 1is this the out put???
No, I’m saying to have wp-config set to run an installed Network. So we want
define(‘WP_ALLOW_MULTISITE’, true);
plus the other 6 lines above.Check your site, and tell us if the db connect error is visible on the front end of your site, ie. what web visitors see, or is it just when you try to get to the back end, ie. the Admin area.
Is there any other error detail displayed when you see “Error establishing a database connection?” While you are troubleshooting, set define(‘WP_DEBUG’, true); to see more details, should already be a line in your wp-config.
Run ‘repair database’ by adding this line below your Network lines in wp-config
define(‘WP_ALLOW_REPAIR’, true);
Once you have done that, request https://www.yoursite.com/wp-admin/maint/repair.php Can you now get into Admin?As long as .htaccess stays blank for now, that’s cool.
Regarding the sql query I sent you, if in phpMyAdmin, clicking on the WP db (the same one in wp-config), then the SQL tab, enter the query on 1 line, and GO, the output should be something like:
blogs-domain site-domain blogs-path site-path domain.tld domain.tld / /
If you can’t get a similar result, note what $table_prefix is equal to in wp-config. Then take a look at table names in your db. Are the table prefixes the same? Is your db using “wp_” the default WP prefix?
Re: the sql query. Any chance the output was displayed lower on the page where you saw the original sql query in colors?
Okay,
define(‘WP_ALLOW_MULTISITE’, true);
plus the other 6 lines above...are on the wp-config file, the .htacess is still blank and other : .htacess_not with the wp ask to put on… the Error establishing a database connection is on the front end…
this is also included in the wp-config file: define(‘WP_ALLOW_REPAIR’, true); … following the link https://omnivisiontest.com/wp-admin/maint/repair.php …. no I can not get into the admin… no there are not any other messages with the Error establishing a database connection
The database is using the wp prefix… there are 18 of them but the config is not one of them… I have gone into the db with the WordPress in it there are 5 of them and then gone into the sql and then put the query in…. Is that right the whole page is this after :
Your SQL query has been executed successfully
EXPLAIN SELECT b.domain AS ‘blogs-domain’, s.domain AS ‘site-domain’, b.path AS ‘blogs-path’, s.path AS ‘site-path’
FROM wp_blogs AS b, wp_site AS s
WHERE b.blog_id =1
AND s.id =1
LIMIT 1
[Inline] [ Edit ] [ Skip Explain SQL ] [ Create PHP Code ]+ Options
id select_type table type possible_keys key key_len ref rows Extra
1 SIMPLE b system PRIMARY NULL NULL NULL 1
1 SIMPLE s system PRIMARY NULL NULL NULL 1Query results operations
Print view Print view (with full texts) Create viewwhat am I doing wrong?
Not sure why we can’t get the sql query in phpMyAdmin to output something understandable.
Does the front end come back online if you set multisite false?
define(‘MULTISITE’, false);
And leave the other network files enabled?18 is the number of tables for a Network with only the main site. Can you still browse the db with phpMyAdmin? If so, confirm that the first record in the wp_blogs table has domain omnivisiontest.com and path /
What does “I have gone into the db with the WordPress in it there are 5 of them …” mean?
What a minite… I had the path as nothing I put the / in path on the wp_blogs (should this be the same on : wp_site) and now the home page comes up with this on the top :
Notice: Use of undefined constant mtf_create_shortcode – assumed ‘mtf_create_shortcode’ in /home/emran3/public_html/wp-content/plugins/mini-twitter-feed/mini-twitter-feed.php on line 59
going back to the admin I get :
Notice: Use of undefined constant mtf_create_shortcode – assumed ‘mtf_create_shortcode’ in /home/emran3/public_html/wp-content/plugins/mini-twitter-feed/mini-twitter-feed.php on line 59
-this happened before… my plug in where deactive… on : https://omnivisiontest.com/wp-admin/maint/repair.php I get :
Warning: Cannot modify header information – headers already sent by (output started at /home/emran3/public_html/wp-content/plugins/mini-twitter-feed/mini-twitter-feed.php:59) in /home/emran3/public_html/wp-admin/maint/repair.php on line 12
WordPressTo allow use of this page to automatically repair database problems, please add the following line to your wp-config.php file. Once this line is added to your config, reload this page.
define(‘WP_ALLOW_REPAIR’, true);
after doing this I have to options : repair database and repair and Optimize Database
which is do you recommend?
Repair, for now. It will tell us if it finds any problems with the Single site tables, but unless we have multisite true, it won’t touch the Network tables.
Yes, wp_site and wp_blogs should have the same domain and the same path, BUT it doesn’t really matter what is in wp_site as the 2 lines
define(‘DOMAIN_CURRENT_SITE’, ‘domain.tld’);
define(‘PATH_CURRENT_SITE’, ‘/’);
completely override the wp_site table.define(‘WP_DEBUG’, true); is giving extra info we might use
define(‘WP_DEBUG’, false); is what you want when you are not troubleshootingokay after the repair look like all tables are fine :
The wp_users table is okay.The wp_usermeta table is okay.
The wp_posts table is okay.
The wp_comments table is okay.
The wp_links table is okay.
The wp_options table is okay.
The wp_postmeta table is okay.
The wp_terms table is okay.
The wp_term_taxonomy table is okay.
The wp_term_relationships table is okay.
The wp_commentmeta table is okay.
The wp_blogs table is okay.
The wp_signups table is okay.
The wp_site table is okay.
The wp_sitemeta table is okay.
The wp_registration_log table is okay.
The wp_blog_versions table is okay.
the error is still on the front end and I can’t get into admin with the
” Notice: Use of undefined constant mtf_create_shortcode – assumed ‘mtf_create_shortcode’ in /home/emran3/public_html/wp-content/plugins/mini-twitter-feed/mini-twitter-feed.php on line 59
Warning: Cannot modify header information – headers already sent by (output started at /home/emran3/public_html/wp-content/plugins/mini-twitter-feed/mini-twitter-feed.php:59) in /home/emran3/public_html/wp-includes/pluggable.php on line 876 ”
Good that you were able to check all the network tables. What does “the error is still on the front end and I can’t get into admin” mean? In network mode? In single mode? Page only displays the “Notice: …” and “Warning: …” ? Remember, your words are my braille.
You should now
define(‘WP_DEBUG’, false);
define(‘WP_ALLOW_REPAIR’, false);Earlier I asked, Does the front end come back online if you leave all other network lines enabled in wp-config, and only define(‘MULTISITE’, false); ?
Yes, I ment that there was literally across the top of the website the above warning… Meaning that if someone visited the webpage they would see it… It is gone now that the config is :
define(‘WP_DEBUG’, false);
define(‘WP_ALLOW_REPAIR’, false);Right now the front end is back on line with the define(‘MULTISITE’, true); and I can get into the admin. This seems like progress?
I guess I should have stressed my earlier comment. “While you are troubleshooting, set define(‘WP_DEBUG’, true);”
Great that you “can get into the admin” but with a network there are 2 admins. There is Site admin for each of the sites, including the main site. The other, is Super or Network admin. Can you add a new site?
If the main site, the original Single site, had posts, are they accessible from the front end?
You can now look at enabling URL Rewrite. On apache this is .htaccess, and on IIS it is web.config.
hmmm, Yes I am able to add a site … the network admin is there.. but when I visit the site I get a 404 and when I go into the new site’s admin (/fr) I also get the 404. The .htaccess is still set up as the blank one… with the .htaccess_not with the WP requested code? should I change this?
- The topic ‘Multi site Warning: An existing WordPress network was detected.’ is closed to new replies.