svn cleanup: sqlite: database disk image is malformed

前端 未结 17 1441
谎友^
谎友^ 2020-12-02 06:31

I was trying to do a svn cleanup because I can\'t commit the changes in my working copy, and I got the following error:

sqllite: databas

相关标签:
17条回答
  • 2020-12-02 07:10

    Integrity check

    sqlite3 .svn/wc.db "pragma integrity_check"
    

    Clean up

    sqlite3 .svn/wc.db "reindex nodes"
    sqlite3 .svn/wc.db "reindex pristine"
    

    Alternatively

    You may be able to dump the contents of the database that can be read to a backup file, then slurp it back into an new database file:

    sqlite3 .svn/wc.db
    
    sqlite> .mode insert
    sqlite> .output dump_all.sql
    sqlite> .dump
    sqlite> .exit
    
    mv .svn/wc.db .svn/wc-corrupt.db
    sqlite3 .svn/wc.db
    
    sqlite> .read dump_all.sql
    sqlite> .exit
    
    0 讨论(0)
  • 2020-12-02 07:10

    I copied over .svn folder from my peer worker's directory and that fixed the issue.

    0 讨论(0)
  • 2020-12-02 07:10

    Throughout my researches, I've found 2 viable solutions.

    1. If you're using any type of connections, ssh, samba, mounting, disconnect/unmount and reconnect/remount. Try again, this often resolved the problem for me. After that you can do svn cleanup or just keep on working normally (depending on when the problem appeared). Rebooting my computer also fixed the problem once... yes it's dumb I know!

    2. Some times all there is to do is to rm -rf your files (or if you're not familiar with the term, just delete your svn folder), and recheckout your svn repository once again. Please note that this does not always solve the problem and you might also have changes you don't want to lose. Which is why I use it as the second option.

    Hope this helps you guys!

    0 讨论(0)
  • 2020-12-02 07:11

    Maybe, could be a solution:

    1. right mouse click over project
    2. team -> disconnect
    3. Select: Also delete ...

    Now, re-connect again:

    1. right mouse click over project
    2. team -> Share project
    3. select your repositorie: mine SVN ( other case: git, etc)
    4. select your repositorie folder

    Note:

    On my case, I did a backup of my files. ( safe ur back :P )

    Edit:

    I am talking about SVN plugin on Eclipse :)

    0 讨论(0)
  • 2020-12-02 07:12

    Do not waste your time on checking integrity or deleting data from work queue table because these are temporary solutions and it will hit you back after a while.

    Just do another checkout and replace the existing .svn folder with the new one. Do an update and then it should go smooth.

    0 讨论(0)
提交回复
热议问题