PREP 2015 System Administration

Failed to Archive Course Directory

Failed to Archive Course Directory

by Michele Titcombe -
Number of replies: 2
Can anyone help me with this error?

I tried, unsuccessfully, two ways to archive a course:
1) through the admin course
2) through file manager as a professor in the course itself.
Both ways failed with the error:

An error occured while archiving the course testcourse101:

Failed to archive course directory '/opt/webwork/courses/testcourse101' with command '2>&1 /bin/tar -C /opt/webwork/courses/testcourse101/.. -czf '/opt/webwork/courses/ 02b3c920-2d65-11e5-a34e-f36c32199daf_testcourse101.tar.gz' testcourse101' (exit=72057594037927935 signal=127 core=128): at /opt/webwork/webwork2/lib/WeBWorK/ContentGenerator/CourseAdmin.pm line 1858.

plus a whole list of warning messages that began with:

Warning messages

  • Use of uninitialized value $dump_out in concatenation (.) or string at /opt/webwork/webwork2/lib/WeBWorK/DB/Schema/NewSQL/Std.pm line 233.
  • Warning: Failed to dump table 'testcourse101_key' with command '2>&1 /usr/bin/mysqldump --defaults-file=/tmp/tZYRISziXn webwork testcourse101_key > /opt/webwork/courses/testcourse101/DATA/mysqldump/key.sql' (exit=72057594037927935 signal=127 core=128):
  • This can be expected if the course was created with an earlier version of WeBWorK. at /opt/webwork/webwork2/lib/WeBWorK/DB/Schema/NewSQL/Std.pm line 234.

I also tried Upgrade Course before doing the archive but that didn't help.




In reply to Michele Titcombe

Re: Failed to Archive Course Directory

by Danny Glin -
Since it looks like several things are failing, I suspect that this may be a permissions issue.  Have you checked to make sure that apache can write to the courses directory, and also to the directory for the individual course?
In reply to Danny Glin

Re: Failed to Archive Course Directory

by Michele Titcombe -
Hi Danny,

During Monday's workshop, Jason suggested the following:

@Michele - it can't hurt to try resetting the file system permissions and seeing what happens. So from /opt/webwork/webwork2 do:
sudo chgrp -R wwdata DATA ../courses htdocs/tmp htdocs/applets logs tmp

sudo chmod -R g+w DATA ../courses htdocs/tmp htdocs/applets logs tmp

sudo find DATA/ ../courses/ htdocs/tmp logs/ tmp/ -type d -a -exec chmod g+s {} \;


That didn't fix the problem, so then Jason suggested to try next:

@Michele - alright, next place to look is the apache error log - sometimes it has more information, or sometimes less but it can paint a fuller picture. So, ahve a look in /var/log/apache2/error.log
for errors related to this and plz let me know what you find.

I tried, but something weird is going on with my server. I cannot do basic commands. Even an 'ls' will give me an error something like 'bash fork Cannot allocate memory'. So, this failure to archive a directory could be the result of something else?