jethrocarr / namedmanager

AGPL web-based DNS management interface in PHP
349 stars 126 forks source link

no XML document from API #41

Closed gregnetau closed 7 years ago

gregnetau commented 7 years ago

Hi,

I am trying to get NamedManager working on Gentoo.

I have 3 servers - 2 running bind and one Webserver. The WEBUI is running fine, however when i run

php -q /usr/share/namedmanager/bind/namedmanager_bind_configwriter.php

I get the following output:

Error: Unknown failure whilst attempting to authenticate with the API - looks like we got no XML document Fatal Error

I have searched for any references to this but I am out of luck.

jethrocarr commented 7 years ago

Sounds like incorrect configuration and it's hitting the wrong URL for the API.

gregnetau commented 7 years ago

Hi,

I did a TCPdump on the request and found this:

.xI....KHTTP/1.1 200 OK Server: nginx Date: Sun, 29 Jan 2017 04:05:15 GMT Content-Type: text/html; charset=UTF-8 Transfer-Encoding: chunked Connection: keep-alive Keep-Alive: timeout=5 Vary: Accept-Encoding

49e
Deprecated: Automatically populating $HTTP_RAW_POST_DATA is deprecated and will be removed in a future version. To avoid this warning set 'always_populate_raw_post_data' to '-1' in php.ini and use the php://input stream instead. in Unknown on line 0

Warning: session_start(): Cannot send session cookie - headers already sent in /var/www/localhost/htdocs/named-manager/include/config.php on line 54

Warning: session_start(): Cannot send session cache limiter - headers already sent in /var/www/localhost/htdocs/named-manager/include/config.php on line 54

Line 50-55 of config.php is the following:

if (isset($_SERVER['SERVER_NAME'])) { // proper session variables session_name("namedmanager"); session_start(); } else { // trick to make logging and error system work correctly for scripts. $GLOBALS["_SESSION"] = array(); $_SESSION["mode"] = "cli"; }

gregnetau commented 7 years ago

Ok the first hint was fixing the PHP.ini. Now resolved

hylitjob commented 7 years ago

[root@localhost lib]# /usr/local/php/bin/php /usr/local/download/namedmanager/bind/namedmanager_bind_configwriter.php Error: Unknown failure whilst attempting to authenticate with the API - Internal Server Error

hylitjob commented 7 years ago

I got this issue too, how to solve it, Thanks!

svalavuo commented 6 years ago

php -q /usr/share/namedmanager/bind/namedmanager_bind_configwriter.php "Error: Unknown failure whilst attempting to authenticate with the API - Internal Server Error" for me too. How to fix this? Server has php 5.4.16 (namedmanager) Client1 has php 5.3.3 Client2 has php 5.6.23-1

This has been working nicely, but now it doesn't. Last synced on 14-08-2017 09:29:02

I can curl the first connection wsdl and it's working.