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


Groups > linux.debian.user > #246615

Re: Under each of these scenarios, what is the neatest and simplest way to manipulate the /etc/network/interfaces file?

From Stella Ashburne <rewefie@gmx.com>
Newsgroups linux.debian.user
Subject Re: Under each of these scenarios, what is the neatest and simplest way to manipulate the /etc/network/interfaces file?
Date 2022-03-25 07:40 +0100
Message-ID <E4LM5-42zk-3@gated-at.bofh.it> (permalink)
References <E2wRb-2GzG-1@gated-at.bofh.it> <E34SR-313u-3@gated-at.bofh.it> <E4leV-3MmI-1@gated-at.bofh.it> <E4HIt-404a-3@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


Mon cheri

> Sent: Friday, March 25, 2022 at 10:09 AM
> From: "David Wright" <deblis@lionunicorn.co.uk>
> To: debian-user@lists.debian.org
> Subject: Re: Under each of these scenarios, what is the neatest and simplest way to manipulate the /etc/network/interfaces file?
>
> Please elaborate on what you mean by "correct" in this context,
> and also give your opinion on the correctness or otherwise of
> this line:
>
>   source-directory /etc/network/interfaces.d
>
> Without knowing the reasoning behind your statement, there's
> not a lot more help I can give.
>

My distro is Debian 11

Attempt #1

When the /etc/network/interfaces file has the line

source-directory /etc/network/interfaces.d/*

and the following three files have the .hidden in /etc/network/interfaces.d/

lan.hidden
usb0.hidden
wlo1.hidden

Upon reboot and in a terminal:

username@hostname:~$ 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
2: wlo1: <BROADCAST,MULTICAST> mtu 1500 qdisc noop state DOWN group default qlen 1000
    link/ether e5:d3:a2:b9:c3:27 brd ff:ff:ff:ff:ff:ff
    altname wln0s7
username@hostname:~$ sudo ifup wlo1.hidden
[sudo] password for username:
ifup: unknown interface wlo1.hidden
username@hostname:~$ sudo ifup wlo1
ifup: unknown interface wlo1
username@hostname:~$


Attempt #2

When the /etc/network/interfaces file has the line

source-directory /etc/network/interfaces.d/*

and the following three files do NOT have the .hidden in /etc/network/interfaces.d/

lan
usb0
wlo1

Upon reboot and in a terminal:

username@hostname:~$ 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
2: wlo1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc noqueue state UP group default qlen 1000
    link/ether e5:d3:a2:b9:c3:27 brd ff:ff:ff:ff:ff:ff
    altname wln0s7
    inet 192.168.43.51/24 brd 192.168.43.255 scope global dynamic wlo1
       valid_lft 3576sec preferred_lft 3576sec
username@hostname:~$


Best wishes.

Stella

Back to linux.debian.user | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread


Thread

Under each of these scenarios, what is the neatest and simplest way  to manipulate the /etc/network/interfaces file? Stella Ashburne <rewefie@gmx.com> - 2022-03-19 03:20 +0100
  Re: Under each of these scenarios, what is the neatest and simplest  way to manipulate the /etc/network/interfaces file? Tim Woodall <debianuser@woodall.me.uk> - 2022-03-19 08:20 +0100
    Re: Under each of these scenarios, what is the neatest and simplest  way to manipulate the /etc/network/interfaces file? Stella Ashburne <rewefie@gmx.com> - 2022-03-19 13:10 +0100
  Re: Under each of these scenarios, what is the neatest and simplest  way to manipulate the /etc/network/interfaces file? Eduardo M KALINOWSKI <eduardo@kalinowski.com.br> - 2022-03-19 12:20 +0100
    Re: Under each of these scenarios, what is the neatest and simplest  way to manipulate the /etc/network/interfaces file? Stella Ashburne <rewefie@gmx.com> - 2022-03-19 13:10 +0100
      Re: Under each of these scenarios, what is the neatest and simplest  way to manipulate the /etc/network/interfaces file? Eduardo M KALINOWSKI <eduardo@kalinowski.com.br> - 2022-03-19 13:30 +0100
        Re: Under each of these scenarios, what is the neatest and simplest  way to manipulate the /etc/network/interfaces file? "hdv@gmail" <hdv.jadev@gmail.com> - 2022-03-19 13:30 +0100
  Re: Under each of these scenarios, what is the neatest and simplest  way to manipulate the /etc/network/interfaces file? David Wright <deblis@lionunicorn.co.uk> - 2022-03-20 15:40 +0100
    Re: Under each of these scenarios, what is the neatest and simplest  way to manipulate the /etc/network/interfaces file? Tim Woodall <debianuser@woodall.me.uk> - 2022-03-21 07:10 +0100
      Re: Under each of these scenarios, what is the neatest and simplest  way to manipulate the /etc/network/interfaces file? David Wright <deblis@lionunicorn.co.uk> - 2022-03-22 03:00 +0100
    Re: Under each of these scenarios, what is the neatest and simplest  way to manipulate the /etc/network/interfaces file? Stella Ashburne <rewefie@gmx.com> - 2022-03-23 13:40 +0100
      Re: Under each of these scenarios, what is the neatest and simplest  way to manipulate the /etc/network/interfaces file? David Wright <deblis@lionunicorn.co.uk> - 2022-03-23 16:30 +0100
    Re: Under each of these scenarios, what is the neatest and simplest  way to manipulate the /etc/network/interfaces file? Stella Ashburne <rewefie@gmx.com> - 2022-03-24 03:20 +0100
      Re: Under each of these scenarios, what is the neatest and simplest  way to manipulate the /etc/network/interfaces file? David Wright <deblis@lionunicorn.co.uk> - 2022-03-25 03:20 +0100
        Re: Under each of these scenarios, what is the neatest and simplest  way to manipulate the /etc/network/interfaces file? Stella Ashburne <rewefie@gmx.com> - 2022-03-25 07:40 +0100
          Re: Under each of these scenarios, what is the neatest and simplest  way to manipulate the /etc/network/interfaces file? David Wright <deblis@lionunicorn.co.uk> - 2022-03-26 05:50 +0100
            Re: Under each of these scenarios, what is the neatest and simplest  way to manipulate the /etc/network/interfaces file? Curt <curty@free.fr> - 2022-03-26 10:20 +0100
            Re: Under each of these scenarios, what is the neatest and simplest  way to manipulate the /etc/network/interfaces file? Greg Wooledge <greg@wooledge.org> - 2022-03-26 13:50 +0100
              Re: Under each of these scenarios, what is the neatest and simplest  way to manipulate the /etc/network/interfaces file? David <bouncingcats@gmail.com> - 2022-03-27 01:10 +0100
              Re: Under each of these scenarios, what is the neatest and simplest  way to manipulate the /etc/network/interfaces file? Andy Smith <andy@strugglers.net> - 2022-03-27 04:30 +0200

csiph-web