WWBN / AVideo-Encoder

Encoder Server for AVideo Platform Open-Source
https://platform.avideo.com
GNU Affero General Public License v3.0
152 stars 189 forks source link

Encoder 3.3 gives file too big error #314

Open dbmasters opened 3 years ago

dbmasters commented 3 years ago

{"files":[{"error":"File is too big","type":"video/mp4","name":"random-title.mp4","size":6361295}]}

Our server is set to 512MB upload size and post size, did version 3 bring with it some new places to set max file size? I tried one file that was pushing 500MB, and one that 6MB and both fail.

akhilleusuggo commented 3 years ago

On the contrary . With chunk upload , you really don't have a max upload size limits . Make sure you have enough ram ( I doubt is the issue . )

Are you sure you're running the last updates ? I know you prefer to upload with ftp , but git is really the way to go .

go to your htaccess on the root directory , and make sure you have unchecked commented this lines ;

#php_value post_max_size 4G
#php_value upload_max_filesize 4G
#php_value memory_limit 512M
dbmasters commented 3 years ago

Found those, they were uncommented in the encoder, not in the streamer tho, uncommented all around, still getting the error. I also see in the aVideo.log a few errors in groups of 3:

[10-Jan-2021 04:56:47 America/Chicago] PHP Warning: fopen(/var/www/html/encoder/videos/configuration.php): failed to open stream: Permission denied in /var/www/html/encoder/objects/Configuration.php on line 108 [10-Jan-2021 04:56:47 America/Chicago] PHP Warning: fwrite() expects parameter 1 to be resource, bool given in /var/www/html/encoder/objects/Configuration.php on line 109 [10-Jan-2021 04:56:47 America/Chicago] PHP Warning: fclose() expects parameter 1 to be resource, bool given in /var/www/html/encoder/objects/Configuration.php on line 110

This references these lines:

        $fp = fopen($global['systemRootPath'] . "videos/configuration.php", "wb");
        fwrite($fp, $content);
        fclose($fp);

In my config, I opened up permissions CHMOD for testing reasons, and the global variables are set properly...this code appears to be part of a configuration rewrite function, why does that even fire at this time?

I am running the 3.3 encoder as of the latest commits from 4 days ago I think it said, and streamer is v10

akhilleusuggo commented 3 years ago
cd /var/www/html/
sudo chown www-data:www-data -R *
dbmasters commented 3 years ago

Yep, exactly what I thought we'd have to do, got that word in to my partner, he does the server stuff, I do the code stuff...

Thanks for the help.

dbmasters commented 3 years ago

Well, changed ownership and all that, still a size limit issue, but I got new errors, so, progress?

(Apologies on formatting)

[10-Jan-2021 12:31:27 America/Chicago] logoff:: done session_id = tcprl9m7ikamfgfmljeidej85o [10-Jan-2021 12:31:27 America/Chicago] https://************/ == https://************/ [10-Jan-2021 12:31:27 America/Chicago] login.json: Login::run [10-Jan-2021 12:31:27 America/Chicago] Login::run (admin, ***, https://************/, true) [10-Jan-2021 12:31:27 America/Chicago] Login::run response: ({"isCaptchaNeed":false,"siteLogo":"https:\/\/************\/videos\/userPhoto\/logo.png","id":1,"user":"admin","donationLink":"","name":"OurWeb Admin","nameIdentification":"admin","pass":"042e6aaeeba423b689a3252020a44832","email":"ourweb@dbmasters.net","channelName":"Ourweb_admin","photo":"https:\/\/************\/videos\/userPhoto\/photo1.png?1600104705","backgroundURL":"https:\/\/************\/view\/img\/background.png","isLogged":true,"isAdmin":true,"canUpload":true,"canComment":true,"canStream":true,"redirectUri":"https:\/\/************\/","categories":[{"id":1,"name":"Default","clean_name":"default","description":"","nextVideoOrder":0,"parentId":0,"created":"2020-09-14 17:03:41","modified":"2020-09-26 09:40:49","iconClass":"fa fa-folder","users_id":1,"private":1,"allow_download":0,"order":0,"total":4,"fullTotal":4,"owner":"admin","canEdit":true,"canAddVideo":true,"hierarchy":"\/","hierarchyAndName":"\/Default"},{"id":6,"name":"Exercise","clean_name":"exercise","description":"","nextVideoOrder":0,"parentId":0,"created":"2020-09-14 18:19:42","modified":"2020-09-26 09:39:10","iconClass":"fa fa-fw iconpicker-component","users_id":1,"private":0,"allow_download":0,"order":35,"total":0,"fullTotal":0,"owner":"admin","canEdit":true,"canAddVideo":true,"hierarchy":"\/","hierarchyAndName":"\/Exercise"},{"id":5,"name":"Fashion","clean_name":"fashion","description":"","nextVideoOrder":0,"parentId":0,"created":"2020-09-14 18:19:30","modified":"2020-09-26 09:37:11","iconClass":"fa fa-fw iconpicker-component","users_id":1,"private":0,"allow_download":0,"order":10,"total":0,"fullTotal":0,"owner":"admin","canEdit":true,"canAddVideo":true,"hierarchy":"\/","hierarchyAndName":"\/Fashion"},{"id":7,"name":"Health and Wellness","clean_name":"health-and-wellness","description":"","nextVideoOrder":0,"parentId":0,"created":"2020-09-14 18:19:59","modified":"2020-09-26 09:39:21","iconClass":"fa fa-fw iconpicker-component","users_id":1,"private":0,"allow_download":0,"order":40,"total":0,"fullTotal":0,"owner":"admin","canEdit":true,"canAddVideo":true,"hierarchy":"\/","hierarchyAndName":"\/Health and Wellness"},{"id":12,"name":"Humor","clean_name":"humor","description":"","nextVideoOrder":0,"parentId":0,"created":"2020-09-26 09:34:41","modified":"2020-09-26 09:36:57","iconClass":"fa fa-fw iconpicker-component","users_id":1,"private":0,"allow_download":0,"order":5,"total":0,"fullTotal":0,"owner":"admin","canEdit":true,"canAddVideo":true,"hierarchy":"\/","hierarchyAndName":"\/Humor"},{"id":4,"name":"Lifestyle","clean_name":"lifestyle","description":"","nextVideoOrder":0,"parentId":0,"created":"2020-09-14 18:19:17","modified":"2020-09-26 09:37:28","iconClass":"fa fa-fw iconpicker-component","users_id":1,"private":0,"allow_download":0,"order":15,"total":0,"fullTotal":0,"owner":"admin","canEdit":true,"canAddVideo":true,"hierarchy":"\/","hierarchyAndName":"\/Lifestyle"},{"id":14,"name":"Medical","clean_name":"medical","description":"","nextVideoOrder":0,"parentId":0,"created":"2020-12-22 23:36:20","modified":"2020-12-22 23:36:47","iconClass":"fa fa-fw iconpicker-component","users_id":1,"private":0,"allow_download":0,"order":37,"total":1,"fullTotal":1,"owner":"admin","canEdit":true,"canAddVideo":true,"hierarchy":"\/","hierarchyAndName":"\/Medical"},{"id":8,"name":"Music","clean_name":"music","description":"","nextVideoOrder":0,"parentId":0,"created":"2020-09-14 18:20:09","modified":"2020-09-26 09:39:35","iconClass":"fa fa-fw iconpicker-component","users_id":1,"private":0,"allow_download":0,"order":45,"total":6,"fullTotal":6,"owner":"admin","canEdit":true,"canAddVideo":true,"hierarchy":"\/","hierarchyAndName":"\/Music"},{"id":10,"name":"Country","clean_name":"country","description":"","nextVideoOrder":0,"parentId":8,"created":"2020-09-15 02:00:17","modified":"2020-10-01 14:52:06","iconClass":"fa fa-fw iconpicker-component","users_id":1,"private":0,"allow_download":0,"order":55,"total":0,"fullTotal":0,"owner":"admin","canEdit":true,"canAddVideo":true,"hierarchy":"\/Music\/","hierarchyAndName":"\/Music\/Country"},{"id":11,"name":"Instrumental","clean_name":"instrumental","description":"","nextVideoOrder":0,"parentId":8,"created":"2020-09-15 02:00:31","modified":"2020-10-01 14:52:16","iconClass":"fa fa-fw iconpicker-component","users_id":1,"private":0,"allow_download":0,"order":60,"total":0,"fullTotal":0,"owner":"admin","canEdit":true,"canAddVideo":true,"hierarchy":"\/Music\/","hierarchyAndName":"\/Music\/Instrumental"},{"id":9,"name":"Rock","clean_name":"rock","description":"","nextVideoOrder":0,"parentId":8,"created":"2020-09-15 02:00:04","modified":"2020-09-26 09:39:43","iconClass":"fa fa-fw iconpicker-component","users_id":1,"private":0,"allow_download":0,"order":50,"total":6,"fullTotal":6,"owner":"admin","canEdit":true,"canAddVideo":true,"hierarchy":"\/Music\/","hierarchyAndName":"\/Music\/Rock"},{"id":13,"name":"News","clean_name":"news","description":"","nextVideoOrder":0,"parentId":0,"created":"2020-09-26 09:38:18","modified":"2020-09-26 09:38:18","iconClass":"fa fa-fw iconpicker-component","users_id":1,"private":0,"allow_download":0,"order":25,"total":0,"fullTotal":0,"owner":"admin","canEdit":true,"canAddVideo":true,"hierarchy":"\/","hierarchyAndName":"\/News"},{"id":3,"name":"Politics","clean_name":"politics","description":"","nextVideoOrder":0,"parentId":0,"created":"2020-09-14 18:19:08","modified":"2020-09-26 09:38:48","iconClass":"fa fa-fw iconpicker-component","users_id":1,"private":0,"allow_download":0,"order":30,"total":9,"fullTotal":9,"owner":"admin","canEdit":true,"canAddVideo":true,"hierarchy":"\/","hierarchyAndName":"\/Politics"},{"id":2,"name":"Social","clean_name":"social","description":"","nextVideoOrder":0,"parentId":0,"created":"2020-09-14 18:18:52","modified":"2020-09-26 09:37:50","iconClass":"fa fa-fw iconpicker-component","users_id":1,"private":0,"allow_download":0,"order":20,"total":3,"fullTotal":3,"owner":"admin","canEdit":true,"canAddVideo":true,"hierarchy":"\/","hierarchyAndName":"\/Social"},{"id":15,"name":"Sports","clean_name":"sports","description":"","nextVideoOrder":0,"parentId":0,"created":"2020-12-22 23:38:19","modified":"2020-12-22 23:38:19","iconClass":"fa fa-fw iconpicker-component","users_id":1,"private":0,"allow_download":0,"order":65,"total":0,"fullTotal":0,"owner":"admin","canEdit":true,"canAddVideo":true,"hierarchy":"\/","hierarchyAndName":"\/Sports"}],"userGroups":[],"streamServerURL":"","streamKey":""}) [10-Jan-2021 12:31:27 America/Chicago] Login::run got an object [10-Jan-2021 12:31:27 America/Chicago] createIfNotExists:: admin [10-Jan-2021 12:31:27 America/Chicago] Verification Start https://************/ [10-Jan-2021 12:31:27 America/Chicago] Verification GetFrom Cache https://************/ [10-Jan-2021 12:31:27 America/Chicago] Verification Response (): {"msg":["Start","https:\/\/************\/ Site verified"],"verified":true,"status":"a"} [10-Jan-2021 12:31:27 America/Chicago] Login:: almost done [10-Jan-2021 12:31:27 America/Chicago] Login:: done session_id = tcprl9m7ikamfgfmljeidej85o session_login true [10-Jan-2021 12:31:28 America/Chicago] isLogged:: session_login = true [10-Jan-2021 12:31:28 America/Chicago] isLogged:: session_login = true [10-Jan-2021 12:31:28 America/Chicago] isLogged:: session_login = true [10-Jan-2021 12:31:28 America/Chicago] isLogged:: session_login = true [10-Jan-2021 12:31:28 America/Chicago] isLogged:: session_login = true [10-Jan-2021 12:31:28 America/Chicago] isLogged:: session_login = true [10-Jan-2021 12:31:28 America/Chicago] isLogged:: session_login = true [10-Jan-2021 12:31:28 America/Chicago] isLogged:: session_login = true [10-Jan-2021 12:31:28 America/Chicago] isLogged:: session_login = true

akhilleusuggo commented 3 years ago

I see no issues . ( no errors on the logs )

Are this the logs of streamer site or encoder ? Try clear the cache and upload a video . Then past the error logs when pasting upload fails .

Erreur1978 commented 3 years ago

I have a question, my Greedy server is up ?

I place a video in my Encoder it downloads it my it does not have in my Avideo site? But if I take Encode with address to you my videos are there ..

[17-Jan-2021 03:37:29 Africa/Abidjan] PHP Warning: Illegal string offset 'mp4' in path/to/my/streamer/site/objects/functions.php on line 1366

baoang commented 3 years ago

I have a question, my Greedy server is up ?

I place a video in my Encoder it downloads it my it does not have in my Avideo site? But if I take Encode with address to you my videos are there ..

[17-Jan-2021 03:37:29 Africa/Abidjan] PHP Warning: Illegal string offset 'mp4' in path/to/my/streamer/site/objects/functions.php on line 1366

[16-Feb-2021 11:42:22 Asia/Taipei] PHP Warning: Illegal string offset 'mp4' in path/to/my/streamer/site/objects/functions.php on line 1374

looks similar. I couldn't transfer video files to streamer either. I used my encoder and disabled cloudflare CDN. the encoder seems to work properly when downloading videos and encoding them, but the streamer site could only receive small files, the thumbnails, but not the video files. The strange thing is, the video files downloaded from youtube are only two to three minutes long, which could be as large as only 50 MB in volume.