Thanks,  good to know.
btw, I use the following POSIX shell function (IPv4, or course):

    ip2hex () { printf "%.2X%.2X%.2X%.2X\n" $( echo ${1:-$(hostname -i)} |
tr '.' ' ') ;}

ip2hex w/o argument gets you the current machine's hex format IP, 'ip2hex
IPADDR' converts an ipaddress to hex format

    ip2hex_le() { ip2hex ${1:?Must Specify an IP Address} | sed -e
's/\(..\)\(..\)\(..\)\(..\)/\2\1\4\3/'  ;}

gets you little-endian format (forget why i needed that)


--stephen

On Tue, Dec 8, 2015 at 10:12 AM, John G Heim <jh...@math.wisc.edu> wrote:

> I just discovered that the syslinux-utils package has a tool called
> gethostip that displays the PXE file name for a host name. So for example,
> if you want to figure out the PXE config file name for a workstation named
> "nitschke", you'd say, "gethostip nitschke". Sample output:
>
> # gethostip nitschke
> nitschke.example.com 192.168.0.66 C0A80042
> I know fai-chboot also determines the pxelinux.cfg file name but I would
> imagine that others do what I do -- once you get one working config file,
> copy it for the other machines you want to do installs on.
>
>


-- 
Stephen Dowdy  -  Systems Administrator  -  NCAR/RAL
303.497.2869   -  sdo...@ucar.edu        -  http://www.ral.ucar.edu/~sdowdy/
  • tip: John G Heim
    • Re: tip: Stephen Dowdy

Reply via email to