I am still waiting for (hopefully) final review/commit of this patch.

--
Øystein

>>>>> "ØG" == Øystein Grøvlen <[EMAIL PROTECTED]> writes:

    ØG> Could someone review/commit the new patch that I added last week?  I
    ØG> have run derbyall with no new errors.

    ØG> --
    ØG> Øystein

    ØG> From: Øystein Grøvlen <[email protected]> (JIRA)
    ØG> Subject: [jira] Updated: (DERBY-555) Unable to restart after disk is 
full
    ØG> To: [email protected]
    ØG> Date: Tue, 04 Oct 2005 13:06:49 +0200 (CEST)
    ØG> Reply-to: Derby Development <[email protected]>

    ØG>      [ http://issues.apache.org/jira/browse/DERBY-555?page=all ]

    ØG> Øystein Grøvlen updated DERBY-555:
    ØG> ----------------------------------

    ØG>     Attachment: derby-555a.diff

    ØG> Added a new patch that changes the message to derby.log and adds a test 
for this bug. 

    ØG> With this patch, when a database is booted in read-only mode, the boot 
message in derby.log will contain information about that.

    ØG> I have also added a test, TurnsReadOnly.java, that without the fix, get 
the NPE.  This is not in a disk full scenario, but it also occurs with a 
read-only DB directory.   Since there is currently no way to turn write access 
back on from a Java program, the DB directory will be read-only after the test 
is run.  Hence, the test framework will not be able to clean up the test 
directory.  Therefore, this test is not added to the derbyall test suite.

    ØG> The following files are changed:

    ØG> M      java/engine/org/apache/derby/impl/store/raw/RawStore.java
    ØG>       Do not check log location for read-only databases (avoids NPE)
    ØG> M      
java/engine/org/apache/derby/impl/store/raw/data/BaseDataFileFactory.java
    ØG>       Add information to boot message in derby.log when database is 
booted in read-only mode.
    ØG> M      java/engine/org/apache/derby/iapi/reference/MessageId.java
    ØG>       Added message id for the read-only part of the boot message
    ØG> M      java/engine/org/apache/derby/loc/messages_en.properties
    ØG>       Added text for the read-only part of the boot message
    ØG> M      
java/testing/org/apache/derbyTesting/functionTests/tests/store/copyfiles.ant
    ØG>       Added TurnsReadOnly_app.properties
    ØG> A      
java/testing/org/apache/derbyTesting/functionTests/tests/store/TurnsReadOnly.java
    ØG>       New test that boots a database with log in non-default location, 
shuts it down, sets DB directory to read-only, boots again and checks that DML 
is not allowed.
    ØG> A      
java/testing/org/apache/derbyTesting/functionTests/tests/store/TurnsReadOnly_app.properties
    ØG>       Test properties
    ØG> A      
java/testing/org/apache/derbyTesting/functionTests/master/TurnsReadOnly.out
    ØG>       Master file for new test.

    ØG> I am currently running derbyall and will update report when test is 
finished.

    >> Unable to restart after disk is full
    >> ------------------------------------
    >> 
    >> Key: DERBY-555
    >> URL: http://issues.apache.org/jira/browse/DERBY-555
    >> Project: Derby
    >> Type: Bug
    >> Components: Store
    >> Versions: 10.2.0.0
    >> Environment: Sun Sparc Solaris, 1.4 JDK, Derby Client/Server
    >> Reporter: Øystein Grøvlen
    >> Assignee: Øystein Grøvlen
    >> Priority: Critical
    >> Attachments: derby-555a.diff
    >> 
    >> 1. Inserted data into the database until the disk was full. (5 clients 
inserting into 5 different tables in parallel.)
    >> 2. Shut down the server
    >> 3. Start the database again without freeing any disk space.
    >> When I try to start the database again, I get Null-pointer-exception, 
regardless of how I connect (have tried embedded, client server, ij, jdbc 
applications).  I have not tried to free some space on the disk before 
starting.  
    >> The call stack is not available right now (the computer I used had to be 
shut down due to problems with our cooling system), but the exception comes 
from the following line in RawStore.java:
    >> properties.put(Attribute.LOG_DEVICE, logFactory.getCanonicalLogPath());
    >> getCanonicalLogPath() returns null which results in a NPE in the hash 
table.
    >> A quick debug before the computer was stopped, showed that the 
logFactory was an instance of org.apache.derby.impl.store.raw.log.ReadOnly 
which always returns null in its  getCanonicalLogPath().
    >> I suspect this may be related to the fact that I ran with the log in a 
non-default location.

    ØG> -- 
    ØG> This message is automatically generated by JIRA.
    ØG> -
    ØG> If you think it was sent incorrectly contact one of the administrators:
    ØG>    http://issues.apache.org/jira/secure/Administrators.jspa
    ØG> -
    ØG> For more information on JIRA, see:
    ØG>    http://www.atlassian.com/software/jira



    ØG> ----------



    ØG> -- 
    ØG> Øystein

-- 
Øystein

Reply via email to