Welcome to MacTalk Australia

the largest Australian community for Apple discussions and topics

Join the discussions, Register Now!
Results 1 to 9 of 9
  1. #1

    Default

    i've got a pppoe connection on the internal ethernet. the modem is connected to my switch. i have enabled internet sharing on the same internet ethernet interface. that's all working fine (to my surprise), but i'd like to be able to assign machines on my lan a static ip based on their mac address. is it possible to configure this on the mac with internet sharing? or do i have to set the static ip address on the client machine? i'd rather leave them on dhcp so they can connect to other networks when they go elsewhere.

    also, since enabling internet sharing, my terminal prompt has changed from "newton" (the name of my computer) to "l196156" (the host part of my pppoe connection in dns). how can i set it back to "newton"?

  2. #2

    Join Date
    Feb 2004
    Posts
    9,050

    Default

    Here's the trick: you can set, in network preferences, different preferences for different locations. When the machines go elsewhere, you just change via the menu which location you are at. That'll save you having to manually change all the settings each time.

    The answer, though, to your actual question is "not without a commercial server".
    The discussion has continued at AppleTalk Australia.

  3. #3

    Default

    that's a trick on the client. i don't wanna set anything on the client. it's annoying having to maintain configurations on multiple machines but i guess this is ok. i don't really need static ip's on the lan clients, as long as i can still refer to them by their name for windows file sharing etc.

  4. #4

    Default

    If you dig into mac os x underbelly im sure its possible with the power of open source
    Mac Pro Dual Xeon 2.8GHz Quad, 6GB Ram, 128GB SSD+320GB+3x1TB HDD, Nvidia GTX285, Mac OS X 10.7
    My Flickr | Portfolio/Photoblog

  5. #5

    Default

    You want a feature called "Static Maps", which is built into OS X Server.
    I'm pretty sure this functionality isn't built into regular OS X.

    You could try something like dnsmasq, which is a DNS server that supports static DHCP leases.

    You might also be able to find certain hardware routers that can do this natively.

  6. #6

    Default

    Try this:

    http://www.faisal.com/software/DHCP-3.0.readme.html

    It's fairly trivial to set up a DHCP server on Linux, and I doubt that much differs on a BSD variant like OS X.

  7. #7

    Join Date
    Oct 2005
    Location
    Wollongong
    Posts
    1,053

    Default

    Originally posted by mrmachine@Nov 12 2005, 07:57 PM
    also, since enabling internet sharing, my terminal prompt has changed from "newton" (the name of my computer) to "l196156" (the host part of my pppoe connection in dns). how can i set it back to "newton"?
    You should be able to set your terminal prompt using the PS1="variables go here" command. Some of the variables you could use are:
    \w current working dir
    \h short host name
    \u your username
    \$ A $ if you are not root, otherwise you get a #

    any changes you make will only be effective in that terminal session, so you will want to edit (or create if you don't have one) a file called ".profile" and add the line

    PS1="\h:\w \u \$ " (for example, this should give you back the original terminal prompt)

    If your hostname has changed then you will want to edit /etc/hostconfig and add a line saying HOSTNAME=newton.local or if you don't want to set that back then you could use
    PS1="newton:\w \u \$"
    Macs: MBP 13" C2D 2.23GHz

  8. #8

    Join Date
    Oct 2005
    Location
    Wollongong
    Posts
    1,053

    Default

    oops, forgot that you can change the hostname in system preferences too, under sharing! Much easier!
    Macs: MBP 13" C2D 2.23GHz

  9. #9

    Default

    thanks bljpoad. i'm familiar with all of that. i have already set my prompt to include \h, which is why it changed in the first place. the host is still set correctly in sharing, but \h takes the en0 interface's host which comes from a reverse dns lookup on the ip assigned by my isp. i fixed the problem with:

    sudo hostname newton

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •