I have a WordPress multisite install on Nginx. Currently I have site1.com as main site. And I added a new site called site2.com as subdirectory. However, I noticed you can actually click on Network Admin > Sites > Edit (site 2), you can change the domain = site2.com and path=/. Instead of using domain=site1.com and path=/site2.
I created to nginx vhost config files under sites-available. And site1 and site2 both work fine. Now you are asking me what is the problem?
The problem is with the permalinks. If you put them to /blog/%postname%/ both site1 and site2 work fine. However if you enter site2.com/blablablablaIAMFAKE the server redirects to site1.com whereas it should remain on site2 and display a 404. If you enter site2.com/blog/blablalbalbla the 404 is displayed appropriately.
One possible way to solve this is to remove the /blog from the permalinks. The tip given on the internet to change the permalink structure per site to default, and to change it under network admin >edit site> settings to /%postname%/ works fine for site1.com (the primary site). But not on site2.com.
Any ideas what could be wrong.