Project Home
Project Home
Documents
Documents
Wiki
Wiki
Discussion Forums
Discussions
Project Information
Project Info
Forum Topic - QDB - disk I/O Error: (7 Items)
   
QDB - disk I/O Error  
Hi,

I was trying to start up QDB with after io-fs-media call.
qdb -c /db/qdb.cfg -vvvvvvvV -Otempstore=/fs/tmpfs -Rset

its giving the following error :

QDB: No script registered for handling corrupt database.
QDB: exec: rc 10, ext 778
qdb: processing [mme_temp]/db/mme_temp.sql - disk I/O error



Its unable to start QDB, can anyone tell me why this is happening ?

Thanks,
Arun

Re: QDB - disk I/O Error  
Qdb uses libsqlite3 for database operations.  It looks like sqlite3
encountered an IO error while trying to write (10 == SQLITE_IOERR, 778 ==
SQLITE_IOERR_WRITE).  I would check your qdb.cfg file to see where
/db/mme_temp.sql is meant to be written (the Filename option for this
database) and try to write this file yourself.  You could try specifying a
different path to write Filename to.

-- 
Ryan J. Allen
QNX Software Systems
Re: QDB - disk I/O Error  
I am using the default qdb.conf file.

[mme_temp]
Filename		=	/fs/tmpfs/mme_temp.db
Schema File		=	/db/mme_temp.sql


 I am able to write to this file by myself.
I tried a different location its giving me input/output error.
 I am working on armle-v7 board with aviage core 1.2.0.
Re: QDB - disk I/O Error  
>>>qdb: processing [mme_temp]/db/mme_temp.sql - disk I/O error

I am guessing this file is located in shared memory?  If so, I suspect the failure is due to the filesystem not 
supporting full posix semantics.

As a quick test, try

# devb-ram ram capacity=8192
# dinit –h /dev/hd1t77 <<<< careful that /dev/hd1 is ramdisk!!!
# mount /dev/hd1t77 /tmp2

Now change the location of the file to reside under /tmp2 and see if it works.
Re: QDB - disk I/O Error  
I am using :

io-fs-media -d tmp -cpages=4 -cbundles=0 before the qdb call. 
this successfully creates a RAMdisk..... /fs/tmpfs.

this call is supposed to create an abstraction for full posix file system right ?

This is where I am trying to create the db.


Thanks,
Arun
Re: QDB - disk I/O Error  
/Fs/tmpfs/ provided by io-fs -dtmp should be fine as a filesystem to store
the databases.

Are there any other files in /fs/tmpfs/ ?  Perhaps a lock file or
something similar that sqlite is honoring but that your attempt to write
to the file ignores.

Have you made any modifications to the .sql files?  Initially I would be
trying this with the default files.  Can you read all of the .sql files
without error (try simply to "cat" the files from the shell).

To try to narrow down the error I would first try to clear all files in
/fs/tmpfs/ (simple to do: just kill io-fs-media and re-start it), then
start with a simplified config file.  Try specifying only one database
(for example, just mme_temp and not mme or mme_library) to see if qdb will
start.  If this still fails you could see if adding some tracing to sqlite
will help; if a query is causing a problem then this will show the
specific query.  You do this by adding arguments:
  qdb -otempstore=/fs/tmpfs/,trace,profile -vvvvvv

(At least six -v's.)


Generally speaking the default configuration should "just work", as long
as all of the files are in the right places.

-- 
Ryan J. Allen
QNX Software Systems

Re: QDB - disk I/O Error  
HI,
I got QDB up and running. many thanks to all the help. It was related to the location of the libraries for qdb. It seems
 to be located in the correct folder structure..Since i am using windows host and cross compiling to arm, I copied it to
 a temp location. That was causing it to behave differently.

Now I am getting an error in io-media-generic

ldd:FATAL: Unresolved symbol "__aeabi_atexit" called from libaoi.so.1
Process 163871 (io-media-generic) exited status=1.

I was wondering if it its relate to armle Vs armle-v7...
i am using aviage core 1.2.0

Thanks,
Arun