Skip to main content


Delay loading /network


!Friendica Support
Hi everyone, I have a big problem on my Friendica installation , When I connect to niwego.com/network , it takes 30/40 seconds to load the page,I chose to display only 10 post on the page, plus when I scroll it lags a lot.

I installed the plugin rendertime , this is the result , it has become almost unusable

Database: 3.619/0, Network: 0, Rendering: 40.65, Session: 0, I/O: 0.01, Other: 0.27, Total: 44.54
Class-Init: 0.005, Boot: 0.004, Init: 0, Content: 44.524, Other: 0.017, Total: 44.55

Ubuntu Server 24.04 LTS

This is the third installation of Friendica, on the others I have the delay, but on this installation (my personal one) it is too much.
Friendica runs on a virtual machine with 8 Cores and 8Gb of memory

Some suggestions , thanks...

This entry was edited (4 months ago)
in reply to NeMyS

Well, I keep getting either 502 Bad Gateway or 504 Gateway Time-out on my node for anything other than local stuff on my node or go through my /profile. The only Plugins/Active addons I have installed are blockbot and notifyall. My Friendica node runs on one of my k3s nodes and is the friendica:stable Image.
in reply to Scifijunkie

I solved it by blocking the domain *activitypub-troll.cf, I had a lot of spam which slows down the network, it works fine now.

Try to reduce the amount of posts per page to around 10, i had this error in the past and i solved it this way thanks to @Michael Vogel

in reply to Scifijunkie

There are a lot of reasons for these messages. It could be performance related. In this case you should try to enable the rendertime addon to check where the performance bottleneck is.

If the times are okay, but you still have got timeouts, then the problem can also be your webserver or php. Then you could check for the maximum number of connections. You should consult your logfiles prior to check if the limits are reached.

in reply to Scifijunkie

This is meant for the lines in the callstack. Since we are looking for performance issues, you can enter something like 0,1 in it. Then every value below 0,1 will be omitted.
in reply to NeMyS

Hmm, it is weird that rendering takes so long. Normally the bottleneck is the network or database.
in reply to NeMyS

Can you deactivate the advancedcontentfilter addon? It would be interesting to see if this improves the performance.
in reply to Michael Vogel

Can you deactivate the advancedcontentfilter addon? It would be interesting to see if this improves the performance.

I disabled advancedcontentfilter (this problem of mine happened before I enabled all the plugins you see) since I blocked this domain I have no problem, I don't know if it's a coincidence. When I view the Workers queue, there were 40/50 sometimes more... Workers only for this domain. But if you want we can do some tests.

I had a similar problem in the past @Scifijunkie and I solved it this way https://explorer.niwego.com/display/b04c899d-5965-ff0f-2394-5be575278305 Thanks to !Friendica Support Support


Error 500 /network


why do I have error 500 in /network , my friendica instance worked fine for a few days, and today when I go to /network , I recive this error , in the web browser I have the error, I also cleaned the cash .

Fedilab works on my Android, I can access (My friends Conversation)

Thanks

!Friendica Support #Friendica


in reply to NeMyS

It would be interesting to see if this improves the performance.

That's it, loading /network

Database: 0.127/0, Network: 0, Rendering: 0.04, Session: 0, I/O: 0, Other: 0.05, Total: 0.21
Class-Init: 0.006, Boot: 0.004, Init: 0, Content: 0.203, Other: 0.003, Total: 0.216
in reply to NeMyS

@𝔫𝕖𝚖ƴ᥉ @Michael Vogel @Scifijunkie Please repeat it again, maybe coincidence that you get better rendering time without the addon. This means that you enable the addon again, try to reload a few times in a row and then disable the addon again and try to reload in a few times again. So you can exclude coincidences like other programs on your server has maybe caused it.

Question aside: Is your server a "shared server", means you don't have root access to it or does it belong to you alone?

Friendica Support reshared this.

in reply to Roland Häder

@Roland Häder Since I installed Friendica on the root domain, the other one explore.ni.. is almost always offline and the virtual machine Off
Do you want me to delete the domain *activitypub-troll.cf from Server-block list And disable plugins and see how long it takes for /network to load? I currently have no latency issues, so far everything is working fast and as it should since i blocked the domain i listed above.
I have access to the entire server, and I have root privileges , It is not a shared server.
Thanks
in reply to NeMyS

@𝔫𝕖𝚖ƴ᥉ @Michael Vogel @Scifijunkie Okay, I just wanted to exclude this, that maybe other users are causing this. But since it runs now pretty fast, then we can exclude external factors. The repeated tests (still with all other in place) are should make sure that the slowdown was caused temporary and not on every request.

Friendica Support reshared this.

in reply to NeMyS

Can you perform select count(*) from advancedcontentfilter_rules;? I'm unsure where this problem originates.
in reply to Michael Vogel

@Michael Vogel
you told me to perform select count(*) from advancedcontentfilter_rules; , do i need to create a new rule?
in reply to NeMyS

I meant that you should perform that SQL command, so that we see the number of lines in that table.
in reply to Michael Vogel

@Michael Vogel

Ah ok sorry I got confused , Just to be clear, I installed the plugin a while ago, but never configured it , not yet
Here he is

MariaDB [MYFRIENDICADB]> select count(*) from advancedcontentfilter_rules;
+----------+
| count(*) |
+----------+
|        0 |
+----------+
1 row in set (0.001 sec)
in reply to NeMyS

This is what I get with rendertime on while loading the page.

Database Read:
DBA::select (58), Hook::loadHooks (336), App::load (303), App::__construct: 0.001
DBA::exists (1038), User::isSiteAdmin (139), UserSession::isSiteAdmin (57), HTTPException::__construct: 0.001
Database::selectFirst (184), Authentication::withSession (600), App::runFrontend (55): 0.001
Database::selectFirst (117), PConfig::get (90), JitPConfig::get (317), Authentication::setForUser (196): 0.001
DBA::select (300), Contact::getVisitorByUrl (163), UserSession::setVisitorsContacts (326), Authentication::setForUser (196): 0.001
Database::selectFirst (335), Authentication::setForUser (196), Authentication::withSession (600), App::runFrontend (55): 0.001
DBA::select (58), Hook::loadHooks (620), App::runFrontend (55): 0.001
Post::selectFirstForUser (110), Display::content (250), BaseModule::run (682), App::runFrontend (55): 0.2
Post::selectFirst (145), Display::content (250), BaseModule::run (682), App::runFrontend (55): 0.008
Database::selectFirst (117), PConfig::get (90), JitPConfig::get (150), Display::content (250): 0.001
Database::update (223), Notification::setAllSeenForUser (151), Display::content (250), BaseModule::run (682): 0.063
Database::update (153), Notify::setAllSeenForUser (152), Display::content (250), BaseModule::run (682): 0.098
DBA::selectFirst (270), Contact::getById (188), Display::displaySidebar (155), Display::content (250): 0.001
DBA::selectFirst (96), ContactSelector::getServerURLForProfile (69), ContactSelector::getServerForProfile (161), ContactSelector::networkToName (172): 0.024
DBA::selectFirst (76), ContactSelector::getServerForProfile (161), ContactSelector::networkToName (172), Strings::formatNetworkName (58): 0.218
DBA::selectFirst (2302), Contact::updateAvatar (1932), Contact::checkAvatarCacheByArray (1843), Contact::getAvatarPath (1877): 0.001
Photo::delete (2428), Contact::updateAvatar (1932), Contact::checkAvatarCacheByArray (1843), Contact::getAvatarPath (1877): 0.022
DBA::select (2444), Contact::updateAvatar (1932), Contact::checkAvatarCacheByArray (1843), Contact::getAvatarPath (1877): 0.001
Contact::update (2461), Contact::updateAvatar (1932), Contact::checkAvatarCacheByArray (1843), Contact::getAvatarPath (1877): 0.066
DBA::selectFirst (270), Contact::getById (1934), Contact::checkAvatarCacheByArray (1843), Contact::getAvatarPath (1877): 0.001
DBA::selectFirst (2036), Contact::getDefaultAvatar (1945), Contact::checkAvatarCacheByArray (1843), Contact::getAvatarPath (1877): 0.031
DBA::selectFirst (2036), Contact::getDefaultAvatar (1948), Contact::checkAvatarCacheByArray (1843), Contact::getAvatarPath (1877): 0.003
DBA::selectFirst (2036), Contact::getDefaultAvatar (1951), Contact::checkAvatarCacheByArray (1843), Contact::getAvatarPath (1877): 0.004
Contact::selectFirst (80), VCard::getHTML (194), Display::displaySidebar (155), Display::content (250): 0.002
Database::selectFirst (117), PConfig::get (90), JitPConfig::get (3636), Contact::magicLinkByContact (118): 0.001
Post::exists (286), Display::displayHead (156), Display::content (250), BaseModule::run (682): 0.003
Post::exists (230), Display::getDisplayData (165), Display::content (250), BaseModule::run (682): 0.008
Post::selectFirstForUser (248), Display::getDisplayData (165), Display::content (250), BaseModule::run (682): 0.007
Database::selectFirst (117), PConfig::get (90), JitPConfig::get (331), Smilies::noSmilies (347): 0.001
Contact::exists (328), Display::addMetaTags (267), Display::getDisplayData (165), Display::content (250): 0.001
DBA::selectFirst (318), User::getById (311), Conversation::statusEditor (275), Display::getDisplayData (165): 0.001
DBA::selectFirst (318), User::getById (43), ACL::getLockstateForUserId (322), Conversation::statusEditor (275): 0.001
DBA::selectFirst (318), User::getById (253), ACL::getFullSelectorHTML (323), Conversation::statusEditor (275): 0.001
Contact::selectToArray (162), ACL::getContactListByUserId (304), ACL::getFullSelectorHTML (323), Conversation::statusEditor (275): 0.004
Contact::selectFirst (165), ACL::getContactListByUserId (304), ACL::getFullSelectorHTML (323), Conversation::statusEditor (275): 0.001
Contact::selectToArray (172), ACL::getContactListByUserId (304), ACL::getFullSelectorHTML (323), Conversation::statusEditor (275): 0.001
DBA::select (113), Counts::get (1027), Conversation::getEmojis (864), Conversation::addChildren (529): 0.001
DBA::p (1052), Conversation::getEmojis (864), Conversation::addChildren (529), Conversation::render (278): 0.004
DBA::p (1101), Conversation::getQuoteShares (865), Conversation::addChildren (529), Conversation::render (278): 0.001
DBA::select (113), Counts::get (1079), Conversation::getCounts (866), Conversation::addChildren (529): 0.001
Post::select (888), Conversation::addChildren (529), Conversation::render (278), Display::getDisplayData (165): 0.004
Post::select (899), Conversation::addChildren (529), Conversation::render (278), Display::getDisplayData (165): 0.008
Post::fetch (905), Conversation::addChildren (529), Conversation::render (278), Display::getDisplayData (165): 0.002
Post::select (948), Conversation::addChildren (529), Conversation::render (278), Display::getDisplayData (165): 0.007
DBA::select (974), Conversation::addChildren (529), Conversation::render (278), Display::getDisplayData (165): 0.001
array_filter (1221), Conversation::smartFlattenConversation (1311), Conversation::convSort (1011), Conversation::addChildren (529): 0.004
DBA::selectFirst (485), User::getOwnerDataById (1136), Post::getCommentBox (453), Post::getTemplateData (204): 0.003
Photo::selectFirst (521), User::getOwnerDataById (1136), Post::getCommentBox (453), Post::getTemplateData (204): 0.001
DBA::select (557), Tag::populateFromItem (3393), Item::prepareBody (464), Post::getTemplateData (204): 0.319
DBA::selectFirst (3610), Contact::magicLinkById (580), Tag::populateFromItem (3393), Item::prepareBody (464): 0.007
DBA::selectToArray (816), Media::getByURIId (3425), Item::prepareBody (464), Post::getTemplateData (204): 0.295
Database::selectToArray (45), PostMedia::_select (66), PostMedia::selectByUriId (128), PostMedia::splitAttachments (3468): 0.002
DBA::selectFirst (349), Contact::getByURL (1328), Contact::getIdForURL (70), UserSession::getPublicContactId (3481): 0.001
DBA::selectFirst (353), Contact::getByURL (1328), Contact::getIdForURL (70), UserSession::getPublicContactId (3481): 0.001
DBA::select (557), Tag::populateFromItem (487), Post::getTemplateData (204), Thread::getTemplateData (680): 0.001
DBA::selectFirst (3610), Contact::magicLinkById (580), Tag::populateFromItem (487), Post::getTemplateData (204): 0.001
DBA::selectFirst (397), Item::photoMenu (563), Post::getTemplateData (204), Thread::getTemplateData (680): 0.001
DBA::selectFirst (158), ContactSelector::networkToName (623), Post::getTemplateData (204), Thread::getTemplateData (680): 0.001
DBA::select (557), Tag::populateFromItem (3393), Item::prepareBody (464), Post::getTemplateData (655): 0.065
DBA::fetch (559), Tag::populateFromItem (3393), Item::prepareBody (464), Post::getTemplateData (655): 0.001
DBA::selectToArray (816), Media::getByURIId (3425), Item::prepareBody (464), Post::getTemplateData (655): 0.066
DBA::select (557), Tag::populateFromItem (487), Post::getTemplateData (655), Post::getTemplateData (204): 0.01
DBA::fetch (559), Tag::populateFromItem (487), Post::getTemplateData (655), Post::getTemplateData (204): 0.001
DBA::selectFirst (397), Item::photoMenu (563), Post::getTemplateData (655), Post::getTemplateData (204): 0.007
DBA::selectFirst (158), ContactSelector::networkToName (623), Post::getTemplateData (655), Post::getTemplateData (204): 0.051
DBA::select (557), Tag::populateFromItem (487), Post::getTemplateData (655), Post::getTemplateData (655): 0.003
DBA::selectFirst (397), Item::photoMenu (563), Post::getTemplateData (655), Post::getTemplateData (655): 0.002
DBA::selectFirst (270), Contact::getById (4033), Item::getPlink (584), Post::getTemplateData (655): 0.003
Post::selectFirst (3427), Item::prepareBody (464), Post::getTemplateData (655), Post::getTemplateData (204): 0.259
Database::selectToArray (45), PostMedia::_select (66), PostMedia::selectByUriId (128), PostMedia::splitAttachments (3461): 0.249
DBA::selectFirst (3610), Contact::magicLinkById (580), Tag::populateFromItem (487), Post::getTemplateData (655): 0.006
Database::selectFirst (117), PConfig::get (90), JitPConfig::get (204), Page::initHead (458): 0.001
DBA::exists (1038), User::isSiteAdmin (139), UserSession::isSiteAdmin (61), rendertime_page_end (222): 0.001

Database Write:

Cache Read:

Cache Write:

Network:

Rendering:
Renderer::replaceMacros (136), VCard::getHTML (194), Display::displaySidebar (155), Display::content (250): 0.001
BBCode::convert (243), BBCode::toPlaintext (306), Display::addMetaTags (267), Display::getDisplayData (165): 0.122
HTML::toPlaintext (243), BBCode::toPlaintext (306), Display::addMetaTags (267), Display::getDisplayData (165): 0.002
BBCode::convert (243), BBCode::toPlaintext (307), Display::addMetaTags (267), Display::getDisplayData (165): 0.004
HTML::toPlaintext (243), BBCode::toPlaintext (307), Display::addMetaTags (267), Display::getDisplayData (165): 0.001
Conversation::statusEditor (275), Display::getDisplayData (165), Display::content (250), BaseModule::run (682): 0.003
Conversation::addRowInformation (943), Conversation::addChildren (529), Conversation::render (278), Display::getDisplayData (165): 0.001
Renderer::replaceMacros (1174), Post::getCommentBox (453), Post::getTemplateData (655), Post::getTemplateData (204): 0.001
Item::photoMenu (563), Post::getTemplateData (655), Post::getTemplateData (204), Thread::getTemplateData (680): 0.003
Item::photoMenu (563), Post::getTemplateData (655), Post::getTemplateData (655), Post::getTemplateData (204): 0.001
Renderer::replaceMacros (592), Conversation::render (278), Display::getDisplayData (165), Display::content (250): 0.007
Renderer::replaceMacros (287), Page::initHead (458), Page::run (687), App::runFrontend (55): 0.001
code

I however still get 504 Gateway Time-out when trying to view /network. I could however turn it from Proxied to DNS only when it comes to Cloudflare. Let me see if that will do anything and I'll report back if it worked or not.

in reply to NeMyS

Well, I turned it from Proxied to DNS only when it comes to Cloudflare, and it just now loaded /network.

I get the following from rendertime

Database: 3.132/0, Network: 0, Rendering: 0.42, Session: 0, I/O: 0.01, Other: 0.51, Total: 4.08
Class-Init: 0.01, Boot: 0.005, Init: 0, Content: 4.057, Other: 0.008, Total: 4.081
Database Read:
DBA::select (556), Circle::sidebarWidget (136), Network::content (250), BaseModule::run (682): 0.045
DBA::selectFirst (318), User::getById (359), BaseModule::getFormSecurityToken (611), Circle::sidebarWidget (136): 0.001
Database::selectFirst (117), PConfig::get (90), JitPConfig::get (60), Feature::isEnabled (138): 0.001
DBA::select (82), GroupManager::getList (121), GroupManager::widget (139), Network::content (250): 0.102
Database::selectFirst (117), PConfig::get (90), JitPConfig::get (3636), Contact::magicLinkByContact (133): 0.001
DBA::selectFirst (2036), Contact::getDefaultAvatar (1948), Contact::checkAvatarCacheByArray (1843), Contact::getAvatarPath (1901): 0.003
DBA::selectFirst (2036), Contact::getDefaultAvatar (1951), Contact::checkAvatarCacheByArray (1843), Contact::getAvatarPath (1901): 0.003
DBA::selectFirst (2179), Contact::getAvatarUrlForId (1865), Contact::getAvatarPath (1901), Contact::getMicro (136): 0.002
DBA::select (275), Widget::networks (145), Network::content (250), BaseModule::run (682): 0.102
Database::selectFirst (117), PConfig::get (90), JitPConfig::get (60), Feature::isEnabled (147): 0.001
Database::selectFirst (117), PConfig::get (90), JitPConfig::get (60), Feature::isEnabled (150): 0.001
Database::selectFirst (117), PConfig::get (90), JitPConfig::get (565), Widget::channels (151): 0.001
DBA::selectFirst (485), User::getOwnerDataById (601), User::getLanguageCode (39), Channel::getTimelines (573): 0.005
Photo::selectFirst (521), User::getOwnerDataById (601), User::getLanguageCode (39), Channel::getTimelines (573): 0.001
Database::selectToArray (59), UserDefinedChannel::_select (120), UserDefinedChannel::selectByUid (579), Widget::channels (151): 0.001
Database::selectFirst (117), PConfig::get (90), JitPConfig::get (60), Feature::isEnabled (153): 0.001
DBA::select (40), SavedSearches::getHTML (154), Network::content (250), BaseModule::run (682): 0.001
Database::selectFirst (117), PConfig::get (90), JitPConfig::get (60), Feature::isEnabled (156): 0.001
DBA::selectToArray (107), Category::getArray (313), Widget::fileAs (157), Network::content (250): 0.001
Database::selectFirst (117), PConfig::get (90), JitPConfig::get (60), Feature::isEnabled (163): 0.001
Database::selectFirst (117), PConfig::get (90), JitPConfig::get (167), Network::content (250): 0.001
Database::selectFirst (117), PConfig::get (90), JitPConfig::get (280), Network::getTabsHTML (173): 0.001
DBA::selectFirst (318), User::getById (43), ACL::getLockstateForUserId (205), Network::content (250): 0.001
DBA::selectFirst (318), User::getById (253), ACL::getFullSelectorHTML (206), Network::content (250): 0.001
Contact::selectToArray (162), ACL::getContactListByUserId (304), ACL::getFullSelectorHTML (206), Network::content (250): 0.006
Contact::selectFirst (165), ACL::getContactListByUserId (304), ACL::getFullSelectorHTML (206), Network::content (250): 0.002
Contact::selectToArray (172), ACL::getContactListByUserId (304), ACL::getFullSelectorHTML (206), Network::content (250): 0.004
DBA::selectToArray (58), Circle::getByUserId (208), ACL::getCircleListByUserId (306), ACL::getFullSelectorHTML (206): 0.001
DBA::selectFirst (318), User::getById (311), Conversation::statusEditor (211), Network::content (250): 0.001
Database::selectFirst (117), PConfig::get (90), JitPConfig::get (60), Feature::isEnabled (391): 0.001
Database::selectFirst (117), PConfig::get (90), JitPConfig::get (243), Temporal::getDateTimeField (397): 0.001
Database::selectFirst (117), PConfig::get (90), JitPConfig::get (428), Conversation::statusEditor (211): 0.001
Database::selectFirst (117), PConfig::get (90), JitPConfig::get (514), Profile::shouldDisplayEventList (222): 0.001
DBA::p (553), Profile::getBirthdays (223), Network::content (250), BaseModule::run (682): 0.009
DBA::selectFirst (349), Contact::getByURL (1328), Contact::getIdForURL (70), UserSession::getPublicContactId (224): 0.001
DBA::selectFirst (353), Contact::getByURL (1328), Contact::getIdForURL (70), UserSession::getPublicContactId (224): 0.001
DBA::select (629), Profile::getEventsReminderHTML (224), Network::content (250), BaseModule::run (682): 0.001
Database::selectToArray (468), Network::getItems (234), Network::content (250), BaseModule::run (682): 0.085
Post::exists (850), Timeline::setItemsSeenByCondition (479), Network::getItems (234), Network::content (250): 0.019
Item::update (854), Timeline::setItemsSeenByCondition (479), Network::getItems (234), Network::content (250): 0.057
Post::selectToArray (481), Network::getItems (234), Network::content (250), BaseModule::run (682): 0.025
DBA::select (113), Counts::get (1027), Conversation::getEmojis (864), Conversation::addChildren (476): 0.002
DBA::fetch (114), Counts::get (1027), Conversation::getEmojis (864), Conversation::addChildren (476): 0.001
DBA::p (1052), Conversation::getEmojis (864), Conversation::addChildren (476), Conversation::render (237): 0.175
DBA::fetch (1053), Conversation::getEmojis (864), Conversation::addChildren (476), Conversation::render (237): 0.001
DBA::p (1101), Conversation::getQuoteShares (865), Conversation::addChildren (476), Conversation::render (237): 0.005
DBA::select (113), Counts::get (1079), Conversation::getCounts (866), Conversation::addChildren (476): 0.003
Post::select (888), Conversation::addChildren (476), Conversation::render (237), Network::content (250): 0.02
Post::fetch (892), Conversation::addChildren (476), Conversation::render (237), Network::content (250): 0.003
Post::select (899), Conversation::addChildren (476), Conversation::render (237), Network::content (250): 0.187
Post::fetch (905), Conversation::addChildren (476), Conversation::render (237), Network::content (250): 0.015
Post::select (948), Conversation::addChildren (476), Conversation::render (237), Network::content (250): 0.009
DBA::select (974), Conversation::addChildren (476), Conversation::render (237), Network::content (250): 0.001
Database::selectFirst (117), PConfig::get (90), JitPConfig::get (1309), Conversation::convSort (1011): 0.001
array_filter (1221), Conversation::smartFlattenConversation (1311), Conversation::convSort (1011), Conversation::addChildren (476): 0.025
array_filter (1219), Conversation::smartFlattenConversation (1311), Conversation::convSort (1011), Conversation::addChildren (476): 0.007
DBA::selectFirst (109), ThreadUser::getIgnored (391), Post::getTemplateData (204), Thread::getTemplateData (680): 0.053
DBA::select (557), Tag::populateFromItem (3393), Item::prepareBody (464), Post::getTemplateData (204): 0.632
DBA::fetch (559), Tag::populateFromItem (3393), Item::prepareBody (464), Post::getTemplateData (204): 0.011
DBA::selectToArray (816), Media::getByURIId (3425), Item::prepareBody (464), Post::getTemplateData (204): 0.203
Database::selectToArray (45), PostMedia::_select (66), PostMedia::selectByUriId (128), PostMedia::splitAttachments (3468): 0.066
DBA::select (557), Tag::populateFromItem (487), Post::getTemplateData (204), Thread::getTemplateData (680): 0.118
DBA::fetch (559), Tag::populateFromItem (487), Post::getTemplateData (204), Thread::getTemplateData (680): 0.01
DBA::selectFirst (397), Item::photoMenu (563), Post::getTemplateData (204), Thread::getTemplateData (680): 0.393
DBA::selectFirst (158), ContactSelector::networkToName (623), Post::getTemplateData (204), Thread::getTemplateData (680): 0.113
DBA::selectFirst (3610), Contact::magicLinkById (580), Tag::populateFromItem (3393), Item::prepareBody (464): 0.013
DBA::selectFirst (3610), Contact::magicLinkById (580), Tag::populateFromItem (487), Post::getTemplateData (204): 0.003
DBA::select (557), Tag::populateFromItem (3393), Item::prepareBody (464), Post::getTemplateData (655): 0.097
DBA::fetch (559), Tag::populateFromItem (3393), Item::prepareBody (464), Post::getTemplateData (655): 0.003
DBA::selectToArray (816), Media::getByURIId (3425), Item::prepareBody (464), Post::getTemplateData (655): 0.047
DBA::select (557), Tag::populateFromItem (487), Post::getTemplateData (655), Post::getTemplateData (204): 0.066
DBA::fetch (559), Tag::populateFromItem (487), Post::getTemplateData (655), Post::getTemplateData (204): 0.002
DBA::selectFirst (397), Item::photoMenu (563), Post::getTemplateData (655), Post::getTemplateData (204): 0.266
DBA::selectFirst (158), ContactSelector::networkToName (623), Post::getTemplateData (655), Post::getTemplateData (204): 0.047
DBA::selectFirst (3610), Contact::magicLinkById (580), Tag::populateFromItem (487), Post::getTemplateData (655): 0.008
DBA::select (557), Tag::populateFromItem (487), Post::getTemplateData (655), Post::getTemplateData (655): 0.004
DBA::selectFirst (397), Item::photoMenu (563), Post::getTemplateData (655), Post::getTemplateData (655): 0.026
DBA::selectFirst (158), ContactSelector::networkToName (623), Post::getTemplateData (655), Post::getTemplateData (655): 0.001
Database::selectFirst (117), PConfig::get (90), JitPConfig::get (204), Page::initHead (458): 0.001

Database Write:

Cache Read:

Cache Write:

Network:

Rendering:
Renderer::replaceMacros (611), Circle::sidebarWidget (136), Network::content (250), BaseModule::run (682): 0.001
Renderer::replaceMacros (295), Temporal::getDateTimeField (397), Conversation::statusEditor (211), Network::content (250): 0.001
Renderer::replaceMacros (428), Conversation::statusEditor (211), Network::content (250), BaseModule::run (682): 0.001
Conversation::statusEditor (211), Network::content (250), BaseModule::run (682), App::runFrontend (55): 0.001
Conversation::addRowInformation (943), Conversation::addChildren (476), Conversation::render (237), Network::content (250): 0.003
Conversation::getItemChildren (1300), Conversation::convSort (1011), Conversation::addChildren (476), Conversation::render (237): 0.01
Conversation::getItemChildren (1301), Conversation::convSort (1011), Conversation::addChildren (476), Conversation::render (237): 0.003
Conversation::getItemChildren (1133), Conversation::getItemChildren (1300), Conversation::convSort (1011), Conversation::addChildren (476): 0.009
Conversation::getItemChildren (1133), Conversation::getItemChildren (1133), Conversation::getItemChildren (1300), Conversation::convSort (1011): 0.001
Conversation::sortItemChildren (1306), Conversation::convSort (1011), Conversation::addChildren (476), Conversation::render (237): 0.004
Conversation::sortItemChildren (1161), Conversation::sortItemChildren (1306), Conversation::convSort (1011), Conversation::addChildren (476): 0.001
Conversation::Friendica\Content\{closure}, array_filter (1221), Conversation::smartFlattenConversation (1311), Conversation::convSort (1011): 0.007
Renderer::replaceMacros (1174), Post::getCommentBox (453), Post::getTemplateData (204), Thread::getTemplateData (680): 0.017
BBCode::fetchShareAttributes (744), Item::getSharedPost (3416), Item::prepareBody (464), Post::getTemplateData (204): 0.002
Item::replaceVisualAttachments (3469), Item::prepareBody (464), Post::getTemplateData (204), Thread::getTemplateData (680): 0.003
Item::addVisualAttachments (3538), Item::prepareBody (464), Post::getTemplateData (204), Thread::getTemplateData (680): 0.02
Item::addLinkAttachment (3539), Item::prepareBody (464), Post::getTemplateData (204), Thread::getTemplateData (680): 0.108
BBCode::convertAttachment (3902), Item::addLinkAttachment (3539), Item::prepareBody (464), Post::getTemplateData (204): 0.072
Item::photoMenu (563), Post::getTemplateData (204), Thread::getTemplateData (680), Conversation::getThreadList (583): 0.033
Renderer::replaceMacros (42), Image::getBodyAttachHtml (3772), Item::addVisualAttachments (3538), Item::prepareBody (464): 0.011
Renderer::replaceMacros (151), Image::getHorizontalMasonryHtml (37), Image::getBodyAttachHtml (3772), Item::addVisualAttachments (3538): 0.001
Renderer::replaceMacros (301), Conversation::formatActivity (367), Post::getTemplateData (204), Thread::getTemplateData (680): 0.004
Conversation::formatActivity (367), Post::getTemplateData (204), Thread::getTemplateData (680), Conversation::getThreadList (583): 0.004
Renderer::replaceMacros (1174), Post::getCommentBox (453), Post::getTemplateData (655), Post::getTemplateData (204): 0.011
BBCode::fetchShareAttributes (744), Item::getSharedPost (3416), Item::prepareBody (464), Post::getTemplateData (655): 0.001
Item::addVisualAttachments (3538), Item::prepareBody (464), Post::getTemplateData (655), Post::getTemplateData (204): 0.002
Item::addLinkAttachment (3539), Item::prepareBody (464), Post::getTemplateData (655), Post::getTemplateData (204): 0.001
Item::photoMenu (563), Post::getTemplateData (655), Post::getTemplateData (204), Thread::getTemplateData (680): 0.023
Renderer::replaceMacros (1174), Post::getCommentBox (453), Post::getTemplateData (655), Post::getTemplateData (655): 0.001
Item::photoMenu (563), Post::getTemplateData (655), Post::getTemplateData (655), Post::getTemplateData (204): 0.001
Renderer::replaceMacros (592), Conversation::render (237), Network::content (250), BaseModule::run (682): 0.06

This could suggest that Cloudflare Proxied servers consider all the Friendica traffic as something to block based on how much traffic is going through them. I can't say if this is true or not but I will keep it on DNS Only for now to see if it keeps loading /network and test /community/global as it is the only other page that gets the "504 Gateway Time-out" error. I'll report back later if it still works or if it breaks.

This entry was edited (4 months ago)
in reply to Scifijunkie

When I used CloudFlare Proxy in the past I remember creating a rule (In the CloudFlare panel) because my application (nextcloud) gave me slowness problems and sometimes it was not possible to reach the site. I'm not 100% sure but maybe you have the same problem I had in the past
in reply to NeMyS

Well, it's back to not loading /network or /community/global and that's with CloudFlare set to DNS only when it comes to Friendica. The odd thing is that when I try to go to /network or /community/global it takes out that entire node of my k3s cluster and it has three nodes. I could see if there is an update to k3s and see if that does anything.
in reply to NeMyS

Well, I did a rather crazy thing. I looked to see if I could find something like htop but for hard drives. I found something called iotop. Now after running it I noted that the total and current disk read was going all over the place. I went ahead and tried to load /network while iotop was running and it would spike to 20 M/s. So I ran e4defrag and let it sit for a while. It finely settled to about 200 K/s. I went ahead and tried to load /network again. It spiked to about 2 to 4 M/s. I saw that some people reported that PeerTube was doing a slow down to so I loaded up my PeerTube which defaults to me to videos just on my PeerTube node. It spiked to 40 M/s.

Now the only real difference between the two to me is that I use lscr.io/linuxserver/mariadb:10.11.5-r0-ls123 when it comes friendica:stable and I use postgres:15 when it come to chocobozzz/peertube:production-bookworm. So it makes me wounder if I need to update mariadb.

in reply to NeMyS

Well, I updated mariadb from lscr.io/linuxserver/mariadb:10.11.5-r0-ls123 to lscr.io/linuxserver/mariadb:10.11.8-r0-ls153. It still spikes but between about 2.5 to 4 M/s and it still takes out the k3s node it's on after a while. At least it seems to still take out the k3s node it's on anyway. That is when I try to load /network.
This entry was edited (3 months ago)
in reply to NeMyS

Well, it seems it's not Friendica taking out the k3s node at least not all the time. It seems that maybe PeerTube and Friendica together were taking out the k3s node they are on. Now mind you I'm just guessing at this point since Friendica still will not load /network or /community/global and PeerTube gives me the following pop-up errors now and then:

<html> <head><title>504 Gateway Time-out</title></head> <body> <center><h1>504 Gateway Time-out</h1></center> <hr><center>openresty</center> </body> </html> <!-- a padding to disable MSIE and Chrome friendly error page --> <!-- a padding to disable MSIE and Chrome friendly error page --> <!-- a padding to disable MSIE and Chrome friendly error page --> <!-- a padding to disable MSIE and Chrome friendly error page --> <!-- a padding to disable MSIE and Chrome friendly error page --> <!-- a padding to disable MSIE and Chrome friendly error page -->

Or something to the effect of "sorry can't load more vides".

It would do it on /videos/trending and /videos/recently-added.

I really don't have any spare servers I can just through together and do other tests right now. Now the spikes I noticed while using PeerTube and Friendica are on the Databases they use. That means Friendica is making mariadb spike between about 2.5 to 4 M/s and PeerTube is making postgres:15 spike between about 20 to 40 M/s.

in reply to NeMyS

Well it seems that @Roland Häder may have been right about that I may have inadvertently caused my own problem. I switched my Interface setting in my Pihole from "Bind only to interface enp3s0" to "Allow only local requests" thinking it would address the "Maximum number of concurrent DNS queries reached" warning better than just upping the concurrent DNS queries. Well it worked by making the warning but I think it might have created the problem of the /network or /community/global not loading for some resone. I say that I switched my Pihole back to "Bind only to interface enp3s0" and I'm having no problems loading either /network or /community/global. I have not looked to see if the spikes still happen or not though when it comes to the mariadb Database it uses. Just a heads up for other admins that use Pihole for DNS inside their networks.
This entry was edited (3 months ago)
in reply to NeMyS

Well it seems that /network or /community/global are not wanting to load again and I'm fresh out if Ideas of what to try now.
in reply to NeMyS

Well I upgraded all of my servers to 24.04.1 and seems that did the trick for me. That would lead me to believe that there may have been a problem with 22.04.1 in the world of Ubuntu. So it might be worth upgrading your distro to the latest version.
in reply to Scifijunkie

Well, I have never installed #Friendica in the #container, I have always used a dedicated VM, I have only had some small problems, even with old versions of Ubuntu Server . I'm not a Containerization expert, but it's not easy to troubleshooting
in reply to NeMyS

Okay, I think I finally found my problem. It's a memory issue on my end. I really can't address that right now though so I'll just have to deal with it for now until I can.
in reply to NeMyS

Well, I can confirm that it was a memory issue on my end for the problem I was having. It now works like a champ and is even faster than it ever was before. So maybe check RAM usage.
in reply to NeMyS

Well, it was working like a champ. It's starting to make me wonder if there is something wrong with the Image. If that's the case then I have to wait and see if it gets addressed in the new release Image. Oh well, it is what it is I guess.
in reply to Scifijunkie

@Scifijunkie
I think it's a configuration issue regarding your problem , try opening a new thread on @Friendica Support and mention that you use #docker
⇧