Link to home
Start Free TrialLog in
Avatar of Mohammed Hamada
Mohammed HamadaFlag for Portugal

asked on

Configure Multisite Wordpress new secondary site on a different domain

I have installed Wordpress Multisite with Multisite configure set to True and Subdomain_Install set to false. I am able to create couple of websites but when I set the site to its own domain name (Domain.com) and try to visit domain.com/wp-admin I get a 404 not found error

When I try to visit the domain.com I get the Testing 123.. apache website instead of the wordpress site.

I would appreciate any help

My Wordpress version is 5.2.2
Server is Centos 7
Running Apache and Phpmyadmin
Database is MariaDB

here's my wp-config.php
<?php
/**
 * The base configuration for WordPress
 *
 * The wp-config.php creation script uses this file during the
 * installation. You don't have to use the web site, you can
 * copy this file to "wp-config.php" and fill in the values.
 *
 * This file contains the following configurations:
 *
 * * MySQL settings
 * * Secret keys
 * * Database table prefix
 * * ABSPATH
 *
 * @link https://codex.wordpress.org/Editing_wp-config.php
 *
 * @package WordPress
 */

/** The name of the database for WordPress */
define( 'DB_NAME', 'wordpressdb' );

/** MySQL database username */
define( 'DB_USER', 'wordpressuser' );

/** MySQL database password */
define( 'DB_PASSWORD', 'Password' );

/** MySQL hostname */
define( 'DB_HOST', 'localhost' );

/** Database Charset to use in creating database tables. */
define( 'DB_CHARSET', 'utf8' );

/** The Database Collate type. Don't change this if in doubt. */
define( 'DB_COLLATE', '' );

/**#@+
 * Authentication Unique Keys and Salts.
 *
 * Change these to different unique phrases!
 * You can generate these using the {@link https://api.wordpress.org/secret-key/1.1/salt/ WordPress$
 * You can change these at any point in time to invalidate all existing cookies. This will force al$
 *
 * @since 2.6.0
 */
define( 'AUTH_KEY',         'put your unique phrase here' );
define( 'SECURE_AUTH_KEY',  'put your unique phrase here' );
define( 'LOGGED_IN_KEY',    'put your unique phrase here' );
define( 'NONCE_KEY',        'put your unique phrase here' );
define( 'AUTH_SALT',        'put your unique phrase here' );
define( 'SECURE_AUTH_SALT', 'put your unique phrase here' );
define( 'LOGGED_IN_SALT',   'put your unique phrase here' );
define( 'NONCE_SALT',       'put your unique phrase here' );

/**#@-*/

/**
 * WordPress Database Table prefix.
 *
 * You can have multiple installations in one database if you give each
 * a unique prefix. Only numbers, letters, and underscores please!
 */
$table_prefix = 'wp_';

/**
 * For developers: WordPress debugging mode.
 *
 * Change this to true to enable the display of notices during development.
 * It is strongly recommended that plugin and theme developers use WP_DEBUG
 * in their development environments.
 *
 * For information on other constants that can be used for debugging,
 * visit the Codex.
 *
 * @link https://codex.wordpress.org/Debugging_in_WordPress
 */
define( 'WP_DEBUG', false );
define( 'WP_MEMORY_LIMIT', '512M');

/* Multisite */
define('WP_ALLOW_MULTISITE', true);
define('MULTISITE', true);
define('SUBDOMAIN_INSTALL', false);
define('DOMAIN_CURRENT_SITE', '[b]Public IP Address[/b]');
define('PATH_CURRENT_SITE', '/wordpress/');
define('SITE_ID_CURRENT_SITE', 1);
define('BLOG_ID_CURRENT_SITE', 1);

/* That's all, stop editing! Happy publishing. */

/** Absolute path to the WordPress directory. */
if ( ! defined( 'ABSPATH' ) ) {
        define( 'ABSPATH', dirname( __FILE__ ) . '/' );
}

/** Sets up WordPress vars and included files. */
require_once( ABSPATH . 'wp-settings.php' );

Open in new window

fotWP.jpg
Avatar of David Favor
David Favor
Flag of United States of America image

Aside: MultiSite is a nightmare to work with. There's a reason why fewer + fewer people use MultiSite.

All you save with MultiSite is a small amount of disk space + massive headaches.

If you're starting a new project, just use normal single site installs.

This said, the message you're getting seems related to how your hosting company has the Apache default directory setup, so likely nothing to do with MultiSite.
Avatar of Mohammed Hamada

ASKER

Hi David, the currently site is hosted by Godaddy which seems to have an automated process of creating multiple directory site.
I would like to export all the directories, settings and import it to my personal data center Centos server.

What kind of apache directory setup you mean if you don't mind?
If I understand, you currently have a MultiSite setup.

My personally, I'd use some backup plugin that was MultiSite aware, then backup each individual MultiSite + migrate it as a single site.

In other words, escape MultiSite as it will be a constant time drain.

BackupBuddy might do this, as they some experimental MultiSite support.

File backups aren't the problem. The crazy MultiSite database setup is the problem.

Exactly how you approach this relates to number of MultiSites you have running.

If it's a few, I'd break them into single sites during migration.

If you have 1000s, I'd migrate them all together (using a MultiSite aware backup plugin), then break them up later on my CentOS box.
ASKER CERTIFIED SOLUTION
Avatar of David Favor
David Favor
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
I removed the server and installed single node for that purpose. although it doesn't seems logical if you want to install a single server for a simple wordpress site as it uses lots of resources however I have been told by some friends that instead of using multisite wordpress I can simply use Plesk which automates the whole process.

Thank you
I removed the server and installed single node for that purpose. although it doesn't seems logical if you want to install a single server for a simple wordpress site as it uses lots of resources however I have been told by some friends that instead of using multisite wordpress I can simply use Plesk which automates the whole process.

Thank you
You're welcome!

Remember your most important resource... which you can never recover once spent...

Your time.

Disk. Memory. CPU. All cheap.

Your time, priceless.