Help Needed: Issues Accessing Files Post-Upgrade from Indico 2.x to 3.x

Hello Indico Community,

I recently upgraded our Indico instance from version 2.x to 3.x, following the official upgrade guide (Upgrade — Indico 3.3.3-dev documentation). The upgrade process was successful, and the system itself seems to be running fine. However, I’ve encountered a significant issue where none of the files from the previous version are accessible or downloadable.

Error Details:
Whenever I or any user attempts to access any file uploaded in the previous events, the system throws an error indicating that the file could not be found and sending emails to me. Here is an example of the error message:

Error Message: Could not send "event/59/contribution/751/246-210-SS_Track_-_Intro_Presentation.pdf": [Errno 2] No such file or directory: '/opt/indico/archive/event/59/contribution/751/246-210-SS_Track_-_Intro_Presentation.pdf'

Traceback Summary:
    Failure in send_file from storage.backend.py
    FileNotFoundError triggered by os.stat(path)

Additional Information:

The files are supposed to be located at: /opt/indico/archive/
The issue is consistently reproducible for all events and files uploaded before the upgrade.

I have verified the paths and permissions, and all seems to be configured correctly. The file paths haven’t changed, and the files do exist on the server. It seems like a potential issue with how the upgraded system references the old file paths.

Has anyone faced a similar issue, or does anyone have any suggestions on how to resolve this? Any help or guidance would be greatly appreciated as these materials are critical for our users.

Thank you in advance for your assistance!

Best regards,

Can you show me your STORAGE_BACKENDS config from indico.conf? Maybe you changed something there during the upgrade?

Hello @ThiefMaster,

Thanks for the response, here is the configuration of STORAGE_BACKENDS config from indico.conf of the new server:

CACHE_DIR = ‘/opt/indico/cache’
TEMP_DIR = ‘/opt/indico/tmp’
LOG_DIR = ‘/opt/indico/log’
STORAGE_BACKENDS = {‘default’: ‘fs:/opt/indico/archive’}
ATTACHMENT_STORAGE = ‘default’

Old Server:
CACHE_DIR = ‘/opt/indico/cache’
TEMP_DIR = ‘/opt/indico/tmp’
LOG_DIR = ‘/opt/indico/log’
STORAGE_BACKENDS = {‘default’: ‘fs:/opt/indico/archive’}
ATTACHMENT_STORAGE = ‘default’

So it seems that the settings for the cache directory, temporary directory, log directory, storage backends, and attachment storage are the same between the old and new server configurations.

Thanks again for helping me out.

Hello,

I am providing an update and seeking further assistance regarding my ongoing challenge with file access issues after upgrading and migrating to a new server (from Indico 2.x to 3.x).

Background Recap:
After initially encountering file access issues post-migration, I discovered that some files were missing due to issues during the transfer. Based on this finding, I have not yet moved all missing files. Instead, I transferred only the files for one specific event to the new server as a preliminary test. These files were placed under the correct directory: /opt/indico/archive.

Current Issue:
Despite this targeted file transfer and server reboot, the system still reports the error “No such file or directory” when attempting to access the files of the test event. This occurs even though I have verified the files are now correctly placed in their respective location of /opt/indico/archive/event/.

Specific Questions:

  1. How can I ensure that the new server correctly recognizes and links to the transferred files for the test event? Is there a specific configuration or caching issue that might be preventing the system from acknowledging the newly placed files?
  2. Assuming we can resolve the issue for the test event, what would be the recommended approach to safely update all previous events with their respective files without affecting the new events created on the new system over the past three months? I aim to restore access to all historical materials without risking the integrity of recent data.

Your expertise and any detailed guidance on resolving these issues would be immensely valuable. I am eager to restore full functionality and ensure that both historical and recent event data are preserved and accessible.

Thank you very much for your assistance and looking forward to your suggestions.

The path stored in the database is relative to the one in indico.conf, so you should not need to fix anything in the DB for specific events.

It’s still weird that you get FileNotFound errors. What OS are you using? Could it be related to SELinux? I’d expect “access denied” in such cases but who knows.

What do you get when running these commands? Please post the output.

ls -l /opt/indico/archive/event/59/contribution/751/246-210-SS_Track_-_Intro_Presentation.pdf
ls -ld /opt/indico/archive/event/59/contribution/751
ls -ld /opt/indico/archive/event/59/contribution
ls -ld /opt/indico/archive/event/59
ls -ld /opt/indico/archive/event
ls -ld /opt/indico/archive
ls -ld /opt/indico

Hello @ThiefMaster,

Following your suggestion, I checked the file permissions and adjusted the owner to indico:www-data. This change has successfully resolved the problem, and everything is now functioning correctly.

Thank you, Adrian, for pointing me in the right direction. Your help was invaluable!