WeBWorK Main Forum

An error occured while archiving the course "coursename"

An error occured while archiving the course "coursename"

by Ricardo T -
Number of replies: 2

Hi, 


I was wondering if anyone ran into issues before when archiving courses. I am currently receiving the following error:

Unable to replace the archival version of 'myTestCourse' at /opt/webwork/webwork2/lib/WeBWorK/ContentGenerator/CourseAdmin.pm line 1981.

This is happening with multiple courses. I believe it might be a permissions issues with WebWork not being able to write to the archive folder, but this system was setup by someone else and I am not too sure where to look to further troubleshoot this.
Archive course error
Any help will be great.

Thank you,
Rick

In reply to Ricardo T

Re: An error occured while archiving the course "coursename"

by Danny Glin -

It does look like it's probably a permissions issue.

By default WeBWorK tries to save archives to /opt/webwork/courses.  Since the error message says "unable to replace ..." it's likely that there is already a backup with the same name in that folder, and that the web server doesn't have permission to overwrite it.

If you want to keep the existing backup, then renaming it will likely fix your problem, since then WeBWorK won't be trying to overwrite the existing file.  Otherwise you can delete the backup, with likely the same result.

It's also possible that the web server doesn't have permission to write to that folder, though I suspect that if this was the case then other things would break as well.

Post back if you need more detailed instructions on the linux commands to do these things.

In reply to Danny Glin

Re: An error occured while archiving the course "coursename"

by Ricardo T -

Hello Danny, 

Thank you for the information. Deleting the old archive file fixed the issue. I also change the ownership of the other archived courses and it seems to be working fine now. 


Thanks!