【Mysql 學習】perror的使用方法

楊奇龍發表於2011-01-12

在mysql的使用過程中遇見很多錯誤,比如由於作業系統引起的,檔案或者目錄不存在,或者sql語句錯誤引起的。這些error 會有相應的程式碼:error#,Errcode#。"#"代表具體的錯誤號。perror可以檢視這些錯誤的詳細內容。
檢視perror的使用方法:
[root@YANG mysql]# perror
perror Ver 2.10, for pc-linux-gnu (i686)
This software comes with ABSOLUTELY NO WARRANTY. This is free software,
and you are welcome to modify and redistribute it under the GPL license

Print a description for a system error code or an error code from
a MyISAM/ISAM/BDB table handler.
If you want to get the error for a negative error code, you should use
-- before the first error code to tell perror that there was no more options.

Usage: perror [OPTIONS] [ERRORCODE [ERRORCODE...]]
  -?, --help          Displays this help and exits.
  -I, --info          Synonym for --help.
  --ndb               Ndbcluster storage engine specific error codes.
  -s, --silent        Only print the error message.
  -v, --verbose       Print error code and message (default).
  -V, --version       Displays version information and exits.

Variables (--variable-name=value)
and boolean options {FALSE|TRUE}  Value (after reading options)
--------------------------------- -----------------------------
ndb                               FALSE
verbose                           TRUE

[root@YANG mysql]# perror 30 60
OS error code  30:  Read-only file system
OS error code  60:  Device not a stream

來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/22664653/viewspace-683698/,如需轉載,請註明出處,否則將追究法律責任。

相關文章