Ifconfig Command Not Found

ifconfig command not found

ifconfig exists in the net-tools package which may not be installed by default;

sudo yum install net-tools

When the package is installed, it will exist as /sbin/ifconfig.

Why “ifconfig” docker command responds bash: ifconfig: command not found on Windows?

Finding current TCP/IP network configuration values doesn't have nothing to do with docker, those applications coming with your os.

  • for windows ipconfig -> wiki
  • for mac ifconfig -> wiki
  • for linux use ip related commands for ex: to get the ip address ip
    addr show

NOTE: in linux ifconfig might work but its deprecated.

more about ifconfig vs ip you can read in this blog

How to install ifconfig command in my ubuntu docker image?

On a fresh ubuntu docker image, run

apt-get update
apt-get install net-tools

These can be executed by logging into the docker container or add this to your dockerfile to build an image with the same.

Command not found in ifconfig | grep IF statement

Looks like you've used apostrophe instead of backtick characters:

` and ' are different

How to add data to an element with ActiveState's dom package

I believe you want the ::dom::document createTextNode command. For example:

::dom::document createTextNode $statElement "some data"

When I add this command to your sample script:

set xmlDoc [::dom::create]
set root [::dom::document createElement $xmlDoc "trafficStatistics"]

set statElement [::dom::document createElement $root "Tx_Frames"]
::dom::element setAttribute $statElement "type" "numericlist"
::dom::element setAttribute $statElement "displayName" "Tx Frames"
::dom::document createTextNode $statElement "some data"

It produces this XML:

<trafficStatistics>
<Tx_Frames type="numericlist" displayName="Tx Frames">some data</Tx_Frames>
</trafficStatistics>

You can find documentation for the dom package here:

http://docs.activestate.com/activetcl/8.5/tcldom/index.html

Hope that helps,

Eric Melski

List all IP's using the command ip and not ifconfig

Please, try this command

hostname -I

How to find particular interface name and status from ifconfig command?

Since you have the interface name, you can do the following:

$ ifconfig interface-name &> /dev/null
$ echo $?

If the output is 0, the interface exists, otherwise, it doesn't.



Related Topics



Leave a reply



Submit