How can I repair the iCal database?


Recommended Posts

My iCal has been acting funny for a while now. It's still usable but it's really annoying. I'm not sure how to explain it so bear with me...

When I'm viewing the calendar for June and hit the back button to view May, it won't do anything, no hang or freeze. Just nothing.

Then when I hit it again, it skips May and goes right to April. And when I do that, the April calendar shows all the events for April, May, and June overlapped.

I can then hit the forward button and go to May, but same thing, events are overlapped and weird.

I've included pictures;

June

post-38279-1216227869_thumb.png

April

post-38279-1216227349_thumb.png

May

post-38279-1216227340_thumb.png

I'm guessing it's an issue with the iCal database, do you guys have any ideas as to how this can be remedied? I'm also worried that if I don't fix it, it may cause further damage to the database and lose all my information.

Thanks in advance.

Edited by HellScream63
Link to comment
https://www.neowin.net/forum/topic/649482-how-can-i-repair-the-ical-database/
Share on other sites

It looks like the cache of information that iCal reads could possibly be corrupted, luckily we can get iCal to recreate its cache information by clearing the old data.

  1. Open iCal.
  2. We need to back up your iCal information before continuing to prevent any loss of data (although unlikely in this situation, it is always a good idea to create a backup of your data before removing any cache files); to do this just click on File in the menu bar and click on "Back up iCal", and then choose a location and save the backup file.
  3. Now, we will need to quit iCal so that we can remove the cache files; a quick way to do this is by using the Cmd-Q keyboard shortcut, or just click on iCal in the menu bar and click on Quit iCal, whichever you prefer.
  4. Let's go ahed and open the Finder. To make sure that we are in your home folder, either click on your user name in the sidebar, or use the keyboard shortcut Cmd-Shift+H.
  5. Now that we are in your Home folder, we need to navigate to the location where the cache files are stored, so lets go ahead and open the "Library" folder, and then open the "Calendars" folder.
  6. Delete any instances of "Calendar Cache" (including "Calendar Cache~2", etc. should they exist).
  7. Now that we have cleared the caches, you can go ahead and re-open iCal. It will rebuild the cache information when you first launch it, and should hopefully correct the issue at hand.

Give these steps a try and please let us know if it resolves your issue. Have a good day! :)

Edited by Cadium

I tried deleting the Calendar Cache and the problem is still there. Thanks for the suggestion though.

Maybe I should try reinstalling like Vegetunks said?

EDIT; I noticed another weird thing. I started going back and forth between the months and the problem seemed to have been gone, so I tried quitting/launching iCal and hitting back to May, and it was there again. I am able to replicate this behavior of it seemingly gone, and them returning on the next launch.

I tried deleting the Calendar Cache and the problem is still there. Thanks for the suggestion though.

Maybe I should try reinstalling like Vegetunks said?

There are a few things that you can try which may remedy this, one of which is removing the preference files for iCal. To do this, first close iCal, and then use the Finder to open up Library and then Preferences and delete "com.apple.iCal.plist" and "iCalExternalSync.plist", then go into the ByHost folder and delete "com.apple.iCal.helper.**********.plist" (the asterisks stand for whatever the physical MAC address is on your computer). Once you have done this, re-perform the actions that I stated in my previous post for deleting the Calendar cache files, then open iCal. This should pretty much reset the application while leaving your calendar data intact (it will, however, reset the day/month views, window size, etc.)

Your second option is booting your Mac in "Safe Boot" mode (which also clears a lot of hidden cache files and resets some of the settings in OS X to their defaults). To do this, restart your Mac and hold down the "Shift" key on the keyboard while it is starting up, you should be presented with the login screen with text in red which says "Safe Boot", from there just log in and then restart the computer. Alternatively, you could try OnyX, which a lot of Mac owners swear by.

There are a few things that you can try which may remedy this, one of which is removing the preference files for iCal. To do this, first close iCal, and then use the Finder to open up Library and then Preferences and delete "com.apple.iCal.plist" and "iCalExternalSync.plist", then go into the ByHost folder and delete "com.apple.iCal.helper.**********.plist" (the asterisks stand for whatever the physical MAC address is on your computer). Once you have done this, re-perform the actions that I stated in my previous post for deleting the Calendar cache files, then open iCal. This should pretty much reset the application while leaving your calendar data intact (it will, however, reset the day/month views, window size, etc.)

Your second option is booting your Mac in "Safe Boot" mode (which also clears a lot of hidden cache files and resets some of the settings in OS X to their defaults). To do this, restart your Mac and hold down the "Shift" key on the keyboard while it is starting up, you should be presented with the login screen with text in red which says "Safe Boot", from there just log in and then restart the computer. Alternatively, you could try OnyX, which a lot of Mac owners swear by.

The system Library or the Library in my home folder?

There's also com.apple.iCal.helper.plist and com.apple.iCal.AlarmScheduler.plist in my home/Library/Preferences

  • 2 months later...

note everyone...i had the exact same problems start happening in my ical, where a certain month displayed these problems that the original poster here described. i was able to even pinpoint it to a single day that would not display properly, while in the day view the other days around it displayed ok. i backed up ical, exited ical, and deleted these files, and my problem was solved:

- all the Calendar Cache files in home/Library/Calendars

- home/Library/Preferences/com.apple.iCal.plist

- home/Library/Preferences/iCalExternalSync.plist

- home/Library/Preferences/ByHost/com.apple.iCal.helper.************.plist

I did not delete any of the files in the home/Library/Application Support/iCal folder (didn't want to lose alarms or any other data), and thankfully discovered that would have been an unnecessary move!

Thanks Cadium for your advice here...

This topic is now closed to further replies.
  • Recently Browsing   0 members

    • No registered users viewing this page.
  • Posts

    • Get 1-year and $60 of Sam's Club value for just $15 with Auto-renew by Steven Parker Become a Sam's Club Member Now! Shop Premium-Quality Products and Enjoy Incredible Perks, and Savings. Today's highlighted deal comes via our Gift Cards section of the Neowin Deals store, where for only a limited time, you can save 75% off a Sam's Club 1 Year Membership with Auto-Renew. Sam’s Club is a membership warehouse club, a limited-item business model that offers members quality products at an exceptional value unmatched by traditional retail. From groceries and kitchen supplies to electronics and furniture, Sam's Club has great deals on the items you want! By redeeming and signing up as a member, you'll be paying just $20 for a 1 year Sam's Club membership (normally $50.) You'll receive a complimentary household card for more savings from already low-priced items. Sign up now and save money on all your food and decor. Find great deals on groceries, kitchen supplies, electronic, furniture & more Get discounts on hotels, rental car, live events, attractions, movies, & more Save up to 60% on hotel accommodations around the world Get a complimentary household card for more savings from already low-priced items Although it was published quite some time ago, Sam's Club members can enjoy discounts like this. Important Details For a physical membership card after online membership registration, present your phone number or email along with a valid ID at Sam’s Club Membership Services in any US Sam's Club location to have your membership card printed. This membership offer is only available to new Sam's Club members in the USA. It is not valid for membership renewals, for those with a current membership, or those who were Sam’s Club members less than 6 months prior to the current date. To check your renewal date, please check your billing statement or your online account, or chat with an associate. Promotion code is non-transferable Offer valid for new Sam’s Club members only; not valid for membership renewals, for those with a current membership, or those who were Sam’s Club members less than 6 months prior to the current date. Auto Renew: By accepting this offer, you authorize annual recurring charges to any card on file for your Sam's Club membership fee(s) plus any applicable taxes at then-current rate every year until you cancel. Current rates, which may change, are $50 for Club level and $110 for Plus level. Visit SamsClub.com or a club or call 1-888-746-7726 for full terms or to cancel auto-renewal. Valid at over 597 U.S. Sam’s Club locations. Find a location near you. Redemption deadline: redeem your code within 30 days of purchase Access options: desktop & mobile Membership MUST be activated within 30 days Membership expires 1 YEAR from the date the Sam's Club membership is activated Limit 1 per person, may buy 1 additional as gift This Sam's Club 1 Year Membership normally costs $60, but can now be yours for just $15, for a limited time, that's a saving of $45 (70%) off! For specifications, and terms, please click the link below. Get 1-year of Sam's Club with Auto-renew for just $15 (was $60) This deal is only available to U.S. residents. Support queries If you have queries or need support for any of the Neowin Deals, please use the contact form here. Neowin Deals are managed and sold by StackCommerce who represent Neowin on an affiliate basis. Why we post these deals We post these because we earn commission on each sale so as not to rely solely on advertising, which many of our readers block. It all helps toward paying staff reporters, servers and hosting costs. So for those that keep moaning and complaining, be thankful we're still online for you to even do that. Other ways to support Neowin Whitelist Neowin by not blocking our ads Create a free member account to see fewer ads Make a donation to support our day to day running costs Subscribe to Neowin - for $14 a year, or $28 a year for an ad-free experience Disclosure: Neowin benefits from revenue of each sale made through our branded deals site powered by StackCommerce.
    • Microsoft, why can't I just turn off Copilot on my MS account (in order to stop OneDrive from wanting to summarize everything, ahem) in a way that doesn't break OneNote instead?
    • If we can't agree on a baseline of reality then there is no point in talking. Its a waste of time.
  • Recent Achievements

    • Collaborator
      ryansurfer98 went up a rank
      Collaborator
    • Week One Done
      Eurosoft10 earned a badge
      Week One Done
    • One Month Later
      Eurosoft10 earned a badge
      One Month Later
    • One Year In
      Skeet Campbell earned a badge
      One Year In
    • One Month Later
      Sharbel earned a badge
      One Month Later
  • Popular Contributors

    1. 1
      +primortal
      589
    2. 2
      +Edouard
      190
    3. 3
      PsYcHoKiLLa
      80
    4. 4
      Michael Scrip
      77
    5. 5
      Steven P.
      73
  • Tell a friend

    Love Neowin? Tell a friend!