Plabon Dutta Plabon Dutta - 5 months ago 30
SQL Question

I can not start the MySQL Server from command line in windows

Whenever I write the command "C:\Program Files\MySQL\MySQL Server 5.0\bin\mysqld" the command prompt hits back with something like this:

C:\>"C:\Program Files\MySQL\MySQL Server 5.5\bin\mysqld"


141110 3:12:58 [Warning] Can't create test file C:\Program Files\MySQL\MySQL Server 5.5\data\Dutta.lower-test

141110 3:12:58 [Warning] Can't create test file C:\Program Files\MySQL\MySQL Server 5.5\data\Dutta.lower-test

141110 3:12:58 [Note] Plugin 'FEDERATED' is disabled.

141110 3:12:58 InnoDB: The InnoDB memory heap is disabled

141110 3:12:58 InnoDB: Mutexes and rw_locks use Windows interlocked functions

141110 3:12:58 InnoDB: Compressed tables use zlib 1.2.3

141110 3:12:58 InnoDB: Initializing buffer pool, size = 128.0M

141110 3:12:58 InnoDB: Completed initialization of buffer pool

141110 3:12:58 InnoDB: Operating system error number 5 in a file operation.

InnoDB: The error means mysqld does not have the access rights to

InnoDB: the directory. It may also be you have created a subdirectory

InnoDB: of the same name as a data file.

InnoDB: File name .\ibdata1

InnoDB: File operation call: 'create'.

InnoDB: Cannot continue operation.

I'm just a beginner. May be a silly mistake. Sorry in advance !!

Answer

The context and privileges of the current user will take affect when you manually start the executable in this way.

You either need to make sure:

  1. The current user has the correct permissions to all files and directories required
  2. You elevate permissions of the command prompt to run as an administrator

If you have the MySQL service installed you can also use net start MySQL.

This page of the MySQL manual contains useful information for installing and running the MySQL server on windows.

Please remember that once you have 'started' the MySQL service (or service) you won't actually see anything, you will then need to use a MySQL client application to connect to the server and interact.