Error - Clean up backup tables logs and files

Error - Clean up backup tables logs and files

Iqids Iqids -
回帖数:8

Php version 8.2.25  // Moodle version 4.5 // on linux server // shared 

I have spent the last week with chatgpt trying to solve issues that I am facing with moodle. Although they do not seem to interfere with the overall functionality of moodle. So, from Site administration - server - clean up backup tables logs and files when I run the task I get all this:

Some HTML tags were opened in the body of the page but not closed.

Remaining containers: 0. Please check for missing or mismatched closing tags.

  • Open header/footer at:
    • line 75 of /lib/classes/output/xhtml_container_stack.php: call to core\output\xhtml_container_stack->log()
    • line 932 of /lib/classes/output/core_renderer.php: call to core\output\xhtml_container_stack->push()
    • line ? of unknownfile: call to core\output\core_renderer->header()
    • line 109 of /lib/classes/output/bootstrap_renderer.php: call to call_user_func_array()
    • line 64 of /admin/tool/task/schedule_task.php: call to core\output\bootstrap_renderer->__call()
  • Stack after push Current stack size: 1 at:
    • line 82 of /lib/classes/output/xhtml_container_stack.php: call to core\output\xhtml_container_stack->log()
    • line 932 of /lib/classes/output/core_renderer.php: call to core\output\xhtml_container_stack->push()
    • line ? of unknownfile: call to core\output\core_renderer->header()
    • line 109 of /lib/classes/output/bootstrap_renderer.php: call to call_user_func_array()
    • line 64 of /admin/tool/task/schedule_task.php: call to core\output\bootstrap_renderer->__call()
  • Close header/footer at:
    • line 113 of /lib/classes/output/xhtml_container_stack.php: call to core\output\xhtml_container_stack->log()
    • line 992 of /lib/classes/output/core_renderer.php: call to core\output\xhtml_container_stack->pop()
    • line 87 of /admin/tool/task/schedule_task.php: call to core\output\core_renderer->footer()
  • Open box at:
    • line 75 of /lib/classes/output/xhtml_container_stack.php: call to core\output\xhtml_container_stack->log()
    • line 2940 of /lib/classes/output/core_renderer.php: call to core\output\xhtml_container_stack->push()
    • line 2928 of /lib/classes/output/core_renderer.php: call to core\output\core_renderer->box_start()
    • line 2675 of /lib/classes/output/core_renderer.php: call to core\output\core_renderer->box()
    • line 178 of /lib/setuplib.php: call to core\output\core_renderer->fatal_error()
    • line ? of unknownfile: call to default_exception_handler()
  • Stack after push Current stack size: 1 at:
    • line 82 of /lib/classes/output/xhtml_container_stack.php: call to core\output\xhtml_container_stack->log()
    • line 2940 of /lib/classes/output/core_renderer.php: call to core\output\xhtml_container_stack->push()
    • line 2928 of /lib/classes/output/core_renderer.php: call to core\output\core_renderer->box_start()
    • line 2675 of /lib/classes/output/core_renderer.php: call to core\output\core_renderer->box()
    • line 178 of /lib/setuplib.php: call to core\output\core_renderer->fatal_error()
    • line ? of unknownfile: call to default_exception_handler()
  • Close box at:
    • line 113 of /lib/classes/output/xhtml_container_stack.php: call to core\output\xhtml_container_stack->log()
    • line 2952 of /lib/classes/output/core_renderer.php: call to core\output\xhtml_container_stack->pop()
    • line 2928 of /lib/classes/output/core_renderer.php: call to core\output\core_renderer->box_end()
    • line 2675 of /lib/classes/output/core_renderer.php: call to core\output\core_renderer->box()
    • line 178 of /lib/setuplib.php: call to core\output\core_renderer->fatal_error()
    • line ? of unknownfile: call to default_exception_handler()
  • line 130 of /lib/classes/output/xhtml_container_stack.php: call to debugging()
  • line 1086 of /lib/classes/output/core_renderer.php: call to core\output\xhtml_container_stack->pop_all_but_last()
  • line 989 of /lib/classes/output/core_renderer.php: call to core\output\core_renderer->container_end_all()
  • line 2701 of /lib/classes/output/core_renderer.php: call to core\output\core_renderer->footer()
  • line 178 of /lib/setuplib.php: call to core\output\core_renderer->fatal_error()
  • line ? of unknownfile: call to default_exception_handler()

There are no more open containers. This suggests there is a nesting problem. Please check the stack for missing or mismatched containers. Current state of open containers:

  • Open header/footer at:
    • line 75 of /lib/classes/output/xhtml_container_stack.php: call to core\output\xhtml_container_stack->log()
    • line 932 of /lib/classes/output/core_renderer.php: call to core\output\xhtml_container_stack->push()
    • line ? of unknownfile: call to core\output\core_renderer->header()
    • line 109 of /lib/classes/output/bootstrap_renderer.php: call to call_user_func_array()
    • line 64 of /admin/tool/task/schedule_task.php: call to core\output\bootstrap_renderer->__call()
  • Stack after push Current stack size: 1 at:
    • line 82 of /lib/classes/output/xhtml_container_stack.php: call to core\output\xhtml_container_stack->log()
    • line 932 of /lib/classes/output/core_renderer.php: call to core\output\xhtml_container_stack->push()
    • line ? of unknownfile: call to core\output\core_renderer->header()
    • line 109 of /lib/classes/output/bootstrap_renderer.php: call to call_user_func_array()
    • line 64 of /admin/tool/task/schedule_task.php: call to core\output\bootstrap_renderer->__call()
  • Close header/footer at:
    • line 113 of /lib/classes/output/xhtml_container_stack.php: call to core\output\xhtml_container_stack->log()
    • line 992 of /lib/classes/output/core_renderer.php: call to core\output\xhtml_container_stack->pop()
    • line 87 of /admin/tool/task/schedule_task.php: call to core\output\core_renderer->footer()
  • Open box at:
    • line 75 of /lib/classes/output/xhtml_container_stack.php: call to core\output\xhtml_container_stack->log()
    • line 2940 of /lib/classes/output/core_renderer.php: call to core\output\xhtml_container_stack->push()
    • line 2928 of /lib/classes/output/core_renderer.php: call to core\output\core_renderer->box_start()
    • line 2675 of /lib/classes/output/core_renderer.php: call to core\output\core_renderer->box()
    • line 178 of /lib/setuplib.php: call to core\output\core_renderer->fatal_error()
    • line ? of unknownfile: call to default_exception_handler()
  • Stack after push Current stack size: 1 at:
    • line 82 of /lib/classes/output/xhtml_container_stack.php: call to core\output\xhtml_container_stack->log()
    • line 2940 of /lib/classes/output/core_renderer.php: call to core\output\xhtml_container_stack->push()
    • line 2928 of /lib/classes/output/core_renderer.php: call to core\output\core_renderer->box_start()
    • line 2675 of /lib/classes/output/core_renderer.php: call to core\output\core_renderer->box()
    • line 178 of /lib/setuplib.php: call to core\output\core_renderer->fatal_error()
    • line ? of unknownfile: call to default_exception_handler()
  • Close box at:
    • line 113 of /lib/classes/output/xhtml_container_stack.php: call to core\output\xhtml_container_stack->log()
    • line 2952 of /lib/classes/output/core_renderer.php: call to core\output\xhtml_container_stack->pop()
    • line 2928 of /lib/classes/output/core_renderer.php: call to core\output\core_renderer->box_end()
    • line 2675 of /lib/classes/output/core_renderer.php: call to core\output\core_renderer->box()
    • line 178 of /lib/setuplib.php: call to core\output\core_renderer->fatal_error()
    • line ? of unknownfile: call to default_exception_handler()
  • line 96 of /lib/classes/output/xhtml_container_stack.php: call to debugging()
  • line 992 of /lib/classes/output/core_renderer.php: call to core\output\xhtml_container_stack->pop()
  • line 2701 of /lib/classes/output/core_renderer.php: call to core\output\core_renderer->footer()
  • line 178 of /lib/setuplib.php: call to core\output\core_renderer->fatal_error()
  • line ? of unknownfile: call to default_exception_handler()

Exception - Call to undefined function core\task\proc_open()

More information about this error

I
I do not have access to proc_open. I have also used Putty, but I still get the same error. I also deleted the 1 task that was in task_adhoc but nothing changed.

Any ideas are appreciated.

Thank you in advance.
 
Stack trace:
  • line 1559 of /lib/classes/task/manager.php: Error thrown
  • line 1539 of /lib/classes/task/manager.php: call to core\task\manager::passthru_via_mtrace()
  • line 96 of /admin/tool/task/schedule_task.php: call to core\task\manager::run_from_cli()

                        
回复Iqids Iqids

Re: Error - Clean up backup tables logs and files

Ken Task -
Particularly helpful Moodlers的头像

What exact version of Moodle?
Seen in version.php file at root of moodle code.

'shared host' ... how was moodle installed?

https://docs.moodle.org/405/en/Installing_Moodle

Have you setup the cron job for your moodle?   That is done outside
of moodle - cPanel? A tool just for cron jobs.  What does that look like?

https://docs.moodle.org/405/en/Cron

You say you used Putty ... What did you do with it - commands issued?  Did you edit any file?

'SoS', Ken

回复Ken Task

Απάντ: Re: Error - Clean up backup tables logs and files

Iqids Iqids -
Hi Ken,
I'm using Moodle 4.5+ (Build: 20241101)
$version = 2024100700.04;

Moodle was installed via plesk and by extracting the moodle zip folder in the directory.
Cron job for scheduled tasks has been setup via plesk and it runs without errors. Cron job has PHP 8.3.13 version if that says anything.

Via putty I tried to access php.ini file but I can't and tried different things chatgpt suggested. Overall, nothing has been changed via putty.
回复Iqids Iqids

Re: Απάντ: Re: Error - Clean up backup tables logs and files

Ken Task -
Particularly helpful Moodlers的头像

Plesk is a control panel (like cPanel, or Webmin, or DirectAdmin, Cockpit). It has reputation of being 'more secure' [difficult?] and some knowledge of how it works is needed.

Best source of info:
https://docs.plesk.com/en-US/obsidian/

Also note hosting provider can and should help you!

Shared hosting ... is generally not a good hosting situation for a Moodle. Lack of controls ... example you've already provided ... the php.ini file. The main php.ini file for that shared server you will not have access to because changes you make to it would affect ***ALL*** customers on that shared hosting server.

PHP version 8.2.25 is ok for Moodle 4.5+.

On shared hosting, customers can set various parameters for PHP in their accounts. A couple of ways: php.ini files in directories where they are needed or an .htaccess file at root of moodle code.

Which one you could do depends upon hosting.  Thus, hosting provider can and should help you!

Hosting providers (the good ones) do have portals for their customers with How-2 docs and other suggestions/fixes.   Those docs are written by the staff of the hosting provider (or should be).

Me thinks those would be a better source to resolve your problems as opposed to ChatGTP.   AI, IMHO, ain't there yet! 微笑

Where do you host?   Name of hosting provider?

'SoS', Ken

回复Ken Task

Απάντ: Re: Απάντ: Re: Error - Clean up backup tables logs and files

Iqids Iqids -
The hosting provider got back to me and basically said that it's a coding error, not something they can offer support for.

Thank you anyway.
回复Iqids Iqids

Re: Error - Clean up backup tables logs and files

Leon Stringer -
Core developers的头像 Particularly helpful Moodlers的头像

Go to the PHP info page in your Moodle site and search for "disable_functions":

disable_functions: no value | no value

Is anything listed?

回复Leon Stringer

Απάντ: Re: Error - Clean up backup tables logs and files

Iqids Iqids -
This is what I have in php info page.
disable_functions exec,passthru,shell_exec,system,suexec,dbmopen,proc_open exec,passthru,shell_exec,system,suexec,dbmopen,proc_open
回复Iqids Iqids

Re: Απάντ: Re: Error - Clean up backup tables logs and files

Leon Stringer -
Core developers的头像 Particularly helpful Moodlers的头像

This is what I have in php info page.
disable_functions exec,passthru,shell_exec,system,suexec,dbmopen,proc_open exec,passthru,shell_exec,system,suexec,dbmopen,proc_open

It looks like your hosting provider has disabled the PHP function proc_open(). Moodle is trying to use this so you get the Call to undefined function error.

For scheduled task this error will only occur when you use the Run now link to run the task from your browser. If the task is run via a cron job this shouldn't occur (I think!).

But follow this up with your hosting provider and ask if they'll remove proc_open from PHP's disable_functions setting for your site.

回复Leon Stringer

Απάντ: Re: Απάντ: Re: Error - Clean up backup tables logs and files

Iqids Iqids -
Unfortunately the hosting provider says that proc_open function is only available on semi-dedicated plans or VPS/ Dedicated servers.

It's true that I get the error when running the task via moodle. Otherwise, via cron I get no errors.