OAI error cant accses

I get problem with OAI ( https://journal.interstudi.edu/index.php/InterKomunika/oai). How to fix it?

Best Regards,
Iqbal

Hi @iqbalafghan,

Check your PHP error log for details; you should see a “Fatal Error” or something similar.

Regards,
Alec Smecher
Public Knowledge Project Team

I have checked the config.inc.php file and the err_log file, the following we found regarding OAI errors,

File config.inc.php
[oai]

; Enable OAI front-end to the site
oai = On

; OAI Repository identifier
repository_id = “journal.interstudi.edu”

; Maximum number of records per request to serve via OAI
oai_max_records = 100

file Err_log :

[22-Jan-2020 03:54:57 UTC] PHP Fatal error: require_once(): Failed opening required ‘classes/oai/ojs/OAIDAO.inc.php’ (include_path=’.:/home/interstu/public_html/journal/classes:/home/interstu/public_html/journal/pages:/home/interstu/public_html/journal/lib/pkp:/home/interstu/public_html/journal/lib/pkp/classes:/home/interstu/public_html/journal/lib/pkp/pages:/home/interstu/public_html/journal/lib/pkp/lib/adodb:/home/interstu/public_html/journal/lib/pkp/lib/phputf8:/home/interstu/public_html/journal/lib/pkp/lib/pqp/classes:/home/interstu/public_html/journal/lib/pkp/lib/smarty:.:/opt/cpanel/ea-php56/root/usr/share/pear’) in /home/interstu/public_html/journal/lib/pkp/includes/functions.inc.php on line 32
[22-Jan-2020 03:55:22 UTC] ojs2 has produced an error

On folder classes/oai/ojs/
We have checked that there is a JournalOAI.inc.php file in line 32

if (!function_exists(‘import’)) {
function import($class) {
static $deprecationWarning = null;
// Try to bypass include path for best performance
$filePath = str_replace(’.’, ‘/’, $class) . ‘.inc.php’;
if (file_exists(BASE_SYS_DIR.’/’.$filePath)) {
include_once BASE_SYS_DIR.’/’.$filePath;
} else {
// Oops, we found a legacy include statement,
// let’s try the include path then.
:32 require_once($filePath);
if (is_null($deprecationWarning) && class_exists(‘Config’)) {
$deprecationWarning = (boolean)Config::getVar(‘debug’, ‘deprecation_warnings’);
}
if ($deprecationWarning) trigger_error(‘Deprecated import of a partially qualified class name.’);
}
}
}

Regards,
Iqbal

Hi @iqbalafghan,

The message:

 PHP Fatal error: require_once(): Failed opening required ‘classes/oai/ojs/OAIDAO.inc.php’

… suggests that this file is missing from your server.

Regards,
Alec Smecher
Public Knowledge Project Team

thanks sir, it worked…