New install mysql: unrecognized service [SOLVED]

Discussions related to the 1.36.x series of ZoneMinder
Post Reply
User avatar
michaelbr
Posts: 25
Joined: Wed Apr 05, 2023 10:25 am

New install mysql: unrecognized service [SOLVED]

Post by michaelbr »

My computer just crashed and had to re-install ZM, my previous install had no problem during install, but this time got this error when trying to restart

Code: Select all

mysql
, the error says

Code: Select all

mysql: unrecognized service
, up to this point, had no problem with installation, I suspect that I mounted my NTFS-3g drive with wrong permissions, so probably I have to remove the installation and startover again. How can I safely remove LAMP? Not sure if there are other data stored in MySQL. How can I safely remove LAMP and mariadb?

Code: Select all

# mysql_secure_installation

NOTE: RUNNING ALL PARTS OF THIS SCRIPT IS RECOMMENDED FOR ALL MariaDB
      SERVERS IN PRODUCTION USE!  PLEASE READ EACH STEP CAREFULLY!

In order to log into MariaDB to secure it, we'll need the current
password for the root user. If you've just installed MariaDB, and
haven't set the root password yet, you should just press enter here.

Enter current password for root (enter for none): 
OK, successfully used password, moving on...

Setting the root password or using the unix_socket ensures that nobody
can log into the MariaDB root user without the proper authorisation.

You already have your root account protected, so you can safely answer 'n'.

Switch to unix_socket authentication [Y/n] n
 ... skipping.

You already have your root account protected, so you can safely answer 'n'.

Change the root password? [Y/n] n
 ... skipping.

By default, a MariaDB installation has an anonymous user, allowing anyone
to log into MariaDB without having to have a user account created for
them.  This is intended only for testing, and to make the installation
go a bit smoother.  You should remove them before moving into a
production environment.

Remove anonymous users? [Y/n] n
 ... skipping.

Normally, root should only be allowed to connect from 'localhost'.  This
ensures that someone cannot guess at the root password from the network.

Disallow root login remotely? [Y/n] 
 ... Success!

By default, MariaDB comes with a database named 'test' that anyone can
access.  This is also intended only for testing, and should be removed
before moving into a production environment.

Remove test database and access to it? [Y/n] n
 ... skipping.

Reloading the privilege tables will ensure that all changes made so far
will take effect immediately.

Reload privilege tables now? [Y/n] 
 ... Success!

Cleaning up...

All done!  If you've completed all of the above steps, your MariaDB
installation should now be secure.

Thanks for using MariaDB!
I updated the 50-server.cnf according to instructions here, then tried restart mysql/mysqld, both gave unrecognized service error, used

Code: Select all

# service --status-all
, neither mysql/mysqld is listed.
Last edited by michaelbr on Mon May 29, 2023 8:45 am, edited 1 time in total.
Thanks for your comment/suggestion
Michael
dougmccrary
Posts: 1322
Joined: Sat Aug 31, 2019 7:35 am
Location: San Diego

Re: New install mysql: unrecognized service

Post by dougmccrary »

Is mysql/d even in /etc?
If not, just reinstall it.
I don't believe there will be any need to remove LA P.
Further, I think the newest versions of ZM will install a DB if there is none found. Or so it seemed. Maybe just try remove ZM and let the .deb do its thing?
User avatar
michaelbr
Posts: 25
Joined: Wed Apr 05, 2023 10:25 am

Re: New install mysql: unrecognized service

Post by michaelbr »

dougmccrary wrote: Sun May 28, 2023 3:08 am Is mysql/d even in /etc?
If not, just reinstall it.
I don't believe there will be any need to remove LA P.
Further, I think the newest versions of ZM will install a DB if there is none found. Or so it seemed. Maybe just try remove ZM and let the .deb do its thing?
Thanks for this information, it seems MX Linux did not install MySQL (it's not in /etc), here are my questions:
1) I'm not that familiar with Linux to install it on my own (just follow the instructions on the MySQL install for Debian will be enough?
2) will this install destroy some configuration on ZM install?
3) do I need MySQL? it seems MariaDB is installed and zm DB is installed on MariaDB
4) the error message said dbname=zm and user=zmuser, I don't see neither on DB install, does it mean that the installl failed?
Thanks for your comment/suggestion
Michael
User avatar
michaelbr
Posts: 25
Joined: Wed Apr 05, 2023 10:25 am

Re: New install mysql: unrecognized service [SOLVED]

Post by michaelbr »

Followed this post and it solved my problem to install ZM on MX Linux.
Thanks for your comment/suggestion
Michael
Post Reply