在MySQL数据库的维护进程中,我们有时候会在MySQL的错误日志文件中看到一些关于Operating system error的错误信息,譬喻在MySQL的错误日志内里,有时候会看到关于
InnoDB: Operating system error number 0. InnoDB: Check that your OS and file system support files of this size. InnoDB: Check also that the disk is not full or a disk quota exceeded. InnoDB: Operating system error number 5. ...........................................
那么这些System Error Code在Linux下别离代表什么意思呢?其实假如碰着错误日志里有这些对应的代码,利用MySQL自带的呼吁东西perror查察一下详细信息即可。很是简朴利便。
[root@DB-Server ~]# perror 2; OS error code 2: No such file or directory [root@DB-Server ~]# perror 3; OS error code 3: No such process [root@DB-Server ~]# perror 4; OS error code 4: Interrupted system call [root@DB-Server ~]# perror 5; OS error code 5: Input/output error [root@DB-Server ~]#
假如你要查察一个范畴的Operating system error,可以利用下面呼吁
[root@DB-Server ~]# perror `seq 0 10` OS error code 0: Success OS error code 1: Operation not permitted OS error code 2: No such file or directory OS error code 3: No such process OS error code 4: Interrupted system call OS error code 5: Input/output error OS error code 6: No such device or address OS error code 7: Argument list too long OS error code 8: Exec format error OS error code 9: Bad file descriptor OS error code 10: No child processes [root@DB-Server ~]#
假如是集群,那么可以shell> perror –ndb errorcode查察,昆山软件开发, 下面表格是关于Linux平台下通用的System Error Code列表,如下所示,完全没有须要硬性记着。碰着查察即可。
假如是Windows平台,那么也可以利用下面呼吁查察详细的System Error Code信息,昆山软件开发,别的,Windows平台下的System Error Code也远比Linux平台下要多,碰着了这些System Error Code,利用呼吁查察即可。
perror.exe 2 perror `perl -e "print join ' ',1..100"`
参考资料: