Wednesday, February 25, 2015

Re:

A failure in name resolution indicates a DNS query failure.

From the machine where the script is failing, can you run 'ping portal' and/or 'nslookup portal' and see if an IP is returned (even if the ping fails)? Are the failures occurring in the view on the same machine (and virtual environment if applicable)?

Is 'portal' a static host entry (/etc/hosts on Linux)?

Does using the IP of the server instead of the name work? (it should unless your code validates SSL certificates and you don't have the IP as the CN or SAN or it is a self-signed certificate)

Does using the fully qualified name (ie portal.example.com) work?

As an aside, what version/fork of the suds library are you using? I would recommend against the regular suds library and instead using the suds-jurko package, also available via PyPi. It should be a drop-in replacement (almost literally, same imports and everything, so be sure to uninstall the old library), and has many bug fixes and optimizations. It is a fork of the original, since the original hasn't seen an update for close to five years. The fork fixed several WSDL consumption issues I encountered with the original.

https://bitbucket.org/jurko/suds

-James

I use below code to authenticate in SharePoint in my view:

import suds  import logging    logging.basicConfig(level=logging.INFO)  logging.getLogger('suds.client').setLevel(logging.DEBUG)    from suds.client import Client    url = 'http://portal:8080/rashno/_vti_bin/lists.asmx?WSDL'    from suds.transport.https import WindowsHttpAuthenticated    ntlm = WindowsHttpAuthenticated(username='***', password='***')  client = Client(url, transport=ntlm)

But i got this error:

<urlopen error [Errno -3] Temporary failure in name resolution>

but when do this with python shell , it authenticate me in sharepoint and after that i can use other sharepoint service with view or shell. can any one tell me whats the problem?

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/4425ae16-2624-40ae-aac3-bf687b0f0d1e%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/CA%2Be%2BciUL0-2EoU4witasarmMzbXGDX1Z9t%3Dqh0KoimZOTGy2MQ%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

No comments:

Post a Comment