Open Atisom opened 6 years ago
Looks like missing permissions on the submission directory. @tiborsimko or @egabancho do you have any ideas?
We did receive the email so it's strange that you got an error back.
Dear lnielsen,
I ran this command:
# chmod 777 /opt/invenio -R
# ls -ld /opt/invenio/var/data/files/
drwxrwxrwx 3 www-data www-data 4096 Dec 4 19:44 /opt/invenio/var/data/files/
This wasn't solve the problem:
2017-12-04 19:44:36 -> InvenioWebSubmitFileConverterError: Unexpected error when converting from /opt/invenio/var/data/files/g0/112/content.pdf;1 to .pdf;pdfa (<type 'exceptions.OSError'>): [Errno 13] Permission denied (websubmit_file_converter.py:511:convert_file)
** Traceback details
Traceback (most recent call last):
File "/usr/local/lib/python2.7/dist-packages/invenio/websubmit_functions/Shared_Functions.py", line 96, in createRelatedFormats
newpath = convert_file(path, output_format=aformat)
File "/usr/local/lib/python2.7/dist-packages/invenio/websubmit_file_converter.py", line 511, in convert_file
raise InvenioWebSubmitFileConverterError("Unexpected error when converting from %s to %s (%s): %s" % (input_file, output_ext, type(err), err))
InvenioWebSubmitFileConverterError: Unexpected error when converting from /opt/invenio/var/data/files/g0/112/content.pdf;1 to .pdf;pdfa (<type 'exceptions.OSError'>): [Errno 13] Permission denied
@Atisom The PDF-to-PDFA conversion is using OpenOffice behind the scenes. This runs using unoconv
under the with CFG_OPENOFFICE_USER
identity. By default this is set to user nobody
for additional security. You will have to set up the permissions to user nobody
as indicated in the INSTALL file:
$ sudo -u www-data /opt/invenio/bin/inveniocfg --check-openoffice
for example:
# grant Apache user the nobody user rights for OpenOffice integration:
$ echo "www-data ALL=(nobody) NOPASSWD: ALL" | $sudo tee /etc/sudoers.d/www-data
$ sudo chmod o-r /etc/sudoers.d/www-data
see the example provisioning script https://github.com/inveniosoftware/invenio/blob/maint-1.2/scripts/provision-web.sh#L118-L120
P.S. Note that if you don't need the PDFA conversion on your system, you can amend the conversion configuration rules to switch it off. You can achieve this by configuring CFG_BIBDOCFILE_DESIRED_CONVERSIONS
in your invenio-local.conf
.
Dear Invenio Team,
I installed the invenio 1.2 from your git repository. (I use Ubuntu 14.04 LTS)
When I try to submit a document, I get "OSError: [Errno 13] Permission denied (subprocess.py:1327:_execute_child)" error. I attached the full message of this exception.
I checked the permissions, but I think these are properly:
Could you help me, please?
Thanks, Attila
ps: I tried to send an email to info@invenio-software.org, but I got error message (550 5.1.1 User unknown)
Exception (subprocess.py 1327 _executechild) at http .txt Exception (websubmit_file_converter.py 511 convertfile) at http .txt