ipconfig

How should this situation be resolved?

MacBook Pro 13″, macOS 13.0

Posted on Oct 26, 2022 7:50 AM

Reply
Question marked as Top-ranking reply

Posted on Oct 26, 2022 9:05 AM

You need to give it a specific interface and request the ip as shown above.


ipconfig getifaddr <interfacename>


You can verify the available interfaces by using the ipconfig getiflist command.


Normally en0 is the main interface, either wi-fi or ethernet. So ipconfig getifaddr en0 should provide the IP address.




8 replies
Question marked as Top-ranking reply

Oct 26, 2022 9:05 AM in response to JokerQian

You need to give it a specific interface and request the ip as shown above.


ipconfig getifaddr <interfacename>


You can verify the available interfaces by using the ipconfig getiflist command.


Normally en0 is the main interface, either wi-fi or ethernet. So ipconfig getifaddr en0 should provide the IP address.




Oct 26, 2022 11:50 AM in response to JokerQian

JokerQian wrote:

Before, ipconfig could see the IP address directly, but now can not see the ip address directly


You're probably remembering ifconfig here, and not ipconfig command. (What you see here is what ipconfig has long done.)


systemsetup and networksetup and airport and networkQuality are some other commands in this same general area, as well.

Oct 26, 2022 8:10 AM in response to JokerQian

What situation? Resolve what?


It's telling you it expects some command or argument. There's nothing to resolve beyond providing a correct command and argument.


What are you trying to accomplish?


You can type: ipconfig getiflist

to get the list of interfaces.


Or you can type ipconfig getifaddr <interfacename> to get the IP address of a specific interface.

This thread has been closed by the system or the community team. You may vote for any posts you find helpful, or search the Community for additional answers.

ipconfig

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple Account.