After upload, all videos have 00:00 duration

Hello to all!
I would initially like to mention that I am new to the community and, of course, if you are asking for your support in an incorrect way, please tell me how I should do it. Concerning my question:

I have inherited a kaltura installation (kaltura-server-11.18.0-1.noarch version) that has an anomaly associated with the duration of the videos. Any video that is imported gets the information of duration 00:00. We equated updating kaltura to the latest version and probably the problem disappeared. However, I decided to run a test and install the same version on another machine (11.18.0-1). I notice that the problem has been exceeded.

Therefore, a number of issues were raised, namely:

  • If the problem in a new installation of the same version is exceeded, will the problem with the original machine upgrade be solved?
  • Did the problem initially not happen and for any reason of bad configuration, started to happen? Could the problem be associated with, for example, the installation of a new flavor?

Has anyone heard of this problem? Do you have any idea what I can do to resolve this?

Hi @trm_1981,

The root cause is explained in this commit:

Newer versions rely on the kaltura-mediainfo package which is of version 0.7.61 rather than the mediainfo package available from the RHEL/CentOS/EPEL repos which is of a higher version.

While it is highly recommend that you upgrade all packages to the latest version, to solve this particular issue, you can install kaltura-mediainfo from the current stable Kaltura repo onto an older version and then change the directives in the following files:
to point to /opt/kaltura/bin/mediainfo instead of /usr/bin/mediainfo.

After making the change, reload your Apache.

This will take care of future entries, for previously ingested entries, you will need to either update the entry.length_in_msecs column like so:

mysql> update entry set length_in_msecs=$LENGTH_IN_MS where id='$ENTRY_ID';

Or using the API, calling media->update() for instance, here is a code sample using the PHP client:

$entryId = '';
$mediaEntry = new KalturaMediaEntry();
$mediaEntry->msDuration = ;
$result = $client->media->update($entryId, $mediaEntry);

Perfect! Thanks a lot jess!
For now its working perfectly!

Hi jess,

Me and my colleague (@trm_1981) have been doing some test with this feature of calculating the video duration. If we change the configuration from using the default mediainfo of the operating system, to the kaltura-mediainfo package, the system retrieves and stores the duration correctly, but this new video does not play in Microsoft Edge browser or iPad/iPhones.

I re-installed a clean system with Kaltura CE 11.18 and using the defaults (mediainfo) from OS (CentOS Linux release 7.4.1708 (Core)), the video plays in every browser, after changing to kaltura-mediainfo and resubmitting the same video, the duration is calculated correctly, but the video doesn’t play in those browsers. But the older video, submitted with the OS media info, still plays with out a problem.

Do you have any idea why this is happening?

Here are the version of all kaltura packages installed (these versions are needed so that the installation in our test env is successful and is the same version of our production env).


Thank you for the help.

Hi @amanadas,

CE 11.18 is rather old [latest stable is 13.5.0] and therefore, so is the HTML5 player version you have.
I recommend you open a trial account on our SaaS and try to ingest the file and play it with the latest version of the player. If that works, which I suspect it will, you should upgrade your CE to the latest stable version.
There are upgrade instructions here:

Technically speaking, it is possible to upgrade ONLY the player but I would advise against it and will not be able to offer official support in the event something goes wrong.

If you have to try that, these are the steps:

  • Upgrade the latest kaltura-html5lib RPM
  • Edit the html5_version in /opt/kaltura/app/configurations/local.ini
  • Edit $BASE_DIR/web/flash/kmc/v5.40.2/config.ini
  • Edit /opt/kaltura/apps/studio/v2.0.5/studio.ini
  • Run php $BASE_DIR/app/deployment/uiconf/deploy_v2.php --ini=$BASE_DIR/web/flash/kmc/v5.40.2/
  • Run php $BASE_DIR/app/deployment/uiconf/deploy_v2.php --ini=/opt/kaltura/apps/studio/v2.0.5/studio.ini
  • Reload Apache

Thank you @jess,

I already tested other version in docker and the same videos on those versions plays normally. I was hopping to solve this problem before the upgrade. I also tried to upgrade only the html5libs but with 11.18 the player v2.62 does not work (at least I was not able to make it work).

We know that we have to do an upgrade and we are going to do it… let’s see how it goes.

Hi @amanadas,

Seeing how you already attempted to only upgrade the player, I suggest you go through the list of steps I provided and see if that works for you although generally speaking, like I said, that’s not the best practice.

Hi @jess,

I tried one more time and installed the latest kaltura-html5lib RPM and did the configuration as you suggested, but i still have the same problem. Something changes when kaltura-mediainfo is used, because the delivery type changes from http to hls.

This video was uploaded with OS mediainfo

The next post has the other image.

This video was uploaded with Kaltura-mediainfo

Do you know why there is this change in behavior? The type of video/encoding changes?

Hi @amanadas,

Sorry but I don’t understand. mediainfo has nothing to do with playback. It is only used to retrieve metadata about the video.
HLS is the default playback method for the player. This is true to all players from version 2.48.1 and above. Why is that an issue?

Sorry for this, I am very new to the Kaltura platform, and maybe there is something not configured for version 11.18 that has to be done.

When the video has 00:00 duration the video plays well, when the video has the duration calculated the video does not play. What I see is the change in deliverytype. I think the problem is not in the mediainfo library but in the way the system handles the new information available when playing the video.

Hi @jess,

In our production system we have reverted the change of using kaltura-mediainfo, and for the videos that have been submitted and have duration different from 0 we are going to change that field directly in the database.

For example, for video 0_3kapjaj1 doing:

update entry set length_in_msecs = 0 where id = ‘0_3kapjaj1’

solves our problem. The video without any more changes, plays in Microsoft EDGE and in iOS devices. The version of kaltura is 11.18 with html5lib 2.45.

Meanwhile we are going to start the migration to one of the latest versions.