kaltura / platform-install-packages

Official deployment packages to install the Kaltura platform on a server or cluster environments using native OS package managers
GNU Affero General Public License v3.0
520 stars 241 forks source link

issue with the mysql DB root password #404

Closed hsafe closed 9 years ago

hsafe commented 9 years ago

Hi While trying to run the kaltura /opt/kaltura/bin/kaltura-config-all.sh script, I failed to notice the issue for the root mysql passwod entry: /etc/kaltura.d/system.ini: line 25: -p: command not found which in turn it does not allow the script finish. Here is the versions I have: Using Centos 6.5 64bit and running a clean install based on the page:https://github.com/kaltura/platform-install-packages/blob/master/doc/install-kaltura-redhat-based.md kaltura-base-10.11.0-7.noarch kaltura-monit-5.13-1.x86_64 Can you please help, am sure that must be a script accepting the superuser password for mysql to later use it configing the database...

KalturaCommunity-zz commented 9 years ago

Hello,

What is line 25 in /etc/kaltura.d/system.ini?

May the source be with you,

Jess Portnoy

Join us for the Kaltura Connect Virtual Summits 2015 - Register now! connect.kaltura.com

On Sun, 24 May 2015, hsafe wrote:

Hi While trying to run the kaltura /opt/kaltura/bin/kaltura-config-all.sh script, I failed to notice the issue for the root mysql passwod entry: /etc/kaltura.d/system.ini: line 25: -p: command not found which in turn it does not allow the script finish. Here is the versions I have: kaltura-base-10.11.0-7.noarch kaltura-monit-5.13-1.x86_64

— Reply to this email directly or view it on GitHub.[ACH7XqrfIpp3gvBhHGHcfwTi8ch5tKc7ks5oMa8MgaJpZM4EnX8g.gif]

hsafe commented 9 years ago

That is an empty line really, I wonder if the file is altered really; but could not find a samlpe script online to replace it ...and would not like to undergo a fresh install :( I did a: vim /opt/kaltura/bin/kaltura-config-all.sh +25

jessp01 commented 9 years ago

Please try to run kaltura-base-config.sh again and provide a proper passwd to MySQL when prompted.

Then, recheck contents of system.ini.

May the source be with you,

Jess Portnoy

Join us for the Kaltura Connect Virtual Summits 2015 - Register now! connect.kaltura.com

On Sun, 24 May 2015, hsafe wrote:

That is an empty line really, I wonder if the file is altered really; but could not find a samlpe script online to replace it ...and would not like to undergo a fresh install :( I did a: vim /opt/kaltura/bin/kaltura-config-all.sh +25

— Reply to this email directly or view it on GitHub.[AFBqvfb19IHeEURp4YvwAbrVY999DSM8ks5oMbCmgaJpZM4EnX8g.gif]

hsafe commented 9 years ago

ahh...interestingly here is what I get at he prompt:

[root@localhost bin]# /opt/kaltura/bin/kaltura-base-config.sh /etc/kaltura.d/system.ini: line 25: -p: command not found kaltura-base-10.11.0-7.noarch /etc/kaltura.d/system.ini: line 25: -p: command not found

jessp01 commented 9 years ago

Please remove symlink /etc/kaltura.d/system.ini and retry.

May the source be with you,

Jess Portnoy

Join us for the Kaltura Connect Virtual Summits 2015 - Register now! connect.kaltura.com

On Sun, 24 May 2015, hsafe wrote:

ahh...interestingly here is what I get at he prompt:

[root@localhost bin]# /opt/kaltura/bin/kaltura-base-config.sh /etc/kaltura.d/system.ini: line 25: -p: command not found kaltura-base-10.11.0-7.noarch /etc/kaltura.d/system.ini: line 25: -p: command not found

— Reply to this email directly or view it on GitHub.[AFBqvYQ4qOCcljIxk9bGKQTraXpzXTbQks5oMbGqgaJpZM4EnX8g.gif]

jessp01 commented 9 years ago

Hello,

Any updates?

hsafe commented 9 years ago

Dear Jess

I failed to follow up on this primarily due to the fact that we encountered an emergency situation with failure of few services in other locations...In fact receive this mail amist those communications... One thing for sure that I want to state here and now is how great support you acted . I am in total debt to you and spare me some more time ... be sure that Ill call back either of ways ...

---- On Tue, 26 May 2015 14:35:33 +0430 Jess Portnoy<notifications@github.com> wrote ----

Hello, Any updates? — Reply to this email directly or view it on GitHub.

jessp01 commented 9 years ago

Thanks for the update and happy to help:) Luck in resolving your current emergency.

May the source be with you,

Jess Portnoy

Join us for the Kaltura Connect Virtual Summits 2015 - Register now! connect.kaltura.com

On Tue, 26 May 2015, hsafe wrote:

Dear Jess

I failed to follow up on this primarily due to the fact that we encountered an emergency situation with failure of few services in other locations...In fact receive this mail amist those communications... One thing for sure that I want to state here and now is how great support you acted . I am in total debt to you and spare me some more time ... be sure that Ill call back either of ways ...

---- On Tue, 26 May 2015 14:35:33 +0430 Jess Portnoy<notifications@github.com> wrote ----

Hello, Any updates? — Reply to this email directly or view it on GitHub.

— Reply to this email directly or view it on GitHub.[AFBqvVN6q-ZFhWc-0oxMMu7q1PhLu22Cks5oNEX1gaJpZM4EnX8g.gif]

hsafe commented 9 years ago

Hello Jess

Thanks for the excellent support. I have a question though, I did a successful install of the scripts: kaltura-base-config.sh What of the below script and if I need to do this one ? kaltura-config-all.sh As the instruction in https://github.com/kaltura/platform-install-packages/blob/master/doc/install-kaltura-redhat-based.md is referring to the kaltura-config-all.sh

DBezemer commented 9 years ago

@hsafe kaltura-base-config.sh only takes care of the basic steps, while kaltura-config-all.sh is needed for an All-in-one server. Base will not give you a fully working Kaltura environment, while kaltura-config-all.sh will take care of all requirements.

If you are not creating a cluster kaltura-config-all.sh is what you need.

hsafe commented 9 years ago

Hello again Thanks so I assumed that I must run the "all"script then. Note that Jess advised me to remove the /etc/kaltura.d/system.ini in earlier post and when I try to get the kaltura-config-all.sh ,it gets through however completing in the end with:

Configuration of 10.11.0 finished successfully! ERROR: could not find /etc/kaltura.d/system.ini so, exiting..

Any idea where I can manually/or using a script creat the file? :(

hsafe commented 9 years ago

any updates in the above? Remember that I rm -rf the file per earlier advices and now it is not being made automatically no where through the installation...Can you please advise?

jessp01 commented 9 years ago

@hsafe, I am not sure I understand our current situation...

What exactly happens when you run kaltura-config-all.sh? it should run several sub scripts, one of them is the kaltura-base-config.sh which should create the system.ini symlink..

Thanks,

hsafe commented 9 years ago

Hi Jess Well the thing is that the all.sh finishes the base-config.sh completely and then complains about non- existant system.ini file to proceed i.e I get up to the Configuration of 10.11.0 finished successfully! and apparently it is the end of the base-config.sh....

jessp01 commented 9 years ago

Can you please run base-config with bash -x?

bash -x /opt/kaltura/bin/kaltura-base-config.sh /path/to/kaltura.ans

2>/tmp/logfile

And send me the output by mail?

Note that you should use an answer file so that it does not interactively prompt you. You can find previously generated answer files under /tmp/kaltura*ans

Thanks,

May the source be with you,

Jess Portnoy

Join us for the Kaltura Connect Virtual Summits 2015 - Register now! virtualconnect2015.kaltura.com

On Sun, 31 May 2015, hsafe wrote:

Hi Jess Well the thing is that the all.sh finishes the base-config.sh completely and then complains about non- existant system.ini file to proceed i.e I get up to the Configuration of 10.11.0 finished successfully! and apparently it is the end of the base-config.sh....

— Reply to this email directly or view it on GitHub.[AFBqvTNO9h4AgyTluEr7KKTzBz086WPtks5oOuF5gaJpZM4EnX8g.gif]

hsafe commented 9 years ago

Sorry scroll line got exhausted find the complete log here attached ...

On 5/31/2015 3:38 PM, Jess Portnoy wrote:

Can you please run base-config with bash -x?

bash -x /opt/kaltura/bin/kaltura-base-config.sh /path/to/kaltura.ans

2>/tmp/logfile

And send me the output by mail?

Note that you should use an answer file so that it does not interactively prompt you. You can find previously generated answer files under /tmp/kaltura*ans

Thanks,

May the source be with you,

Jess Portnoy

Join us for the Kaltura Connect Virtual Summits 2015 - Register now! virtualconnect2015.kaltura.com

On Sun, 31 May 2015, hsafe wrote:

Hi Jess Well the thing is that the all.sh finishes the base-config.sh completely and then complains about non- existant system.ini file to proceed i.e I get up to the Configuration of 10.11.0 finished successfully! and apparently it is the end of the base-config.sh....

— Reply to this email directly or view it on GitHub.[AFBqvTNO9h4AgyTluEr7KKTzBz086WPtks5oOuF5gaJpZM4EnX8g.gif]

— Reply to this email directly or view it on GitHub https://github.com/kaltura/platform-install-packages/issues/404#issuecomment-107156532.

Hamid Safe Borhancid.com

[root@red5 ~]# bash -x /opt/kaltura/bin/kaltura-base-config.sh /tmp/kaltura_ kaltura_24_05_13_59.ans kaltura_24_05_14_27.ans kaltura_24_05_15_18.ans kaltura_30_05_17_19.ans kaltura_31_05_15_42.ans
kaltura_24_05_14_01.ans kaltura_24_05_14_28.ans kaltura_30_05_10_40.ans kaltura_30_05_17_28.ans
kaltura_24_05_14_06.ans kaltura_24_05_15_07.ans kaltura_30_05_17_15.ans kaltura_30_05_17_35.ans
[root@red5 ~]# bash -x /opt/kaltura/bin/kaltura-base-config.sh /tmp/kaltura_30_05_17_35.ans ++ dirname /opt/kaltura/bin/kaltura-base-config.sh

+ echo -en '\033[0;36m

Kaltura install answer file written to /tmp/kaltura_31_05_15_54.ans - Please save it!

This answers file can be used to silently-install re-install this machine or deploy other hosts in your cluster.

\033[m '

Kaltura install answer file written to /tmp/kaltura_31_05_15_54.ans - Please save it!

This answers file can be used to silently-install re-install this machine or deploy other hosts in your cluster.

hsafe commented 9 years ago

Jess any updates ?As the base script is completely installed successfully(per the end message)can we create manually the file and let the -all script carry on ?

jessp01 commented 9 years ago

Hello,

Can you please verify /opt/kaltura/app/configurations/system.ini currently contains all correct values, then manually symlink to /etc/kaltura.d and re-run config-all?

hsafe commented 9 years ago

Well I get up to this:

ERROR 1045 (28000): Access denied for user 'kaltura'@'localhost' (using password: YES)

    Archving logs to /opt/kaltura/log/log_31_05_15_18_28.tar.gz...

Could there be a problem of multiple accounts in the mysql db? mysql> select user from mysql.user; +---------+ | user | +---------+ | etl | | kaltura | | root | | caltura | | kaltura | | root | +---------+ 6 rows in set (0.00 sec)

mysql>

I presume your script is responsible to create the user kaltura on the db right?

KalturaCommunity-zz commented 9 years ago

what is the output for: mysql> select user,host from mysql.user;

Also, you can see the exact query batch tries to do if you run it with -x

Once this works from CLI, it will also work from the script.

May the source be with you,

Jess Portnoy

Join us for the Kaltura Connect Virtual Summits 2015 - Register now! virtualconnect2015.kaltura.com

On Sun, 31 May 2015, hsafe wrote:

Well I get up to this:

  • /opt/kaltura/bin/kaltura-batch-config.sh /tmp/kaltura_30_05_17_35.ans kaltura-batch-10.11.0-1.noarch base-config completed successfully, if you ever want to re-configure your system (e.g. change DB hostname) run the following script: # rm /opt/kaltura/app/base-config.lock # /opt/kaltura/bin/kaltura-base-config.sh

ERROR 1045 (28000): Access denied for user 'kaltura'@'localhost' (using password: YES)

Archving logs to /opt/kaltura/log/log_31_05_15_18_28.tar.gz...
  • '[' 11 -ne 0 ']'
  • echo -e '\033[1;31mERROR: /opt/kaltura/bin/kaltura-batch-config.sh failed:( You can re-run it when the issue is fixed.\033[m' ERROR: /opt/kaltura/bin/kaltura-batch-config.sh failed:( You can re-run it when the issue is fixed.
  • exit 113

Could there be a problem of multiple accounts in the mysql db? mysql> select user from mysql.user; +---------+ | user | +---------+ | etl | | kaltura | | root | | caltura | | kaltura | | root | +---------+ 6 rows in set (0.00 sec)

mysql>

I presume your script is responsible to create the user kaltura on the db right?

— Reply to this email directly or view it on GitHub.[ACH7Xmfz9p1zAXx90kaZ17-hJeib0S9Yks5oOwyLgaJpZM4EnX8g.gif]

hsafe commented 9 years ago

mysql> select user,host from mysql.user; +---------+-----------+ | user | host | +---------+-----------+ | etl | % | | kaltura | % | | root | 127.0.0.1 | | caltura | localhost | | kaltura | localhost | | root | localhost | +---------+-----------+

KalturaCommunity-zz commented 9 years ago

I suggest you check if the command the script is trying to run works from CLI, if it does not, this needs to be corrected. You can always use kaltura-drop-db.sh to drop all Kaltura related info from the DB and then reinstall. It is possible that the double kaltura user is causing MySQL to refuse a connection IF the passwds are not the same in both. Did you create one of these manually? the install script only creates one and then sets it with a random passwd which you can find in /etc/kaltura.d/system.ini, as well as in your answer files and under /opt/kaltura/app/configurations/db.ini

All these places should have the same passwd for the kaltura and etl user, otherwise it will not work.

May the source be with you,

Jess Portnoy

Join us for the Kaltura Connect Virtual Summits 2015 - Register now! virtualconnect2015.kaltura.com

On Sun, 31 May 2015, hsafe wrote:

mysql> select user,host from mysql.user; +---------+-----------+ | user | host | +---------+-----------+ | etl | % | | kaltura | % | | root | 127.0.0.1 | | caltura | localhost | | kaltura | localhost | | root | localhost | +---------+-----------+

— Reply to this email directly or view it on GitHub.[ACH7Xm_Cz-wi12CsW31nwTFXF3NPXewhks5oOw9-gaJpZM4EnX8g.gif]

hsafe commented 9 years ago

Dear Jess

While Ill do the above, I was wondering if Centos 6.5 minimal install has been the source of a clean install for you. I say this as had to strive in other instructions-usually old lengthy and complex where the requirements were more than the present installed packages in this machine. One caution is also the site turnkey where the admin also refered to multiple issues encountered in installing kaltura in a Centos server. One last thing, is the method/scripts primarily developed on Ubuntu and adopted to Centos?

On 5/31/2015 8:18 PM, KalturaCommunity wrote:

I suggest you check if the command the script is trying to run works from CLI, if it does not, this needs to be corrected. You can always use kaltura-drop-db.sh to drop all Kaltura related info from the DB and then reinstall. It is possible that the double kaltura user is causing MySQL to refuse a connection IF the passwds are not the same in both. Did you create one of these manually? the install script only creates one and then sets it with a random passwd which you can find in /etc/kaltura.d/system.ini, as well as in your answer files and under /opt/kaltura/app/configurations/db.ini

All these places should have the same passwd for the kaltura and etl user, otherwise it will not work.

May the source be with you,

Jess Portnoy

Join us for the Kaltura Connect Virtual Summits 2015 - Register now! virtualconnect2015.kaltura.com

On Sun, 31 May 2015, hsafe wrote:

mysql> select user,host from mysql.user; +---------+-----------+ | user | host | +---------+-----------+ | etl | % | | kaltura | % | | root | 127.0.0.1 | | caltura | localhost | | kaltura | localhost | | root | localhost | +---------+-----------+

— Reply to this email directly or view it on GitHub.[ACH7Xm_Cz-wi12CsW31nwTFXF3NPXewhks5oOw9-gaJpZM4EnX8g.gif]

— Reply to this email directly or view it on GitHub https://github.com/kaltura/platform-install-packages/issues/404#issuecomment-107211519.

Hamid Safe Borhancid.com

jessp01 commented 9 years ago

Hello,

Minimal install should be fine and it does not appear any of your issues stem from that. Actually, the original install was first developed for RHEL/CentOS and ported onto Deb based systems.

Perhaps it would be best for you to simply remove everything as explained here: https://github.com/kaltura/platform-install-packages/blob/master/doc/install-kaltura-redhat-based.md#remove-kaltura

And redo the install process?

hsafe commented 9 years ago

Hi Jess OK this is good and lets hope a clean up solve the issue ...

On 6/1/2015 2:01 PM, Jess Portnoy wrote:

Hello,

Minimal install should be fine and it does not appear any of your issues stem from that. Actually, the original install was first developed for RHEL/CentOS and ported onto Deb based systems.

Perhaps it would be best for you to simply remove everything as explained here: https://github.com/kaltura/platform-install-packages/blob/master/doc/install-kaltura-redhat-based.md#remove-kaltura

And redo the install process?

— Reply to this email directly or view it on GitHub https://github.com/kaltura/platform-install-packages/issues/404#issuecomment-107380389.

Hamid Safe Borhancid.com

jessp01 commented 9 years ago

Please let me know if otherwise. For now, can you close this issue and reopen should reinstall have issues?

Also, remember you must set a MySQL root passwd and also run mysql_secure_install in order for things to work, perhaps this was also an issue in your prev. attempt?

May the source be with you,

Jess Portnoy

Join us for the Kaltura Connect Virtual Summits 2015 - Register now! virtualconnect2015.kaltura.com

On Mon, 1 Jun 2015, hsafe wrote:

Hi Jess OK this is good and lets hope a clean up solve the issue ...

On 6/1/2015 2:01 PM, Jess Portnoy wrote:

Hello,

Minimal install should be fine and it does not appear any of your issues stem from that. Actually, the original install was first developed for RHEL/CentOS and ported onto Deb based systems.

Perhaps it would be best for you to simply remove everything as explained here: https://github.com/kaltura/platform-install-packages/blob/master/doc/install-kaltura-redhat-based.md#remove-kaltura

And redo the install process?

— Reply to this email directly or view it on GitHub https://github.com/kaltura/platform-install-packages/issues/404#issuecomment-107380389.

Hamid Safe Borhancid.com

— Reply to this email directly or view it on GitHub.[AFBqvdcktjcTz45-8ibE99cLnMOhaIlqks5oPB5LgaJpZM4EnX8g.gif]