Good morning,
I have a problem during registration. When a user registers the following message appears:

OPS, something went wrong.

POST http://cantierecreativo.click/register

Swift_TransportException: Expected response code 220 but got an empty response in /var/www/html/vendor/swiftmailer/swiftmailer/lib/classes/Swift/Transport/AbstractSmtpTransport.php:447
Stack trace:
#0 /var/www/html/vendor/swiftmailer/swiftmailer/lib/classes/Swift/Transport/AbstractSmtpTransport.php(360): Swift_Transport_AbstractSmtpTransport->assertResponseCode()
#1 /var/www/html/vendor/swiftmailer/swiftmailer/lib/classes/Swift/Transport/AbstractSmtpTransport.php(147): Swift_Transport_AbstractSmtpTransport->readGreeting()
#2 /var/www/html/vendor/swiftmailer/swiftmailer/lib/classes/Swift/Transport/SendmailTransport.php(50): Swift_Transport_AbstractSmtpTransport->start()
#3 /var/www/html/vendor/swiftmailer/swiftmailer/lib/classes/Swift/Mailer.php(65): Swift_Transport_SendmailTransport->start()
#4 /var/www/html/vendor/illuminate/mail/Mailer.php(521): Swift_Mailer->send()
#5 /var/www/html/vendor/illuminate/mail/Mailer.php(288): Illuminate\Mail\Mailer->sendSwiftMessage()
#6 /var/www/html/vendor/illuminate/mail/Mailer.php(212): Illuminate\Mail\Mailer->send()
#7 /var/www/html/vendor/flarum/core/src/Mail/Job/SendRawEmailJob.php(33): Illuminate\Mail\Mailer->raw()
#8 /var/www/html/vendor/illuminate/container/BoundMethod.php(36): Flarum\Mail\Job\SendRawEmailJob->handle()
#9 /var/www/html/vendor/illuminate/container/Util.php(40): Illuminate\Container\BoundMethod::Illuminate\Container\{closure}()
#10 /var/www/html/vendor/illuminate/container/BoundMethod.php(93): Illuminate\Container\Util::unwrapIfClosure()
#11 /var/www/html/vendor/illuminate/container/BoundMethod.php(35): Illuminate\Container\BoundMethod::callBoundMethod()
#12 /var/www/html/vendor/illuminate/container/Container.php(653): Illuminate\Container\BoundMethod::call()
#13 /var/www/html/vendor/illuminate/bus/Dispatcher.php(128): Illuminate\Container\Container->call()
#14 /var/www/html/vendor/illuminate/pipeline/Pipeline.php(128): Illuminate\Bus\Dispatcher->Illuminate\Bus\{closure}()
#15 /var/www/html/vendor/illuminate/pipeline/Pipeline.php(103): Illuminate\Pipeline\Pipeline->Illuminate\Pipeline\{closure}()
#16 /var/www/html/vendor/illuminate/bus/Dispatcher.php(132): Illuminate\Pipeline\Pipeline->then()
#17 /var/www/html/vendor/illuminate/queue/CallQueuedHandler.php(119): Illuminate\Bus\Dispatcher->dispatchNow()
#18 /var/www/html/vendor/illuminate/pipeline/Pipeline.php(128): Illuminate\Queue\CallQueuedHandler->Illuminate\Queue\{closure}()
#19 /var/www/html/vendor/illuminate/pipeline/Pipeline.php(103): Illuminate\Pipeline\Pipeline->Illuminate\Pipeline\{closure}()
#20 /var/www/html/vendor/illuminate/queue/CallQueuedHandler.php(118): Illuminate\Pipeline\Pipeline->then()
#21 /var/www/html/vendor/illuminate/queue/CallQueuedHandler.php(70): Illuminate\Queue\CallQueuedHandler->dispatchThroughMiddleware()
#22 /var/www/html/vendor/illuminate/queue/Jobs/Job.php(98): Illuminate\Queue\CallQueuedHandler->call()
#23 /var/www/html/vendor/illuminate/queue/SyncQueue.php(43): Illuminate\Queue\Jobs\Job->fire()
#24 /var/www/html/vendor/flarum/core/src/User/AccountActivationMailerTrait.php(54): Illuminate\Queue\SyncQueue->push()
#25 /var/www/html/vendor/flarum/core/src/User/AccountActivationMailer.php(67): Flarum\User\AccountActivationMailer->sendConfirmationEmail()
#26 /var/www/html/vendor/illuminate/events/Dispatcher.php(424): Flarum\User\AccountActivationMailer->handle()
#27 /var/www/html/vendor/illuminate/events/Dispatcher.php(249): Illuminate\Events\Dispatcher->Illuminate\Events\{closure}()
#28 /var/www/html/vendor/flarum/core/src/Foundation/DispatchEventsTrait.php(33): Illuminate\Events\Dispatcher->dispatch()
#29 /var/www/html/vendor/flarum/core/src/User/Command/RegisterUserHandler.php(120): Flarum\User\Command\RegisterUserHandler->dispatchEventsFor()
#30 /var/www/html/vendor/illuminate/bus/Dispatcher.php(122): Flarum\User\Command\RegisterUserHandler->handle()
#31 /var/www/html/vendor/illuminate/pipeline/Pipeline.php(128): Illuminate\Bus\Dispatcher->Illuminate\Bus\{closure}()
#32 /var/www/html/vendor/illuminate/pipeline/Pipeline.php(103): Illuminate\Pipeline\Pipeline->Illuminate\Pipeline\{closure}()
#33 /var/www/html/vendor/illuminate/bus/Dispatcher.php(132): Illuminate\Pipeline\Pipeline->then()
#34 /var/www/html/vendor/illuminate/bus/Dispatcher.php(78): Illuminate\Bus\Dispatcher->dispatchNow()
#35 /var/www/html/vendor/flarum/core/src/Api/Controller/CreateUserController.php(45): Illuminate\Bus\Dispatcher->dispatch()
#36 /var/www/html/vendor/flarum/core/src/Api/Controller/AbstractSerializeController.php(116): Flarum\Api\Controller\CreateUserController->data()
#37 /var/www/html/vendor/flarum/core/src/Api/Controller/AbstractCreateController.php(22): Flarum\Api\Controller\AbstractSerializeController->handle()
#38 /var/www/html/vendor/flarum/core/src/Http/RouteHandlerFactory.php(41): Flarum\Api\Controller\AbstractCreateController->handle()
#39 /var/www/html/vendor/flarum/core/src/Http/Middleware/ExecuteRoute.php(27): Flarum\Http\RouteHandlerFactory->Flarum\Http\{closure}()
#40 /var/www/html/vendor/laminas/laminas-stratigility/src/Next.php(52): Flarum\Http\Middleware\ExecuteRoute->process()
#41 /var/www/html/vendor/flarum/core/src/Api/Middleware/ThrottleApi.php(33): Laminas\Stratigility\Next->handle()
#42 /var/www/html/vendor/laminas/laminas-stratigility/src/Next.php(52): Flarum\Api\Middleware\ThrottleApi->process()
#43 /var/www/html/vendor/flarum/core/src/Http/Middleware/ResolveRoute.php(69): Laminas\Stratigility\Next->handle()
#44 /var/www/html/vendor/laminas/laminas-stratigility/src/Next.php(52): Flarum\Http\Middleware\ResolveRoute->process()
#45 /var/www/html/vendor/flarum/core/src/Http/Middleware/SetLocale.php(51): Laminas\Stratigility\Next->handle()
#46 /var/www/html/vendor/laminas/laminas-stratigility/src/Next.php(52): Flarum\Http\Middleware\SetLocale->process()
#47 /var/www/html/vendor/flarum/core/src/Http/Middleware/HandleErrors.php(57): Laminas\Stratigility\Next->handle()
#48 /var/www/html/vendor/laminas/laminas-stratigility/src/Next.php(52): Flarum\Http\Middleware\HandleErrors->process()
#49 /var/www/html/vendor/laminas/laminas-stratigility/src/MiddlewarePipe.php(77): Laminas\Stratigility\Next->handle()
#50 /var/www/html/vendor/laminas/laminas-stratigility/src/MiddlewarePipe.php(66): Laminas\Stratigility\MiddlewarePipe->process()
#51 /var/www/html/vendor/flarum/core/src/Api/Client.php(141): Laminas\Stratigility\MiddlewarePipe->handle()
#52 /var/www/html/vendor/flarum/core/src/Api/Client.php(96): Flarum\Api\Client->send()
#53 /var/www/html/vendor/flarum/core/src/Forum/Controller/RegisterController.php(56): Flarum\Api\Client->post()
#54 /var/www/html/vendor/flarum/core/src/Http/RouteHandlerFactory.php(41): Flarum\Forum\Controller\RegisterController->handle()
#55 /var/www/html/vendor/flarum/core/src/Http/Middleware/ExecuteRoute.php(27): Flarum\Http\RouteHandlerFactory->Flarum\Http\{closure}()
#56 /var/www/html/vendor/laminas/laminas-stratigility/src/Next.php(52): Flarum\Http\Middleware\ExecuteRoute->process()
#57 /var/www/html/vendor/flarum/core/src/Http/Middleware/ContentTypeOptionsHeader.php(21): Laminas\Stratigility\Next->handle()
#58 /var/www/html/vendor/laminas/laminas-stratigility/src/Next.php(52): Flarum\Http\Middleware\ContentTypeOptionsHeader->process()
#59 /var/www/html/vendor/flarum/core/src/Http/Middleware/ReferrerPolicyHeader.php(30): Laminas\Stratigility\Next->handle()
#60 /var/www/html/vendor/laminas/laminas-stratigility/src/Next.php(52): Flarum\Http\Middleware\ReferrerPolicyHeader->process()
#61 /var/www/html/vendor/flarum/core/src/Http/Middleware/FlarumPromotionHeader.php(30): Laminas\Stratigility\Next->handle()
#62 /var/www/html/vendor/laminas/laminas-stratigility/src/Next.php(52): Flarum\Http\Middleware\FlarumPromotionHeader->process()
#63 /var/www/html/vendor/flarum/core/src/Http/Middleware/ShareErrorsFromSession.php(57): Laminas\Stratigility\Next->handle()
#64 /var/www/html/vendor/laminas/laminas-stratigility/src/Next.php(52): Flarum\Http\Middleware\ShareErrorsFromSession->process()
#65 /var/www/html/vendor/flarum/core/src/Http/Middleware/CheckCsrfToken.php(44): Laminas\Stratigility\Next->handle()
#66 /var/www/html/vendor/laminas/laminas-stratigility/src/Next.php(52): Flarum\Http\Middleware\CheckCsrfToken->process()
#67 /var/www/html/vendor/flarum/core/src/Http/Middleware/ResolveRoute.php(69): Laminas\Stratigility\Next->handle()
#68 /var/www/html/vendor/laminas/laminas-stratigility/src/Next.php(52): Flarum\Http\Middleware\ResolveRoute->process()
#69 /var/www/html/vendor/flarum/core/src/Http/Middleware/SetLocale.php(51): Laminas\Stratigility\Next->handle()
#70 /var/www/html/vendor/laminas/laminas-stratigility/src/Next.php(52): Flarum\Http\Middleware\SetLocale->process()
#71 /var/www/html/vendor/flarum/core/src/Http/Middleware/AuthenticateWithSession.php(31): Laminas\Stratigility\Next->handle()
#72 /var/www/html/vendor/laminas/laminas-stratigility/src/Next.php(52): Flarum\Http\Middleware\AuthenticateWithSession->process()
#73 /var/www/html/vendor/flarum/core/src/Http/Middleware/RememberFromCookie.php(52): Laminas\Stratigility\Next->handle()
#74 /var/www/html/vendor/laminas/laminas-stratigility/src/Next.php(52): Flarum\Http\Middleware\RememberFromCookie->process()
#75 /var/www/html/vendor/flarum/core/src/Http/Middleware/StartSession.php(61): Laminas\Stratigility\Next->handle()
#76 /var/www/html/vendor/laminas/laminas-stratigility/src/Next.php(52): Flarum\Http\Middleware\StartSession->process()
#77 /var/www/html/vendor/flarum/core/src/Http/Middleware/CollectGarbage.php(46): Laminas\Stratigility\Next->handle()
#78 /var/www/html/vendor/laminas/laminas-stratigility/src/Next.php(52): Flarum\Http\Middleware\CollectGarbage->process()
#79 /var/www/html/vendor/flarum/core/src/Http/Middleware/ParseJsonBody.php(28): Laminas\Stratigility\Next->handle()
#80 /var/www/html/vendor/laminas/laminas-stratigility/src/Next.php(52): Flarum\Http\Middleware\ParseJsonBody->process()
#81 /var/www/html/vendor/flarum/core/src/Http/Middleware/HandleErrors.php(57): Laminas\Stratigility\Next->handle()
#82 /var/www/html/vendor/laminas/laminas-stratigility/src/Next.php(52): Flarum\Http\Middleware\HandleErrors->process()
#83 /var/www/html/vendor/flarum/core/src/Http/Middleware/InjectActorReference.php(25): Laminas\Stratigility\Next->handle()
#84 /var/www/html/vendor/laminas/laminas-stratigility/src/Next.php(52): Flarum\Http\Middleware\InjectActorReference->process()
#85 /var/www/html/vendor/laminas/laminas-stratigility/src/MiddlewarePipe.php(77): Laminas\Stratigility\Next->handle()
#86 /var/www/html/vendor/middlewares/request-handler/src/RequestHandler.php(84): Laminas\Stratigility\MiddlewarePipe->process()
#87 /var/www/html/vendor/laminas/laminas-stratigility/src/Next.php(52): Middlewares\RequestHandler->process()
#88 /var/www/html/vendor/middlewares/base-path-router/src/BasePathRouter.php(99): Laminas\Stratigility\Next->handle()
#89 /var/www/html/vendor/laminas/laminas-stratigility/src/Next.php(52): Middlewares\BasePathRouter->process()
#90 /var/www/html/vendor/laminas/laminas-stratigility/src/Middleware/OriginalMessages.php(36): Laminas\Stratigility\Next->handle()
#91 /var/www/html/vendor/laminas/laminas-stratigility/src/Next.php(52): Laminas\Stratigility\Middleware\OriginalMessages->process()
#92 /var/www/html/vendor/middlewares/base-path/src/BasePath.php(73): Laminas\Stratigility\Next->handle()
#93 /var/www/html/vendor/laminas/laminas-stratigility/src/Next.php(52): Middlewares\BasePath->process()
#94 /var/www/html/vendor/flarum/core/src/Http/Middleware/ProcessIp.php(24): Laminas\Stratigility\Next->handle()
#95 /var/www/html/vendor/laminas/laminas-stratigility/src/Next.php(52): Flarum\Http\Middleware\ProcessIp->process()
#96 /var/www/html/vendor/laminas/laminas-stratigility/src/MiddlewarePipe.php(77): Laminas\Stratigility\Next->handle()
#97 /var/www/html/vendor/laminas/laminas-stratigility/src/MiddlewarePipe.php(66): Laminas\Stratigility\MiddlewarePipe->process()
#98 /var/www/html/vendor/laminas/laminas-httphandlerrunner/src/RequestHandlerRunner.php(73): Laminas\Stratigility\MiddlewarePipe->handle()
#99 /var/www/html/vendor/flarum/core/src/Http/Server.php(45): Laminas\HttpHandlerRunner\RequestHandlerRunner->run()
#100 /var/www/html/public/index.php(26): Flarum\Http\Server->listen()
#101 {main}

I hope someone can help me, I have a VPS, I installed all the flarum requirements. It seems to require something about sending emails.

My email drivers are set to “mail”

  • luceos replied to this.
  • Hi LordZargum,
    I'm grateful to see replies made by hf06 and luceos that are trying to help you.

    I saw also your post in the Italian Flarum forum where I have replied to you.
    Maybe the first try you should do is to configure your SMTP settings for sending email and also check your hosting as I know the port 25 maybe blocked and need be unlocked by the provider support.

    Also I suggest to check that you are using an updated Flarum version and an updated PHP so I asjed about this infos in the Italian community 😊

    Disable email verification for new members and find a temporary solution.
    Use this extension: https://flarum.org/extension/isaced/flarum-ext-email-verification-switch

    Additionally, you need to configure SMTP settings instead of mail settings.

    • Server: Your mail server (domain.com or mail.domain.com)
    • Port: 465, etc.
    • Encryption: ssl (in lowercase)
    • Username: The email you created on your VPS server (info@domain.com)
    • Password: The email password

    Lastly, if you're using a CDN like Cloudflare, you should disable the proxy for the server address. The proxy usually prevents emails from being sent. For example, enable the proxy for "www" and "forum," but disable it for domain.com

      LordZargum if you are using the native php mail function, you will need to make sure your server can handle that email. If it can send, but it doesn't arrive, you need to set up your email records on your domain (spf especially).

      huseyinfiliz please don't recommend temporary solutions before exhausting solutions to the actual issue.

        luceos I understand your intention, but what I’ve noticed since the first day I registered on the forum is that you assume the user you’re responding to has advanced technical knowledge.

        Personally, I find your response insufficient because we can see from LordZargum's previous replies that he is a new member and has just installed Flarum. Moreover, he hasn’t specifically mentioned wanting to use the "mail" function.

        Clearly, he has just set up Flarum and hasn’t configured the email settings yet. I explained the email settings in a way that is generally used in Flarum forums.

        As the number of Flarum forums increases, more users with weaker technical knowledge will start to install and use Flarum.

          huseyinfiliz that's a great argument and I agree. But I've seen in the past that giving people a simple way out makes them no longer investigate the actual problem, and as such remain on the "temporary" fix forever.

          What I try to achieve with my posts is give an idea where to look, but it's up to the user to pursue the problem solving. For digital illiterates it usually boils down to requesting help from the hosting provider, for those that are capable of managing a vps, it will require them to do their own research.

          Understand that I'm okay with offering the temporary solution, but I need to stress that understanding and resolving the actual issue first is structurally more valuable.

            luceos First of all, I apologize for veering off-topic in this conversation. You may delete my comments on this matter if necessary. I just want to mention this since the topic has come up.

            I think the main issue stems from the lack of a beginner's guide for Flarum. There isn't anything simple that teaches how Flarum works or how to troubleshoot errors. What I mean is that your "Troubleshooting" page seems quite complicated, and it appears that users need a beginner's guide before diving into troubleshooting.

            Personally, when I was installing Flarum, the documentation on this site felt complex, and I managed to set it up thanks to the simpler guide topics available on flarumtr.com, which is in my native language. Yes, they write "just do this" for some things, but perhaps that’s necessary for the initial crawling steps. The topic on "essential plugins for every forum" helped me quickly overcome many issues.

            Once I got Flarum up and running as a functional forum, making customizations can be enjoyable. However, getting numerous errors after an already complicated installation process can be quite frustrating.

              Hi LordZargum,
              I'm grateful to see replies made by hf06 and luceos that are trying to help you.

              I saw also your post in the Italian Flarum forum where I have replied to you.
              Maybe the first try you should do is to configure your SMTP settings for sending email and also check your hosting as I know the port 25 maybe blocked and need be unlocked by the provider support.

              Also I suggest to check that you are using an updated Flarum version and an updated PHP so I asjed about this infos in the Italian community 😊

              Thank you all for the support. I will try to ask the host to open the ports for forwarding and receiving emails, install SSL and then a mail server.

              Hem, yes I'm a novice for Flarum 😄

              huseyinfiliz

              Really not trying to start anything here, but I thought your post would be very helpful to innumerable people evaluating Flarum for the first time and I wished that it existed back when I was evaluating it against other choices.

              The truth is Flarum is like a box of Legos, where most other forum software is more like a pre-fabricated toy. You dump out all the pieces when you get home from the toy store and say "I wish I had something to play with right now" but you have to build something first. Then you eventually realize the building is the fun part.

              It takes a real investment of time and research to get it working the way you want it to, but then you have the experience, like I did last night, of entering one short command into the terminal (of your VPS) and adding Direct Messaging capabilities (the extension neoncube/flarum-private-messages) in about 5 seconds, and it just works!

              And then you immediately realize to make it even cooler you need to add WebSockets functionality and the research begins anew . . . .

              Maybe a support forum for non-developer-level Flarum users would be appropriate? Flarum for Dummies. We could all share quick and dirty shortcuts and solutions to make it just work the way we want it to and leave the genius-level stuff for the big kids.

              If only there was a way to quickly and easily deploy forum software. <smiley -- my emojis aren't working>

              And this is no way intended to be critical of @luceos -- without his generous support responses to me (and to others) I would have needed to bail-out a long time ago.

              At this point, I am beyond thrilled with my Flarum implementation and it's become a dangerously seductive distraction.

                endlessedits I really don’t want to prolong this topic, but it has already become quite scattered.

                endlessedits I wished that it existed back when I was evaluating it against other choices.

                If you noticed, in my first message, knowing that his a new user, I actually created a simple getting-started guide that includes email settings and more. The reason I did this is exactly what you pointed out in your message.

                endlessedits Maybe a support forum for non-developer-level Flarum users would be appropriate? Flarum for Dummies.

                I think only a quick start guide is needed.

                endlessedits I fully agree with you. I fell in love with Flarum at first sight from an American site, simple design, user friendly and above all open source. With each passing day, I like it more and more, but alas, I understand the fact that many web amateurs desist from using it because the community is too much for 'expert' users. This is in no way a criticism and I appreciate those who work hard every day to keep the forum and the rest going but I think we really need a "Flarum for dummies" forum ✌️

                Anyway I'm making a quick edit to say that thanks to your advice and that of peopleinside (we've been in touch via telegram as I'm Italian, to avoid language problems), I was able to migrate to a bigger, better performing server, activate SSL and fix the email problem.

                You were fantastic! Thanks again! @huseyinfiliz @luceos @peopleinside