Solved

setting static IPs via commandline

Posted on 2004-09-22
3
310 Views
Last Modified: 2013-11-13
I have a mac osx powermac on my network that I access via commandline only.  Right now, its getting its address via DHCP...   I plan to restrict the range that my router assigns DHCP to, and give the mac a static ip outside of that range.  Once its static, I dont have to worry that my shell scripts are pushing to the wrong ip!  Does anyone know how I can change network settings via command line?

-meue
0
Comment
Question by:meuedyn
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 30

Accepted Solution

by:
weed earned 500 total points
ID: 12128241
0
 

Expert Comment

by:dobbyduck
ID: 12129459

Telnet or SSH to the OS X machine and use ifconfig (man ifconfig) to configure the ip addresses.
You must be root. (enable in netinfo).
> ifconfig en0 192.168.1.66
this will change the ip of your machine to 192.168.1.66. You can also add the subnet mask and broadcast mask if required.

Dobby.
0
 
LVL 30

Expert Comment

by:weed
ID: 12129756
That's what the link I just posted says...
0

Featured Post

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

A common question or need, when setting-up a new Mac for someone would be to make all of the applications, installed, available from the dock. Many people often do not realize an application is installed unless it is in the dock. Creating a custo…
In this article we have discussed about the OS X EI Capitan and how to fix Wi-Fi issue in OS X El Capitan. We have explained how to delete system level preferences and create a new Wi-Fi location to resolve Wi-Fi issue.
Michael from AdRem Software outlines event notifications and Automatic Corrective Actions in network monitoring. Automatic Corrective Actions are scripts, which can automatically run upon discovery of a certain undesirable condition in your network.…
If you’ve ever visited a web page and noticed a cool font that you really liked the look of, but couldn’t figure out which font it was so that you could use it for your own work, then this video is for you! In this Micro Tutorial, you'll learn yo…

724 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question