I know it's none of my business, but this in the future when your site grows up will cause you a lot of headaches.
I speak from my own experience, I had problems with this.
I saved mysql songs, I know it gave a very tense overload I had to disable the site for 3 days and move everything to files, I lost a lot of users.
If I were you I would save everything in folders, example I have the file wesley.mp4 use the function md5()
in it, it will generate a string 4f755db8796988ecf1a3dba1c0cc584d
After this you use a substr('4f755db8796988ecf1a3dba1c0cc584d',0,2);
will return 4f.
With this you create a folder called 4f in php there are functions that create the folder if it does not exist.
so it would look like this /uploads/4f/wesley.mp4
in this case several files may have 4f at the beginning of md5.
So you can save thousands of files in subfolders that will not get heavy, as I did in the image below.
The first string of the file is always 'a' or '1', it will sort all the strings with 1 or a in this folder, I currently have about 700,000 mp3 files in these folders.
I hope I have helped.