The most awaited tutorial is here: Learn Installing LEMP

#35

It’s ok. Assuming you are using domain registrar default nameservers when it will be active you will have options to configure custom DNS records instead of updating nameservers. So, there you can update A, CNAME kind of records.

0 Likes

#36

I have not tried that way. Cannot recommend. :frowning:

0 Likes

#37

@GulshanKumar How to redirect 301 from non www to www in NGINX Server? and where to add the code?

Thanks!
Pramod

0 Likes

#38

WordPress handle www and non-www redirect itself based two things

  1. What URL access while accessing Famous 5-Minute Installation page
  2. What finally exist at WordPress general settings.
1 Like

#39

OK, Then I don’t need to add the code like this:

server { 
server_name example.com; 
return 301 $scheme://www.example.com$request_uri; 
}

But what to do with these:

Should I add them into Nginx Config which is located in:
/etc/nginx/nginx.conf

or I’ll need to add this into the main server file:
/etc/nginx/sites-available/example-com

0 Likes

#40

This one.

Yes, you don’t need. Usually to prevent from such issue. Make sure always access domain with correct version while Install WordPress. Because WordPress will use same information based on famous 5 minutes installation page.

Source: #32. Visit your blog domain name to setup WordPress for the first time.

1 Like

#41

I don’t know what will happen if I don’t add these codes. You remember I had 1500 404 errors in search console after adding the codes all problems had been solved. If I will not add them, it will again start happening with my site and site will lose the all link juice from old urls.

1 Like

#42

One more thing, Is NGINX sufficient and we don’t need to use cache plugin? Asking because as NGINX doesn’t have htaccess and again some codes will require to add into the config file, otherwise cache plugin will not function.

0 Likes

#43

Most cache plugin works fine with NGINX. You can try Breeze, it’s simple.

1 Like

#44

The replacement of .htaccess is nginx.conf file that can be added in the /var/www/html directory. Some cache plugin like W3TC does this way.

0 Likes

#45

I have installed the NGINX server and installed the WordPress but didn’t install the SSL. Will do it tomorrow morning. Hope, all things will work fine. Thanks for creating such great and simple article.

0 Likes

#47

How to restore existing MySQL database in LEMP server? @GulshanKumar

0 Likes

#48
0 Likes