Slow page loading on DigitalOcean
-
Nope - no improve performance. Specific - only facebook <!-- Facebook Pixel Code --> and VK pixel code in <head> and google analytics and yandex metrics <scripts> in global footer. but by the firebug - they loads near half a second - but main page and categories load slow.
-
the ultimate questions are...
what instance are you running? 1 vcore 1GB VM? bigger? smaller?
Do you have swap? in case you don't have enough memory...
is the DB on the same server as nginx and nodebb? separate?
Which OS are you running?
If these questions were answered, please point me to it, and I will see if I can help
-
which version of mongodb are you using?
-
If you go to the
/api
routes... e.g.http://yoursite.tld/api/recent
, is the rest still slow?Definitely seems like some mongo indices are missing though it could really be anyone's guess at this point.
You can re-create the indices by running this in MongoDB after
use
-ing your NodeBB database:db.objects.createIndex({ _key: 1, score: -1 }, { background: true }); db.objects.createIndex({ _key: 1, value: -1 }, { background: true, unique: true, sparse: true }); db.objects.createIndex({ expireAt: 1 }, { expireAfterSeconds: 0, background: true });
-
@julian said in Slow page loading on DigitalOcean:
If you go to the
/api
routes... e.g.http://yoursite.tld/api/recent
, is the rest still slow?Definitely seems like some mongo indices are missing though it could really be anyone's guess at this point.
You can re-create the indices by running this in MongoDB after
use
-ing your NodeBB database:db.objects.createIndex({ _key: 1, score: -1 }, { background: true }); db.objects.createIndex({ _key: 1, value: -1 }, { background: true, unique: true, sparse: true }); db.objects.createIndex({ expireAt: 1 }, { expireAfterSeconds: 0, background: true });
Thanks a lot! Now it works like a car on f1!)
-
@dread said in Slow page loading on DigitalOcean:
https://github.com/Serhey/nodebb-plugin-featured-topics-extended-with-title
Oh.
That is a very ... unorthodox ... way of forking my plugin.
-
@yariplus said in Slow page loading on DigitalOcean:
@dread said in Slow page loading on DigitalOcean:
https://github.com/Serhey/nodebb-plugin-featured-topics-extended-with-title
Oh.
That is a very ... unorthodox ... way of forking my plugin.
Sorry - I just start to using github. I foget to write fork. Fixed.