在出问题之前,利用mysqld-nt --skip-grant-tables 进行了密码的重置。
别无任何操作
现在在任务管理器里是出现不了mysql-nt.exe 了
去计算机管理处启动mysql服务则提示:在本地计算机无法启动mysql服务 错误193另:.err文件提示出下:
 
121206 11:34:33 [Note] C:\Program Files\MySQL\MySQL Server 5.0\bin\mysqld-nt: Normal shutdown121206 11:34:34 [Note] C:\Program Files\MySQL\MySQL Server 5.0\bin\mysqld-nt: Shutdown complete121206 11:41:00 [ERROR] Can't open shared library 'amd.dll' (errno: 0 )
121206 11:41:00 [Note] C:\Program Files\MySQL\MySQL Server 5.0\bin\mysqld-nt: ready for connections.
Version: '5.0.67-community-nt'  socket: ''  port: 3306  MySQL Community Edition (GPL)
Can't start server: Bind on TCP/IP port: Invalid argument
121206 11:47:07 [ERROR] Do you already have another mysqld server running on port: 3306 ?
121206 11:47:07 [ERROR] Aborting121206 11:47:07 [Note] mysqld-nt: Shutdown completeCan't start server: Bind on TCP/IP port: Invalid argument
121206 11:47:27 [ERROR] Do you already have another mysqld server running on port: 3306 ?
121206 11:47:27 [ERROR] Aborting121206 11:47:27 [Note] mysqld-nt: Shutdown complete121206 11:49:15 [Note] C:\Program Files\MySQL\MySQL Server 5.0\bin\mysqld-nt: Normal shutdown121206 11:49:15 [Note] C:\Program Files\MySQL\MySQL Server 5.0\bin\mysqld-nt: Shutdown complete121206 11:50:33 [Note] mysqld-nt: ready for connections.
Version: '5.0.67-community-nt'  socket: ''  port: 3306  MySQL Community Edition (GPL)
121206 11:53:20 [Warning] Found invalid password for user: 'root@localhost'; Ignoring user
121206 12:11:26 [Note] mysqld-nt: ready for connections.
Version: '5.0.67-community-nt'  socket: ''  port: 3306  MySQL Community Edition (GPL)
121206 12:13:13 [Warning] Found invalid password for user: 'root@localhost'; Ignoring user
Can't start server: Bind on TCP/IP port: Invalid argument
121206 12:18:26 [ERROR] Do you already have another mysqld server running on port: 3306 ?
121206 12:18:26 [ERROR] Aborting121206 12:18:26 [Note] mysqld-nt: Shutdown complete121206 15:02:09 [Note] mysqld-nt: ready for connections.
Version: '5.0.67-community-nt'  socket: ''  port: 3306  MySQL Community Edition (GPL)
121206 15:04:07 [Warning] Found invalid password for user: 'root@localhost'; Ignoring user
121206 15:50:20 [Note] mysqld-nt: ready for connections.
Version: '5.0.67-community-nt'  socket: ''  port: 3306  MySQL Community Edition (GPL) 请知道问题症结的朋友来解答,必有谢~ 

解决方案 »

  1.   

    Do you already have another mysqld server running on port: 3306端口3306被占用
    最简答的方法就是重启下
      

  2.   

    在进程中KILL MYSQL,重新启动,你安装了2个MYSQL?
    mysqld-nt --skip-grant-tables 重置密码后要结束MYSQL进程,重新启动MYSQL。
      

  3.   

    回复1楼
    我去查了端口占用,里面没有3306被占用
    回复2楼 
    在复置密码后我去进程管理器结束了mysqld-nt.exe   然后重启完就再也启动不了mysql 了
    服务器上上就一个mysql,稳定运行一年多了,由于要加新东西,我忘密码后,重置后就出现这个问题了
    刚重启完服务器,还是不行 
    以下附上一些参考内容 C:\Documents and Settings\Administrator>mysql
    ERROR 2003 (HY000): Can't connect to MySQL server on 'localhost' (10061)C:\Documents and Settings\Administrator>net start mysql
    发生系统错误 193。*** 不是有效的 Win32 应用程序。
      

  4.   

    控制面板->管理工具->服务中是否有MYSQL?能否启动
    从提示上看
    121206 15:02:09 [Note] mysqld-nt: ready for connections.
    已经启动MYSQL了
      

  5.   

    回复4楼同样提示193 错误     服务里显示 mysql 未启动啊
      

  6.   

    将*。ERR删除,重新启动MYSQL,贴ERR中的内容
      

  7.   

    重启了3遍服务器,把data 下的.err文件删除后  重新启动mysql 还是问题193    但是不生成.err 文件了
    第二遍重启服务器后, 把.err 文件还原,删除里面所有内容  再重启mysql 问题依旧,.err内容 为空
    第三遍重复第二遍....
      

  8.   

    由于下列错误,MySQL 服务启动失败: 
    MySQL 不是有效的 Win32 应用程序。 
      

  9.   

    在安装目录BIN下,是否有MySQLInstanceConfig.exe,运行配置MYSQL
      

  10.   

    有,并且重新配置,直至最后一步,又卡在了启动mysql这一步骤上
      

  11.   

    你将MY。INI COPY到其它目录,再运行试试
      

  12.   

    直接在命令行下执行 
    C:\pro....saasafa\mysql\mysql-5.1.58-win32\bin\mysqld --console然后看输出的内容是什么。如果异常则贴出显示。
      

  13.   

    结果是这样儿的,有点看不太明白,还烦请高手给看一下C:\Program Files\MySQL\MySQL Server 5.0\bin>mysqld-nt.exe --console
    InnoDB: The first specified data file .\ibdata1 did not exist:
    InnoDB: a new database to be created!
    121207 17:54:41  InnoDB: Setting file .\ibdata1 size to 10 MB
    InnoDB: Database physically writes the file full: wait...
    121207 17:54:41  InnoDB: Log file .\ib_logfile0 did not exist: new to be createdInnoDB: Setting log file .\ib_logfile0 size to 170 MB
    InnoDB: Database physically writes the file full: wait...
    InnoDB: Progress in MB: 100
    121207 17:54:43  InnoDB: Log file .\ib_logfile1 did not exist: new to be createdInnoDB: Setting log file .\ib_logfile1 size to 170 MB
    InnoDB: Database physically writes the file full: wait...
    InnoDB: Progress in MB: 100
    InnoDB: Doublewrite buffer not found: creating new
    InnoDB: Doublewrite buffer created
    InnoDB: Creating foreign key constraint system tables
    InnoDB: Foreign key constraint system tables created
    121207 17:54:45  InnoDB: Started; log sequence number 0 0
    121207 17:54:45 [ERROR] Can't open shared library 'amd.dll' (errno: 0 )
    121207 17:54:45 [Note] mysqld-nt.exe: ready for connections.
    Version: '5.0.67-community-nt'  socket: ''  port: 3306  MySQL Community Edition
    (GPL)
      

  14.   

    121207 17:54:45 [Note] mysqld-nt.exe: ready for connections.
    说明已经启动了MYSQL,检查一下MI。INI中DATADIR,看看目录中是否有
    数据文件
      

  15.   

    my.ini中的datadir 指向为数据目录,里面有建好的几个数据文件
    以下显示my.ini的截图
    输入启动进入mysql 显示如下
    C:\Documents and Settings\Administrator>mysql -n root -p
    Enter password: *******
    ERROR 2003 (HY000): Can't connect to MySQL server on 'localhost' (10061)
      

  16.   

    之前正常时进程中有mysqld-nt.exe从无不启动后,则进程中没有mysqld-nt.exe  带m开头的进程都没有
      

  17.   

    问个问题, 在服务器上运行此命令后,不关掉DOS窗口,mysqld-nt就启动了。 这怎么处理啊C:\Program Files\MySQL\MySQL Server 5.0\bin>mysqld-nt --skip-grant-tables
      

  18.   

    执行:mysqld-nt --skip-grant-tables 当前窗口将会停止。MYSQL服务已经启动了
    另外打开一个命令行窗口,执行mysql
    >use mysql 
    >update user set password=password("new_password") where user="root"; 
    >flush privileges; 
    >exit 
    用Ctrl+Alt+Del,找到mysqld-nt的进程杀掉它,在重新启动mysql-nt服务,就可以用新密码登录了
      

  19.   

    接21楼
    我就是按上述方法重置的密码, 完全遵照执行的。 在我结束mysql-nt服务后,然后重启利用net start mysql 后则提示错误193,再就无法启动mysql-nt这个服务了, 然后就出现了我1楼问题的问题了
      

  20.   

    不会吧,我用此方法解决N多密码忘记的问题,没有出现过此问题按21楼的方法能否启动MYSQL、进入MYSQL命令行?
      

  21.   

    不行啊, 我以前重置的时候也没出现问题
    现在用net start mysql 启动时,提示错误193
    用服务窗口启动时也是提示错误193. 
    就是无法启动服务。 
    直接输入启动进入mysql 显示如下
    C:\Documents and Settings\Administrator>mysql -n root -p
    Enter password: *******
    ERROR 2003 (HY000): Can't connect to MySQL server on 'localhost' (10061) 
      

  22.   

    检查一下你的MYSQL服务项中,那个执行的命令是什么? 按#15 中的方法直接放到命令中执行一下看一下结果。至少说明你的MYSQL本身没有什么问题。
      

  23.   

    C:\Program Files\MySQL\MySQL Server 5.0\bin>mysqld-nt --console
    121211  9:45:17  InnoDB: Started; log sequence number 0 43655
    121211  9:45:18 [ERROR] Can't open shared library 'amd.dll' (errno: 0 )
    121211  9:45:18 [Note] mysqld-nt: ready for connections.
    Version: '5.0.67-community-nt'  socket: ''  port: 3306  MySQL Community Edition
    (GPL)
    使用mysqld-nt --console后提示以上,这时mysql启动成功,数据访问正常。进程中也有mysqld-nt.exe但是一旦把这个CMD窗口关掉,mysqld-nt就会随之自动关掉了。 这可怎么处理啊。
      

  24.   

    mysqld --install
    试试,估计是MYSQL的服务被破坏了
      

  25.   

    利用 mysqld-nt install 提示的是服务已经存在了   然后还是不能启动服务    如果服务被破坏,怎么进行修复呢?mysqld-nt -install 提示如下 
    C:\Program Files\MySQL\MySQL Server 5.0\bin>mysqld-nt -install
    The service already exists!
    The current server installed: "C:\Program Files\MySQL\MySQL Server 5.0\bin\mysql
    d-nt" --defaults-file="C:\Program Files\MySQL\MySQL Server 5.0\my.ini" MySQL
      

  26.   

    在进程中KILL MYSQL,再mysqld --install,这就是在控制面板中建立MYSQL服务。
      

  27.   

    mysqld-nt.exe 只有在输入了命令mysqld-nt --console 后,才会出现在任务管理器中。 
    按以上步骤,当出现mysqld-nt.exe后,杀掉,然后利用mysqld-nt --install 后,提示如下
    C:\Program Files\MySQL\MySQL Server 5.0\bin>mysqld-nt -install The service already exists! The current server installed: "C:\Program Files\MySQL\MySQL Server 5.0\bin\mysql d-nt" --defaults-file="C:\Program Files\MySQL\MySQL Server 5.0\my.ini" MySQL然后去管理中的服务中,去启动mysql服务 ,提示依旧是错误193. 现在唯一可以做的就是 打开cmd窗口,输入mysqld-nt --console 一直开着这个窗口,这样服务器用到mysql的网站才能全部运行,否则全都提示无法连接到数据库
    但是这样也不是个办法啊
      

  28.   

    进入CMD窗口
    sc delete mysql服务名
    再mysqld-nt -install
      

  29.   

    按照以上步骤进行,提示全部为成功。但是服务器服务还是未开启。 任务管理器中未出现mysqld-nt.exe服务 
    运行结果如下:
    C:\Documents and Settings\Administrator>sc delete mysql
    [SC] DeleteService 成功C:\Documents and Settings\Administrator>mysqld-nt -install
    Service successfully installed.C:\Documents and Settings\Administrator>mysql
    ERROR 2003 (HY000): Can't connect to MySQL server on 'localhost' (10061)C:\Documents and Settings\Administrator>
      

  30.   

    你在服务中启动MYSQL服务没有?
      

  31.   

    先sc delete mysql成功
    再mydqld-nt -install 成功
    然后服务项中出来mysql了,点击启动。提示193错误....重试了两遍,重启了服务器,还是以上的错误
      

  32.   

    net start mysql 也试了的, 结果如下C:\Documents and Settings\Administrator>net start mysql
    发生系统错误 193。*** 不是有效的 Win32 应用程序。
    C:\Documents and Settings\Administrator>
      

  33.   

    要在MYSQL的安装目录BIN下运行
      

  34.   

    那么纠结。保存data文件夹,卸载了重装,再把data覆盖了
      

  35.   

    在bin目录下运行也是一样的结果 呈现如下C:\Program Files\MySQL\MySQL Server 5.0\bin>net start mysql
    发生系统错误 193。*** 不是有效的 Win32 应用程序。
    C:\Program Files\MySQL\MySQL Server 5.0\bin>my.ini 有过修改,是利用MySQLInstanceConfig.exe 进行过修复,不过修复到最后也是卡在了不能启动服务上了就过不去了。
    后来我又把my.ini 重新恢复了。
      

  36.   

    删除*.ERR,重新启动MYSQL,贴*.ERR
     MY.ini内容
      

  37.   

    重启服务器后,直接按以下命令进行,一直无法启动服务
    当使用mysqld-nt --console时进程里面出现了mysqld-nt 此服务。但是一关掉窗口,就会消失掉mysqld-nt.exeMicrosoft Windows [版本 5.2.3790]
    (C) 版权所有 1985-2003 Microsoft Corp.C:\Documents and Settings\Administrator>cd \program files\mysql\mysql server 5.0
    \binC:\Program Files\MySQL\MySQL Server 5.0\bin>mysqld-nt -install
    Service successfully installed.C:\Program Files\MySQL\MySQL Server 5.0\bin>net start mysql
    发生系统错误 193。*** 不是有效的 Win32 应用程序。
    C:\Program Files\MySQL\MySQL Server 5.0\bin>sc delete mysql
    [SC] DeleteService 成功C:\Program Files\MySQL\MySQL Server 5.0\bin>mysqld-nt install
    Service successfully installed.C:\Program Files\MySQL\MySQL Server 5.0\bin>net start mysql
    发生系统错误 193。*** 不是有效的 Win32 应用程序。
    C:\Program Files\MySQL\MySQL Server 5.0\bin>mysqld-nt --console
    121211 16:06:19  InnoDB: Started; log sequence number 0 43655
    121211 16:06:20 [ERROR] Can't open shared library 'amd.dll' (errno: 0 )
    121211 16:06:20 [Note] mysqld-nt: ready for connections.
    Version: '5.0.67-community-nt'  socket: ''  port: 3306  MySQL Community Edition
    (GPL)当进行完所有步骤后,.err 文件内容 为空。没有任何内容my.ini 内容如下
    # MySQL Server Instance Configuration File
    # ----------------------------------------------------------------------
    # Generated by the MySQL Server Instance Configuration Wizard
    #
    #
    # Installation Instructions
    # ----------------------------------------------------------------------
    #
    # On Linux you can copy this file to /etc/my.cnf to set global options,
    # mysql-data-dir/my.cnf to set server-specific options
    # (@localstatedir@ for this installation) or to
    # ~/.my.cnf to set user-specific options.
    #
    # On Windows you should keep this file in the installation directory 
    # of your server (e.g. C:\Program Files\MySQL\MySQL Server X.Y). To
    # make sure the server reads the config file use the startup option 
    # "--defaults-file". 
    #
    # To run run the server from the command line, execute this in a 
    # command line shell, e.g.
    # mysqld --defaults-file="C:\Program Files\MySQL\MySQL Server X.Y\my.ini"
    #
    # To install the server as a Windows service manually, execute this in a 
    # command line shell, e.g.
    # mysqld --install MySQLXY --defaults-file="C:\Program Files\MySQL\MySQL Server X.Y\my.ini"
    #
    # And then execute this in a command line shell to start the server, e.g.
    # net start MySQLXY
    #
    #
    # Guildlines for editing this file
    # ----------------------------------------------------------------------
    #
    # In this file, you can use all long options that the program supports.
    # If you want to know the options a program supports, start the program
    # with the "--help" option.
    #
    # More detailed information about the individual options can also be
    # found in the manual.
    #
    #
    # CLIENT SECTION
    # ----------------------------------------------------------------------
    #
    # The following options will be read by MySQL client applications.
    # Note that only client applications shipped by MySQL are guaranteed
    # to read this section. If you want your own MySQL client program to
    # honor these values, you need to specify it as an option during the
    # MySQL client library initialization.
    #
    [client]port=3306[mysql]default-character-set=gbk
    # SERVER SECTION
    # ----------------------------------------------------------------------
    #
    # The following options will be read by the MySQL Server. Make sure that
    # you have installed the server correctly (see above) so it reads this 
    # file.
    #
    [mysqld]# The TCP/IP Port the MySQL Server will listen on
    port=3306
    #Path to installation directory. All paths are usually resolved relative to this.
    basedir="C:/Program Files/MySQL/MySQL Server 5.0/"#Path to the database root
    datadir="C:/Program Files/MySQL/MySQL Server 5.0/Data/"# The default character set that will be used when a new schema or table is
    # created and no character set is defined
    default-character-set=gbk# The default storage engine that will be used when create new tables when
    default-storage-engine=INNODB# Set the SQL mode to strict
    sql-mode="STRICT_TRANS_TABLES,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION"# The maximum amount of concurrent sessions the MySQL server will
    # allow. One of these connections will be reserved for a user with
    # SUPER privileges to allow the administrator to login even if the
    # connection limit has been reached.
    max_connections=100# Query cache is used to cache SELECT results and later return them
    # without actual executing the same query once again. Having the query
    # cache enabled may result in significant speed improvements, if your
    # have a lot of identical queries and rarely changing tables. See the
    # "Qcache_lowmem_prunes" status variable to check if the current value
    # is high enough for your load.
    # Note: In case your tables change very often or if your queries are
    # textually different every time, the query cache may result in a
    # slowdown instead of a performance improvement.
    query_cache_size=0# The number of open tables for all threads. Increasing this value
    # increases the number of file descriptors that mysqld requires.
    # Therefore you have to make sure to set the amount of open files
    # allowed to at least 4096 in the variable "open-files-limit" in
    # section [mysqld_safe]
    table_cache=256# Maximum size for internal (in-memory) temporary tables. If a table
    # grows larger than this value, it is automatically converted to disk
    # based table This limitation is for a single table. There can be many
    # of them.
    tmp_table_size=18M
    # How many threads we should keep in a cache for reuse. When a client
    # disconnects, the client's threads are put in the cache if there aren't
    # more than thread_cache_size threads from before.  This greatly reduces
    # the amount of thread creations needed if you have a lot of new
    # connections. (Normally this doesn't give a notable performance
    # improvement if you have a good thread implementation.)
    thread_cache_size=8#*** MyISAM Specific options# The maximum size of the temporary file MySQL is allowed to use while
    # recreating the index (during REPAIR, ALTER TABLE or LOAD DATA INFILE.
    # If the file-size would be bigger than this, the index will be created
    # through the key cache (which is slower).
    myisam_max_sort_file_size=100G# If the temporary file used for fast index creation would be bigger
    # than using the key cache by the amount specified here, then prefer the
    # key cache method.  This is mainly used to force long character keys in
    # large tables to use the slower key cache method to create the index.
    myisam_sort_buffer_size=35M# Size of the Key Buffer, used to cache index blocks for MyISAM tables.
    # Do not set it larger than 30% of your available memory, as some memory
    # is also required by the OS to cache rows. Even if you're not using
    # MyISAM tables, you should still set it to 8-64M as it will also be
    # used for internal temporary disk tables.
    key_buffer_size=25M# Size of the buffer used for doing full table scans of MyISAM tables.
    # Allocated per thread, if a full scan is needed.
    read_buffer_size=64K
    read_rnd_buffer_size=256K# This buffer is allocated when MySQL needs to rebuild the index in
    # REPAIR, OPTIMZE, ALTER table statements as well as in LOAD DATA INFILE
    # into an empty table. It is allocated per thread so be careful with
    # large settings.
    sort_buffer_size=256K
    #*** INNODB Specific options ***
    # Use this option if you have a MySQL server with InnoDB support enabled
    # but you do not plan to use it. This will save memory and disk space
    # and speed up some things.
    #skip-innodb# Additional memory pool that is used by InnoDB to store metadata
    # information.  If InnoDB requires more memory for this purpose it will
    # start to allocate it from the OS.  As this is fast enough on most
    # recent operating systems, you normally do not need to change this
    # value. SHOW INNODB STATUS will display the current amount used.
    innodb_additional_mem_pool_size=2M# If set to 1, InnoDB will flush (fsync) the transaction logs to the
    # disk at each commit, which offers full ACID behavior. If you are
    # willing to compromise this safety, and you are running small
    # transactions, you may set this to 0 or 2 to reduce disk I/O to the
    # logs. Value 0 means that the log is only written to the log file and
    # the log file flushed to disk approximately once per second. Value 2
    # means the log is written to the log file at each commit, but the log
    # file is only flushed to disk approximately once per second.
    innodb_flush_log_at_trx_commit=1# The size of the buffer InnoDB uses for buffering log data. As soon as
    # it is full, InnoDB will have to flush it to disk. As it is flushed
    # once per second anyway, it does not make sense to have it very large
    # (even with long transactions).
    innodb_log_buffer_size=1M# InnoDB, unlike MyISAM, uses a buffer pool to cache both indexes and
    # row data. The bigger you set this the less disk I/O is needed to
    # access data in tables. On a dedicated database server you may set this
    # parameter up to 80% of the machine physical memory size. Do not set it
    # too large, though, because competition of the physical memory may
    # cause paging in the operating system.  Note that on 32bit systems you
    # might be limited to 2-3.5G of user level memory per process, so do not
    # set it too high.
    innodb_buffer_pool_size=47M# Size of each log file in a log group. You should set the combined size
    # of log files to about 25%-100% of your buffer pool size to avoid
    # unneeded buffer pool flush activity on log file overwrite. However,
    # note that a larger logfile size will increase the time needed for the
    # recovery process.
    innodb_log_file_size=170M# Number of threads allowed inside the InnoDB kernel. The optimal value
    # depends highly on the application, hardware as well as the OS
    # scheduler properties. A too high value may lead to thread thrashing.
    innodb_thread_concurrency=18
      

  38.   

    检查一下服务中的启动项
    是否是mysql安装目录\bin\mysqld" --defaults-file="my.ini目录\my.ini" MySQL怎么会提示 不是有效的 Win32 应用程序?
    有病毒?
      

  39.   

    服务启动项中的路径是 
    "C:\Program Files\MySQL\MySQL Server 5.0\bin\mysqld-nt" MySQL就是这个目录
      

  40.   

    mysqld-nt --console,启动后
    用MYSQLDUMP备份,重新安装MYSQL