Page 1 of 2 12 LastLast
Results 1 to 10 of 16

Thread: Ubuntu Server cant Be Accessed Over IP or SHH But CloudFlare Tunnel Works Fine

  1. #1
    Join Date
    Aug 2024
    Beans
    9

    Ubuntu Server cant Be Accessed Over IP or SHH But CloudFlare Tunnel Works Fine

    Hello All,

    I am having this strange issue, after running for sometime, my Ubuntu server cant be accessed over local IP, cant SSH, cant reach any service like radarr, Jellyfin or so, unless i restart it.
    But i am using Cloudflare tunnel so that if i am out of my home, so i can reach it, and it works fine even when i cant access services locally.
    Means I cant reach Jellyfin from local IP but I can reach it via Cloudflare tunnel and it works perfectly fine, same goes with other services.
    P.S. my server is over WiFi

  2. #2
    currentshaft is offline Oops! My Coffee Cup is empty.
    Join Date
    May 2024
    Beans
    Hidden!

    Re: Ubuntu Server cant Be Accessed Over IP or SHH But CloudFlare Tunnel Works Fine

    <
    Last edited by currentshaft; 4 Weeks Ago at 12:58 AM.

  3. #3
    Join Date
    Aug 2024
    Beans
    9

    Re: Ubuntu Server cant Be Accessed Over IP or SHH But CloudFlare Tunnel Works Fine

    Hello,

    Thanks for your reply

    What more information you need?

    Here is my /etc/netplan/50-cloud-init.yaml

    network:
    version: 2
    ethernets:
    enp0s31f6:
    dhcp4: true
    wifis:
    wlp1s0:
    access-points:
    "MySSID":
    password: "MyPassword"
    addresses:
    - 10.0.0.100/8
    nameservers:
    addresses: [8.8.8.8]
    routes:
    - to: default
    via: 10.0.0.1




    My router IP is 10.0.0.1 and subnet mask on router is 255.255.0.0.

    What troubleshooting have you already performed to rule out Cloudflare or your local router?


    I am clueless where to start and what to check

  4. #4
    Join Date
    Mar 2010
    Location
    Squidbilly-Land
    Beans
    Hidden!
    Distro
    Ubuntu

    Re: Ubuntu Server cant Be Accessed Over IP or SHH But CloudFlare Tunnel Works Fine

    You need to edit that yaml file to ensure forum code tags are used or it is useless for us to review. YAML is space sensitive.

  5. #5
    Join Date
    Aug 2024
    Beans
    9

    Re: Ubuntu Server cant Be Accessed Over IP or SHH But CloudFlare Tunnel Works Fine

    Here you go,

    Code:
    network:    version: 2
        ethernets:
            enp0s31f6:
                dhcp4: true
        wifis:
            wlp1s0:
                access-points:
                    "MySSID":
                        password: "MyPass"
                addresses:
                - 10.0.0.100/8
                nameservers:
                    addresses: [8.8.8.8]
                routes:
                - to: default
                  via: 10.0.0.1
    Just asking, is addresses field with 10.0.0.100/8 correct?

  6. #6
    Join Date
    Mar 2010
    Location
    Squidbilly-Land
    Beans
    Hidden!
    Distro
    Ubuntu

    Re: Ubuntu Server cant Be Accessed Over IP or SHH But CloudFlare Tunnel Works Fine

    Quote Originally Posted by rahulsharma49 View Post
    Just asking, is addresses field with 10.0.0.100/8 correct?
    Unlikely. Most home subnets allow 256 hosts, so /24 would be correct.
    The indentation of the wifi part looks wrong to me, but I don't use wifi except on laptops and never use netplan to configure it. Sorry.

    YAML is extremely indentation sensitive, in addition to all the other picky things about it.
    https://netplan.readthedocs.io/en/stable/examples/ has examples of a correct wifi config for different security levels.

    Because I don't know your network at all, I can only guess that this is the example you want to follow:
    Code:
    network:
      version: 2
      renderer: networkd
      wifis:
        wlp2s0b1:
          dhcp4: no
          dhcp6: no
          addresses: [192.168.0.21/24]
          nameservers:
            addresses: [192.168.0.1, 1.0.0.1]
          access-points:
            "network_ssid_name":
              password: "**********"
          routes:
            - to: default
              via: 192.168.0.1
    The stuff in red is what I think you'll need to change, assuming WPA of some sort is used.
    Last edited by TheFu; August 21st, 2024 at 01:14 PM.

  7. #7
    Join Date
    Aug 2024
    Beans
    9

    Re: Ubuntu Server cant Be Accessed Over IP or SHH But CloudFlare Tunnel Works Fine

    tried the above yaml file and my server goes out of network, switced back to old yaml and now it is connected again

  8. #8
    Join Date
    Mar 2010
    Location
    Squidbilly-Land
    Beans
    Hidden!
    Distro
    Ubuntu

    Re: Ubuntu Server cant Be Accessed Over IP or SHH But CloudFlare Tunnel Works Fine

    Quote Originally Posted by rahulsharma49 View Post
    tried the above yaml file and my server goes out of network, switced back to old yaml and now it is connected again
    • If you don't show your work, how can anyone help?
    • Did you change all the red parts in the example?
    • Did you do the 2 netplan commands for the YAML to be generated and applied?


    It broke, isn't very descriptive. We cannot read minds.

    The subnet with that gateway aren't typical for .... anyone. That /8 subnet is something Google or China might use on their main, huge, gateway routers, not a small business or home user. I suspect very few enterprises would have a /8 subnet either. Typically, a medium-sized business would use a /20 netmask, but you need to know the "correct" answer. We can't tell you. Ask your network guys.

  9. #9
    Join Date
    Aug 2024
    Beans
    9

    Re: Ubuntu Server cant Be Accessed Over IP or SHH But CloudFlare Tunnel Works Fine

    sry for last reply, after couple of restart it is now working, i dont know how but it is working now.

    Code:
    If you don't show your work, how can anyone help?
    What work i need to show, please tell

    Code:
     That /8 subnet is something Google or China might use on their main, huge, gateway routers, not a small business or home user

    My router configuration has subnet mask as 255.255.0.0, does it matter or it is correct?

  10. #10
    currentshaft is offline Oops! My Coffee Cup is empty.
    Join Date
    May 2024
    Beans
    Hidden!

    Re: Ubuntu Server cant Be Accessed Over IP or SHH But CloudFlare Tunnel Works Fine

    2
    Last edited by currentshaft; 4 Weeks Ago at 12:59 AM.

Page 1 of 2 12 LastLast

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •