Does ifconfig the same across all Unix-like OS?

Status
Not open for further replies.

balanga

Son of Beastie

Reaction score: 148
Messages: 3,146

I noticed on some newer Linux distros that they no longer use ifconfig!!! I think ip has replaced it.

Looking at FreeBSD's ifconfig() makes you realise just how powerfull/feature rich it is. Makes you wonder if anyone uses more than 5% of its capability
 
OP
OP
B

badbrain

Guest


I noticed on some newer Linux distros that they no longer use ifconfig!!! I think ip has replaced it.

Looking at FreeBSD's ifconfig() makes you realise just how powerfull/feature rich it is. Makes you wonder if anyone uses more than 5% of its capability
I think they're both available. But the newer ip is recommended.
 
OP
OP
B

badbrain

Guest


system-d distro's use ip a and all that jazz.
Devuan uses ifconfig and their sysV init is very similar to ours.
Almost forgot, MX Linux is also based on Devuan. It's the reason why I've both ifconfig and ip available :)
 

recluce

Active Member

Reaction score: 29
Messages: 146

Again shows the grubby tentacles of systemd everywhere in the OS with most Linux distros. I do not want my init to take over my network stack!

Other non-systemd options would include Gentoo (optional) and Artix (based on Arch). These would use ifconfig.
 

moridin

Member

Reaction score: 24
Messages: 34

`ifconfig` syntax is pretty much the same everywhere, it's the keywords that make the difference, but basic usage stays the same, e.g. ifconfig if0 inet ... up.

What *is* interesting in other implementations is the difference between (data)link and (IP) interface, more visible in Solaris (dladm/ipadm), less visible in Linux (why is it called 'ip' if it's not about ip only).
 

SirDice

Administrator
Staff member
Administrator
Moderator

Reaction score: 8,050
Messages: 31,632

but basic usage stays the same
Unless it's a wireless interface, then you need to use iwconfig. Or a bridge and need to use brconfig. Need VLANs? Then you need yet another command. It drove me bonkers, they're all network interfaces for crying out loud.

I love the fact that any type of network interface is configured using the same ifconfig(8) command on FreeBSD.
 

moridin

Member

Reaction score: 24
Messages: 34

Unless it's a wireless interface, then you need to use iwconfig. Or a bridge and need to use brconfig. Need VLANs? Then you need yet another command. It drove me bonkers, they're all network interfaces for crying out loud.
That's Linux, I presume (not really familiar with it)? In Solaris, I'd just use dladm to do all the *datalink* configuration (and I like the distinction).
 

SirDice

Administrator
Staff member
Administrator
Moderator

Reaction score: 8,050
Messages: 31,632

I presume ifconfig just matches better with the Solaris kernel because, like FreeBSD, it's a complete OS. So the userland tools are perfectly matched with the kernel and its capabilities. With Linux there's a kernel, period. And you need a bunch of tools from other projects to make it work. Because they're separate projects the tools and the kernel never quite match up.
 

CraigHB

Well-Known Member

Reaction score: 87
Messages: 295

Because they're separate projects the tools and the kernel never quite match up.
That's one of the main reasons I really like FreeBSD over other systems. Things are a lot more seamless the way FreeBSD is developed. I think it's one of the big failings of a purely "bazaar" model.
 
OP
OP
B

badbrain

Guest


It's just the name is the same. Their arguments are completely different.
 
OP
OP
B

badbrain

Guest


That's one of the main reasons I really like FreeBSD over other systems. Things are a lot more seamless the way FreeBSD is developed. I think it's one of the big failings of a purely "bazaar" model.
I like Linux over FreeBSD. Because there's no base nor ports. Packages will use the openssl from the openssl package but not the openssl of the system. Get rid of a lot of problems.
 

kpedersen

Daemon

Reaction score: 585
Messages: 1,518

I like Linux over FreeBSD. Because there's no base nor ports.
You might want to check out Linux Standard Base
https://refspecs.linuxfoundation.org/lsb.shtml

More enterprise facing Linux distros very much adhere to this. For everything else (Even the big ones like Debian and Fedora), Linux is basically a free for all.

It kind of reminds me of playing with Raspbian Linux on the Raspberry Pi. Was the static IP address set it /etc/network/interfaces (Debian style)? Nope. Was it set in /etc/systemd/network (systemd style)? Nope.
It was set seemingly bizarrely in /etc/dhcpcd.conf. Yes the configuration file of a DHCP client... This is IMO unsuitable for its prime purpose of teaching kids about technology.
So I uninstalled much of the crap; added ifconfig and sys-v scripts and set it in rc.local and got on with my life.

As for ports; many Linux distributions do favour the ports approach (Gentoo, Arch). Also if you have ever had to package an .rpm or a .deb, it is nowhere near as elegant or as automated.
 
Status
Not open for further replies.
Top