mirror of
https://github.com/MariaDB/server.git
synced 2026-05-06 15:15:34 +02:00
os0file.c:
Print a better error message to the .err log if InnoDB's advisory file locking fails innobase/os/os0file.c: Print a better error message to the .err log if InnoDB's advisory file locking fails
This commit is contained in:
parent
875cdfe3c9
commit
433430f4a2
1 changed files with 10 additions and 1 deletions
|
|
@ -394,10 +394,19 @@ os_file_lock(
|
|||
lk.l_start = lk.l_len = 0;
|
||||
if (fcntl(fd, F_SETLK, &lk) == -1) {
|
||||
fprintf(stderr,
|
||||
"InnoDB: Unable to lock %s, error: %d", name, errno);
|
||||
"InnoDB: Unable to lock %s, error: %d\n", name, errno);
|
||||
|
||||
if (errno == EAGAIN || errno == EACCES) {
|
||||
fprintf(stderr,
|
||||
"InnoDB: Check that you do not already have another mysqld process\n"
|
||||
"InnoDB: using the same InnoDB data or log files.\n");
|
||||
}
|
||||
|
||||
close(fd);
|
||||
|
||||
return(-1);
|
||||
}
|
||||
|
||||
return(0);
|
||||
}
|
||||
#endif /* USE_FILE_LOCK */
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue