Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.os.linux.networking > #4003 > unrolled thread

Fixed IP addreses on network.

Started byDoug Laidlaw <laidlaws@hotkey.net.au>
First post2017-03-30 03:23 +1100
Last post2017-04-02 14:39 -0700
Articles 20 on this page of 37 — 14 participants

Back to article view | Back to comp.os.linux.networking


Contents

  Fixed IP addreses on network. Doug  Laidlaw  <laidlaws@hotkey.net.au> - 2017-03-30 03:23 +1100
    Re: Fixed IP addreses on network. Pascal Hambourg <pascal@plouf.fr.eu.org> - 2017-03-29 20:57 +0200
      Re: Fixed IP addreses on network. Doug Laidlaw <laidlaws@hotkey.net.au> - 2017-03-30 06:20 +1100
    Re: Fixed IP addreses on network. William Unruh <unruh@invalid.ca> - 2017-03-29 21:01 +0000
      Re: Fixed IP addreses on network. Doug Laidlaw <laidlaws@hotkey.net.au> - 2017-03-30 23:32 +1100
        Re: Fixed IP addreses on network. Pascal Hambourg <pascal@plouf.fr.eu.org> - 2017-03-30 20:28 +0200
        Re: Fixed IP addreses on network. Gordon <Gordon@clear.net.nz> - 2017-03-31 05:23 +0000
    Re: Fixed IP addreses on network. robert.wolfe@wildcat.uuhec.net (Robert Wolfe) - 2017-03-30 13:27 +0000
    Re: Fixed IP addreses on network. robert.wolfe@wildcat.uuhec.net (Robert Wolfe) - 2017-03-30 13:28 +0000
      Re: Fixed IP addreses on network. Pascal Hambourg <pascal@plouf.fr.eu.org> - 2017-03-30 20:34 +0200
        Re: Fixed IP addreses on network. Richard Kettlewell <invalid@invalid.invalid> - 2017-03-30 20:20 +0100
          Re: Fixed IP addreses on network. Gordon <Gordon@clear.net.nz> - 2017-03-31 05:44 +0000
        Re: Fixed IP addreses on network. "Jonathan N. Little" <lws4art@gmail.com> - 2017-03-30 16:56 -0400
          Re: Fixed IP addreses on network. Pascal Hambourg <pascal@plouf.fr.eu.org> - 2017-03-31 00:18 +0200
            Re: Fixed IP addreses on network. "Jonathan N. Little" <lws4art@gmail.com> - 2017-03-30 18:52 -0400
              Re: Fixed IP addreses on network. Pascal Hambourg <pascal@plouf.fr.eu.org> - 2017-03-31 19:38 +0200
    Re: Fixed IP addreses on network. ray carter <ray@zianet.com> - 2017-03-30 14:04 +0000
    Re: Fixed IP addreses on network. "Jonathan N. Little" <lws4art@gmail.com> - 2017-03-30 12:33 -0400
      Re: Fixed IP addreses on network. "Carlos E. R." <robin_listas@es.invalid> - 2017-03-31 01:59 +0200
        Re: Fixed IP addreses on network. "Jonathan N. Little" <lws4art@gmail.com> - 2017-03-30 23:10 -0400
          Re: Fixed IP addreses on network. Gordon <Gordon@clear.net.nz> - 2017-03-31 05:34 +0000
            Re: Fixed IP addreses on network. "Jonathan N. Little" <lws4art@gmail.com> - 2017-03-31 08:43 -0400
            Re: Fixed IP addreses on network. Jorgen Grahn <grahn+nntp@snipabacken.se> - 2017-03-31 14:10 +0000
              Re: Fixed IP addreses on network. "Jonathan N. Little" <lws4art@gmail.com> - 2017-03-31 11:02 -0400
              Re: Fixed IP addreses on network. Pascal Hambourg <pascal@plouf.fr.eu.org> - 2017-03-31 19:45 +0200
          Re: Fixed IP addreses on network. "Carlos E. R." <robin_listas@es.invalid> - 2017-04-01 02:01 +0200
            Re: Fixed IP addreses on network. Pascal Hambourg <pascal@plouf.fr.eu.org> - 2017-04-01 09:41 +0200
              Re: Fixed IP addreses on network. "Carlos E. R." <robin_listas@es.invalid> - 2017-04-01 12:50 +0200
                Re: Fixed IP addreses on network. Pascal Hambourg <pascal@plouf.fr.eu.org> - 2017-04-02 00:17 +0200
                  Re: Fixed IP addreses on network. "Carlos E. R." <robin_listas@es.invalid> - 2017-04-02 01:22 +0200
                    Re: Fixed IP addreses on network. Pascal Hambourg <pascal@plouf.fr.eu.org> - 2017-04-02 11:41 +0200
                      Re: Fixed IP addreses on network. Jerry Peters <jerry@example.invalid> - 2017-04-02 20:00 +0000
                  Re: Fixed IP addreses on network. Jerry Peters <jerry@example.invalid> - 2017-04-02 19:57 +0000
                    Re: Fixed IP addreses on network. William Unruh <unruh@invalid.ca> - 2017-04-03 00:07 +0000
                      Re: Fixed IP addreses on network. Pascal Hambourg <pascal@plouf.fr.eu.org> - 2017-04-06 23:58 +0200
    Re: Fixed IP addreses on network. John Carter <me@mymailsvr.org> - 2017-03-31 04:51 +0000
    Re: Fixed IP addreses on network. Dave <noone$$@llondel.org> - 2017-04-02 14:39 -0700

Page 1 of 2  [1] 2  Next page →


#4003 — Fixed IP addreses on network.

FromDoug Laidlaw <laidlaws@hotkey.net.au>
Date2017-03-30 03:23 +1100
SubjectFixed IP addreses on network.
Message-ID<fcRCA.432076$Tb4.251145@fx03.fr7>
I have bought a Raspberry Pi (amazing device) and
added it to my home network.  I would like to give it
a fixed IP address on the network.  I read somewhere
about associating the Pi's MAC address with a fixed
IP address, but my router does not seem to support 
doing that.  My desktop computer has a set IP 
address in its config, but the Pi runs Kodi, which is
not an operating system, they tell me, so it can't
set its own address.

Any ideas please?

Doug.
-- 

[toc] | [next] | [standalone]


#4005

FromPascal Hambourg <pascal@plouf.fr.eu.org>
Date2017-03-29 20:57 +0200
Message-ID<obh02d$6vr$1@saria.nerim.net>
In reply to#4003
Le 29/03/2017 à 18:23, Doug Laidlaw a écrit :
> I have bought a Raspberry Pi (amazing device) and
> added it to my home network.  I would like to give it
> a fixed IP address on the network.  I read somewhere
> about associating the Pi's MAC address with a fixed
> IP address, but my router does not seem to support
> doing that.  My desktop computer has a set IP
> address in its config, but the Pi runs Kodi, which is
> not an operating system, they tell me, so it can't
> set its own address.

I doubt that Kodi can run on it own on bare hardware, it has to run on 
top of an underlying operating system. If you posted to this newsgroup, 
I guess you suspect that the operating system is some GNU/Linux flavour.

[toc] | [prev] | [next] | [standalone]


#4006

FromDoug Laidlaw <laidlaws@hotkey.net.au>
Date2017-03-30 06:20 +1100
Message-ID<obh1ee$16ue$1@gioia.aioe.org>
In reply to#4005
On 30/03/17 05:57, Pascal Hambourg wrote:
> Le 29/03/2017 à 18:23, Doug Laidlaw a écrit :
>> I have bought a Raspberry Pi (amazing device) and
>> added it to my home network.  I would like to give it
>> a fixed IP address on the network.  I read somewhere
>> about associating the Pi's MAC address with a fixed
>> IP address, but my router does not seem to support
>> doing that.  My desktop computer has a set IP
>> address in its config, but the Pi runs Kodi, which is
>> not an operating system, they tell me, so it can't
>> set its own address.
>
> I doubt that Kodi can run on it own on bare hardware, it has to run on
> top of an underlying operating system. If you posted to this newsgroup,
> I guess you suspect that the operating system is some GNU/Linux flavour.

Quite right.  The OS is Linux, but it is contained in a squashfs archive 
that is not directly accessible There are a few config files and a small 
selection of systemd.  The best way to run it seems to be, to run it 
from a host OS. Instructions for Ubuntu are plentiful: if you are 
running something different, they don't want to know you.  I have the 
full Kodi running in Mageia in the same way, with an independent startup 
option in the login menu.

Raspbian, the preferred OS for the Pi, is based on Debian Jessie.  I 
downloaded the NOOBS software selection.  It includes Raspbian and 
LibreELEC, a basic setup with Kodi embedded, but the two seem quite 
independent.

Doug.

[toc] | [prev] | [next] | [standalone]


#4008

FromWilliam Unruh <unruh@invalid.ca>
Date2017-03-29 21:01 +0000
Message-ID<obh7bd$b8g$1@dont-email.me>
In reply to#4003
On 2017-03-29, Doug Laidlaw <laidlaws@hotkey.net.au> wrote:
> I have bought a Raspberry Pi (amazing device) and
> added it to my home network.  I would like to give it
> a fixed IP address on the network.  I read somewhere
> about associating the Pi's MAC address with a fixed
> IP address, but my router does not seem to support 

I am pretty sure it does support that. What is your router?
Are you connecting via wireless or ethernet? 

> doing that.  My desktop computer has a set IP 
> address in its config, but the Pi runs Kodi, which is
> not an operating system, they tell me, so it can't

Kodi is not but I think it runs on top of an OS, which would almost
certainly have that ability. What program  does the network connection?

> set its own address.
>
> Any ideas please?
>
> Doug.

[toc] | [prev] | [next] | [standalone]


#4009

FromDoug Laidlaw <laidlaws@hotkey.net.au>
Date2017-03-30 23:32 +1100
Message-ID<obitst$1uj$1@gioia.aioe.org>
In reply to#4008
On 30/03/17 08:01, William Unruh wrote:
> I am pretty sure it does support that. What is your router?
> Are you connecting via wireless or ethernet?

Maybe it should, but the forums are full of complaints about its 
deficiencies.  It is a Huawei HG659, which they gave us when the 
Broadband service arrived.  Connection to it is via Ethernet.  The 
router had to be in our kitchen, to be near an alarm sender, and instead 
of an ethernet cable down the passage, I was sold a gadget that sends 
data through the power system with transducers at each end.  But that 
isn't relevant to this post.  The appropriate menu mentions all kinds of 
hook-ups that I have never heard of, but nothing resembling what I want. 
  MAC addresses don't seem to be mentioned in the options at all.  It 
was suggested that I chainload a router that is configurable.

Doug.

[toc] | [prev] | [next] | [standalone]


#4014

FromPascal Hambourg <pascal@plouf.fr.eu.org>
Date2017-03-30 20:28 +0200
Message-ID<objiot$uor$1@saria.nerim.net>
In reply to#4009
Le 30/03/2017 à 14:32, Doug Laidlaw a écrit :
> On 30/03/17 08:01, William Unruh wrote:
>> I am pretty sure it does support that. What is your router?
>> Are you connecting via wireless or ethernet?
>
> Maybe it should, but the forums are full of complaints about its
> deficiencies.  It is a Huawei HG659, which they gave us when the
> Broadband service arrived (...) The appropriate menu mentions all kinds of
> hook-ups that I have never heard of, but nothing resembling what I want.
>  MAC addresses don't seem to be mentioned in the options at all.

MAC-IP address reservation is usually in the LAN DHCP server settings.

[toc] | [prev] | [next] | [standalone]


#4023

FromGordon <Gordon@clear.net.nz>
Date2017-03-31 05:23 +0000
Message-ID<ek67fbF6b67U3@mid.individual.net>
In reply to#4009
On 2017-03-30, Doug Laidlaw <laidlaws@hotkey.net.au> wrote:
> On 30/03/17 08:01, William Unruh wrote:
>> I am pretty sure it does support that. What is your router?
>> Are you connecting via wireless or ethernet?
>
> Maybe it should, but the forums are full of complaints about its 
> deficiencies.  It is a Huawei HG659, which they gave us when the 
> Broadband service arrived.  Connection to it is via Ethernet.


The Huawei is a box which turns pulses of light into pulses that ethernet
knows how to handle.   

>  The 
> router had to be in our kitchen, to be near an alarm sender, and instead 
> of an ethernet cable down the passage, I was sold a gadget that sends 
> data through the power system with transducers at each end.  But that 
> isn't relevant to this post.  The appropriate menu mentions all kinds of 
> hook-ups that I have never heard of, but nothing resembling what I want. 
>   MAC addresses don't seem to be mentioned in the options at all.  It 
> was suggested that I chainload a router that is configurable.
>

Okay we have ethernet.

BTW way one can have have the router near the Huawei and a ethernet cable
can go to the alarm sender; yes? Ethernet is good to send a signal down
approx 100m of cable.

You have Kodi running on the pi

So lets ask Google "static Ip address on raspberry pi kodi"

Google says

http://raspberrypi.stackexchange.com/questions/3247/how-do-i-configure-raspbmc-with-a-static-ip-address

This is darn close to what you need yes? Remember xmbc is now kodi. Things
might have changeed slightly in the last 2 and a half years.


Could we have some more 

[toc] | [prev] | [next] | [standalone]


#4010

Fromrobert.wolfe@wildcat.uuhec.net (Robert Wolfe)
Date2017-03-30 13:27 +0000
Message-ID<170330072952109@wildcat.uuhec.net>
In reply to#4003
-> I have bought a Raspberry Pi (amazing device) and
-> added it to my home network.  I would like to give it
-> a fixed IP address on the network.  I read somewhere
-> about associating the Pi's MAC address with a fixed
-> IP address, but my router does not seem to support
-> doing that.  My desktop computer has a set IP
-> address in its config, but the Pi runs Kodi, which is
-> not an operating system, they tell me, so it can't
-> set its own address.
->
-> Any ideas please?

Why not just set up the OS to have a static IP and let the OS do the
work?  What OS are you running on the Pi?

[toc] | [prev] | [next] | [standalone]


#4011

Fromrobert.wolfe@wildcat.uuhec.net (Robert Wolfe)
Date2017-03-30 13:28 +0000
Message-ID<170330072952110@wildcat.uuhec.net>
In reply to#4003
->
-> Raspbian, the preferred OS for the Pi, is based on Debian Jessie.  I
-> downloaded the NOOBS software selection.  It includes Raspbian and
-> LibreELEC, a basic setup with Kodi embedded, but the two seem quite
-> independent.
->

If you are running Raspbian then, all you need to do is set up the
static IP addresses in /etc/network/interfaces IIRC.

[toc] | [prev] | [next] | [standalone]


#4015

FromPascal Hambourg <pascal@plouf.fr.eu.org>
Date2017-03-30 20:34 +0200
Message-ID<objj3h$uu6$1@saria.nerim.net>
In reply to#4011
Le 30/03/2017 à 15:28, Robert Wolfe a écrit :
>
> If you are running Raspbian then, all you need to do is set up the
> static IP addresses in /etc/network/interfaces IIRC.

IIRC, Raspbian uses dhcpcd and a comment in /etc/network/interfaces 
instructs to configure all interfaces in dhcpcd's configuration even for 
static addresses instead of this file. Really weird.

[toc] | [prev] | [next] | [standalone]


#4016

FromRichard Kettlewell <invalid@invalid.invalid>
Date2017-03-30 20:20 +0100
Message-ID<87tw6avaf8.fsf@LkoBDZeT.terraraq.uk>
In reply to#4015
Pascal Hambourg <pascal@plouf.fr.eu.org> writes:
> Le 30/03/2017 à 15:28, Robert Wolfe a écrit :

>> If you are running Raspbian then, all you need to do is set up the
>> static IP addresses in /etc/network/interfaces IIRC.
>
> IIRC, Raspbian uses dhcpcd and a comment in /etc/network/interfaces
> instructs to configure all interfaces in dhcpcd's configuration even
> for static addresses instead of this file. Really weird.

That doesn’t seem to be the case, or at least it’s certainly not
mandatory. I have a perfectly ordinary static IP address configuration
on my Pi.

-- 
http://www.greenend.org.uk/rjk/

[toc] | [prev] | [next] | [standalone]


#4025

FromGordon <Gordon@clear.net.nz>
Date2017-03-31 05:44 +0000
Message-ID<ek68l1F6b67U5@mid.individual.net>
In reply to#4016
On 2017-03-30, Richard Kettlewell <invalid@invalid.invalid> wrote:
> Pascal Hambourg <pascal@plouf.fr.eu.org> writes:
>> Le 30/03/2017 à 15:28, Robert Wolfe a écrit :
>
>>> If you are running Raspbian then, all you need to do is set up the
>>> static IP addresses in /etc/network/interfaces IIRC.
>>
>> IIRC, Raspbian uses dhcpcd and a comment in /etc/network/interfaces
>> instructs to configure all interfaces in dhcpcd's configuration even
>> for static addresses instead of this file. Really weird.
>
> That doesn’t seem to be the case, or at least it’s certainly not
> mandatory. I have a perfectly ordinary static IP address configuration
> on my Pi.
>

Indeed. My several pis have static IP addresses. If using Rasbian then there
is even a GUI to do this. Network manager come in please.

Right click on the up and down arrows icon. Netwrok settings and follow your
mouse. Not done, darn try again ;-) ;-(

[toc] | [prev] | [next] | [standalone]


#4017

From"Jonathan N. Little" <lws4art@gmail.com>
Date2017-03-30 16:56 -0400
Message-ID<objr7i$6l9$1@dont-email.me>
In reply to#4015
Pascal Hambourg wrote:
> Le 30/03/2017 à 15:28, Robert Wolfe a écrit :
>>
>> If you are running Raspbian then, all you need to do is set up the
>> static IP addresses in /etc/network/interfaces IIRC.
>
> IIRC, Raspbian uses dhcpcd and a comment in /etc/network/interfaces
> instructs to configure all interfaces in dhcpcd's configuration even for
> static addresses instead of this file. Really weird.
>

dhcpcd? Do you mean dhcpd.conf> If so that is the DHCP *server* 
settings. Only applicable if you are running DHCP *server* on the 
Raspberry PI. If I understand your OP you want to set a static IP on the 
Raspberry PI as the *client*. You want to set it statically and not get 
it dynamically from the router. Your router has the DHCP *server*.

Now most modern routers can "reserve" addresses based on MAC addresses. 
It is usually found under the advance settings for the DHCP server on 
the router. On a Linux server you would edit the /etc/dhcp/dhcpd.conf. 
But that is not what you are asking.

For you, you want to determine the DHCP range for the pool on your 
router. A typical value is 100-254. That would mean you have a range of 
2-99 address for static IPs,(assuming Class C network). Then you will 
want to edit your PI's interfaces configuration as I detailed elsewhere 
in the thread.


-- 
Take care,

Jonathan
-------------------
LITTLE WORKS STUDIO
http://www.LittleWorksStudio.com

[toc] | [prev] | [next] | [standalone]


#4018

FromPascal Hambourg <pascal@plouf.fr.eu.org>
Date2017-03-31 00:18 +0200
Message-ID<obk07n$12l0$1@saria.nerim.net>
In reply to#4017
Le 30/03/2017 à 22:56, Jonathan N. Little a écrit :
> Pascal Hambourg wrote:
>> Le 30/03/2017 à 15:28, Robert Wolfe a écrit :
>>>
>>> If you are running Raspbian then, all you need to do is set up the
>>> static IP addresses in /etc/network/interfaces IIRC.
>>
>> IIRC, Raspbian uses dhcpcd and a comment in /etc/network/interfaces
>> instructs to configure all interfaces in dhcpcd's configuration even for
>> static addresses instead of this file. Really weird.
>
> dhcpcd?

Yes.

> Do you mean dhcpd.conf > If so that is the DHCP *server* settings

No. I mean dhcpcd, the DHCP *client* daemon.

I have come across the following comment in the /etc/network/interfaces 
file provided in Raspbian in several threads :

# Please note that this file is written to be used with dhcpcd.
# For static IP, consult /etc/dhcpcd.conf and 'man dhcpcd.conf'.

[toc] | [prev] | [next] | [standalone]


#4019

From"Jonathan N. Little" <lws4art@gmail.com>
Date2017-03-30 18:52 -0400
Message-ID<obk22d$uhk$1@dont-email.me>
In reply to#4018
Pascal Hambourg wrote:
> Le 30/03/2017 à 22:56, Jonathan N. Little a écrit :
>> Pascal Hambourg wrote:
>>> Le 30/03/2017 à 15:28, Robert Wolfe a écrit :
>>>>
>>>> If you are running Raspbian then, all you need to do is set up the
>>>> static IP addresses in /etc/network/interfaces IIRC.
>>>
>>> IIRC, Raspbian uses dhcpcd and a comment in /etc/network/interfaces
>>> instructs to configure all interfaces in dhcpcd's configuration even for
>>> static addresses instead of this file. Really weird.
>>
>> dhcpcd?
>
> Yes.
>
>> Do you mean dhcpd.conf > If so that is the DHCP *server* settings
>
> No. I mean dhcpcd, the DHCP *client* daemon.
>
> I have come across the following comment in the /etc/network/interfaces
> file provided in Raspbian in several threads :
>
> # Please note that this file is written to be used with dhcpcd.
> # For static IP, consult /etc/dhcpcd.conf and 'man dhcpcd.conf'.

Well that must be Raspbian specific. In Ubuntu it is
/etc/dhcp/dhclient.conf

Anyway you cannot not set you IP with the client configuration, you set 
what the client send to the DHCP server... You can setup an alias 
interface though, from man:

alias {
   interface "eth0";
   fixed-address 192.5.5.213;
   option subnet-mask 255.255.255.255;
}

But if you really want to set a static IP on your interface I would say 
/etc/network/interfaces/interfaces.d/ is the correct place to do it.

-- 
Take care,

Jonathan
-------------------
LITTLE WORKS STUDIO
http://www.LittleWorksStudio.com

[toc] | [prev] | [next] | [standalone]


#4029

FromPascal Hambourg <pascal@plouf.fr.eu.org>
Date2017-03-31 19:38 +0200
Message-ID<obm46h$1mb1$1@saria.nerim.net>
In reply to#4019
Le 31/03/2017 à 00:52, Jonathan N. Little a écrit :
> Pascal Hambourg wrote:
>>
>> I have come across the following comment in the /etc/network/interfaces
>> file provided in Raspbian in several threads :
>>
>> # Please note that this file is written to be used with dhcpcd.
>> # For static IP, consult /etc/dhcpcd.conf and 'man dhcpcd.conf'.
>
> Well that must be Raspbian specific.

I did not pretend otherwise.

> Anyway you cannot not set you IP with the client configuration, you set
> what the client send to the DHCP server.

dhcpcd can be configured to set up a static address on an interface, an 
then does not act as a DHCP client.

[toc] | [prev] | [next] | [standalone]


#4012

Fromray carter <ray@zianet.com>
Date2017-03-30 14:04 +0000
Message-ID<ek4hjcF8curU2@mid.individual.net>
In reply to#4003
On Thu, 30 Mar 2017 03:23:38 +1100, Doug  Laidlaw wrote:

> I have bought a Raspberry Pi (amazing device) and added it to my home
> network.  I would like to give it a fixed IP address on the network.  I
> read somewhere about associating the Pi's MAC address with a fixed IP
> address, but my router does not seem to support doing that.  My desktop
> computer has a set IP address in its config, but the Pi runs Kodi, which
> is not an operating system, they tell me, so it can't set its own
> address.
> 
> Any ideas please?
> 
> Doug.

Suggest you try comp.sys.raspberry-pi group

[toc] | [prev] | [next] | [standalone]


#4013

From"Jonathan N. Little" <lws4art@gmail.com>
Date2017-03-30 12:33 -0400
Message-ID<objbri$e95$1@dont-email.me>
In reply to#4003
Doug Laidlaw wrote:
> I have bought a Raspberry Pi (amazing device) and
> added it to my home network.  I would like to give it
> a fixed IP address on the network.  I read somewhere
> about associating the Pi's MAC address with a fixed
> IP address, but my router does not seem to support
> doing that.  My desktop computer has a set IP
> address in its config, but the Pi runs Kodi, which is
> not an operating system, they tell me, so it can't
> set its own address.
>
> Any ideas please?

If you have Raspbian OS the default it is a Debian version of Linux. I 
have Ubuntu on mine, but the process is basically the same.

1) First discover the interface ID of your adapter. Legacy naming 
convention was eth0, eth1, wlan0, etc.; but with introduction of systemd 
the naming convention has changed. Example in a terminal window run 
command "ifconfig":

ifconfig

enxb827eb109bc0 Link encap:Ethernet  HWaddr b8:27:eb:10:9b:c0
           inet addr:192.168.1.5  Bcast:192.168.57.255  Mask:255.255.255.0
           inet6 addr: fe80::ba27:ebff:fe10:9bc0/64 Scope:Link
           UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
           RX packets:2619 errors:0 dropped:0 overruns:0 frame:0
           TX packets:1452 errors:0 dropped:0 overruns:0 carrier:0
           collisions:0 txqueuelen:1000
           RX bytes:3675789 (3.6 MB)  TX bytes:135742 (135.7 KB)
...

"enxb827eb109bc0" is my Ethernet jack's identifier. Yours may be 
different. Just take note of it you will need it later.

2) Determine naming convention for interface partials for your OS with 
grep command. It can vary *.conf, *.cfg, ... depending on distro

grep source /etc/network/interfaces

source /etc/network/interfaces.d/*.cfg

3) Now make a static config file for your adapter. I'm going to call it 
"mystatic.cfg" because in the previous step the pattern was "*.cfg" and 
I will use the easy editor "nano":

sudo nano /etc/network/interfaces.d/mystatic.cfg

4) File content for this example with IP 192.168.1.2 with your router's 
IP 192.168.1.1, adjust accordingly:

# Set static IP for interface
auto enxb827eb109bc0
iface enxb827eb109bc0 inet static
address 192.168.1.2
netmask 255.255.255.0
broadcast 192.168.1.255
gateway 192.168.1.1

5) restart networking:

sudo systemctl restart networking.service

That should do it, your can check status with:

systemctl status networking.service

and confirm interface IP with

ifconfig

HTH

-- 
Take care,

Jonathan
-------------------
LITTLE WORKS STUDIO
http://www.LittleWorksStudio.com

[toc] | [prev] | [next] | [standalone]


#4020

From"Carlos E. R." <robin_listas@es.invalid>
Date2017-03-31 01:59 +0200
Message-ID<bni0rd-0if.ln1@minas-tirith.valinor>
In reply to#4013
On 2017-03-30 18:33, Jonathan N. Little wrote:

> If you have Raspbian OS the default it is a Debian version of Linux. I
> have Ubuntu on mine, but the process is basically the same.
> 
> 1) First discover the interface ID of your adapter. Legacy naming
> convention was eth0, eth1, wlan0, etc.; but with introduction of systemd
> the naming convention has changed. Example in a terminal window run
> command "ifconfig":

That change wasn't due to systemd. It happened at the same time, but
this thing comes from the kernel.

-- 
Cheers,
       Carlos E.R.

[toc] | [prev] | [next] | [standalone]


#4021

From"Jonathan N. Little" <lws4art@gmail.com>
Date2017-03-30 23:10 -0400
Message-ID<obkh5h$s49$1@dont-email.me>
In reply to#4020
Carlos E. R. wrote:
> On 2017-03-30 18:33, Jonathan N. Little wrote:
>
>> If you have Raspbian OS the default it is a Debian version of Linux. I
>> have Ubuntu on mine, but the process is basically the same.
>>
>> 1) First discover the interface ID of your adapter. Legacy naming
>> convention was eth0, eth1, wlan0, etc.; but with introduction of systemd
>> the naming convention has changed. Example in a terminal window run
>> command "ifconfig":
>
> That change wasn't due to systemd. It happened at the same time, but
> this thing comes from the kernel.
>


Really? I did not get that impression: 
<https://www.freedesktop.org/wiki/Software/systemd/PredictableNetworkInterfaceNames/>

-- 
Take care,

Jonathan
-------------------
LITTLE WORKS STUDIO
http://www.LittleWorksStudio.com

[toc] | [prev] | [next] | [standalone]


Page 1 of 2  [1] 2  Next page →

Back to top | Article view | comp.os.linux.networking


csiph-web