#! /bin/sh

  PATH=$PATH:/usr/sbin

  date > /tmp/jurgen_$$
  echo " " >> /tmp/jurgen_$$

  echo "======================================" >> /tmp/jurgen_$$
  echo set type=NS >> /tmp/jurgen_$$
  echo ifisica.uaslp.mx >> /tmp/jurgen_$$
  echo set type=MX >> /tmp/jurgen_$$
  echo ifisica.uaslp.mx >> /tmp/jurgen_$$
  nslookup <<EOF >> /tmp/jurgen_$$ 2>&1
set type=NS
ifisica.uaslp.mx
set type=MX
ifisica.uaslp.mx
exit
EOF

  echo " " >> /tmp/jurgen_$$
  echo "======================================" >> /tmp/jurgen_$$
  echo set type=SOA >> /tmp/jurgen_$$
  echo server dns1.avantel.net.mx >> /tmp/jurgen_$$
  echo uaslp.mx >> /tmp/jurgen_$$
  echo ifisica.uaslp.mx >> /tmp/jurgen_$$
  echo ls -d uaslp.mx >> /tmp/jurgen_$$
  nslookup <<EOF >> /tmp/jurgen_$$ 2>&1
set type=SOA
server dns1.avantel.net.mx
uaslp.mx
ifisica.uaslp.mx
ls -d uaslp.mx
exit
EOF

  echo " " >> /tmp/jurgen_$$
  echo "======================================" >> /tmp/jurgen_$$ 
  echo set type=SOA >> /tmp/jurgen_$$
  echo server dec1.ifisica.uaslp.mx >> /tmp/jurgen_$$
  echo ifisica.uaslp.mx >> /tmp/jurgen_$$
  nslookup <<EOF >> /tmp/jurgen_$$ 2>&1
set type=SOA
server dec1.ifisica.uaslp.mx
ifisica.uaslp.mx
exit
EOF

  echo " " >> /tmp/jurgen_$$
  echo "======================================" >> /tmp/jurgen_$$
  echo set type=SOA >> /tmp/jurgen_$$
  echo server deimos.tc.uaslp.mx >> /tmp/jurgen_$$
  echo uaslp.mx >> /tmp/jurgen_$$
  echo ls -d uaslp.mx >> /tmp/jurgen_$$
  nslookup <<EOF >> /tmp/jurgen_$$ 2>&1
set type=SOA
server deimos.tc.uaslp.mx
uaslp.mx
ls -d uaslp.mx
exit
EOF

  echo " " >> /tmp/jurgen_$$
  echo "======================================" >> /tmp/jurgen_$$ 
  echo set type=SOA >> /tmp/jurgen_$$
  echo server minnie.ec.uaslp.mx >> /tmp/jurgen_$$
  echo uaslp.mx >> /tmp/jurgen_$$ 
  echo ls -d uaslp.mx>> /tmp/jurgen_$$
  nslookup <<EOF >> /tmp/jurgen_$$ 2>&1
set type=SOA
server minnie.ec.uaslp.mx
uaslp.mx
ls -d uaslp.mx
exit
EOF

  echo " " >> /tmp/jurgen_$$
  echo "======================================" >> /tmp/jurgen_$$ 
  echo " " >> /tmp/jurgen_$$
  date >> /tmp/jurgen_$$
  /usr/sbin/Mail -s check_dns adolfo@ifisica.uaslp.mx,jsl@ifisica.uaslp.mx,jurgen,limon@ifisica.uaslp.mx,renteria@ifisica.uaslp.mx < /tmp/jurgen_$$

  rm /tmp/jurgen_$$

  exit