Peter Chan
asked on
Issue of IP address
It looks as though IPv4 is disabled.
ASKER
I did no change ever on it. And do not know why IPv4 does become unavailable.
What do you have in /etc/network/interfaces for the eth0 device?
ASKER
The OS is Ubuntu 20.04. I do not see interfaces inside /etc/network but the following.
It is impossible to determine based on what you provided.
https://ubuntu.com/server/docs/network-configuration
Is this a new install?
What changes were made?
https://ubuntu.com/server/docs/network-configuration
Is this a new install?
What changes were made?
look at /etc/sysconfig/networking or /etc/networking
can the system get out?
presumably the Ubuntu install is provided/accessible, add the net-tools software package
what happens if you set an IPv4 address on
the interface with the ipv6 address relfects that it is sending 8k data and receiving packets. 780+k data
apt install net-tools what happens?
you cut the image so it is not clear name interface and the options
can the system get out?
presumably the Ubuntu install is provided/accessible, add the net-tools software package
what happens if you set an IPv4 address on
the interface with the ipv6 address relfects that it is sending 8k data and receiving packets. 780+k data
apt install net-tools what happens?
you cut the image so it is not clear name interface and the options
ASKER
I did no change to it. Before this, it was fine with proper IPv4 address. There is sysctl.d folder within /etc/ and no sysconfig there.
Have you tried changing the ethernet adapter in the server? Is it a retail Server or just a PC used as a Server? Retail Servers usually have more than one ethernet Adapter, even many normal Mainboards have more than one...
ASKER
It is PC running as the server. I did no change to the OS and did not also physically change anything.
Which system provides DHCP services on the network?
have you tried using ip to set an ipv4 address on the ensxxx interface and see what message you get.
The local interface reflect the inet (ipv4) localhost address, it is unclear why the betwork one is not showing anything.
have you tried using ip to set an ipv4 address on the ensxxx interface and see what message you get.
The local interface reflect the inet (ipv4) localhost address, it is unclear why the betwork one is not showing anything.
IPs are assigned as follows for Ubuntu...
1) Maybe from DHCP.
2) Pre-Artful version - /etc/network/interfaces
3) Post-Artful version - /etc/netplan/some-file-nam e
1) Maybe from DHCP.
2) Pre-Artful version - /etc/network/interfaces
3) Post-Artful version - /etc/netplan/some-file-nam
Starting point info for debugging...
1) What Distro you're running as Pre-Artful + Post-Artful versions configure networking differently.
2) If you're expecting to run a static IP or dynamic IP (DHCP).
3) If this has ever worked, or this is a new Ubuntu install.
1) What Distro you're running as Pre-Artful + Post-Artful versions configure networking differently.
2) If you're expecting to run a static IP or dynamic IP (DHCP).
3) If this has ever worked, or this is a new Ubuntu install.
ASKER
Thanks to all.
Arnold,
Can I have more details of your current way?
Arnold,
Can I have more details of your current way?
Can you post the result of
https://ubuntu.com/blog/ubuntu-bionic-netplan
ip a
lsb_release -a
cat /etc/netplan/*
New versions ubuntu use netplan.https://ubuntu.com/blog/ubuntu-bionic-netplan
ifconfig -i <interfacename> <ip_address> netmask <netmask> up
this presumes you install the net-tools.
The other option since you are in a GUI desktop is to follow:
https://www.linuxtechi.com/assign-static-ip-address-ubuntu-20-04-lts/
I suspect that the IPv4 instead of the IPv6 got disabled in error.
this presumes you install the net-tools.
The other option since you are in a GUI desktop is to follow:
https://www.linuxtechi.com/assign-static-ip-address-ubuntu-20-04-lts/
I suspect that the IPv4 instead of the IPv6 got disabled in error.
You asked, "Can I have more details of your current way?"
Depends on your Distro.
First mention your Distro, to provide a 100% correct answer, as Ubuntu-pre-Artful + Ubuntu-Post-Artful all have different answers.
Depends on your Distro.
First mention your Distro, to provide a 100% correct answer, as Ubuntu-pre-Artful + Ubuntu-Post-Artful all have different answers.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Look like you have 2 netplan files. Can you show the full content of the file that has the network interface name in it? It is the last part in your screenshot, but that is not showing full content. We need that file edited. What was the IP you used to have before?
You can try editing the file, replace the content with something like following
Replace 192.168.1 with your actual LAM IP range.
To apply changes,. run
You can try editing the file, replace the content with something like following
network:
version: 2
renderer: networkd
ethernets:
enp1s0:
addresses:
- 192.168.1.10/24
gateway4: 192.168.1.1
Replace 192.168.1 with your actual LAM IP range.
To apply changes,. run
sudo netplan apply
You have at lease 2 files in /etc/netplan, the 2nd one is showing:
network:
ethernets:
enpls0:
dhcp4: true
Can you make sure the dhcp4: true line is in that file? If not then add it and then give the command: netplan apply
If you get any errors when running the netplan command, you can post them here.
network:
ethernets:
enpls0:
dhcp4: true
Can you make sure the dhcp4: true line is in that file? If not then add it and then give the command: netplan apply
If you get any errors when running the netplan command, you can post them here.
@Peter Chan
You have closed the question which is fine of course but you have selected a comment that ends with a question. How can a comment that ends with a question be the solution? Can you explain that?
Thanks.
You have closed the question which is fine of course but you have selected a comment that ends with a question. How can a comment that ends with a question be the solution? Can you explain that?
Thanks.