Forums | Mahara Community

Support /
Error while exporting content to Mahara


Juan Menéndez's profile picture
Posts: 36

25 September 2020, 9:30

Hi !

I'm running Moodle 3.3 and Mahra 17.10.9

I have integrated Moodle and Mahara succesfully and works for SSO, but it is not possible to export content from Moodle to Mahara, it failled and the error is as follows:

"Failed to start communication with remote server: remote server error: code: , message: A nonrecoverable error occurred. This probably means you have encountered a bug in the systemERROR 4"

The error log in Mahara is as follows:

"[WAR] ce (api/xmlrpc/server.php:60) Networking is not available at this address. You can access this service at https://www.myportfoliomahara.es/api/xmlrpc/server.php"

I think the error is caused because Mahara is installed in a PHP cluster behind a Proxy because they are different hosts.

 

My question is:
If I comment the following line of code in "api/xmlrpc/server.php" could it solve the problem ?:

"if (get_hostname_from_uri($_SERVER['HTTP_HOST']) != get_hostname_from_uri(get_config('wwwroot'))) {
    throw new XmlrpcServerException('Networking is not available at this address. You can access this service at '.get_config('wwwroot').'api/xmlrpc/server.php',
6013);
}"

And on the other hand, if I comment that line of code can I have problems with other Mahara functions?

 

Thank you very much.

Cheers 

Juan

Kristina Hoeppner's profile picture
Posts: 4863

28 November 2020, 19:33

Hi Juan,

Sorry for the late reply. Did you make sure that networking is turned on on your Mahara site? If both sites are behind the proxy, the connection should be able to be established. I'm afraid I can't tell you what implications your changes will have as I'm not a developer. We usually do not make changes in that area of code to prevent unforeseen things from happening.

Best

Kristina

2 results