New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Problem: Cannot store AIP with large files #981
Comments
Hi @jorikvankemenade this is a good spot. That field looks like it definitely needs to be updated. However, I am seeing a different behavior using percona in the docker-compose setup. If i create a 4GB file:
And store as uncompressed:in the storage service I see:
In the storage service I have two AIPS:
So you can see, the field has maxed out, but it hasn't caused the storage service to fall-over. My reason for looking is that storing this size of AIP is not unusual in a lot of deployments, so it's odd that it's happening here. I can see you're using In my CentOS deployment, i can see the column is likely fixed to 32-bits:
If you can think of anything else that might be impacting this, or perhaps, let us know if updating that field helps at all it will be useful for other readers of this ticket looking at mysql in other deployments of Archivematica. |
I see that you posted the schema for SQLite. This schema shows the field as an
So I guess it is "a lucky find" in the sense that I shot myself in the foot by using MySQL instead of SQLite for the storage service.
I am currently in the process of testing ingesting running big files in my setup. I'll update this ticket when I know more. |
@ross-spencer I have successfully imported a 5.1GB video file in my MySQL backed storage service. It requires not one, but two very small pull requests. So I hope that it wouldn't take you guys to much time to check them. Let me know what you think! |
Awesome, we'll make a note here for @sromkey about considering those next week for inclusion in |
I could reproduce the issue on CentOS, SS with percona 5.7 and AM 1.10.1 deployed with ansible. I tested with a 4.3 GB transfer (linux iso file) When using the default MySQL 5.7 uses the strict sql mode by default, it is an important change from MySQL 5.6. I tried again disabling the MySQL strict mode with At last, I tested the change in database that @jorikvankemenade proposes and then I could storage the AIP with the default MySQL 5.7 strict mode, and the Archival Storage shows the AIP size. This is the change in database (when SS is the Storage Service database name):
|
I've tested with a transfer containing three large files - 2.3 GB, 8.3 GB, and 11.3 GB - and the AIP stored fine. I believe that the MySQL settings are standard for a fresh install on the test site I'm using. The Archival Storage tab shows the correct AIP size. The test server is running on CentOS. |
Expected behaviour
When creating a transfer with large single files, i.e. videos, a verified AIP should be stored successfully. This is of course given that the file system supports the size of the files.
Current behaviour
If an AIP contains a file that is bigger than 2.15 GB the "Store AIP step" fails. In the dashboard it will show the following error:
And in the storage service we will have the following error:
So there is a problem with the
size
field in thefiles
endpoint of the storage service. Thefiles
endpoint is served by thePackage
model. Looking at the table we get:So the size field is an
int(11)
, or a 32-bit integer. This limits the maximum file size to a maximum of 2.147.483.647 bytes or 2.15 GB. Since I think it is perfectly reasonable to have bigger files I think this number should be increased. This means changing the type of the size field in the Package model in the storage service. If we change the number field fromIntegerField
toBigIntegerField
we increase the max file size to the order of exabytes. I would think a pretty save limit :). I'll start working on creating and testing a PR this afternoon.Steps to reproduce
Your environment (version of Archivematica, operating system, other relevant details)
CentOS 7, Archivematica 1.10, Storage Service 0.15, MySQL 5.7.26 for both the Storage Service and Archivematica.
For Artefactual use:
Before you close this issue, you must check off the following:
The text was updated successfully, but these errors were encountered: