Cloudron makes it easy to run web apps like WordPress, Nextcloud, GitLab on your server. Find out more or install now.


Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Bookmarks
  • Search
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Brand Logo

Cloudron Forum

Apps | Demo | Docs | Install
  1. Cloudron Forum
  2. Support
  3. Email sending broken after updating to 8.2.x (due to IPv6 issues)

Email sending broken after updating to 8.2.x (due to IPv6 issues)

Scheduled Pinned Locked Moved Solved Support
ipv6emailupdate8.2.3
74 Posts 13 Posters 7.5k Views 13 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • avatar1024A Offline
    avatar1024A Offline
    avatar1024
    wrote on last edited by avatar1024
    #51

    Right so, after adding to /etc/sysctl.conf:

    net.ipv6.conf.all.disable_ipv6 = 1
    net.ipv6.conf.default.disable_ipv6 = 1
    net.ipv6.conf.lo.disable_ipv6 = 1
    net.ipv6.conf.eth0.disable_ipv6 = 1
    

    on reboot, cat /proc/sys/net/ipv6/conf/all/disable_ipv6 return 1 so one would think it's all good, but it isn't. curl https://ipv6.api.cloudron.io/api/v1/helper/public_ip still retunrs the IPv6 address and I can still see it in ifconfig for the network interface. Yet manually running either sysctl -p or sysctl -w net.ipv6.conf.eth0.disable_ipv6=1 post boot works just fine to disable IPv6. So there is something at boot time that prevents disabling IPv6.

    I therefore went the bulletproof way and disabled ipv6 as a boot argument in grub (GRUB_CMDLINE_LINUX_DEFAULT="ipv6.disable=1"). But then I got of errors at boot time when services start, especially for nginx so that;s not working either.

    Any idea?

    J 1 Reply Last reply
    1
    • avatar1024A avatar1024

      Right so, after adding to /etc/sysctl.conf:

      net.ipv6.conf.all.disable_ipv6 = 1
      net.ipv6.conf.default.disable_ipv6 = 1
      net.ipv6.conf.lo.disable_ipv6 = 1
      net.ipv6.conf.eth0.disable_ipv6 = 1
      

      on reboot, cat /proc/sys/net/ipv6/conf/all/disable_ipv6 return 1 so one would think it's all good, but it isn't. curl https://ipv6.api.cloudron.io/api/v1/helper/public_ip still retunrs the IPv6 address and I can still see it in ifconfig for the network interface. Yet manually running either sysctl -p or sysctl -w net.ipv6.conf.eth0.disable_ipv6=1 post boot works just fine to disable IPv6. So there is something at boot time that prevents disabling IPv6.

      I therefore went the bulletproof way and disabled ipv6 as a boot argument in grub (GRUB_CMDLINE_LINUX_DEFAULT="ipv6.disable=1"). But then I got of errors at boot time when services start, especially for nginx so that;s not working either.

      Any idea?

      J Offline
      J Offline
      joseph
      Staff
      wrote on last edited by
      #52

      @avatar1024 usually, if that happens it's because something else is enabling ipv6 on the interface. Do you use netplan? If so, I could chek /etc/netplan/50-cloud-init.yaml . Does it have some statically assigned ipv6 block?

      avatar1024A 1 Reply Last reply
      3
      • J joseph

        @avatar1024 usually, if that happens it's because something else is enabling ipv6 on the interface. Do you use netplan? If so, I could chek /etc/netplan/50-cloud-init.yaml . Does it have some statically assigned ipv6 block?

        avatar1024A Offline
        avatar1024A Offline
        avatar1024
        wrote on last edited by avatar1024
        #53

        @joseph said in Email sending broken after updating to 8.2.x (due to IPv6 issues):

        Do you use netplan? If so, I could chek /etc/netplan/50-cloud-init.yaml . Does it have some statically assigned ipv6 block?

        I was not aware I did use netplan (I don;t even really know what it is), but yes there is this config file and it seems to contain static IPs, see:

        network:
          version: 2
          ethernets:
            eth0:
              match:
                macaddress: "xx:xx:xx:xx:xx:xx"
              addresses:
              - "152.xx.xx.43/22"
              - "2a03:4000:xx:xx:xxxx:xxxx:xxxx:6007/64"
              nameservers:
                addresses:
                - 46.38.225.230
                - 46.38.252.230
                - 2a03:4000:0:1::e1e6
              routes:
              - to: "default"
                via: "152.xx.xx.1"
              - on-link: true
                to: "default"
                via: "fe80::1"
        

        If you tell me how i should modify the file then I'll try it out.

        Thanks a lot for your help.

        J 1 Reply Last reply
        2
        • avatar1024A avatar1024

          @joseph said in Email sending broken after updating to 8.2.x (due to IPv6 issues):

          Do you use netplan? If so, I could chek /etc/netplan/50-cloud-init.yaml . Does it have some statically assigned ipv6 block?

          I was not aware I did use netplan (I don;t even really know what it is), but yes there is this config file and it seems to contain static IPs, see:

          network:
            version: 2
            ethernets:
              eth0:
                match:
                  macaddress: "xx:xx:xx:xx:xx:xx"
                addresses:
                - "152.xx.xx.43/22"
                - "2a03:4000:xx:xx:xxxx:xxxx:xxxx:6007/64"
                nameservers:
                  addresses:
                  - 46.38.225.230
                  - 46.38.252.230
                  - 2a03:4000:0:1::e1e6
                routes:
                - to: "default"
                  via: "152.xx.xx.1"
                - on-link: true
                  to: "default"
                  via: "fe80::1"
          

          If you tell me how i should modify the file then I'll try it out.

          Thanks a lot for your help.

          J Offline
          J Offline
          joseph
          Staff
          wrote on last edited by
          #54

          @avatar1024 said in Email sending broken after updating to 8.2.x (due to IPv6 issues):

            - "2a03:4000:xx:xx:xxxx:xxxx:xxxx:6007/64"
          

          yup, this is the culprit. The IPv6 address is statically assigned here. You have to put a # in front of the line to comment it out and reboot the machine.

          avatar1024A 1 Reply Last reply
          2
          • J joseph

            @avatar1024 said in Email sending broken after updating to 8.2.x (due to IPv6 issues):

              - "2a03:4000:xx:xx:xxxx:xxxx:xxxx:6007/64"
            

            yup, this is the culprit. The IPv6 address is statically assigned here. You have to put a # in front of the line to comment it out and reboot the machine.

            avatar1024A Offline
            avatar1024A Offline
            avatar1024
            wrote on last edited by
            #55

            @joseph said in Email sending broken after updating to 8.2.x (due to IPv6 issues):

            yup, this is the culprit. The IPv6 address is statically assigned here. You have to put a # in front of the line to comment it out and reboot the machine.

            THANK YOU! That worked.

            Seems like netplan is here by default since Ubuntu 18: https://pscl4rke.wordpress.com/2019/10/01/disabling-ipv6-on-ubuntu-18-04-the-netplan-version/

            1 Reply Last reply
            1
            • J Offline
              J Offline
              joseph
              Staff
              wrote on last edited by
              #56

              @avatar1024 I found this https://github.com/canonical/netplan/blob/main/doc/netplan-tutorial.md#editing-netplan-yaml-files-to-disable-ipv6 . Can't figure where this page is "published" . The yaml ref is at https://netplan.readthedocs.io/en/latest/netplan-yaml/

              1 Reply Last reply
              2
              • potemkin_aiP Offline
                potemkin_aiP Offline
                potemkin_ai
                wrote on last edited by
                #57

                Just for the reference: netplan try is usually a better way, as it might save from end up getting locked out from the server. I also usually run a background cron task, that removes those temporary files from /etc/netplan, when messing with the network.

                1 Reply Last reply
                2
                • P Offline
                  P Offline
                  privsec
                  wrote on last edited by
                  #58

                  Ok, its not working again (or maybe it never did.

                  These are my screens

                  image.png

                  image.png

                  image.png

                  image.png
                  From my understadning, it is set up correctly.

                  jdaviescoatesJ 1 Reply Last reply
                  0
                  • P privsec

                    Ok, its not working again (or maybe it never did.

                    These are my screens

                    image.png

                    image.png

                    image.png

                    image.png
                    From my understadning, it is set up correctly.

                    jdaviescoatesJ Offline
                    jdaviescoatesJ Offline
                    jdaviescoates
                    wrote on last edited by
                    #59

                    @privsec said in Email sending broken after updating to 8.2.x (due to IPv6 issues):

                    its not working again

                    What exactly isn't working?

                    Have you set up the ipv6 reverse dns/ PTR /rDNS record too?

                    I use Cloudron with Gandi & Hetzner

                    avatar1024A 1 Reply Last reply
                    1
                    • jdaviescoatesJ jdaviescoates

                      @privsec said in Email sending broken after updating to 8.2.x (due to IPv6 issues):

                      its not working again

                      What exactly isn't working?

                      Have you set up the ipv6 reverse dns/ PTR /rDNS record too?

                      avatar1024A Offline
                      avatar1024A Offline
                      avatar1024
                      wrote on last edited by
                      #60

                      @jdaviescoates said in Email sending broken after updating to 8.2.x (due to IPv6 issues):

                      What exactly isn't working?

                      I imagine they are getting bounce to Gmail.

                      @jdaviescoates said in Email sending broken after updating to 8.2.x (due to IPv6 issues):

                      Have you set up the ipv6 reverse dns/ PTR /rDNS record too?

                      Looks like they have looking at screenshot 2....but possibly badly. I think it should say my.businessdoctorut.com

                      Though for me, after setting it all up properly I kept getting issues and random bounces with the same error message. Only completely disabling IPv6 from the network interface works (and even that turned out to be a struggle 😰)

                      P 1 Reply Last reply
                      1
                      • avatar1024A avatar1024

                        @jdaviescoates said in Email sending broken after updating to 8.2.x (due to IPv6 issues):

                        What exactly isn't working?

                        I imagine they are getting bounce to Gmail.

                        @jdaviescoates said in Email sending broken after updating to 8.2.x (due to IPv6 issues):

                        Have you set up the ipv6 reverse dns/ PTR /rDNS record too?

                        Looks like they have looking at screenshot 2....but possibly badly. I think it should say my.businessdoctorut.com

                        Though for me, after setting it all up properly I kept getting issues and random bounces with the same error message. Only completely disabling IPv6 from the network interface works (and even that turned out to be a struggle 😰)

                        P Offline
                        P Offline
                        privsec
                        wrote on last edited by
                        #61

                        @avatar1024 My mail server location is b0d6d65a-4adf-4129-a4e0-aaf0455d485f-image.png

                        I do keep getting bounced emails from Gmail.

                        avatar1024A 1 Reply Last reply
                        2
                        • potemkin_aiP Offline
                          potemkin_aiP Offline
                          potemkin_ai
                          wrote on last edited by
                          #62

                          Just in case - I've just found that IPv6 might be enabled at the NetPlan level, despite all of the sysctl and other configs.

                          To disable - add to the appropriate yaml file in /etc/netplan - link-local: [ ipv4 ] - on the same level as dhcp instruction. Run netplan try and netplan apply if you are lucky.

                          That seems to disable IPv6 on Linux.

                          <rant> Linux start looking more and more like Windows 😢 </rant>

                          avatar1024A 1 Reply Last reply
                          2
                          • potemkin_aiP potemkin_ai

                            Just in case - I've just found that IPv6 might be enabled at the NetPlan level, despite all of the sysctl and other configs.

                            To disable - add to the appropriate yaml file in /etc/netplan - link-local: [ ipv4 ] - on the same level as dhcp instruction. Run netplan try and netplan apply if you are lucky.

                            That seems to disable IPv6 on Linux.

                            <rant> Linux start looking more and more like Windows 😢 </rant>

                            avatar1024A Offline
                            avatar1024A Offline
                            avatar1024
                            wrote on last edited by avatar1024
                            #63

                            @potemkin_ai said in Email sending broken after updating to 8.2.x (due to IPv6 issues):

                            I've just found that IPv6 might be enabled at the NetPlan level

                            Yep this has been discussed above in this thread...from post #52 onward. The solution provided by @joseph worked on my end. I had originally tried something along the line you mentioned (adding link-local: [ ipv4 ] to the yaml file but that didn't work...although I might have done it wrong).

                            1 Reply Last reply
                            0
                            • P privsec

                              @avatar1024 My mail server location is b0d6d65a-4adf-4129-a4e0-aaf0455d485f-image.png

                              I do keep getting bounced emails from Gmail.

                              avatar1024A Offline
                              avatar1024A Offline
                              avatar1024
                              wrote on last edited by
                              #64

                              @privsec said in Email sending broken after updating to 8.2.x (due to IPv6 issues):

                              I do keep getting bounced emails from Gmail.

                              In that case I would just disable IPv6 altogether from your server network interface. That's the only only thing that worked for me.

                              1 Reply Last reply
                              0
                              • P Offline
                                P Offline
                                privsec
                                wrote on last edited by
                                #65

                                OK, sorry I am off and on. I do not do this as a full time job. I need this resolved but im lost as to what to do.

                                At this point, I just want to future proof myself from IPV6. How do I permanently disable and remove this functionality on my VPS from Netcup.

                                GengarG 1 Reply Last reply
                                0
                                • girishG Offline
                                  girishG Offline
                                  girish
                                  Staff
                                  wrote on last edited by
                                  #66

                                  @Gengar I signed up but it is stuck in "Order Pending"

                                  GengarG 1 Reply Last reply
                                  1
                                  • P privsec

                                    OK, sorry I am off and on. I do not do this as a full time job. I need this resolved but im lost as to what to do.

                                    At this point, I just want to future proof myself from IPV6. How do I permanently disable and remove this functionality on my VPS from Netcup.

                                    GengarG Offline
                                    GengarG Offline
                                    Gengar
                                    wrote on last edited by Gengar
                                    #67

                                    @privsec Are you also having the issue of PTR6 value turning to "null" ?

                                    73040c11-a1eb-44ad-92d4-c946be1ae94f-image.png

                                    @privsec why would you turn off IPv6 completly ? You can do it but why ? I understood that emails servers from Google and Microsoft are now using full IPv6 resolution and if they receive an email coming from an IPv4 mail server they may or will consider it as spam more easily...

                                    But regarding your question @privsec , how to disable IPv6 completly, I think I would do it on the OS level because I've seen that IPv6 is not enabled inside the docker containers.

                                    First I would start to disable it temporarily using this command as I did in my tests before :
                                    sudo sysctl -w net.ipv6.conf.all.disable_ipv6=1

                                    It will disable ipv6 until next reboot.

                                    And if it works like that for you, then you can reboot your server and try to disable it permanently by creating a new file : sudo nano /etc/sysctl.d/10-disable-ipv6.conf

                                    And you write this in this file :

                                    net.ipv6.conf.all.disable_ipv6 = 1
                                    net.ipv6.conf.default.disable_ipv6 = 1
                                    

                                    to save your file and quit nano
                                    CTRL+0 - ENTER - CTRL+X

                                    And then apply this new config file by doing :
                                    sudo sysctl --system

                                    And IPv6 should be disabled completly at the OS level. Reboot your server.

                                    1 Reply Last reply
                                    1
                                    • girishG girish forked this topic on
                                    • girishG Offline
                                      girishG Offline
                                      girish
                                      Staff
                                      wrote on last edited by
                                      #68

                                      I spun the infomaniak postings to a separate thread - https://forum.cloudron.io/topic/13566/infomaniak-ipv6-issues

                                      1 Reply Last reply
                                      1
                                      • P Offline
                                        P Offline
                                        privsec
                                        wrote on last edited by
                                        #69

                                        My IPV6 in the dashboard is reporting working just fine.
                                        image.png

                                        Emails are not sending to gmail emails and I need this resolved.

                                        1 Reply Last reply
                                        0
                                        • P Offline
                                          P Offline
                                          privsec
                                          wrote on last edited by
                                          #70

                                          Who can I pay to solve this for me?

                                          scookeS jdaviescoatesJ 2 Replies Last reply
                                          0
                                          Reply
                                          • Reply as topic
                                          Log in to reply
                                          • Oldest to Newest
                                          • Newest to Oldest
                                          • Most Votes


                                          • Login

                                          • Don't have an account? Register

                                          • Login or register to search.
                                          • First post
                                            Last post
                                          0
                                          • Categories
                                          • Recent
                                          • Tags
                                          • Popular
                                          • Bookmarks
                                          • Search