Linux - NewbieThis Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place!
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Ubuntu Linux, private network with three devices: laptop, cdev, and edev. All three connected to a switch that shows all active.
Ping returns message:
Connect: Network is unreachable
Wireshark shows that device cdev is sending messages
I edited /etc/host such that I left the first few lines unchanged as shown here
Code:
127.0.0.1 local host
127.0.1.1 esdev
// I added the three lines below but not this comment
192.168.1.10 laptop
192.168.1.20 edev
192.168.1.43 cdev
// and left the remainder of the file unchanged
The laptop really did now want me to change hosts so I copied it to another directory, saved the original, edited a copy, then copied it back to directory /etc with sudo cp command. Then I rebooted and the results are unchanged. I used the "more" command to see that /etc/hosts realy did get changed.
What do I need to do different?
Last edited by bkelly; 12-26-2017 at 03:49 PM.
Reason: formatting
There is a second paragraph of similiar data that instead of enp0s25 it has lo, and a third with wlp61s0.
Do you need any of those two sets of statistics?
edit
I followed some instructions that said to right click “nm” which I take to mean “network manager” which I take to mean the little antenna looking icon in the upper right. That open a dialog with title: Editing ETH. Select the tab: IPv4 Settings.
Clicking on Add allows the editing of an IP address. Enter 192.168.1.10
Tab gets me to what looks like network mask where I recall from somewhere I should enter 255.255.255.0. Which does not entirely make sense because the last octect is the only one that changes.
There is no gateway on this network, just the three devices connected to a network switch box.
Pressing Tag again gets me back to the IP address that was just entered. Save button is not enabled.
Do not know how to get Save enabled.
Last edited by bkelly; 12-26-2017 at 03:38 PM.
Reason: formatting
There is a second paragraph of similiar data that instead of enp0s25 it has lo, and a third with wlp61s0.
Do you need any of those two sets of statistics?
First, please look at the first link in my signature and use CODE tags.
I edited my previous post and added the CODES
The ping to the loopback address does work. Ping to 192.168.1.10, the desired local address, returns Network unreachable.
I am unable to extract something to try different from your reply. That is probably because of not understanding something
The laptop cannot be connected to this network so I took a pic with my cell phone, emailed to my work address, and attempted to attach it here. Looking at this post does not reveal that attachment. Maybe it will be visible after Submit Reply.
Edit:
The attachment is visible. Am not able to do anything to get the Save button to be enabled.
Note that in my first post I wrote that wireshark shows that the device referred to as cdev, ip 192.168.1.43, posts messages. That indicates that the network proper is functioning, the switch is functioning, and at least one other device is functioning. It proves that the NIC on this laptop is functional.
But, something in the configuration is not right.
Last edited by bkelly; 12-26-2017 at 03:59 PM.
Reason: more info
Distribution: Currently: OpenMandriva. Previously: openSUSE, PCLinuxOS, CentOS, among others over the years.
Posts: 3,881
Rep:
Thanks for using CODE tags, it makes it a lot easier to read.
From your post #3, it looks like your ethernet is not getting an IPv4 address at boot time. You also have your connection set as "Manual" from your screenshot.
Why "manual"? Because there are three devices on the network. Two have fixed IP addresses, 192,168.1.20 and .43. The third is the laptop that must also have a fixed address. That would be 192.168.1.10. there is no DNS server and no gateway computer.
What should be different?
Distribution: openSUSE, Raspbian, Slackware. Previous: MacOS, Red Hat, Coherent, Consensys SVR4.2, Tru64, Solaris
Posts: 2,803
Rep:
Quote:
Originally Posted by bkelly
I edited my previous post and added the CODES
The ping to the loopback address does work. Ping to 192.168.1.10, the desired local address, returns Network unreachable.
I'm not an Ubuntu guru so I may not be able to get you detailed info on what's going on, but whenever I see "Network unavailable" I wonder whether a default route has been defined or whether the network has been fully configured.
What do you see when you issue:
Code:
netstat -r
or
Code:
ip route
When I issue the latter, I see:
Code:
$ ip route
default via 192.168.13.1 dev enp3s0
192.168.13.0/24 dev enp3s0 proto kernel scope link src 192.168.13.7
My workstation has address "192.168.13.7" and "192.168.13.1" is the (uh) "clean" interface on my firewall/router system. I'm going to go out on a limb and posit that you do not see a line like "default via ... ".
and nothing more. There are more spaces in the second line that looks like making it look column friendly, but no characters below that line, just the next command line prompt.
enter: ip route
to get,..., nothing. Well not quite, it does provide another copy of the command prompt line.
That looks like a good clue but I don't know where to go with it.
Enter the command ifconfig and the returned the same as I posted earlier,
three groups of responses that are mostly status items. It does not describe, to the novice,
what is wrong or what might be changed.
Use this command
Code:
ifconfig enp0s25
and it gives the same response, but a single block with the lead in "enp0s25"
use this command as suggested
Code:
ifconfig enp0s25 192.168.1.10
and it responds with
Code:
SIOCSIFADDR: Operation not permitted
SIOCIFFLAGS: Operation not permitted
Found a page that said to do this
Code:
sudo apt install ethtool
Did that then ran this command with the shown response
Code:
sudo ethtool enp0s25
Settings for enp0s25:
Supported port [ TP ]
Supported link modes: 10baseT/Half 10baseTFull
….
It continue on to list more information such as 100 Mbit and 1000 Mbit interfaces and a list of attributes. To my ability, it is telling me that all is good and describes port enp0s25. I am unable to discover something wrong that bears changing.
Looking up the various ifconfig and ip and route commands provides a huge amount of information. However, as a novice, I am not able to determine what should be and how to change my system to match the should be condition.
Last edited by bkelly; 12-26-2017 at 05:54 PM.
Reason: more information
And it just presented the next prompt. No information, no error.
That is almost all for today. I will try again tomorrow, after asking about mounting a USB drive.
Distribution: Currently: OpenMandriva. Previously: openSUSE, PCLinuxOS, CentOS, among others over the years.
Posts: 3,881
Rep:
Quote:
Originally Posted by bkelly
Yes, tried that as root
Code:
sudo ifconfig epn0s25 192168.1.10
And it just presented the next prompt. No information, no error.
That is almost all for today. I will try again tomorrow, after asking about mounting a USB drive.
It should be the following, rather than the above:
Code:
sudo ifconfig epn0s25 192.168.1.10
If it give no error, do you still have the same problem?
and nothing more. There are more spaces in the second line that looks like making it look column friendly, but no characters below that line, just the next command line prompt.
enter: ip route
to get,..., nothing. Well not quite, it does provide another copy of the command prompt line.
That looks like a good clue but I don't know where to go with it.
You have no routes configured. Is this a standalone network? Do you have a router from your ISP?
If it's standalone, something still needs to act as the router for your network. (You did say thre was no "gateway computer" in your original post---I missed that and I think that's the source of your problem.) Perhaps one of the systems is acting as a server of some sort? That might be a good choice.
List the three devices you have on your network and their IP addresses. You're using a 192.168.x.x address space, right? Might be a good idea to issue the "ip route" (or "netstat -r") command on all three systems (laptop?, cdev?, and edev?) as well as the "ifconfig -a" or "ip addr list" command on each and post the output for all systems.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.