List:General Discussion« Previous MessageNext Message »
From:Lars Dittmann Date:January 21 2000 1:12pm
Subject:Re: Error:While trying to read and write into one table at the same time
View as plain text  

sinisa@stripped wrote:

> Lars Dittmann writes:
>  > Hi everybody,
>  >
>  > We are using the following components:
>  > MySQL v 3.21.29-gamma and
>  > mm.mysql.jdbc-1.2a (or maybe mm.mysql.jdbc-1.2b)
>  >
>  > Two days ago we have encountered a problem with our Java Clients, who
>  > write and read in our database at the same time.
>  > Once in a while this error code occurred:
>  > SQLException: Error during query: Unexpected Exception:
>  > java.sql.SQLException message given: General error: Can't lock file
>  > (errno: 11)
>  > SQLState:     S1000
>  > VendorError:  0
>  >
>  > We could not explain the problem exactly, but now we have isolated it by
>  > the following test:
>  >
>  > We have created to Java Clients:
>  > Test_read:  Reads permanently from table1
>  > Test_write: Writes permanently new records into table1
>  >
>  > We ran the clients simultaneously in different combinations:
>  > Running two or more Test_read Clients at the same was no problem
>  > Running two or more Test_write Clients at the same was no problem
>  > Running one Test_read and one Test_write Client at the same time was no
>  > problem for the Test_read Client, but the Test_write throuw the
>  > exception mentioned above.
>  >
>  > In Test_read we are using ReadOnly-Connections, that did not solve the
>  > problem.
>  >
>  > Question: How can we solve the problem?
>  > Restriction: We need to access the database without coordination, so
>  > writing a Scheduler won't help
>  > Idea: For all Insert-Statements we could write a function, that checks,
>  > if the returned error is 11. If this is the case the functions waits
>  > like 5 sec. and tries to Insert again. But we do not think this is very
>  > nice.
>  >
>  > Thanks for you help,
>  > Andre & Lars
>  >
>
> Hi!
>
> First of all, please upgrade to the latest stable release. It is hard
> to provide support for ancient versions.
>

If we upgrade our version, do we need to redifine the tables on our database?
Are we going to loose our data? What is the number of the best version for NT?
Is there an update programm?

>
> But your problem is quite typical. You have run out of system
> resources.
>
> You should  increase maximum number of file descriptors, and if that
> does not help, you should increase max number of processes.
>
> How to do it. It depends on your OS and it's version. If it is Unix,
> then kernel version.

We are using a Windows NT Server with 1 Gigabyte RAM. Do You have a hint, how
we could increase our number of file descriptors or our number of processes?
What are typicall numbers for this parameters?

thanks, Lars

>
>
> Regards,
>
> Sinisa
>
> +----------------------------------------------------------------------+
> | TcX  ____  __     _____   _____  ___     ==  mysql@stripped            |
> |     /*/\*\/\*\   /*/ \*\ /*/ \*\ |*|     Sinisa Milivojevic          |
> |    /*/ /*/ /*/   \*\_   |*|   |*||*|     mailto:sinisa@stripped     |
> |   /*/ /*/ /*/\*\/*/  \*\|*|   |*||*|     Larnaka, Cyprus             |
> |  /*/     /*/  /*/\*\_/*/ \*\_/*/ |*|____                             |
> |  ^^^^^^^^^^^^/*/^^^^^^^^^^^\*\^^^^^^^^^^^                            |
> |             /*/             \*\                Developers Team       |
> +----------------------------------------------------------------------+

Thread
Ultra High PerformanceEric Savage19 Mar
  • Ultra High Performancesinisa20 Mar
  • Re: Error:While trying to read and write into one table at the same timesinisa21 Jan
  • Re: Error:While trying to read and write into one table at the same timeLars Dittmann21 Jan
  • help: Can't find key for index errorwebmaster junet22 Jan
    • Re: help: Can't find key for index errorsinisa22 Jan
Re: Ultra High PerformanceFred Lindberg19 Mar