Studio/ Player Error

Hi Jess,
I keep having problems with my studio, besides the fact that i cannot modify any of the default players, if i create a new player it works in studio but when i go back to content and try and select it from the drop down everything freezez, i can’t select the old players, if i do a ctrl+f5 refresh the old players start working but the one i created in studio just gives a “Undefined” error with no counterpart in kaltlog:

Please check the attached imagine.

Edit: This is the error i am getting
angular-1.0.4.min.js:60 TypeError: Cannot read property ‘split’ of undefined
at Object.getVersionFromPath (kmc.min.js?v=v5.40.2:6)
at Object. (kmc.min.js?v=v5.40.2:5)
at Function.each (jquery-1.8.3.min.js:2)
at s (kmc.min.js?v=v5.40.2:5)
at Object.fn (kmc.min.js?v=v5.40.2:6)
at Object.$digest (angular-1.0.4.min.js:84)
at a.$apply (angular-1.0.4.min.js:86)
at a (kmc.min.js?v=v5.40.2:5)
at kmc.min.js?v=v5.40.2:5
at a.$broadcast (angular-1.0.4.min.js:88)
(anonymous) @ angular-1.0.4.min.js:60

Regards,
Jacob R

Hi @razvan_iacob,

What does your /opt/kaltura/apps/studio/v*/studio.ini look like?

Hi Jess,
This is the output:

[root@node1 448]# cat /opt/kaltura/apps/studio/v*/studio.ini
[general]
component.name = HTML5Studio ;the application Name
component.version = v2.0.8 ;similar to folder name

[defaultKdp]
widgets.studio.version = v2.0.8
widgets.studio.name = Video Studio V2
widgets.studio.usage = html5studio
widgets.studio.config = ‘{“version”:“v2.0.8”, “name”:“Video Studio V2”, “tags”:“studio_v2”, “html5_version”:“v2.50”, “html5lib”:"//portal.servcast.net/html5/html5lib/v2.50/mwEmbedLoader.php", “default_entryID”:"@DEF_ENTRY@", “defaultLocale”:“en_US”, “defaultPlayerConfig”:[]}’

[general]
component.name = HTML5Studio ;the application Name
component.version = v2.0.8 ;similar to folder name

[defaultKdp]
widgets.studio.version = v2.0.8
widgets.studio.name = Video Studio V2
widgets.studio.usage = html5studio
widgets.studio.config = ‘{“version”:“v2.0.8”, “name”:“Video Studio V2”, “tags”:“studio_v2”, “html5_version”:“v2.50”, “html5lib”:"//portal.servcast.net/html5/html5lib/v2.50/mwEmbedLoader.php", “default_entryID”:"@DEF_ENTRY@", “defaultLocale”:“en_US”, “defaultPlayerConfig”:[]}’

Hi @razvan_iacob,

Did you just paste the output twice by mistake or do you really have duplicate sections in the INI file?
Also, try to redploy with:

# php $BASE_DIR/app/deployment/uiconf/deploy_v2.php --ini=/opt/kaltura/apps/studio/v2.0.8/studio.ini

or, if running on Ubuntu/Debian, the same as above but adding --user=www-data and then also reload Apache.
and remember to reload Apache afterwards.

No the output looks doubled because i have:
drwxr-xr-x. 10 root root 4096 Jan 19 06:00 v2.0.5
drwxr-xr-x. 10 root root 4096 Feb 1 03:22 v2.0.8

And because i have two versions but with the same ini file, that’s why the it looks like that i guess.

Edit:
[root@node1 v2.0.8]# php $BASE_DIR/app/deployment/uiconf/deploy_v2.php --ini=/opt/kaltura/apps/studio/v2.0.8/studio.ini
Deployed successfully
[root@node1 v2.0.8]# service httpd reload
Reloading httpd:
[root@node1 v2.0.8]#

Edit: Removed v2.0.5 altogether from the server.

But i have the same errors.

OK, a few things:

mysql> select * from ui_conf where id=$PLAYER_ID\G

Then, does /opt/kaltura/web/VALUE_RETURNED_FROM_conf_file_path_COLUMN exist?
If not, is the directory writeable to the Apache user? if it does exist, is it readable to the Apache user and does it have content?

Also, is the value for the html5_url column correct?

This is what i get when i run the first query.
mysql> use kaltura;
Reading table information for completion of table and column names
You can turn off this feature to get a quicker startup with -A

Database changed
mysql> select * from ui_conf where id=$PLAYER_ID\G;
ERROR 1054 (42S22): Unknown column ‘$PLAYER_ID’ in 'where clause’
ERROR:
No query specified

mysql> select * from ui_conf where id=$PLAYER_ID;
ERROR 1054 (42S22): Unknown column ‘$PLAYER_ID’ in 'where clause’
mysql>

Edit1: Regarding the path of the config file. if you are reffering to the uiconf_xxxxxx_.xml thing, yes that exists as in the database, but the file is a empty xml file. Besides those there are some files uiconf_xxxxx_xx.config.xml those exista and have entries in them, explicitly the entries i entered in the new player i created for example.

As a concrete example: the new player is is 23448656. the path that shows in the database exists
mysql> select conf_file_path from ui_conf where id=23448656;
±---------------------------------------------------------+
| conf_file_path |
±---------------------------------------------------------+
| /content/generatedUiConf/23/448/ui_conf_23448656__22.xml |
±---------------------------------------------------------+
1 row in set (0.00 sec)

But the file itself is empty however there is a file ui_conf_23448656__22.config.xml that has the options that i added in the new player.

Seems the respective files here is the output:

[root@node1 448]# ll ui_conf_23448656__22.xml
-rw-r–r--. 1 root root 5273 Feb 1 2017 ui_conf_23448656__22.xml
[root@node1 448]# ll ui_conf_23448656__22.config.xml
-rw-r-----. 1 apache kaltura 2697 Feb 1 2017 ui_conf_23448656__22.config.xml
[root@node1 448]#

So the xml is owned by root root
And .config.xml is owned by apache kaltura

Also not very clear to what are you reffering as the value for html5 column, where should i find that ?

Regards,
Jacob R.

html5_url is a column in the kaltura.ui_conf table.
As for the files, the one owned by root has r permissions for other, so Studio should still be able to read it but best to set all flles under /opt/kaltura/web//content/generatedUiConf to be writeable to the Apache user.

Also, when I wrote $PLAYER_ID, I meant for you to replace it with your actual UI conf ID for the player, you can see that in the Studio’s index page.

Database changed
mysql> select conf_file_path from ui_conf where id=23448682;
±---------------------------------------------------------+
| conf_file_path |
±---------------------------------------------------------+
| /content/generatedUiConf/23/448/ui_conf_23448682__12.xml |
±---------------------------------------------------------+
1 row in set (0.00 sec)

mysql> Ctrl-C – exit!
Aborted
[root@node1 generatedUiConf]# ll /content/generatedUiConf/23/448/ui_conf_23448682__12.xml
ls: cannot access /content/generatedUiConf/23/448/ui_conf_23448682__12.xml: No such file or directory

Seems when i am creating new players the xml is not getting created even tho the database entry exists.
Also i’ve changed the ownership of all the files under generateduiconf to apache:kaltura
Regarding the html5_url for the same ui_conf it is as follows:

mysql> select html5_url from ui_conf where id=23448682;
±-------------------------------------------+
| html5_url |
±-------------------------------------------+
| /html5/html5lib/{latest}/mwEmbedLoader.php |
±-------------------------------------------+
1 row in set (0.00 sec)

Please advice what to check further, because it’s killing me.

it’s not /content/generatedUiConf/23/448/ui_conf_23448682__12.xml it should be /opt/kaltura/web/content/generatedUiConf/23/448/ui_conf_23448682__12.xml, the conf_file_path is relative to /opt/kaltura/web.

What does:

ls -al /opt/kaltura/web/content/generatedUiConf/23/448/ui_conf_23448682*

return?
also, easiest way to test permissions is to temporarily edit /etc/passwd so that the Apache user can start a shell session.
Before you read on, be sure to change this back after testing as this poses a security risk if left this way.

apache:x:48:48:Apache:/var/www:/sbin/nologin

becomes:

apache:x:48:48:Apache:/var/www:/bin/sh

this will allow you to start a shell as the apache user, like so:

# su - apache

Then you can check whether you’re able to create a file under /opt/kaltura/web/content/generatedUiConf/23/448/ with:

$ touch /opt/kaltura/web/content/generatedUiConf/23/448/test

If that doesn’t work, you need to understand why, probably wrong permissions to one of the directories along the path, if you do manage to create the file, then we can assume the issue is not with permissions, in which case, you should check for errors in the Apache error log [/opt/kaltura/log/kaltura_apache_errors*.log] and the API logs [/opt/kaltura/log/kaltura_api_v3.log and /opt/kaltura/log/kaltura_prod.log].

Yes that is correct, it’s my mistake, i was checking the correct links, i know the path is relative to /opt/kaltura/web, but this has been messing with my head…can’t think straight.

[root@node1 0]# ls -al /opt/kaltura/web/content/generatedUiConf/23/448/ui_conf_23448682*
-rw-r-----. 1 apache kaltura 1747 Feb 2 2017 /opt/kaltura/web/content/generatedUiConf/23/448/ui_conf_23448682__12.config.xml
-rw-r-----. 1 apache kaltura 13523 Feb 2 2017 /opt/kaltura/web/content/generatedUiConf/23/448/ui_conf_23448682__12.xml
-rw-r-----. 1 apache kaltura 1747 Feb 2 2017 /opt/kaltura/web/content/generatedUiConf/23/448/ui_conf_23448682__22.config.xml
-rw-r-----. 1 apache kaltura 376 Feb 2 2017 /opt/kaltura/web/content/generatedUiConf/23/448/ui_conf_23448682__2.config.xml

What look like beeing correct.
Also managed to create the test file

[root@node1 0]# nano /etc/passwd
[root@node1 0]# su - apache
-sh-4.1$ ^C
-sh-4.1$ touch /opt/kaltura/web/content/generatedUiConf/23/448/test
-sh-4.1$ ll /opt/kaltura/web/content/generatedUiConf/23/448/test
-rw-r–r--. 1 apache apache 0 Feb 2 2017 /opt/kaltura/web/content/generatedUiConf/23/448/test
-sh-4.1$

So it’s not a permissions issue. Please check the logs while trying to load the player and see what errors are raised…
You can use the kaltog alias which will output these errors/exceptions to STDOUT and then look at the logs to find the root cause.

Jess, the strange thing is i get no relevant error in any of the mentioned logs about my entry or ui_conf id i am using.
And another thing i observed and that i find very strange, the player works in Studio, but not when i select it from the player list nothing happens, and also if i select another player they don’t update the player preview, if I refresh the page and go back to content and preview and embedd and select one of the default players, it works i can select the other players, untill I select the new player, once I select it then i cannot select even the old players.

Again no relevant entries in any logs when i select the player.
What I have and in kaltlog and apache logs is just:
(My Studio version is v2.0.8 )

[root@node1 v2.0.8]# tail -f /opt/kaltura/log/kaltura_apache_errors*.log
[Thu Feb 02 03:40:17 2017] [error] [client 162.244.80.123] File does not exist: /opt/kaltura/app/alpha/web/phpmyadmin
[Thu Feb 02 03:41:12 2017] [error] [client 191.96.249.42] File does not exist: /opt/kaltura/app/alpha/web/phpmyadmin
[Thu Feb 02 04:02:31 2017] [error] [client 162.244.80.123] File does not exist: /opt/kaltura/apps/studio/v2.0.5, referer: http://portal.servcast.net/index.php/kmc/kmc4
[Thu Feb 02 04:08:03 2017] [error] [client 162.244.80.123] File does not exist: /opt/kaltura/apps/studio/v2.0.5, referer: http://portal.servcast.net/index.php/kmc/kmc4
[Thu Feb 02 04:08:25 2017] [error] [client 162.244.80.123] File does not exist: /opt/kaltura/apps/studio/v2.0.5, referer: http://portal.servcast.net/index.php/kmc/kmc4
[Thu Feb 02 04:18:42 2017] [error] [client 162.244.80.123] File does not exist: /opt/kaltura/apps/studio/v2.0.5, referer: http://portal.servcast.net/index.php/kmc/kmc4
[Thu Feb 02 04:19:05 2017] [error] [client 162.244.80.123] File does not exist: /opt/kaltura/apps/studio/v2.0.5, referer: http://portal.servcast.net/index.php/kmc/kmc4
[Thu Feb 02 04:19:32 2017] [error] [client 162.244.80.123] File does not exist: /opt/kaltura/apps/studio/v2.0.5, referer: http://portal.servcast.net/index.php/kmc/kmc4
[Thu Feb 02 04:21:06 2017] [error] [client 162.244.80.123] File does not exist: /opt/kaltura/apps/studio/v2.0.5, referer: http://portal.servcast.net/index.php/kmc/kmc4
[Thu Feb 02 04:30:31 2017] [error] [client 162.244.80.123] File does not exist: /opt/kaltura/apps/studio/v2.0.5, referer: http://portal.servcast.net/index.php/kmc/kmc4

In kaltlog i get the a lot of analytics errors t. but again no entry when I select the player in preview and embed.

]
2017-02-02 04:45:08 [0.000945] [162.244.80.123] [1734183855] [4] [API] [KalturaDispatcher->dispatch] CRIT: exception ‘Exception’ with message ‘Action does not exist!’ in /opt/kaltura/app/infra/log/KalturaLog.php:74
Stack trace:
#0 /opt/kaltura/app/api_v3/lib/KalturaDispatcher.php(56): KalturaLog::crit(‘Action does not…’)

#3 {main}
2017-02-02 04:45:08 [0.000722] [162.244.80.123] [1734183855] [5] [API] [KalturaFrontController->getExceptionObject] ERR: exception ‘KalturaAPIException’ with message ‘Action “trackevent” does not exists for service “analytics”’ in /opt/kaltura/app/api_v3/lib/KalturaDispatcher.php:57
Stack trace:
#0 /opt/kaltura/app/api_v3/lib/KalturaFrontController.php(113): KalturaDispatcher->dispatch(‘analytics’, ‘trackEvent’, Array)
]
2017-02-02 04:45:19 [0.001084] [162.244.80.123] [548124190] [4] [API] [KalturaDispatcher->dispatch] CRIT: exception ‘Exception’ with message ‘Action does not exist!’ in /opt/kaltura/app/infra/log/KalturaLog.php:74
Stack trace:
#0 /opt/kaltura/app/api_v3/lib/KalturaDispatcher.php(56): KalturaLog::crit(‘Action does not…’)

#3 {main}
2017-02-02 04:45:19 [0.000781] [162.244.80.123] [548124190] [5] [API] [KalturaFrontController->getExceptionObject] ERR: exception ‘KalturaAPIException’ with message ‘Action “trackevent” does not exists for service “analytics”’ in /opt/kaltura/app/api_v3/lib/KalturaDispatcher.php:57
Stack trace:
#0 /opt/kaltura/app/api_v3/lib/KalturaFrontController.php(113): KalturaDispatcher->dispatch(‘analytics’, ‘trackEvent’, Array)

]
2017-02-02 04:45:21 [0.000875] [162.244.80.123] [978685516] [4] [API] [KalturaDispatcher->dispatch] CRIT: exception ‘Exception’ with message ‘Action does not exist!’ in /opt/kaltura/app/infra/log/KalturaLog.php:74
Stack trace:
#0 /opt/kaltura/app/api_v3/lib/KalturaDispatcher.php(56): KalturaLog::crit(‘Action does not…’)

#3 {main}
2017-02-02 04:45:21 [0.000704] [162.244.80.123] [978685516] [5] [API] [KalturaFrontController->getExceptionObject] ERR: exception ‘KalturaAPIException’ with message ‘Action “trackevent” does not exists for service “analytics”’ in /opt/kaltura/app/api_v3/lib/KalturaDispatcher.php:57
Stack trace:
#0 /opt/kaltura/app/api_v3/lib/KalturaFrontController.php(113): KalturaDispatcher->dispatch(‘analytics’, ‘trackEvent’, Array)

As i said the only thing i see is:

And as you can see in the screenshot the player is the one of the kdp ones, as they are selected by default when entering preview and embed

Hi @razvan_iacob,

A bit hard for me to figure the root cause without access to the ENV. However, if I remember correctly, you ENV is of 11.n.n and you’ve only upgraded the HTML5 player. While this can often work out just fine, there are often changes in the player or Studio that require related changes in the server [the other way around can sometimes also be true]. Therefore, my suggestion would be to upgrade the entire system to the latest version [12.9.0]. This is more than likely to solve all your issues.

The idea is that i have a clusterd enviromnent and always when i upgrade nothing worked, and i have accounts on the platform and a lot of content…
And yes that is correct i have 11.18 and i upgraded only the html lib.
If needed i can give you access to the ENV just to take a look. If not how should i proceed with upgrading my whole system ?

Thank you,
Jacob R.

Hi @razvan_iacob,

I’m afraid I cannot provide that level of support. While on rare occasions I do log into user ENVs to observe a particular issue that many are affected by, this is not a scalable model and is also not the case here.
I hope you understand.

As for how to upgrade, including links to upgrade instructions below.
As with any complex server side product, upgrades can get complicated, we do our very best to simplify and test the process continuously but there are always edge cases. My best recommendation to avoid downtime is to first do so on a staging ENV. If you’ll have issues post upgrading, do post them and I’ll gladly help you solve them.
In general, I recommend performing upgrades at small intervals, you don’t have to upgrade every other week, but the longer you wait between upgrades, the bigger the delta and risk.

Upgrade howtos:

RPM based:

Deb based:

Or, if running a cluster:


Jess,
I upgraded my platform and the platform stopped working. and when i load, portal.servcast.net i get the default apache web page…

Hi @razvan_iacob,

Did you re-run the config scripts after upgrading the packages? if not, please run them.
If you did, start by checking the defined Apache vhosts by running:
# apachectl -t -DDUMP_VHOSTS

And paste the output here.

Yes,
I did run the configuration scripts.

apachectl -t -DDUMP_VHOSTS
VirtualHost configuration:
wildcard NameVirtualHosts and default servers:
*:443 portal.servcast.net (/etc/httpd/conf.d/zzzkaltura.conf:1)
Syntax OK

OK, few issues I can see, first:
# curl -I -v https://portal.servcast.net
curl: (60) SSL certificate problem: unable to get local issuer certificate
More details here: http://curl.haxx.se/docs/sslcerts.html

curl performs SSL certificate verification by default, using a "bundle"
of Certificate Authority (CA) public keys (CA certs). If the default
bundle file isn’t adequate, you can specify an alternate file
using the --cacert option.

So, something is off with the CA cert.
You should have /opt/kaltura/app/configurations/apache/kaltura.ssl.conf symlinked to /etc/httpd/conf.d/zzzkaltura.ssl.conf if the node is to work over SSL.
/opt/kaltura/app/configurations/apache/kaltura.ssl.conf should include:

SSLCertificateFile @SSL_CERTIFICATE_FILE@
SSLCertificateKeyFile @SSL_CERTIFICATE_KEY_FILE@
SSLCACertificateFile @SSL_CERTIFICATE_CHAIN_FILE@

Where the placeholders should be paths to the relevant file. You are prompted about that during kaltura-front-config.sh if you answered:

Is your Apache working with SSL?[Y/n]

with a ‘Y’.

Please re-run kaltura-front-config.sh and paste the full output here. Of course, do not paste any confidential info but I need to understand how you answered the prompts.

Also, when running:
# curl -I -v https://portal.servcast.net -k

Where, -k means (SSL) This option explicitly allows curl to perform “insecure” SSL connections and transfers, the RC is:
HTTP/1.1 403 Forbidden

After making sure you answered yes to SSL and provided the paths to the key, cert and CA files, if it’s still 403, need to check the Apache error and access logs to understand why.
For SSL, the Kaltura VHosts logs will be under /opt/kaltura/log/kaltura_apache_errors_ssl.log and /opt/kaltura/log/kaltura_apache_access_ssl.log, for non SSL, they will be /opt/kaltura/log/kaltura_apache_errors.log and /opt/kaltura/log/kaltura_apache_access.log