Skip to content

Blomstra Realtime issues on ubuntu server

Solved Linux
26 2 4.6k 1
  • @justoverclock and I see this in the log

    [2021-10-11 15:10:01] flarum.DEBUG: trigger POST: {post_value} {"post_value":"{\"name\":\"Flarum\\\\Post\\\\Event\\\\Posted\",\"data\":\"{\\\"data\\\":{\\\"type\\\":\\\"discussions\\\",\\\"id\\\":\\\"1\\\",\\\"attributes\\\":{\\\"title\\\":\\\"test\\\",\\\"slug\\\":\\\"1-test\\\",\\\"commentCount\\\":8,\\\"participantCount\\\":1,\\\"createdAt\\\":\\\"2021-10-11T14:37:36+00:00\\\",\\\"lastPostedAt\\\":\\\"2021-10-11T15:10:00+00:00\\\",\\\"lastPostNumber\\\":8,\\\"canReply\\\":false,\\\"canRename\\\":false,\\\"canDelete\\\":false,\\\"canHide\\\":false,\\\"isApproved\\\":true,\\\"canViewWhoTypes\\\":false,\\\"canTag\\\":false,\\\"subscription\\\":null,\\\"isSticky\\\":false,\\\"canSticky\\\":false,\\\"isLocked\\\":false,\\\"canLock\\\":false},\\\"relationships\\\":{\\\"tags\\\":{\\\"data\\\":[{\\\"type\\\":\\\"tags\\\",\\\"id\\\":\\\"1\\\"}]},\\\"user\\\":{\\\"data\\\":{\\\"type\\\":\\\"users\\\",\\\"id\\\":\\\"1\\\"}},\\\"lastPostedUser\\\":{\\\"data\\\":{\\\"type\\\":\\\"users\\\",\\\"id\\\":\\\"1\\\"}},\\\"lastPost\\\":{\\\"data\\\":{\\\"type\\\":\\\"posts\\\",\\\"id\\\":\\\"8\\\"}}}},\\\"included\\\":[{\\\"type\\\":\\\"tags\\\",\\\"id\\\":\\\"1\\\",\\\"attributes\\\":{\\\"name\\\":\\\"General\\\",\\\"description\\\":null,\\\"slug\\\":\\\"general\\\",\\\"color\\\":\\\"#888\\\",\\\"backgroundUrl\\\":null,\\\"backgroundMode\\\":null,\\\"icon\\\":null,\\\"discussionCount\\\":0,\\\"position\\\":0,\\\"defaultSort\\\":null,\\\"isChild\\\":false,\\\"isHidden\\\":false,\\\"lastPostedAt\\\":\\\"2021-10-11T14:45:03+00:00\\\",\\\"canStartDiscussion\\\":false,\\\"canAddToDiscussion\\\":false}},{\\\"type\\\":\\\"users\\\",\\\"id\\\":\\\"1\\\",\\\"attributes\\\":{\\\"username\\\":\\\"Marko\\\",\\\"displayName\\\":\\\"Marko\\\",\\\"avatarUrl\\\":null,\\\"slug\\\":\\\"Marko\\\"}},{\\\"type\\\":\\\"posts\\\",\\\"id\\\":\\\"8\\\",\\\"attributes\\\":{\\\"number\\\":8,\\\"createdAt\\\":\\\"2021-10-11T15:10:00+00:00\\\",\\\"contentType\\\":\\\"comment\\\",\\\"contentHtml\\\":\\\"<p>dfg<\\\\\\/p>\\\"}}]}\",\"channels\":[\"guest\"]}"} 
    [2021-10-11 15:10:05] flarum.DEBUG: trigger POST: {post_value} {"post_value":"{\"name\":\"Flarum\\\\Post\\\\Event\\\\Posted\",\"data\":\"{\\\"data\\\":{\\\"type\\\":\\\"discussions\\\",\\\"id\\\":\\\"1\\\",\\\"attributes\\\":{\\\"title\\\":\\\"test\\\",\\\"slug\\\":\\\"1-test\\\",\\\"commentCount\\\":9,\\\"participantCount\\\":1,\\\"createdAt\\\":\\\"2021-10-11T14:37:36+00:00\\\",\\\"lastPostedAt\\\":\\\"2021-10-11T15:10:05+00:00\\\",\\\"lastPostNumber\\\":9,\\\"canReply\\\":false,\\\"canRename\\\":false,\\\"canDelete\\\":false,\\\"canHide\\\":false,\\\"isApproved\\\":true,\\\"canViewWhoTypes\\\":false,\\\"canTag\\\":false,\\\"subscription\\\":null,\\\"isSticky\\\":false,\\\"canSticky\\\":false,\\\"isLocked\\\":false,\\\"canLock\\\":false},\\\"relationships\\\":{\\\"tags\\\":{\\\"data\\\":[{\\\"type\\\":\\\"tags\\\",\\\"id\\\":\\\"1\\\"}]},\\\"user\\\":{\\\"data\\\":{\\\"type\\\":\\\"users\\\",\\\"id\\\":\\\"1\\\"}},\\\"lastPostedUser\\\":{\\\"data\\\":{\\\"type\\\":\\\"users\\\",\\\"id\\\":\\\"1\\\"}},\\\"lastPost\\\":{\\\"data\\\":{\\\"type\\\":\\\"posts\\\",\\\"id\\\":\\\"9\\\"}}}},\\\"included\\\":[{\\\"type\\\":\\\"tags\\\",\\\"id\\\":\\\"1\\\",\\\"attributes\\\":{\\\"name\\\":\\\"General\\\",\\\"description\\\":null,\\\"slug\\\":\\\"general\\\",\\\"color\\\":\\\"#888\\\",\\\"backgroundUrl\\\":null,\\\"backgroundMode\\\":null,\\\"icon\\\":null,\\\"discussionCount\\\":0,\\\"position\\\":0,\\\"defaultSort\\\":null,\\\"isChild\\\":false,\\\"isHidden\\\":false,\\\"lastPostedAt\\\":\\\"2021-10-11T15:10:00+00:00\\\",\\\"canStartDiscussion\\\":false,\\\"canAddToDiscussion\\\":false}},{\\\"type\\\":\\\"users\\\",\\\"id\\\":\\\"1\\\",\\\"attributes\\\":{\\\"username\\\":\\\"Marko\\\",\\\"displayName\\\":\\\"Marko\\\",\\\"avatarUrl\\\":null,\\\"slug\\\":\\\"Marko\\\"}},{\\\"type\\\":\\\"posts\\\",\\\"id\\\":\\\"9\\\",\\\"attributes\\\":{\\\"number\\\":9,\\\"createdAt\\\":\\\"2021-10-11T15:10:05+00:00\\\",\\\"contentType\\\":\\\"comment\\\",\\\"contentHtml\\\":\\\"<p>dfgdfgdfg<\\\\\\/p>\\\"}}]}\",\"channels\":[\"guest\"]}"} 
    [2021-10-11 15:10:10] flarum.DEBUG: trigger POST: {post_value} {"post_value":"{\"name\":\"Flarum\\\\Post\\\\Event\\\\Posted\",\"data\":\"{\\\"data\\\":{\\\"type\\\":\\\"discussions\\\",\\\"id\\\":\\\"1\\\",\\\"attributes\\\":{\\\"title\\\":\\\"test\\\",\\\"slug\\\":\\\"1-test\\\",\\\"commentCount\\\":10,\\\"participantCount\\\":1,\\\"createdAt\\\":\\\"2021-10-11T14:37:36+00:00\\\",\\\"lastPostedAt\\\":\\\"2021-10-11T15:10:10+00:00\\\",\\\"lastPostNumber\\\":10,\\\"canReply\\\":false,\\\"canRename\\\":false,\\\"canDelete\\\":false,\\\"canHide\\\":false,\\\"isApproved\\\":true,\\\"canViewWhoTypes\\\":false,\\\"canTag\\\":false,\\\"subscription\\\":null,\\\"isSticky\\\":false,\\\"canSticky\\\":false,\\\"isLocked\\\":false,\\\"canLock\\\":false},\\\"relationships\\\":{\\\"tags\\\":{\\\"data\\\":[{\\\"type\\\":\\\"tags\\\",\\\"id\\\":\\\"1\\\"}]},\\\"user\\\":{\\\"data\\\":{\\\"type\\\":\\\"users\\\",\\\"id\\\":\\\"1\\\"}},\\\"lastPostedUser\\\":{\\\"data\\\":{\\\"type\\\":\\\"users\\\",\\\"id\\\":\\\"1\\\"}},\\\"lastPost\\\":{\\\"data\\\":{\\\"type\\\":\\\"posts\\\",\\\"id\\\":\\\"10\\\"}}}},\\\"included\\\":[{\\\"type\\\":\\\"tags\\\",\\\"id\\\":\\\"1\\\",\\\"attributes\\\":{\\\"name\\\":\\\"General\\\",\\\"description\\\":null,\\\"slug\\\":\\\"general\\\",\\\"color\\\":\\\"#888\\\",\\\"backgroundUrl\\\":null,\\\"backgroundMode\\\":null,\\\"icon\\\":null,\\\"discussionCount\\\":0,\\\"position\\\":0,\\\"defaultSort\\\":null,\\\"isChild\\\":false,\\\"isHidden\\\":false,\\\"lastPostedAt\\\":\\\"2021-10-11T15:10:05+00:00\\\",\\\"canStartDiscussion\\\":false,\\\"canAddToDiscussion\\\":false}},{\\\"type\\\":\\\"users\\\",\\\"id\\\":\\\"1\\\",\\\"attributes\\\":{\\\"username\\\":\\\"Marko\\\",\\\"displayName\\\":\\\"Marko\\\",\\\"avatarUrl\\\":null,\\\"slug\\\":\\\"Marko\\\"}},{\\\"type\\\":\\\"posts\\\",\\\"id\\\":\\\"10\\\",\\\"attributes\\\":{\\\"number\\\":10,\\\"createdAt\\\":\\\"2021-10-11T15:10:10+00:00\\\",\\\"contentType\\\":\\\"comment\\\",\\\"contentHtml\\\":\\\"<p>ciaociaociao<\\\\\\/p>\\\"}}]}\",\"channels\":[\"guest\"]}"} 
    [2021-10-11 15:10:43] flarum.DEBUG: trigger POST: {post_value} {"post_value":"{\"name\":\"Flarum\\\\Post\\\\Event\\\\Posted\",\"data\":\"{\\\"data\\\":{\\\"type\\\":\\\"discussions\\\",\\\"id\\\":\\\"1\\\",\\\"attributes\\\":{\\\"title\\\":\\\"test\\\",\\\"slug\\\":\\\"1-test\\\",\\\"commentCount\\\":11,\\\"participantCount\\\":1,\\\"createdAt\\\":\\\"2021-10-11T14:37:36+00:00\\\",\\\"lastPostedAt\\\":\\\"2021-10-11T15:10:43+00:00\\\",\\\"lastPostNumber\\\":11,\\\"canReply\\\":false,\\\"canRename\\\":false,\\\"canDelete\\\":false,\\\"canHide\\\":false,\\\"isApproved\\\":true,\\\"canViewWhoTypes\\\":false,\\\"canTag\\\":false,\\\"subscription\\\":null,\\\"isSticky\\\":false,\\\"canSticky\\\":false,\\\"isLocked\\\":false,\\\"canLock\\\":false},\\\"relationships\\\":{\\\"tags\\\":{\\\"data\\\":[{\\\"type\\\":\\\"tags\\\",\\\"id\\\":\\\"1\\\"}]},\\\"user\\\":{\\\"data\\\":{\\\"type\\\":\\\"users\\\",\\\"id\\\":\\\"1\\\"}},\\\"lastPostedUser\\\":{\\\"data\\\":{\\\"type\\\":\\\"users\\\",\\\"id\\\":\\\"1\\\"}},\\\"lastPost\\\":{\\\"data\\\":{\\\"type\\\":\\\"posts\\\",\\\"id\\\":\\\"11\\\"}}}},\\\"included\\\":[{\\\"type\\\":\\\"tags\\\",\\\"id\\\":\\\"1\\\",\\\"attributes\\\":{\\\"name\\\":\\\"General\\\",\\\"description\\\":null,\\\"slug\\\":\\\"general\\\",\\\"color\\\":\\\"#888\\\",\\\"backgroundUrl\\\":null,\\\"backgroundMode\\\":null,\\\"icon\\\":null,\\\"discussionCount\\\":0,\\\"position\\\":0,\\\"defaultSort\\\":null,\\\"isChild\\\":false,\\\"isHidden\\\":false,\\\"lastPostedAt\\\":\\\"2021-10-11T15:10:10+00:00\\\",\\\"canStartDiscussion\\\":false,\\\"canAddToDiscussion\\\":false}},{\\\"type\\\":\\\"users\\\",\\\"id\\\":\\\"1\\\",\\\"attributes\\\":{\\\"username\\\":\\\"Marko\\\",\\\"displayName\\\":\\\"Marko\\\",\\\"avatarUrl\\\":null,\\\"slug\\\":\\\"Marko\\\"}},{\\\"type\\\":\\\"posts\\\",\\\"id\\\":\\\"11\\\",\\\"attributes\\\":{\\\"number\\\":11,\\\"createdAt\\\":\\\"2021-10-11T15:10:43+00:00\\\",\\\"contentType\\\":\\\"comment\\\",\\\"contentHtml\\\":\\\"<p>sdgsfsdfsdfsdfsdfsdfsdfsdfsdfsdfsdf<\\\\\\/p>\\\"}}]}\",\"channels\":[\"guest\"]}"} 
    

    Are you able to post now ?

    @phenomlab yes but i get console error about websocket

    pusher.js:4026 WebSocket connection to ‘wss://forum.justoverclock.it:6001/app/1ddbcd118d43678d3943c6a3f3541ff2?protocol=7&client=js&version=7.0.3&flash=false’ failed:

  • @phenomlab yeah but i need to develop around this so i need it for now.

    php flarum realtime:serve -vvv --debug
    Starting websocket server, which listens on 0.0.0.0:6001.
    App key expected is #############################
    App secret expected is #############################
    Max connections 1000
    

    @justoverclock I removed your app and key and secret. Don’t post anything sensitive 🙂

  • @phenomlab yes but i get console error about websocket

    pusher.js:4026 WebSocket connection to ‘wss://forum.justoverclock.it:6001/app/1ddbcd118d43678d3943c6a3f3541ff2?protocol=7&client=js&version=7.0.3&flash=false’ failed:

    @justoverclock

    i think this is not valid for my server?

    [program:realtime]
    command=/usr/bin/php /var/www/flarum/flarum realtime:serve
    numprocs=1
    autostart=true
    autorestart=true
    user=www-data
    
  • @justoverclock I removed your app and key and secret. Don’t post anything sensitive 🙂

    @phenomlab 😮 u mean that u are working on this?

  • @justoverclock

    i think this is not valid for my server?

    [program:realtime]
    command=/usr/bin/php /var/www/flarum/flarum realtime:serve
    numprocs=1
    autostart=true
    autorestart=true
    user=www-data
    

    @justoverclock Correct. That path should be

    /home/justoverclock/domains/forum.justoverclock.it/homes/flarum/public

  • @phenomlab 😮 u mean that u are working on this?

    @justoverclock No, I meant that you have posted sensitive information concerning your flarum installation on another public forum, which could expose your site to attack.

  • @justoverclock No, I meant that you have posted sensitive information concerning your flarum installation on another public forum, which could expose your site to attack.

    @phenomlab my file is now

    [program:realtime]
    command=/usr/bin/php /home/justoverclock/domains/forum.justoverclock.it/homes/flarum/public realtime:serve
    numprocs=1
    autostart=true
    autorestart=true
    user=www-data
    

    but same error

  • @phenomlab my file is now

    [program:realtime]
    command=/usr/bin/php /home/justoverclock/domains/forum.justoverclock.it/homes/flarum/public realtime:serve
    numprocs=1
    autostart=true
    autorestart=true
    user=www-data
    

    but same error

    @justoverclock Yes, I don’t expect the error to be any different to be honest. You’re running from the CLI anyway, and this path is for the supervisor service.

  • @justoverclock Yes, I don’t expect the error to be any different to be honest. You’re running from the CLI anyway, and this path is for the supervisor service.

    @phenomlab well…now i can’t post enymore…error 500

  • @phenomlab well…now i can’t post enymore…error 500

    @justoverclock Seeing as this is a premium Flarum extension, and you’ve paid for support, you should ask there I think. From what I see in the logs, plus the way I know websockets work, I think you need additional config in nginx.conf.

    Compare this with the guide from kyrne on discuss (which is completely free by the way and works 100%) - https://extiverse.com/extension/kyrne/websocket

    For the record, I purchased Realtime before I departed the Flarum ecosystem, and it didn’t work - period, so I got a refund.

  • justoverclockundefined justoverclock has marked this topic as solved on
  • Just checked this thread on Discuss. It’s effectively not stable yet. My suggestion would be to use kyrne/websocket


Did this solution help you?
Did you find the suggested solution useful? Support 💗 Sudonix with a coffee
If your organisation needs deeper expertise around infrastructure, security, or technology leadership, learn more about Phenomlab Ltd. Many of the deeper technical guides behind Sudonix are published there.

Related Topics
  • To the Window to the Linux . . .

    Pinned Linux arch linux windows endoflife
    22
    19 Votes
    22 Posts
    2k Views
    @phenomlab said: @Madchatthew ouch. Sounds nasty. Did you get to the bottom of why it happened? I believe it is due to not everything getting upgraded because i wasn’t checking on the different packages I had installed from the AUR. Then when I ran yay it was like, hey would you like to update all of these things that you haven’t updated in months, perhaps years or ever for that matter and I was like yes please If you don’t have yay there are no notifications that you need more updates than what you realize. Chrome was staying updated because it would give me a notification, but there was the nvidia package that needed to be upgraded as well and I had never upgraded it. I didn’t realize it and should have. Then some of those packages use cmake and that needed to be updated as well. So using yay is beneficial to make sure you get all the updates you need.
  • Arch Linux | Reflector

    Linux arch linux pacman reflector updates
    4
    4 Votes
    4 Posts
    2k Views
    I have another update for reflector that I just figured out. You will want to edit the following file and add details to make sure that every time it updates the mirror list, it is grabbing them from your country and I grab 10 and sort them by rate. This will ensure that your mirrorlist isn’t getting populated with links from other countries which can slow down you downloads. sudo nano /etc/xdg/reflector/reflector.conf This is what the file looks like. # Reflector configuration file for the systemd service. # # Empty lines and lines beginning with "#" are ignored. All other lines should # contain valid reflector command-line arguments. The lines are parsed with # Python's shlex modules so standard shell syntax should work. All arguments are # collected into a single argument list. # # See "reflector --help" for details. # Recommended Options # Set the output path where the mirrorlist will be saved (--save). --save /etc/pacman.d/mirrorlist # Select the transfer protocol (--protocol). --protocol https # Select the country (--country). # Consult the list of available countries with "reflector --list-countries" and # select the countries nearest to you or the ones that you trust. For example: --country US # Use only the most recently synchronized mirrors (--latest). --latest 10 # Sort the mirrors by synchronization time (--sort). --sort rate Here are the different flag options that you can change or add to this file. I found this on google by searching arch linux reflector flags. Filtering Options (What to find) --country <CODE/Name>: Selects mirrors from specific countries (e.g., US, France,Germany). Use {Link: reflector --list-countries https://archlinux.org/mirrors/status/}, for a full list. --protocol <http|https>: Filters for HTTP or HTTPS mirrors. --age <hours>: Only includes mirrors synced within the last X hours (e.g., --age 12). --delay <hours>: Limits to mirrors with a reported sync delay of X hours or less (e.g., --delay 0.25 for 15 mins). --latest <N>: Limits results to the top N newest mirrors. Sorting Options (How to order) --sort rate: Sorts by download speed (requires testing, can be slow). --sort age: Sorts by most recently synced. --sort score: Sorts by overall score. --sort country: Sorts by country, useful with multiple countries. Output Options (Where to put it) --save <path>: Writes the filtered/sorted list to a file (e.g., /etc/pacman.d/mirrorlist). --verbose or -v: Shows detailed progress and mirror info.
  • Linux on a Stick

    Linux linux usb arch
    29
    16 Votes
    29 Posts
    4k Views
    @DownPW I haven’t tried either of those, I am sure they run fast as well. Linux is so versatile it is awesome!
  • Linux Certification

    Linux linux certs
    4
    2 Votes
    4 Posts
    787 Views
    @Madchatthew You might be sorry you asked This is the mentoring category below. Presently, it’s unused, but we have a dedicated area for it. https://sudonix.org/category/8/mentoring Other services https://sudonix.org/services
  • Arch Linux + Me = Crazy

    Linux arch linux web server vps
    10
    0 Votes
    10 Posts
    1k Views
    @Madchatthew hmm, yes, that might be problematic.
  • Error certification on virtualmin/Nginx

    Solved Linux cert virtualmin nginx
    17
    2
    0 Votes
    17 Posts
    3k Views
    @DownPW anytime
  • Avoid network traffic jam with BBR

    Linux ftp speed
    2
    1 Votes
    2 Posts
    847 Views
    @DownPW interesting. Does this have any effect on data transfers over SCP
  • IRC Server/Client - Chat App with NodeBB

    Linux nodebb irc server client
    6
    1 Votes
    6 Posts
    2k Views
    @Hari not sure from the consumer perspective, but Skype has been all but completely consumed by Microsoft Teams when it comes to business usage.