Page 6 of 7 FirstFirst ... 4567 LastLast
Results 51 to 60 of 68

Thread: static ip

  1. #51
    Join Date
    Mar 2023
    Location
    Illinois
    Beans
    48
    Distro
    Lubuntu 22.04 Jammy Jellyfish

    Re: static ip

    Let me give this one more shot first I want to figure out what im doing wrong. will let you know thanks

    upon further trying yes please post a working yaml I want to test it on this
    Last edited by greg612; 2 Weeks Ago at 03:03 AM.

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

    Re: static ip

    Code:
    $ lsb_release -d
    No LSB modules are available.
    Description:    Ubuntu 24.04 LTS
    
    $ ip a
    1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN group default qlen 1000
        link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
        inet 127.0.0.1/8 scope host lo
           valid_lft forever preferred_lft forever
        inet6 ::1/128 scope host noprefixroute 
           valid_lft forever preferred_lft forever
    2: enp1s0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UP group default qlen 1000
        link/ether 52:54:00:aa:fd:df brd ff:ff:ff:ff:ff:ff
        inet 172.22.22.12/24 brd 172.22.22.255 scope global enp1s0
           valid_lft forever preferred_lft forever
        inet6 fe80::5054:ff:feaa:fddf/64 scope link 
           valid_lft forever preferred_lft forever
    
    sudo more /etc/netplan/01-network-manager-01.yaml network:
      version: 2
      renderer: networkd
      ethernets:
         enp1s0:
           addresses:
              - 172.22.22.12/24
           dhcp4: false
           dhcp6: false
           routes:
             - to: default
               via: 172.22.22.1
           optional: true
           nameservers:
             addresses: [ "172.22.22.81","172.22.22.80" ]
             search: [example.foo,example.com]
    This is a new install, so I still need to disable IPv6 and do a few more network things, but the static IP has been working since 5 minutes post-install. However, I am having an issue getting ssh with keys working which has stumped me so far. ssh -vvvv is providing lots of information and my key is seen, accepted, but not used. I have more research ... but I'm inclined to blame IPv6 right now.

  3. #53
    Join Date
    Feb 2011
    Location
    Coquitlam, B.C. Canada
    Beans
    3,524
    Distro
    Ubuntu Development Release

    Re: static ip

    Quote Originally Posted by TheFu View Post
    For networking to work correctly, 3 things are needed.
    • IP address
    • Subnet/Netmask
    • Gateway IP


    Many posts ago, I asked to see two commands (ip a AND ip r) from a working config which would have shown these things. I asked to see it with DHCP and a working configuration. Then we could easily setup the correct values for a static IP from the working DHCP information.

    This stuff isn't really that hard.
    Agreed.

    We still need to see the output for "ip r" from the working DHCP setup. From reviewing the 6 pages of this thread, nowhere has it been confirmed/proved that 192.168.25.1 is actually the gateway.
    Any follow-up information on your issue would be appreciated. Please have the courtesy to report back.

  4. #54
    Join Date
    Mar 2023
    Location
    Illinois
    Beans
    48
    Distro
    Lubuntu 22.04 Jammy Jellyfish

    Re: static ip

    Code:
    james@mustang:~$ ip r
    default via 192.168.25.1 dev eno1 proto static 
    192.168.25.0/24 dev eno1 proto kernel scope link src 192.168.25.3

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

    Re: static ip

    Quote Originally Posted by TheFu View Post
    - 192.168.25.3/24 to 192.168.25.1 using that subnet mask?

    That doesn't seem right.
    When you allow DHCP, what's the IP and gateway that works?
    Doesn't the gateway need to be in the same subnet as the LAN?
    I've been reading through the entire thread 1 more time. I get confused because short answers that don't include the question being answered clearly are confusing.

    As I read my post above, I don't know what I was thinking. 192.168.25.3/24 via 192.168.25.1 (gw) DOES make perfect sense.


    For some clarity, after any change is made to a netplan.yaml file, 2 commands are mandatory,
    Code:
    sudo netplan generate --debug  # assuming this doesn't have any errors/warnings.
    sudo netplan apply
    I don't recognize the DNS servers being used. I use 1.1.1.1 and 1.0.0.1 for public DNS. When using IP addresses, DNS doesn't matter, so I've ignored it.
    8.8.8.8 is google's (we want to watch you) DNS. Mostly it is just an easy, known, IP to ping. That's the entire point.

    So, after each change with generate/apply steps, run these commands to provide a clear answer:
    Code:
    ip a  # show the IP address on the system
    ip r |column -t   # show the routing table
    ping 192.268.25.1   # ping your LAN router (use the correct IP for it if this is wrong)
    ping 8.8.8.8   # ping a well-known internet IP
    If we are starting over 100%, showing the working DHCP version, then the desired static IP version would be helpful.
    Clearly label each group of commands with the scenario. Let's act like this is 100% new thread and step back.
    You should also verify that the DHCP range configured inside your DHCP server has limits. It shouldn't be the entire /24 subnet. When choosing the range for static IPs, always choose an IP outside the DHCP range and ensure it isn't already being used.

    We all know these things, but for being very clear, thought I'd post them.

  6. #56
    Join Date
    Mar 2023
    Location
    Illinois
    Beans
    48
    Distro
    Lubuntu 22.04 Jammy Jellyfish

    Re: static ip

    Code:
     ping 8.8.8.8
    PING 8.8.8.8 (8.8.8.8) 56(84) bytes of data.
    64 bytes from 8.8.8.8: icmp_seq=1 ttl=58 time=18.0 ms
    64 bytes from 8.8.8.8: icmp_seq=2 ttl=58 time=16.5 ms
    64 bytes from 8.8.8.8: icmp_seq=3 ttl=58 time=15.9 ms
    64 bytes from 8.8.8.8: icmp_seq=4 ttl=58 time=16.8 ms
    64 bytes from 8.8.8.8: icmp_seq=5 ttl=58 time=16.3 ms
    64 bytes from 8.8.8.8: icmp_seq=6 ttl=58 time=17.0 ms
    64 bytes from 8.8.8.8: icmp_seq=7 ttl=58 time=16.6 ms
    64 bytes from 8.8.8.8: icmp_seq=8 ttl=58 time=16.1 ms
    64 bytes from 8.8.8.8: icmp_seq=9 ttl=58 time=16.6 ms
    64 bytes from 8.8.8.8: icmp_seq=10 ttl=58 time=17.3 ms
    ^C
    --- 8.8.8.8 ping statistics ---
    10 packets transmitted, 10 received, 0% packet loss, time 9013ms
    rtt min/avg/max/mdev = 15.936/16.705/17.995/0.577 ms
    
    
    james@mustang:~$ ip a
    1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN group default qlen 1000
        link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
        inet 127.0.0.1/8 scope host lo
           valid_lft forever preferred_lft forever
        inet6 ::1/128 scope host noprefixroute 
           valid_lft forever preferred_lft forever
    2: eno1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UP group default qlen 1000
        link/ether f8:b1:56:e4:ca:fc brd ff:ff:ff:ff:ff:ff
        altname enp0s25
        inet 192.168.25.54/24 metric 100 brd 192.168.25.255 scope global dynamic eno1
           valid_lft 7011sec preferred_lft 7011sec
        inet6 fe80::fab1:56ff:fee4:cafc/64 scope link 
           valid_lft forever preferred_lft forever
    
    
    james@mustang:~$ ip r
    default via 192.168.25.1 dev eno1 proto dhcp src 192.168.25.54 metric 100 
    192.168.25.0/24 dev eno1 proto kernel scope link src 192.168.25.54 metric 100 
    192.168.25.1 dev eno1 proto dhcp scope link src 192.168.25.54 metric 100 
    james@mustang:~$
    Stock out of box working network.
    Last edited by greg612; 1 Week Ago at 02:55 AM.

  7. #57
    Join Date
    Mar 2023
    Location
    Illinois
    Beans
    48
    Distro
    Lubuntu 22.04 Jammy Jellyfish

    Re: static ip

    The dns I use is quad9

  8. #58
    Join Date
    Mar 2023
    Location
    Illinois
    Beans
    48
    Distro
    Lubuntu 22.04 Jammy Jellyfish

    Re: static ip

    Code:
     lsb_release -d
    No LSB modules are available.
    Description:    Ubuntu 24.04 LTS
    james@mustang:~$ ip r
    default via 192.168.25.1 dev eno1 proto static 
    192.168.25.0/24 dev eno1 proto kernel scope link src 192.168.25.3 
    james@mustang:~$ ip a
    1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN group default qlen 1000
        link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
        inet 127.0.0.1/8 scope host lo
           valid_lft forever preferred_lft forever
        inet6 ::1/128 scope host noprefixroute 
           valid_lft forever preferred_lft forever
    2: eno1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UP group default qlen 1000
        link/ether f8:b1:56:e4:ca:fc brd ff:ff:ff:ff:ff:ff
        altname enp0s25
        inet 192.168.25.3/24 brd 192.168.25.255 scope global eno1
           valid_lft forever preferred_lft forever
        inet6 fe80::fab1:56ff:fee4:cafc/64 scope link 
           valid_lft forever preferred_lft forever

  9. #59
    Join Date
    Mar 2023
    Location
    Illinois
    Beans
    48
    Distro
    Lubuntu 22.04 Jammy Jellyfish

    Re: static ip

    I got this straight from netplan for this 24.04 working yaml

    Code:
    network:
        version: 2
        renderer: networkd
        ethernets:
            eno1:
              addresses:
                  - 192.168.25.3/24
              nameservers:
                  addresses: [9.9.9.9, 149.112.112.112]
              routes:
                  - to: default
                    via: 192.168.25.1
    Code:
     ping 1.1.1.1
    PING 1.1.1.1 (1.1.1.1) 56(84) bytes of data.
    ^C
    --- 1.1.1.1 ping statistics ---
    6 packets transmitted, 0 received, 100% packet loss, time 5151ms
    
    james@mustang:~$ ping 8.8.8.8
    PING 8.8.8.8 (8.8.8.8) 56(84) bytes of data.
    ^C
    --- 8.8.8.8 ping statistics ---
    8 packets transmitted, 0 received, 100% packet loss, time 7156ms
    nope

  10. #60
    Join Date
    Mar 2023
    Location
    Illinois
    Beans
    48
    Distro
    Lubuntu 22.04 Jammy Jellyfish

    Re: static ip

    Code:
    ip a
    1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN group default qlen 1000
        link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
        inet 127.0.0.1/8 scope host lo
           valid_lft forever preferred_lft forever
        inet6 ::1/128 scope host noprefixroute 
           valid_lft forever preferred_lft forever
    2: eno1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UP group default qlen 1000
        link/ether f8:b1:56:e4:ca:fc brd ff:ff:ff:ff:ff:ff
        altname enp0s25
        inet 192.168.25.3/24 brd 192.168.25.255 scope global eno1
           valid_lft forever preferred_lft forever
        inet6 fe80::fab1:56ff:fee4:cafc/64 scope link 
           valid_lft forever preferred_lft forever
    james@mustang:/etc/netplan$ ip r
    default via 192.168.25.1 dev eno1 proto static 
    192.168.25.0/24 dev eno1 proto kernel scope link src 192.168.25.3

Page 6 of 7 FirstFirst ... 4567 LastLast

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
  •