Re: [DNG] Refracta have a static IP

2021-07-14 Thread Marjorie Roome via Dng
On Wed, 2021-07-14 at 18:41 +, g4sra via Dng wrote:

> If 'NetworkManager' rears its head.purge with prejudice would be
> my advice.
> 
On the other hand it /is/ quite straightforward to set static IPs if
you /do/ use Network Manager.

All I have in /etc/network/interfaces.d/interfaces is:

# The loopback network interface
auto lo
iface lo inet loopback

For my desktop computer, in Network Manager, for my SSID in IPV4
settings:

Address: 192.169.1.215
Netmask: 24
Gateway: 192.168.254

Of course your actual machine address and gateway address will vary.

I do also assign my network's static IPs and corresponding MAC
addresses in my Router's Static ARP table. In general anything fixed at
home (desktop, mail server, printer, smart tvs, chromecast, roku, WAP,
etc) has a static IP and portable devices (phones, tablets, cameras,
etc) has a dynamic IP.

-- 
Marjorie
 

___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng


Re: [DNG] Refracta have a static IP

2021-07-14 Thread g4sra via Dng
<--snip-->
> 

> What does the following show (everythingish installed that triggers dhclient)
> for P in $(dpkg -l | grep dhcp); do apt-cache rdepends $P 2>/dev/null | grep 
> '|' ; done
> 

> If 'NetworkManager' rears its head.purge with prejudice would be my 
> advice.

Arrgh! that command chain doesn't (distinguish between what is and isn't 
installed) work right.
Lesson learned, test before you post...

publickey - g4sra@protonmail.com - 0x42E94623.asc
Description: application/pgp-keys


signature.asc
Description: OpenPGP digital signature
___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng


Re: [DNG] Refracta have a static IP

2021-07-14 Thread g4sra via Dng

On Tuesday, July 13th, 2021 at 9:41 PM, Steve Litt  
wrote:

> Hi all,
> I'm trying to make my new Chimera based Refracta have a static IP
> address at 192.168.0.199/24, in order that every other computer on the
> 192.168.0.0/24 subnet can easily access it, and so I can put it on my
> LAN DNS.
> So I made my /etc/network/interfaces look like the following, which
> follows the guidelines of "man interfaces":
> =
> auto lo
> iface lo inet loopback
> allow-hotplug eth0
> iface eth0 inet static
> address 192.168.0.199
> gateway 192.168.0.1
> =
> Unfortunately, instead of the IP address being 192.168.0.199, it's a
> DHCP supplied 192.168.0.204 . What additional steps must I take to get
> my desired 192.168.0.199?
> Additional note: When I used 192.168.0.40, which I KNOW is not in my
> leased DHCP range, the result was the same. What must I do to get a
> static IP at 192.168.0.199/24 ?

> Thanks,
> SteveT


What does the following show (everythingish installed that triggers dhclient)

for P in $(dpkg -l | grep dhcp); do apt-cache rdepends $P 2>/dev/null | grep 
'|' ; done

If 'NetworkManager' rears its head.purge with prejudice would be my advice.



publickey - g4sra@protonmail.com - 0x42E94623.asc
Description: application/pgp-keys


signature.asc
Description: OpenPGP digital signature
___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng


Re: [DNG] Refracta have a static IP

2021-07-14 Thread Bernard Rosset via Dng

..could this be as simple as:
address 192.168.0.199/24 #???


Yes


No, in /etc/network/interfaces it needs a net mask line like this :


auto eth0
iface eth0 inet static
   address 192.168.nnn.nnn
   netmask 255.255.255.0
   gateway 192.168.nnn.nnn


No

RTFM?

Documentation states, for both INET & INET6 families:
address address
   Address (dotted quad/netmask) required

netmask mask
   Netmask (dotted quad or number of bits) deprecated

Are we really debating how to configure network addresses without first 
searching in the man pages?

I hope no-one is giving speeches in the whole lot :oP

The only things which are not documented in the "interfaces" man page is 
how the default value for optional directives is computed. In doubt, 
specify those, but they are technically not required. Welcome to 
"default values" wonderland.


Happy documentation reading,
Bernard (Beer) Rosset
https://rosset.net/
___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng


Re: [DNG] Refracta have a static IP

2021-07-14 Thread Simon Hobson
Arnt Karlsen  wrote:

>> So I made my /etc/network/interfaces look like the following, which
>> follows the guidelines of "man interfaces":
>> 
>> ===
>> auto lo
>> iface lo inet loopback
>> 
>> allow-hotplug eth0
>> iface eth0 inet static
>>  address 192.168.0.199
> 
> ..could this be as simple as:
> address 192.168.0.199/24 #??? It shouldn't be.
> 
>>  gateway 192.168.0.1
>> ===

No, in /etc/network/interfaces it needs a net mask line like this :

> auto eth0
> iface eth0 inet static
>   address 192.168.nnn.nnn
>   netmask 255.255.255.0
>   gateway 192.168.nnn.nnn

I usually use auto, but I believe for a "server" type setup then the effect is 
the same as allow-hotplug.

Simon

___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng


Re: [DNG] Refracta have a static IP

2021-07-14 Thread Arnt Karlsen
On Tue, 13 Jul 2021 16:41:06 -0400, Steve wrote in message 
<20210713164106.41efd...@mydesk.domain.cxm>:

> Hi all,
> 
> I'm trying to make my new Chimera based Refracta have a static IP
> address at 192.168.0.199/24, in order that every other computer on the
> 192.168.0.0/24 subnet can easily access it, and so I can put it on my
> LAN DNS.
> 
> So I made my /etc/network/interfaces look like the following, which
> follows the guidelines of "man interfaces":
> 
> ===
> auto lo
> iface lo inet loopback
> 
> allow-hotplug eth0
> iface eth0 inet static
>   address 192.168.0.199

..could this be as simple as:
address 192.168.0.199/24 #??? It shouldn't be.

>   gateway 192.168.0.1
> ===
> 
> Unfortunately, instead of the IP address being 192.168.0.199, it's a
> DHCP supplied 192.168.0.204 . What additional steps must I take to get
> my desired 192.168.0.199?
> 
> Additional note: When I used 192.168.0.40, which I KNOW is not in my
> leased DHCP range, the result was the same. What must I do to get a
> static IP at 192.168.0.199/24 ?


..many ways: https://duckduckgo.com/?q=Devuan+fixed+ip+on+dhcp&ia=web
or https://duckduckgo.com/?q=Devuan+static+ip+on+dhcp&ia=web all shows
various ways to set up your dhcp client to request a specific ip, or
have your dhcp server deliver a specific ip address to a specific mac
address on that dhcp client.  Etc.

..note that any of those servers or clients on your lan "may have"
caches or cached settings that you "may" wanna clean out. ;o)

..also, if you haven't set up ipv6, that too might mess up your lan.

..your problem looks quite a bit like:
https://unix.stackexchange.com/questions/85047/losing-static-ip-and-and-getting-dhcp-ip

..e.g. /etc/dhcpcd.conf from link above:
# /etc/dhcpcd.conf 
# to stop all my NICs from getting the DHCP address
# above any configured interface: (I am using 2 NICs 
# both set at eth0 and eth1)

denyinterfaces eth0 eth1

...and #: /etc/init.d/networking restart

..a neater way, once everything works ok:
https://www.linuxquestions.org/questions/linux-networking-3/alternating-between-dhcp-and-a-static-address-depending-on-availability-4175676466/


..the classic way, way down: https://tldp.org/HOWTO/DHCP/x74.html
at: 3.11. Alternative DHCP client (ISC dhclient):

...create a /etc/dhclient.conf file with this example configuration.

interface "eth0" {
  send dhcp-client-identifier 1:xx:xx:xx:xx:xx:xx;
  # send dhcp-lease-time 86400;
}

Here we assume that the ethernet interface is eth0. If not change
accordingly. Also replace xx:xx:xx:xx:xx with your ethernet address."

..classic serverside way: https://tldp.org/HOWTO/DHCP/x369.html where
you want: "You can also assign specific IP addresses based on clients
ethernet address e.g.

host haagen {
   hardware ethernet 08:00:2b:4c:59:23;
   fixed-address 192.168.1.222;
}

This will assign IP address 192.168.1.222 to a client with ethernet
address 08:00:2b:4c:59:23."

..nd, I found out why I found myself searching for "fixed", 
rather than "static." ;o)

-- 
..med vennlig hilsen = with Kind Regards from Arnt Karlsen
...with a number of polar bear hunters in his ancestry...
  Scenarios always come in sets of three: 
  best case, worst case, and just in case.
___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng


Re: [DNG] Refracta have a static IP

2021-07-14 Thread Hendrik Boom
On Tue, Jul 13, 2021 at 04:41:06PM -0400, Steve Litt wrote:
> Hi all,
> 
> I'm trying to make my new Chimera based Refracta have a static IP
> address at 192.168.0.199/24, in order that every other computer on the
> 192.168.0.0/24 subnet can easily access it, and so I can put it on my
> LAN DNS.
> 
> So I made my /etc/network/interfaces look like the following, which
> follows the guidelines of "man interfaces":
> 
> ===
> auto lo
> iface lo inet loopback
> 
> allow-hotplug eth0
> iface eth0 inet static
>   address 192.168.0.199
>   gateway 192.168.0.1
> ===
> 
> Unfortunately, instead of the IP address being 192.168.0.199, it's a
> DHCP supplied 192.168.0.204 . What additional steps must I take to get
> my desired 192.168.0.199?

Last tine I had this problem, I reconfigured the router to assign the 
desired IP number based on the 48-bit ethernet ID of the coputer's 
interface.

-- hendrik
> 
> Additional note: When I used 192.168.0.40, which I KNOW is not in my
> leased DHCP range, the result was the same. What must I do to get a
> static IP at 192.168.0.199/24 ?
> 
> Thanks,
> 
> SteveT
> 
> Steve Litt 
> Spring 2021 featured book: Troubleshooting Techniques of the Successful
> Technologist http://www.troubleshooters.com/techniques
> ___
> Dng mailing list
> Dng@lists.dyne.org
> https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng
___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng