Hello, I have tried compiling Unbound V1.6.0 --with-pythonmodule on Ubuntu 16.04 and CentOS7 and after a few days I haven't got it working yet!
If I install the version that comes from the package managers in Ubuntu (1.5.8) then that works without issue. When I build the python module in version 1.6.0 it creates the module, but then when I run unbound it can't find it. [1486464444] unbound[22131:0] notice: Start of unbound 1.6.0. [1486464444] unbound[22131:0] warning: did not exit gracefully last time (21788) Could not find platform independent libraries <prefix> Could not find platform dependent libraries <exec_prefix> Consider setting $PYTHONHOME to <prefix>[:<exec_prefix>] Traceback (most recent call last): File "<string>", line 1, in <module> ImportError: No module named distutils.sysconfig Traceback (most recent call last): File "<string>", line 1, in <module> NameError: name 'distutils' is not defined Traceback (most recent call last): File "<string>", line 1, in <module> ImportError: No module named unboundmodule I have tried various fixes including specifying the paths in the config, and trying with python 3.5 instead of 2.7 but I keep getting the same issue. I also made a symbolic link to the file in tot he unbound folder, but that still showed the same error. I've asked the same here: http://askubuntu.com/questions/880749/cant-install-unbound-dns-server-with-pythonmodule I am willing to pay for someone to have a look at my server. All I need is server running Ubuntu with Unbound v 1.6.0 working with the python module. Happy to pay an hourly rate or just pay a fixed amount if I could get some help! I've built a large App that depends on this, and 5.8 was working perfectly. I've tried: ./configure --with-pythonmodule and various mixture ending in ./configure --prefix=/usr --sysconfdir=/etc --disable-static --with-pythonmodule --with-pyunbound --with-pidfile=/run/unbound.pid PYTHON_LDFLAGS="-lpython2.7" PYTHON_VERSION="2.7" They all show the same error that the module can't be found. I did get a version working when targeting 3.5, but then it looks like the module has an issue with encoding between C and Python. I've submitted a bug about that one which shows the error: File "/opt/arkdns/arkdns/__init__.py", line 85, in operate name = qstate.qinfo.qname_str File "/usr/lib/python3/dist-packages/unboundmodule.py", line 132, in _get_qname_str def _get_qname_str(self): return dnameAsStr(self.qname) TypeError: in method 'dnameAsStr', argument 1 of type 'char const *' I'm presuming the 2.7 issue is just something to do with my ./configure for Ubuntu? Kind Regards, Matt
