我正在尝试使用 mysqldump 命令备份 mysql 数据库,但我得到的消息是mysqldump: option '--tables' cannot take an argument。
给你:
root@myhost:~# mysqldump mydatabase --user myuser --password mypassword
Warning: Using unique option prefix table instead of tables is deprecated and will be removed in a future release. Please use the full name instead.
mysqldump: option '--tables' cannot take an argument
我尝试了几种参数组合,但我最终发现,如果我只是尝试获取完全没有参数的命令版本或事件,结果是相同的:
root@myhost:~# mysqldump --version
Warning: Using unique option prefix table instead of tables is deprecated and will be removed in a future release. Please use the full name instead.
mysqldump: option '--tables' cannot take an argument
root@myhost:~# mysqldump
Warning: Using unique option prefix table instead of tables is deprecated and will be removed in a future release. Please use the full name instead.
mysqldump: option '--tables' cannot take an argument
正如您在以下几行中看到的,它是在 debian 7 上运行的 mysql server 5.5。
系统版本:
root@myhost:~# uname -a
Linux myhost 3.2.0-4-amd64 #1 SMP Debian 3.2.41-2+deb7u2 x86_64 GNU/Linux
mysql客户端版本:
root@myhost:~# mysql --version
mysql Ver 14.14 Distrib 5.5.35, for debian-linux-gnu (x86_64) using readline 6.2
mysql服务器版本:
root@myhost:~# mysql -h localhost --user=myuser --password=mypassword mydatabase
Reading table information for completion of table and column names
You can turn off this feature to get a quicker startup with -A
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 75
Server version: 5.5.35-0+wheezy1-log (Debian)
Copyright (c) 2000, 2013, Oracle and/or its affiliates. All rights reserved.
Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.
Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.
mysql> quit
Bye
我在网上寻找过这个问题,但我看不到任何人报告这个确切的问题。我不是 mysql 专家,但我可以说这是一个非常简单的安装。如果您需要更多信息,请告诉我。
在此先感谢,伊万