![]() |
| Home > Computers and Hardware > |
FAQ: Sun Computer Administration Frequently Asked Questions |
Section 5 of 5 - Prev - Next
All sections - 1 - 2 - 3 - 4 - 5
Change the 129.137.11.255 number to the proper broadcast address
for your site and use the proper ethernet device as well.
Here is a program
ftp://ftp.ececs.uc.edu/pub/sun-faq/Source/netmask.c
that can be used to calculate your broadcast address.
You will have to set each interface's broadcast individually.
Or if you are not afraid to use adb you can use the following
script to turn on all 1's in the kernel and fix the problem once
and for all. This method fixes ifconfig so that its 'broadcast +'
option works properly; all 1's instead of all 0's. That way you don't
have to remember to change /etc/rc.local each time you change the
machine's IP address. Also, you don't have to set each interface's
broadcast individually.
#!/bin/sh
# Make sure that we're running as root or this is not going to work.
if id | grep "^uid=0(" >/dev/null 2>&1; then
:
else
echo Error: you must be superuser to run this program. 1>&2
exit 1
fi
OS=`uname`
OSREV=`uname -r`
if [ "$OS" != SunOS ]; then
echo Invalid OS: $OS
exit 1
fi
case "$OSREV" in
4*)
;;
*)
echo Invalid OSREV: $OSREV
exit 1
;;
esac
# This fixes the kernel in memory and on the disk.
adb -k -w /vmunix /dev/mem </dev/null
in_ifinit+0x1f0/W 0x92103fff
in_ifinit+0x1f0?W 0x92103fff
EOF
# Now reconfigure the interface(s).
ifconfig -a broadcast +
# This keeps the fix from being backed out should the kernel ever
# be rebuilt.
FILE=/sys/`arch -k`/OBJ/in.o
if [ ! -f ${FILE}.orig ]; then
cp -p ${FILE} ${FILE}.orig
fi
adb -w $FILE </dev/null
in_ifinit+0x1f0?W 0x92103fff
EOF
exit
Last Updated: Feb 5, 1997.
Section 5 of 5 - Prev - Next
All sections - 1 - 2 - 3 - 4 - 5
| Back to category Computers and Hardware - Use Smart Search |
| Home - Smart Search - About the project - Feedback |
© allanswers.org | Terms of use