AKSW / Erfurt

PHP5 / Zend based Semantic Web API for Social Semantic Software
41 stars 27 forks source link

[OSx] Apache: Erfut error: Virtuoso adapter requires the ODBC extension to be loaded. #142

Closed cfrancois7 closed 7 years ago

cfrancois7 commented 7 years ago

I'm using ontowiki on my MacOSx laptop el capitan.

When I was using ontowiki with Nginx I didn't get this problem.

When I try to access the page on my localhost (localhost/~myName/ontowiki) I got this message in the ontowiki.log (other logs are empty): Erfurt_Store_Adapter_Exception: Virtuoso adapter requires the ODBC extension to be loaded. -> /Users/myName/Sites/ontowiki/vendor/aksw/erfurt/library/Erfurt/Store/Adapter/Virtuoso.php@104

I can properly connect my virtuoso with Isql and I tested the OCDB driver, everything works fine. I just don't know how to run the ODBC extension here.

But the OCDB driver works fine:

$ make odbctest
Your connection to Virtuoso seems to work fine:
cfrancois7 commented 7 years ago

I create a test just to know the ongoing service.

<?php
print_r(get_loaded_extensions());
?>

With that code I get: Array ( [0] => Core [1] => date [2] => ereg [3] => libxml [4] => openssl [5] => pcre [6] => sqlite3 [7] => zlib [8] => bcmath [9] => bz2 [10] => calendar [11] => ctype [12] => curl [13] => dba [14] => dom [15] => hash [16] => fileinfo [17] => filter [18] => ftp [19] => gd [20] => SPL [21] => iconv [22] => json [23] => ldap [24] => mbstring [25] => session [26] => standard [27] => mysqlnd [28] => mysqli [29] => PDO [30] => pdo_mysql [31] => pdo_sqlite [32] => Phar [33] => posix [34] => Reflection [35] => mysql [36] => shmop [37] => SimpleXML [38] => snmp [39] => soap [40] => sockets [41] => exif [42] => sysvmsg [43] => sysvsem [44] => sysvshm [45] => tidy [46] => tokenizer [47] => wddx [48] => xml [49] => xmlreader [50] => xmlrpc [51] => xmlwriter [52] => xsl [53] => zip [54] => apache2handler )

Indeed odbc is not loaded.

pfrischmuth commented 7 years ago

The ODBC extension needs to be active for the Virtuoso backend to work.

cfrancois7 commented 7 years ago

I forgot to reply. It is just on Mac, the build-in Apache-PHP 5 config doesn't provide the support for ODBC. It is necessary to install the package with brew or something else with the extensions for ODBC. So the issue is closed.