Guest User!

You are not Sophos Staff.

This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

DNS Group not working?

We are on UTM 9.201-23

I created a DNS Group, mail.otpnet.nl, but it keeps telling me it's [unresolved].
So I go to Support.Tools.DNS Lookup.

Now when I enter mail.otpnet.nl it's resolvable and returns a couple of IP's.
But the DNS group stays [unresolved].

Is this a bug or what am I doning wrong?

Scubaticus-Scecond.


This thread was automatically locked due to age.
  • Not for the faint of heart, either to look at or run on a UTM.

    The following mess, for the command line, is intended to update the MX records for $MX (mail.otpnet.nl) and assign the relevant DNS Hosts (creating them along the way, if needed) to the Network Group $MXGROUPREF (REF_NetGroOtpnTest1 - the group must already exist, not generated here).  It does not delete any REFs but will remove REFs from $MXGROUPREF.

    Not well tested, no error handling, no data checks, no promises, no warranty, no support, etc.

    MX=mail.otpnet.nl;MXGROUPREF=REF_NetGroOtpneTest1;unset MXREFLIST;MXHOSTS=$(dig +short mx $MX | cut -f 2 -d \ ); for MXHOST in $MXHOSTS ; do OUTPUT1=$(cc get_objects_filtered \$_-\>{data}-\>{name}\ eq\ \"$MXHOST\"); if [ "$OUTPUT1" = '[]' ] ; then cc set_object \{\"class\"\=\>\"network\",\"type\"\=\>\"dns_host\",\"data\"\=\>{\"name\"\=\>\"$DNSNAME\",\"resolved\"\=\>\"0\",\"hostname\"\=\>\"$MXHOST\",\"resolved6\"\=\>\"0\",\"address6\"\=\>\"::\",\"comment\"\=\>\"\",\"timeout\"\=\>\"180\",\"interface\"\=\>\"\",\"address\"\=\>\"0.0.0.0\"\}\} ; fi ; MXREFLIST+=$(cc get_objects_filtered \$_-\>{data}-\>{name}\ eq\ \"$MXHOST\" | grep \'ref\'\ \=\>\ \'REF_ | sed -e s/^.*\ \'//g -e s/\',/\ /g) ; done ; echo -e "RAW\nchange_object('$MXGROUPREF','members',["$(echo $MXREFLIST | sed -e s/^/\'/ -e s/\ /\',\ \'/g -e s/\$/\'/)"])" | cc -batch


    How would this be done without the cc -batch?  I'd rather use something like "cc change_object REF... but I couldn't sort it out within the timeframe my patience allowed.  REFs were checked (get_objects_filtered) by name and not hostname because it generated fewer logs.
  • I need to route requests for mail.otp group to another remote sophos device (so I can instruct PandoraFMS to check if a mail server is accepting mail). Only this remote device has access to the hosts defined in the mail.otp group over a VPN tunnel. Request outside this VPN are not honored.
     

    This sounds like an interesting problem, but I'm a visual-tactile learner, and I can't draw a picture of what you're trying to accomplish. Also I don't understand why the UTM is insufficient and that PandoraFMS is required.   

    Cheers - Bob  

    Sorry for any short responses.  Posted from my iPhone.
     
    Sophos UTM Community Moderator
    Sophos Certified Architect - UTM
    Sophos Certified Engineer - XG
    Gold Solution Partner since 2005
    MediaSoft, Inc. USA
Share Feedback
×

Submitted a Tech Support Case lately from the Support Portal?