Scheduled Maintenance: We are aware of an issue with Google, AOL, and Yahoo services as email providers which are blocking new registrations. We are trying to fix the issue and we have several internal and external support tickets in process to resolve the issue. Please see: viewtopic.php?t=158230

 

 

 

ifconfig not showing subinterfaces

Linux Kernel, Network, and Services configuration.
Post Reply
Message
Author
wnichols
Posts: 2
Joined: 2018-02-01 20:08

ifconfig not showing subinterfaces

#1 Post by wnichols »

I am currently on Debian Stretch. During installation I configured an IP via the install wizard and this works fine. When I run "ifconfig -a" I see the IP and I can connect to services listening on it.

I added a second IP to the same NIC via /etc/network/interfaces file. I basically copied the syntax of the existing entry and duplicated it to fit my needs. After restarting networking services the IP answers and can be used but it is not visible via "IFCONFIG -A" BUT is visible via "ip address list"

auto ens192:0
allow-hotplug ens192:0
iface ens192 inet statuc
address theIP
gateway theGateway

Is there any way to get this interface to show up when using the command ifconfig -a?

User avatar
bw123
Posts: 4015
Joined: 2011-05-09 06:02
Has thanked: 1 time
Been thanked: 28 times

Re: ifconfig not showing subinterfaces

#2 Post by bw123 »

Is there any way to get this interface to show up when using the command ifconfig -a?
Why does it need to show up in ifconfig?
/usr/share/doc/ifupdown/examples/network-interfaces.gz

# Multiple addresses can be added by simply using multiple iface stanzas.
# This also allows you to add both IPv4 and IPv6 addresses to the same
# interface:
#
# auto eth0
# iface eth0 inet static
# address 192.168.0.42/24
# gateway 192.168.0.1
# iface eth0 inet static
# address 172.16.0.1/24
resigned by AI ChatGPT

User avatar
Thorny
Posts: 542
Joined: 2011-02-27 13:40

Re: ifconfig not showing subinterfaces

#3 Post by Thorny »

I am a bit confused by your post, wnichols.
According to the release notes for Stretch:
5.3.9. net-tools will be deprecated in favor of iproute2

The net-tools package is no longer part of new installations by default, since its priority has been lowered from important to optional. Users are instead advised to use the modern iproute2 toolset (which has been part of new installs for several releases already). ...
ifconfig is from the net-tools package.

wnichols
Posts: 2
Joined: 2018-02-01 20:08

Re: ifconfig not showing subinterfaces

#4 Post by wnichols »

Thorny wrote:I am a bit confused by your post, wnichols.
According to the release notes for Stretch:
5.3.9. net-tools will be deprecated in favor of iproute2

The net-tools package is no longer part of new installations by default, since its priority has been lowered from important to optional. Users are instead advised to use the modern iproute2 toolset (which has been part of new installs for several releases already). ...
ifconfig is from the net-tools package.
Thanks Thorny. I'll look into this. I've used ifconfig for so long I wanted to try and keep using it if I could which is why I asked.

Post Reply