Problem with centos7 autoinstaller
Added by Huolin Xin over 6 years ago
I have another workstation running a fresh copy of centOS7 and I tried the centos7AutoInstallation.py installer and I encountered the following error message. Here I am running python 2.7.5.
[root@localhost Desktop]# python centos7AutoInstallation.py
File "centos7AutoInstallation.py", line 315
self.runCommand("systemctl stop mariadb")
^
SyntaxError: invalid syntax
[root@localhost Desktop]# python
Python 2.7.5 (default, Apr 11 2018, 07:36:10)
[GCC 4.8.5 20150623 (Red Hat 4.8.5-28)] on linux2
Type "help", "copyright", "credits" or "license" for more information.
Replies (8)
RE: Problem with centos7 autoinstaller - Added by Anchi Cheng over 6 years ago
I fixed it. However, mariadb stuff is only on trunk where active development is. How come you are using it ? The use of yum installation of mariadb is an alternative to mysql that I tried in my last installation. It needs others on the team to verify. Did our documentation lead you there ? We'd better change it.
RE: Problem with centos7 autoinstaller - Added by Huolin Xin over 6 years ago
Hi Anchi,
Thank you for updating this. I ran into the same "Can't connect to local MySQL server through socket mysqld.sock" problem. I found that I need to install mysql-server and I followed the guide in the link below. It might be a dependency that is worth adding to the script. BTW, I
https://www.digitalocean.com/community/tutorials/how-to-install-mysql-on-centos-7
https://www.linode.com/docs/databases/mysql/how-to-install-mysql-on-centos-7/
RE: Problem with centos7 autoinstaller - Added by Huolin Xin over 6 years ago
Anchi Cheng wrote:
I fixed it. However, mariadb stuff is only on trunk where active development is. How come you are using it ? The use of yum installation of mariadb is an alternative to mysql that I tried in my last installation. It needs others on the team to verify. Did our documentation lead you there ? We'd better change it.
BTW, using the new script, it installs mariadb-server. However, I still need to manually install mysql-server for the script to run through.
RE: Problem with centos7 autoinstaller - Added by Huolin Xin over 6 years ago
Anchi Cheng wrote:
I fixed it. However, mariadb stuff is only on trunk where active development is. How come you are using it ? The use of yum installation of mariadb is an alternative to mysql that I tried in my last installation. It needs others on the team to verify. Did our documentation lead you there ? We'd better change it.
I finally see the Leginon/Appion web interface but I encounter the following error
[huolin@DESKTOP-4JECNCG Desktop]$ START /bin/firefox "http://localhost/myamiweb/setup/autoInstallSetup.php?password=123456&myamidir=/tmp/myami/&uploadsample=1"
Error: (2059, "Authentication plugin 'caching_sha2_password' cannot be loaded: /usr/lib64/mysql/plugin/caching_sha2_password.so: cannot open shared object file: No such file or directory")
RE: Problem with centos7 autoinstaller - Added by Anchi Cheng over 6 years ago
You may find the answer from Google. What version of mysql did you install ? It may be way ahead of what we use and tested. Can you wait a few days for Sargis to run through AutoInstaller for CentOS 7 on a new workstation ?
If you got the centos7AutoInstallor.py file from myami-beta or myami-3.3, you should have had a specific version of mysql that Sargis has tested previously. Please check inside the file to see which branch it is cloning our repository from.
RE: Problem with centos7 autoinstaller - Added by Huolin Xin over 6 years ago
Anchi Cheng wrote:
I fixed it. However, mariadb stuff is only on trunk where active development is. How come you are using it ? The use of yum installation of mariadb is an alternative to mysql that I tried in my last installation. It needs others on the team to verify. Did our documentation lead you there ? We'd better change it.
Now the problem is that the databases do not exist. I tried schema_update.py and at the end of the following, there is an error.
[huolin@DESKTOP-4JECNCG dbschema]$ python schema_update.py
connected to db 'projectdb' on server 'localhost'
Traceback (most recent call last):
File "schema_update.py", line 9, in <module>
project_dbupgrade = dbupgrade.DBUpgradeTools('projectdata', drop=True)
File "/usr/lib/python2.7/site-packages/sinedon/dbupgrade.py", line 51, in init
db = sinedon.sqldb.connect(*dbconf)
File "/usr/lib/python2.7/site-packages/sinedon/sqldb.py", line 15, in connect
c = MySQLdb.connect(*newkwargs)
File "/usr/lib64/python2.7/site-packages/MySQLdb/__init__.py", line 81, in Connect
return Connection(*args, **kwargs)
File "/usr/lib64/python2.7/site-packages/MySQLdb/connections.py", line 193, in init
super(Connection, self).__init__(*args, **kwargs2)
_mysql_exceptions.OperationalError: (2059, "Authentication plugin 'caching_sha2_password' cannot be loaded: /usr/lib64/mysql/plugin/caching_sha2_password.so: cannot open shared object file: No such file or directory")
RE: Problem with centos7 autoinstaller - Added by Huolin Xin over 6 years ago
Anchi Cheng wrote:
I fixed it. However, mariadb stuff is only on trunk where active development is. How come you are using it ? The use of yum installation of mariadb is an alternative to mysql that I tried in my last installation. It needs others on the team to verify. Did our documentation lead you there ? We'd better change it.
I am seeing the following error msg in troubleshoot
!!! WARNING !!! Cannot connect to the database server with db_host: localhost db_usr : root
What is my default Database username and password in http://localhost/myamiweb/setup/ ?
RE: Problem with centos7 autoinstaller - Added by Anchi Cheng over 6 years ago
You did not answer my questions. What is the mysql version ? And why are you using the autoinstallor that clones trunk ? Unless you are a developer, please do not use that. myami-beta is sufficient for alpha-tested features pre-released.
Most likely your mysql version is too new to use the autoinstaller. Older mysql installation comes with no password for root which you change later.SeeDatabase_Server_Installation. The newest ones comes with an auto-generated root password which you need to write down druing the installation.
At this point, you have to do your installation manually with such a database.
You can follow the instruction in Database_Server_Installation with the missing steps, just remember that you will need to have password entered at each connection instead. Then continue with manually installation for webserver.