Good evening all
I'm sorry to be so pushy with the urgent addendum but we have an event and
some demos coming up and we only now realise that BaseX isn't working
anymore. (Our own fault.)
We upgraded from BaseX 7.9 to 8.3 (after going from Cent OS 6 to Cent OS 7).
Thinking we could use the same settings from our .basex configuration file,
I ran the command basexserver as I used to. This works, but I remember
seeing a message in the command line that some attributes were not
recognised and that a new configuration file was created by basex itself,
and that a server was launched subsequently. The issue is, though, that we
use BaseX as a back-end database system that processes requests from an
apache webservice. On Machine A the webservice is running, and basex is
running on machine B. The webservice fires a session request (with PHP) like
so:
$session = new Session("machineB", 1958, "admin", "admin");
However, the connection fails. First a warning, followed by a Fatal error.
PHP Warning: socket_connect(): unable to connect [113]: No route to host in
basex-client.php on line 17
Line 17 would be the first one of this clause:
if(!socket_connect($this->socket, $h, $p)) {
throw new Exception("Can't communicate with server.");
}
My instinct was that the webservice could not connect to basex because some
settings in the newly created .basex file were incorrect. However, I checked
them and they are definitely correct. Shown below:
# General Options
DEBUG = false
DBPATH = /home/obelix/sonarbasex/WRPPH
REPOPATH = /home/nobackup/Gretel/BaseXRepo
LANG = English
LANGKEYS = false
GLOBALLOCK = false
# Client/Server Architecture
HOST = localhost
PORT = 1958
SERVERPORT = 1958
USER =
PASSWORD =
SERVERHOST =
PROXYHOST =
PROXYPORT = 9591
NONPROXYHOSTS =
IGNORECERT = false
TIMEOUT = 30
KEEPALIVE = 600
PARALLEL = 8
LOG = true
LOGMSGMAXLEN = 1000
# HTTP Services
WEBPATH = /home/pricie/sonar/BaseXWeb
RESTPATH =
RESTXQPATH =
CACHERESTXQ = false
HTTPLOCAL = false
STOPPORT = 8591
AUTHMETHOD = Basic
I did find, however, that unlike the .basex file of our previous version,
this one does not have an EVENTPORT attribute. Is this normal? I can't find
it in the documentation anymore either. So if it has nothing to do with
ports an access, why would I then get a 'no route to host' error? Is there
ANY way that, given my basex file above, this is caused by BaseX? Or is it
more likely to be a network/permission error?
Thank you in advance, I'm running out of ideas!
Kind regards
Bram