Mysql service is missing

后端 未结 6 1862
Happy的楠姐
Happy的楠姐 2020-12-13 17:50

I have installed Mysql server locally and everything was working Ok but today when I tried to get a connection to the local db, I got an error. After checking services showe

6条回答
  •  悲哀的现实
    2020-12-13 18:21

    If you wish to have your config file on a different path you have to give your service a name:

    mysqld --install NAME --defaults-file=C:\my-opts2.cnf
    

    You can also use the name to install multiple mysql services listening on different sockets if you need that for some reason. You can see why it's failing by copying the execution path and adding --console to the end in the terminal. Finally, you can modify the starting path of a service by regediting:

    HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\services\NAME
    
    

    That works well but it isn't as useful because the windows service mechanism provides little logging capabilities.

提交回复
热议问题