DB compact error

I was able to compact a large (>10GB) BDB using db_compact, and then I decided to compact again, to see what effect it had. I get this exception each time when using version 4.6.21:
java.lang.IllegalArgumentException: Invalid argument: DB_ENV->log_put: record larger than maximum file size (18094568 > 10485760)
at com.sleepycat.db.internal.db_javaJNI.Db_compact(Native Method)
at com.sleepycat.db.internal.Db.compact(Db.java:277)
at com.sleepycat.db.Database.compact(Database.java:66)
I could try to see if increasing the max log file size will help, but how I can I be certain that the log_put call won't exceed that size?

try this and see if it solves,
also, Emp_name data type is int. it should be varchar.
I suspect the reason is because you already have some data in student table but you identity seeds were not updated and hence it is trying to insert a row with emp_id value that already exists.and hence the primary key violation. also, your table DDL did
not really have an primary key but it would still error since you are inserting duplicate row in the identity column.
so, try resetting the identity seed value to the max(emp_id) in the table.
select max(Emp_ID) from  student
--use the output of the above statement
DBCC CHECKIDENT ('Student', RESEED,<<--use the output of the above statement-->>)
--your max(emp_id) should match with last_value column in the below( do not if this query would run in compact DB though)
select seed_value,increment_value,last_value from sys.identity_columns where object_id=object_id('Student')
now, try your insert.
Hope it Helps!!

Similar Messages

  • Compaction Error in Mail etc.

    Yesterday I started getting a compaction error from Mail when I tried to delete large portions of the Inbox. Although I could delete a few emails at a time and then quit. they were back after the next compaction. Today I tried to troubleshoot it, and I think I made it worse. Note: I was unaware of the "Rebuild" mailbox option.
    I eventually found this forum discussion and it sounded like my problem, so I tried it:
    With the Mail.app quit and using the Finder, go to Home > Library > Mail > this POP account named folder (named by the user name and incoming mail server for the account).
    Move the account named folder to the Desktop. The account named folder contains all mailboxes associated with the account such as the account's Inbox and Sent mailbox.
    Launch Mail and a new account named folder will be created automatically by Mail within the Mail folder.
    I tried Mail again, and now I somehow had lots of junk mail back which I'd long since deleted, in my old Inbox. I was also missing some emails, from Jan. 2, 2007 'til now. I "got new mail", and it's only from Feb. 5 2007 'til now (1 month on the server.)
    The size of the old Inbox was 96.4 MB. After importing it, it's 87.2 MB. Would that account for the missing emails? If so, how do I get them back?
    iBook G4   Mac OS X (10.3.9)   22 GB free on hard drive

    Thanks for the response. Sorry that was so confusing.
    I found the "instructions to import the old mailboxes from the original POP account named folder moved to the Desktop" in another thread, and I'll be darned if I can find that thread again today.
    (This should be a bit more clear.)
    I removed the PoP account to the Desktop, opened mail so it recreated the Inbox, and imported the contents of the original PoP folder into mail.
    After importing, I had the imported Old Inbox containing deleted junk mail which somehow returned, and some emails were missing. I tried the same deletion of large blocks of mail that caused the error message in the original Inbox, only now it worked perfectly.
    > I "got new mail", and it's only from Feb. 5
    2007 'til now (1 month on the server.)
    This is for/within the old Inbox mailbox that was
    imported from the old account named folder moved to
    the Desktop?
    Nope, the new mail was in the original Inbox-mailbox, which was clear until I hit Shift-Command-N. The Old Inbox is in its own, newly-created-when-imported mailbox.
    Pre-import Old Inbox contents:
    content_index 3.7 MB
    content_index-(null)-303 2.4 MB
    content_index-localhost-257 2.6 MB
    content_index-localhost-393 948 KB
    Info.plist 4 KB
    mbox 86.4 MB
    tableofcontents 232 KB
    iBook   Mac OS X (10.3.9)  

  • Error message: Compaction error

    My mail program is not sending or receiving. Error message: "Compaction Error There was a failure while writing to the disc. The disc may be full. The mailbox will be returned to its state before compaction."

    What is your hard drive capacity and available free space?

  • "Compaction Error" in Mail

    I continue to get a "compaction error" when I try to delete emails/move them to my junk. It says my mailbox is too full and yet I can't delete anything because it is too full! I've tried all sorts of combinations of deleting, etc. Help please!

    Hirschee's message of 30 May (and others previously) describes the same problem I am experiencing. It seems to arise when the Inbox gets too full.
    I solved it once before by freeing up space on the hard disk, but that has not worked this time. It is nightmarish not being able to delete.
    I have a POP account.
    Any advice gratefully received.
    Ben.
    iBook dual USB 500MHz G3 Mac OS X (10.2.x) (10.2.8)
    replying to -
    Hello, and welcome to the Discussions.
    What type of account do you have -- POP, IMAP or
    .mac?
    If IMAP (or .mac) what are your selections in Mail
    Preferences/Accounts/Special Mailboxes (assumes you
    are running Panther as your Profile reports)? It
    appears you may be leaving deleted messages in the
    Inbox?
    Ernie
    iBook dual USB 500MHz G3   Mac OS X (10.2.x)   (10.2.8)

  • Help! Mail Compaction Error - Lost Messages

    I had too many e-mails in my inbox and was selectively deleting e-mails. I got a message about a "compaction" error, and when my e-mail restarted, I had gone from 5,000 messages to 75.
    I need to keep many of the lost messages -- that's why I was selectively deleting them. This happened to me once before a year or two ago, and I know there's a way to get those messages back -- but I can't find my notes.
    Help! What do I do?

    Hello Emily.
    The folder it created contained a folder called
    "split_mailboxes" but nothing ever appeared in there.
    What did appear were files called "Sent Messages-0001",
    "Sent Messages-0002" etc...
    I believe these files are the parts into which the script breaks the troublesome mbox file within the Sent Messages.mbox package. They are in the same mbox format, just named differently, and are to be imported into Mail using the Other data format option. I believe the script should do this automatically, but apparently it didn't for some reason.
    In Mail, do File > Import Mailboxes, choose Other as the data format, and follow the instructions to import all these files. You'll have to select the folder that contains the files, rather than the files themselves, when telling Mail what to import.

  • More Lost Mail After Compacting Error

    I've seen this problem in a few posts, but still have not been able to get back the missing email. While deleting a bunch of messages, I got the compaction error message, and when I restarted the email, almost all the messages were gone. I followed the steps to put the inbox on the desktop and import it back to mail, but due to its absurdly large size (1.49G, and yes, I imagine that's the root of all my problems) the mail crashed. I tried using mboxbreaker, but got "Error-48 already an item with that name" and "Error- 2753 the variable spec is not defined". Any help will be much appreciated; while the vast majority of the lost messages should have been deleted long ago, there are some important personal things amongst the sludge.

    yeah, i just don't get it. the settings are exactly the same...i've made sure of that. connection doctor says everything is fine...and outmail mail works. but new mail just sits in my web based inbox, and mac mail never pulls it off...frustrating. out of all the problems i thought i might have when doing a fresh install, i didn't expect this one.
    jon.

  • Compaction error

    I had found a good discussion on this, but the fix didn't suit my situation. Because it had been considered answered by the original poster, I could not post a reply. So here we are with a new one.
    Now that disclaimer is done, a user has gotten this error message:
    Compaction Error. There was a failure while writing to the disk. The disk maybe full. The mailbox will be restored to its state before compaction.
    while trying to delete his email messages. The first thing I looked at was to view the file size of his inbox. It is a paltry 112Kb. Too small and there were only 3 messages in his inbox. I moved his mail folder to the top of his home directory and recreated his mail, however, any previous mails are missing. Here are the following steps taken to get to the point of missing email.
    He opens Mail
    He deletes message with big attachments
    He gets the compaction error
    He clicks OK
    He closes Mail
    He opens Mail
    There is no more mail
    The mail file size reduces dramatically.
    Is it at all possible to get this person's mail back?

    I would also like to mention that I have a copy of this Mail file on a CD so that I can still some how some way try to retrieve it. Most importantly, this is Panther and its Mail.
    Finally, there is 18G available free space on this computer with the mail problem, so drive space is not an issue. Because this was not my computer and this user can't give me as detailed information as size of box or number of messages before the crash, this is the best I can provide for details. Thanks all.

  • Compaction Error when saving to disk

    I desperatly need help. Everytime I open mail it is ok then it freezes when saving to disk - and error message "compaction error" cleared out folders still no luck. Please help!!!

    What is your hard drive capacity and available free space?

  • Mailbox Compaction Error?

    Help!
    I have an iMac (Mac OS X 10.2.8) and suddely I am having trouble deleting emails from my mailbox. When I attempt to delete emails (both from my inbox as well as from my sent files) a dialog box pops up that reads:
    Compaction Error
    There was a failure while writing to the disk. The disk may be full. The mailbox will be restored to its state before compaction.
    Any advice on how to fix this problem without having to pay a $49.95 technical support fee?
    Thanks!

    What is your hard drive capacity and available free space?

  • Compaction error since old issue of too little free space........

    I continue to have an issue with apple Mail. This started when I had too little hard drive free space. I have now upgraded and added an external hard drive with 2 partitions and have deleted a ton of stuff from my original 8.5gig hard drive to leave me with about 3gigs of free space. I began using Carbon Copy Cloner to back everything up on a weekly basis. Now my issue is that e-mails wont delete and mail will shut down occasionally. It will also give me "compaction errors" and revert the mailbox to original settings. I have tried all of Allan Sampsons suggestions, like going to Applications/Library/ etc. and moving the Inbox to my desktop. etc. etc. etc. ALL has not helped and is just seeming to compound the issue....things keep getting worse. Until just the last few days I was also having shut down issues and "sleep" issues. I ran disk utility and this seems to have been cleared up. I really believe that I have some corruption in my Mail program and would like to remove Mail and reinstall it fresh. Does anybody have any other suggestions? I think I can reinstall with no problem, but I'm unclear how to remove the old corrupted version of Mail. Could someone give me other suggestions or help me through the removal of the corrupted old Mail?

    Hello Alana.
    Deleting and re-installing the Mail.app rarely resolve this or any problem.
    All Mail.app data is stored in the Mail folder at Home > Library > Mail and all email account information and general Mail.app settings are stored in the Mail.app preference file.
    Since your hard drive did not have adequate free hard drive space required for OS X to function properly until recently, it sounds like some of your mailboxes (mbox files) have some corruption (not the application itself). If so, re-installing the Mail.app will not resolve this since no data is stored in the application.
    Quit Mail first and using the Finder, go to Home > Library > Mail. Move the entire Mail folder to the external hard drive for later use.
    Launch Mail and a new Mail folder and account named folders within will be created automatically. All mailboxes will be empty and any created rules and signatures will not be available along with Junk Mail "learned" settings lost but this will determine if the problem lies within the old Mail folder which I believe it does.
    If this allows the Mail.app to function properly, you can use the Import Mailboxes function to import selected mailboxes from within the old Mail folder moved to the external hard drive and I would import only a number of available mailboxes at one time since one or a number of the existing mailboxes probably have some corruption due to the lack of free hard drive space you had previously.

  • Mail opens, tries to compact messages, then quits.

    Howdy,
    One other thing of note is that I'm down to approx 3.6 gig of disk space.
    I have gone to home/library/Mail/[email protected] and moved the file INBOX.mbox to the desktop (and put it in a folder labeled "Old INBOX"), and then deleted the file MessageUidsAlreadyDownloaded.
    Next I restarted Mail. It downloaded 50 messages (showing them in the inbox window) while the little spinner spins and the little message window shows "Reading table of contents"; then "compacting message 554 of 558;" at which point it quits and says that I got a compacting error and that the disk may be full.
    Now it worked fine when it had less than 3 gig free. What gives?
    Also, I know that I have one folder with a lot of pictures in it. Two problems:
    I have no earthly idea where to find the attachements (the Pics) so that I can delete them; and my finder does not help.
    I tried to find folders based on size (I really only use this for email, web surfing, and itunes. For that reason, I believe that whatever has eaten the 30 odd gig of disk space must have some relation to one of those apps. So, I searched for Kind=folder and Size is greater than 1000000 kb. I got a bunch of folders alright, but nothing bigger than 500 MB, and none of those sorted by size.
    I give up, what gives here? Any suggestions? Many thanks in advance,
    Bart Chambers

    (and put it in a folder labeled "Old INBOX")
    Where did you put this "Old INBOX" named folder - in
    the Earthlink account named folder? If so, there is
    no reason to do so. When moving a .mbox file from
    within a POP account named folder (with the Mail.app
    quit before doing so), a new .mbox file is created
    automatically by Mail within the account named folder
    when the function is used by the account - in this
    case, a new INBOX.mbox file.
    I put it on the desktop, in the (probably futile) expectation that at some point I might be able to reclaim the 800 some-odd messages that were there when the fan got all brown and stinky. I was aware (from reading an older thread on this forum) that a new INBOX.mbox file would be created at the time I started MAIL again.
    Next I restarted Mail. It downloaded 50 messages
    (showing them
    in the inbox window) while the little spinner spins
    and the little
    message window shows "Reading table of contents";
    then
    "compacting message 554 of 558;" at which point it
    quits and says
    that I got a compacting error and that the disk may
    be full.
    This is obviously not occurring with the new
    INBOX.mbox created automatically by Mail within the
    account named folder since there aren't 558 messages
    available within this mailbox.
    Yep, I mentioned that because it indicates to me that something is not entirely kosher. I have no clue why MAIL thinks that there are 558 messages, or that it is compacting #554.
    OK, I have a clue, but that's all. I think that those numbers are stored somewhere in some kind of mox-nix scratch file that should have been cleaned out, but for some reason, did not get cleaned out. How could I flush this?
    The only way to remove message attachments with all
    Mail.app versions prior to Tiger Mail is from within
    the Mail.app and accessing the messages with
    attachments.
    Well, that sure is a bit inconvenient, since Mail seems bound and determined to say hello, and immediately Goodbye without even asking, however insincerely, about my mum's health.
    What is the overall size of the Mail folder at Home >
    Library > Mail?
    If the finder can be believed (the "get info" function anyway), it's 263.4 MB.
    The Mail.app alone requires the same amount of free
    hard drive space as the overall size of the Mail
    folder for general housekeeping duties during use.
    Well, that would explain why it continued to work up until space got down to 2 gb, but it would also seem that it ought to work now with 3.3 gb available.
    Depending on your hard drive capacity, I would focus
    on freeing up more hard drive space.
    I would have thought (actually, I did think) that this would be a dandy idea myself. That's why I mentioned my problems using Find (folders =/> 1000000 kb). Even my iTunes folder (home/Music/iTunes/) is only 12.51 gb.
    Oh, wait, does iTunes reserve enough (disk) space to equal the actual space consumed?
    If push comes to shove, I suppose I could burn a bunch of music CDs and dump the music from iTunes, but that would not be my prefered outcome.
    Check this link for information regarding a lack of
    adequate free hard drive space with OS X.
    http://www.thexlab.com/faqs/lackofram.html
    And this link for suggestions to free up hard drive
    space.
    http://www.thexlab.com/faqs/freeingspace.html
    I shall do that now, thank you very much for your time and courtesy, I sincerely appreciate the help.
    Bart Chambers
    iBook 1.07 ghz PPC G4, 768 MB DDR   Mac OS X (10.3.9)  

  • Mail Crashing Out

    As soon as I delete messages from Mail, the program throws a wobbly. I receive a message "Compaction Error" Unable to write to the disc. Messages will be reset.(Or words to that effect} The program then "Unexpectedly quits".
    I have tried resetting permissions, verifying and repairing the disc.
    The latest problem is that someone suggested I try "Rebuild" mailbox and that's resulted in the program being inaccessible. It now freezes on 'message 37 of 212' as it tries to rebuild.
    (Sorry that the exact wording can't be given as I can no longer access the program-it's a near as I can remember!)
    Thanks
    Graham

    You're welcome.
    What does create a new operating set of mailboxes mean - deleting and recreating the account?
    If so, there is a warning message provided when/before deleting an account with Mail that indicates all account mailboxes will also be deleted when the account is deleted. You must select OK in the warning message window dialogue box before the account is deleted.
    The only way to recover the deleted account mailboxes and messages within is the same as when any other data is deleted - by accident or on purpose - using a data recovery utility.

  • CAN NOT OPEN DOCUMENTS DOWNLOADED

    Good Evening,
    when I try to open a document after downloading, be it an email attachment or another, for example, the manual for the guarantee of the Z3 compact, error and tells me I can only close office suite. You can help me solve this problem? Thank You.
    Kind regards and excuse any errors, but I'm Italian!
    Micaela.
    Micaela
    Solved!
    Go to Solution.

    Settings, apps, all, office suite, clear data and also clear defaults
    "I'd rather be hated for who I am, than loved for who I am not." Kurt Cobain (1967-1994)

  • "Invalid segment" when shrinking a partitioned table

    I'm encountering the following error when trying to shrink space compact for a partitioned table. Would you know how can I go about this?
    I need to make it work.
    SQL> alter table PS_SGSN_1_MONTH modify partition P_201304 shrink space compact;
    alter table PS_SGSN_1_MONTH modify partition P_201304 shrink space compact
    ERROR at line 1:
    ORA-10635: Invalid segment or tablespace type
    My Oracle DB version is 11gR2

    Yes, that would be the right thing to do to check how and where MV is being used and what downtime you can get to fix this. Check if you can change the Materialized view to create based on primary key instead of Row id.
    Steps would be
    1 drop the materialized views related
    2 drop the materialized views logs
    3 shrink the tables and indexes
    4 recreate the materialized views log
    5 recreate the materialized views
    Also, there is a bug with the primary key as well. Check this
    Bug 13709220 - ORA-10663 when shrinking a master table of an MVIEW with primary key (Doc ID 13709220.8)

  • Loosing Sent Mail

    Hi,
    I get this message once and a while when I look in my Sent mail folder:
    The message from Peter Carry <[email protected]> concerning “Speedline Tech- Electrovert quote and rental” has not been downloaded from the server. You need to take this account online in order to download it.
    Mail does not say its "Working Offline" when this occurs. The usual fix is for me to exit Mail and re-strat, then I can see Sent mail just fine.
    Can someone tell me what the problem is?
    Also, related to this, which happened today and caused me great anguish, has to do with deleting sent mail. I typically retain about 3 months worth of sent mail. I just went to delete November's mail. I went into Sent and seleted all the November mail and deleteled. I exited the program and a message came up "Compaction Error, Mail will set back to pre compaction", something like that. Then when I ran Mail again the Sent folder was empty. Holy Cow !!!
    This happened before about 5 months ago.
    Thanks in advance for your help.

    Pete,
    On your initial post to start this Topic, your Profile said 10.4.2 -- I took my lead from that. If running 10.3.9 and Mail 1.3.11, then it is a different problem, and is a truly Overstuffed Mailbox. See:
    http://discussions.apple.com/thread.jspa?messageID=1958833

Maybe you are looking for