Fix A Corrupt Session File
This is a brief tutorial to fix a corrupt Session file. Your Session file is a database file that helps to run your Session. The procedure is a easy, and without risk of losing images or image data. That said, always create a backup before performing maintenance on your data.
Fix A Corrupt Session File
It always happens when it is most inconvenient: when opening a Session you get a message that the Session database seems to corrupt and can not be opened.
At this point there is still hope. You click on Verify and Repair…
If this is what you get, the Session database file is lost. The text can vary (I intentionally screwed up here big time) but the color is red, and red is bad. What does this mean, what is the damage, and how do you recover? And last, is there a preventive measure you can take?
Note: if you have a backup of your Session file, restore it. If not, read on for repair.
I take you through some easy steps to quickly recover from this disaster. And although it is a proven method, be aware that you always perform this at your own risk. Backup before you start!
Anatomy Of A Session
Let me start with some basic knowledge about what a Session is. If you are already familiar with the basics, please skip this section and continue with the next.
On the file and folder level, a Session consists of four folders – Capture, Output, Selects, Trash – and a Session file in a single folder, the parent folder.
Session File
The Session file is a database file with the name of the Session. It shares the name with the parent folder of the Session. In my example, the parent folder is called Alchemist, and the Session database file Alchemist.cosessiondb.
The Session database contains information about the Session, like Session Favorites and Session Albums. Also, the Process Recipe you used last time in your session is stored in that database as is the Capture Name when tethering.
Session Folders
The four Session Folders – Capture, Selects, Output, and Trash – contain your images. These four folders are linked to four different functions in Capture One. In a brief description below I highlight the defaults for these folders.
The Capture Folder is where your images are stored during tethered shooting, but you can also import from a card into the Capture Folder.
The Selects Folder is where you move your best image to. Currently, with Albums and Smart Albums, the Selects Folder is not used very frequently.
The Output Folder is where Capture One stores the processed images. Of course, you can process to other folders, but this is the default.
The Trash Folder is where your images go that you delete. The folder is like a bin, that you can empty to permanently delete your images from your disk.
You can read more about Sessions in my series of posts that start with Sessions Explained.
Corrupt Database
When you open a session, Capture One opens the session database and finds folders, favorites, and other settings and applies them accordingly. When Capture One can not read the database properly it gives the corrupt warning, as I showed you ad the beginning.
Your first aid is to run a verification from the File menu > Verify Catalog or Session. Browse to the Session database file and open it. It will find the same error and provides the option to repair it.
It may succeed or it may fail. When it succeeds, open the Session and continue with your work. If it fails, replace the database with a new empty one to repair the Session.
Replace Database
Replacing the Session database file is a fairly simple operation with some unconventional logic in it as you will see in a minute. What you actually do is that you create a new session in the same location as the old one.
This sounds scary but the fun part is that existing images and their adjustments remain intact.
If you find this a scary exercise, try it with a dummy session first.
Important notice: Make a backup copy first, better safe than sorry.
The Process Step by Step
The following step-by-step procedure will fix a corrupt Session file.
- Close Capture One
- In Finder (Mac) or Explorer (Windows) locate the session and the corrupt session file inside it; check that the parent folder of the Session and the Session database file have the same name (this is the default but important in this procedure as one of them may have been altered, theoretically)
- This is a great moment for backing up your Session
- Select the Session database file with the .cosessiondb extension; change the extension, for example by adding _old to it, resulting in .cosessiondb_old
- Select and copy the name; you can do this by acting as if you want to change it (Enter on Mac, F2 on Windows) and hit Cmd+C (Mac) or Ctrl+C (Windows) to copy the name without the extension.
Note: this will assure that you create a copy with the same name. - Memorize the location of your Session on your disk; for example, your Session’s parent folder is in the Picture folder. So far for the preparations. Now let’s get on with it and create a new Session database file!
- Start Capture One with the Alt (Mac) or Shift (Windows and some iMacs) key pressed to open it with the Recent dialog; choose New Session in the Recent dialog
- In the Name field, paste the name of the Session you copied in step 5
- For the Location, select the same location and create the Session; in my example, it was the Pictures folder but yours may differ
- Click OK to create the Session.
That’s all!
Finishing Up
Now, go to the Library tool in Capture One. Your images are still in the Capture Folder, as are other images in the other three Session Folders as before you had a corrupt Session database file. Notice that any adjustments are still there.
Any Session Favorite and Session Album must be recreated. Check and select the Process Recipe again that you used for processing your images earlier in the session. And if you shoot tethered, check the Capture Name and counter.
Prevention
You can regularly verify the Session database for errors the same way I explained at the beginning of the post. This will help to prevent unrecoverable errors. And a regular backup is also helpful. Note that there is no backup feature inside Capture One for Sessions, only for Catalogs, unfortunately.
Thank you
For reading. Please feel free to leave a comment. Like us on Facebook or subscribe to our newsletter to stay informed about new blogs.
Want to try Capture One? Or would you like to buy it?
Best Regards,
Image Alchemist
When I try to copy my session to an external drive it says it can’t copy the properties. What went wrong?
Hi Monica,
From your question, it is hard to say what went wrong. You can send a screenshot if you like to me at info@imagealchemist.net. I would be happy to help you.
Best, Paul Steunebrink / Image Alchemist
None of the ratings and edits are recovered? What went wrong?
Hi Karsten,
Maybe you moved the images to a new session but not the Capture One subfolder inside the image folder. Send me a mail via the contact page if you need further assistance.
Best, Paul Steunebrink / Image Alchemist
Hi Paul, and first off thankyou for all your Capture one postings over the years; they are always clear and very helpful.
I would like to share some hard to come by information on the subject of Corrupted sessions.
Your instruction on how to fix a corrupted session file works in all instances APART from the case when the .cos files were created in one version of Capture One and the newer (or repaired) session is created in another version.
Specifically, I have only just succeeded in restoring the edits on a corrupted Capture One 21 session.
The session was originally made in Capture One 20 and updated along with all my other sessions when I upgraded to Capture One 21
I was unaware that the Capture One 20 session was corrupted as the update to Capture One 21 went ahead without any problem and would probably have never known about it as jobs tend to get archived and forgotten…
However the trouble started when the client requested images from the shoot with all the original edits plus one or two others.
I opened my Capture one 21 session and discovered that the selects folder had become jumbled up with some other folder containing a large number of images but crucially none of the edits were visible.
I assumed it would be reasonably simple to locate the .cos files and the Select image files, place them in appropriately created folders and point a newly created Capture One session in the right direction…
Sadly it was impossible to do this until I reinstalled and launched Capture One 20. The process was then straightforward and was completed by launching Capture One 21 and updating the Capture One 20 session file.
A long and tedious story I know but it may help others to be very cautious about updating a session to a new version of Capture One without opening it first to check all is OK.
Another unhelpful aspect of the updating process is that although the folder containing the original .cos files is retained, the backup cosessiondb file that is created only works with the newer version of the programme. This is surely a bug as the only useful backup to be created at this stage would be one that allows the previous version of the software to work.
Kind regards,
Peter
Hi Peter,
Thank you for being here at the Image Alchemist.
The issue with the backup sessiondb file is new to me. As far as I know, you should be able to use it with the previous version, assuming it was made with that version, after renaming.
Best, Paul Steunebrink / Image Alchemist
THANK YOU!!! You saved me HOURS of work and a heap of frustration. Your solution worked perfectly for me. Thank you again 🙂
Great to hear Keith that it helped you. That is the idea. By the way, what an amazing website you have. Images, text, design, everything. Well done!
Best, Paul Steunebrink / Image Alchemist
Thank you so much. This is a great fix!
Happy to hear!
Best, Paul Steunebrink / Image Alchemist
absolute life saver, thank you!
Awesome, Toby. Good to hear.
Best regards, Paul Steunebrink / Image Alchemist
Thank you! Thank you! Thank you! I just did my first big job after our lockdowns lifted and used CO instead of Lightroom to have a more reliable tether. My horror when I found the entire job wouldn’t open the next day when I went to deliver proofs to my client. I can’t believe that this happened in my first week of using CO and it was a massive (indescribable) relief to find your very calmly logical reset article. Capture One should endorse this article and have it in the introduction slides. It is essential reading.
Now I just need to figure out a practical workflow for sending proofs of portraits for entire acting schools that can be selected by the students in a pic-time gallery for me to edit the raw and upload the edited copy for them to download as a jpeg in Pic-time like I did with Lightroom. If you have an idea about that I am all ears.
Thank you again,
Oscar
Hi Oscar,
I am so happy for you that this post helped in times of stress.
Regarding your question on students selecting images, I am not experienced. I know that (commercial) sites exist, but Capture One does not offer this. If you are on Facebook, you could post this in one of the groups on photography.
Best regards, Paul Steunebrink / Image Alchemist
Hello Paul,
I hope all’s well with you. I love your blog, been following it for a while now and I’m now in need of advice! Can you confirm that the steps above apply to Catalogues as well, rather than just Sessions? I’m halfway through editing last weeks wedding and I suddenly got this horrible problem with a corrupted catalogue. I’ve tried restoring my back-up images and edits from the Catalogue that are on my external drive without success. Before I go through the steps outlined above, I though I would check with you to see if the steps still apply to a Catalogue.
Thanks you in advance for any advice!
Best wishes,
David
Hello David,
Thank you for your message. Good to hear you find the blogs helpful.
The procedure outlined here for repairing sessions does not apply to catalogs. Despite many familiarities between the two, there are distinct differences between sessions and catalogs and in particular the function of the database.
A catalog database contains all links to images and all image adjustments. Therefore, it is paramount that you backup your catalog database after every use.
Have you tried to restore the catalog backup? Did you perform a verification of the catalog?
Contact me directly by mail if you need further assistance.
Best, Paul Steunebrink / Image Alchemist
My problem is the other way round.
The data in my session is ok but the metadata tags in the cos files are empty. I noticed this when I tried to open some archived v6 and v7 sessions with a later version of Capture One (v9). The session database file has all the metadata (colour tags, copyright info) and I can see it flash very briefly in the thumbnails browser before Capture One reads the cos files and wipes the metadata.
Is there a way to force Capture One to keep the metadata which is in the session db file and write it to the cos files? Or export the data to xmp sidecars?
Hi Sam,
I suggest you check your Preferences > Image > Metadata section. Set Auto Sync to None. Close and open Capture One again.
You might want to read more on metadata in Capture One
Best regards, Paul Steunebrink / Image Alchemist
Paul you have SAVED me! This was such an incredible help and I was petrified I had lost thousands and thousands of images and ratings of said images. I truly cannot thank-you enough for this!
Hi Cat,
Happy to hear this post helped you. Thank you for letting us know.
Best, Paul Steunebrink / Image Alchemist
LIFESAVER. This helped me so much and worked flawlessly. All my edits, ratings, and files are perfectly intact. Crazy that Capture One doesn’t somehow make this an automatic process already.
Thank you Frankie,
Glad to hear it helped. To be honest, I learned this procedure from Capture One many years ago, but they are not very vocal about it. So I made this post.
Best, Paul Steunebrink / Image Alchemist
Thank you, you saved my life.
Thank you
Thank you 🙂
Happy to hear that Quentin. Thank you for sharing.
Best regards, Paul Steunebrink / Image Alchemist