How to restore emlx files in their rightful place (Mail.app)

This might be the wrong place to post this, but I don't really know where else to try. The story goes like this.
My girlfriend uses mail for business and personal, but never filed any of her emails away. There they were, 2000+ emails all in one folder. I don't know why, but it drove me nuts and one evening I tried to file them all away, with hideous consequences.
I somehow managed to create two folders with the same name. I then tried to delete the empty one, but of course, as Murphy's Law dictates, the app deleted both of them.
About 60% of her emails were deleted. No undo, no look in the trash, nothing.
Boy was I in trouble. So I shelled out $80 on FileSalvage, which managed to get them all back. But of course now they come in a single folder with different names (1.emlx, 2.emlx , rather than 6378.emlx etc etc)
Now I've got them in a folder on the desktop, and I need to find a way to get them back where they belong. As the details of where they used to be are still stored in the "envelope index", is there a way of launching terminal and looking at the data in the sql lite db here? Then making some sort of applescript that will save them in the right places?
I'm fairly au fait with applescript, but have no way of finding what the previous names of these files were.
Obviously I've learnt my lesson - so no "should have backed it up" responses, please! Girlfriend still very annoyed. And it all happened 6 weeks ago!

What makes you think this could be the wrong place to post about your problem? I wish all posts here where as on-topic as yours.
Mail has some bugs and glitches when it comes to manage mailboxes. If you see strange things happening when doing so, quit Mail and make a backup of the ~/Library/Mail folder before trying to "solve" the problem by deleting anything.
Back to the problem, verify/repair the disk first (not just permissions), as described here:
The Repair functions of Disk Utility: what's it all about?
After having fixed all filesystem issues, if any, and making sure that there's enough space available on the startup disk (a few GB, plus the space needed to make a backup copy of the Mail folder), proceed as follows if you want to re-create the index:
1. Quit Mail.
2. In the Finder, go to ~/Library/Mail/. Make a backup copy of this folder, just in case something goes wrong -- e.g. by dragging it to the Desktop while holding the Option (Alt) key down.
3. Locate Envelope Index and move it to the Trash. If you see an Envelope Index-journal file there, delete it as well.
4. Open Mail. It will tell you that your mail needs to be "imported". Click Continue and Mail will proceed to re-create Envelope Index -- Mail says it's "importing", but it just re-creates the index if the mailboxes are already in Mail 2.x format.
You can import the *.emlx messages back into Mail by creating a folder with an .mbox suffix (e.g. Recovered.mbox), then a Messages folder within that folder, and moving all the *.emlx messages to be imported within the Messages folder.
In Mail, do File > Import Mailboxes, choose Mail for Mac OS X as the data format, and follow the instructions to import the recovered messages. Note that Mail wants you to select the folder that contains the *.mbox folder, not the *.mbox folder itself.
Note: For those not familiarized with the ~/ notation, it refers to the user's home folder, i.e. ~/Library is the Library folder within the user's home folder.

Similar Messages

  • I want restore these files to the right place

    Hello
    have problem
    have wiped these files of the folder encoding (System/Library/coreservices/Encodings/):
    libArabicConverter.dylib
    libCyrillicConverter.dylib
    libGreekConverter.dylib
    libHebrewConverter.dylib
    libJapaneseConverter.dylib
    libKoreanConverter.dylib
    libLatin2Converter.dylib
    libLatin5Converter.dylib
    libLatinSuppConverter.dylib
    libSimplifiedChineseConverter.dylib
    libSymbolConverter.dylib
    libThaiConverter.dylib
    libTraditionalChineseConverter.dylib
    libVietnameseConverter.dylib
    And when it prepared the files from the trash folder،، And put it in a folder encoding the appeared following message :
    (Sorry, the operation could not be completed because an unexpected error occurred
    Error code-8062)
    My question now is how re-files to folder?

    Hi anas
    I forgot to tell you something important
    CEMETERY currently can not uninstall what her income!!
    do not know what is the cause of it!
    That does not make a lot of sense. Is that a Google translation from Arabic?
    Anyway it may be unrelated to your stuck files so we shall proceed regardless.
    If entered the trash I can watch those files and can to move it to my desktop but can not lay it down in folder encoding.
    OK, well that's good. You may as well take them out of the trash and put them elsewhere for the time being, on your Desktop.
    It may be the problem is that file or folder permissions have been altered.
    So try this.
    1. Open Disk Utility (found in Applications/Utilities) and run Repair Permissions.
    After that, see if you can move one of the files into the folder as before, by supplying your Admin password when asked to authenticate.
    If you still get that error,
    2. Restart in Safemode. This will do a directory check.
    http://support.apple.com/kb/HT1455?viewlocale=en_US
    Restart again this time, normally.
    3. If after trying to move it again, you still get that error, you may have to use Terminal to move them. It will consist of four parts separated by a space.
    Make room so you can see those files, eg libArabicConverter.dylib
    Open Terminal (found in Applications/Utilities) and type
    sudo mv
    and press the space bar once after mv.
    Drag the file libArabicConverter.dylib into the Terminal window and press the space bar once.
    Copy and paste into the Terminal window the address /System/Library/Coreservices/Encodings/
    what you are doing is 1. with root permissions 2. move 3. a file 4. to this folder.
    Press return and type in your Admin password, press return again.
    With luck that file should now be back where it belongs.
    Repeat for the others.
    When finished run Repair Permissions again as you did before, even though this last step is probably not necessary.
    Message was edited by: roam

  • How to Restore Control file to New Server

    I want to test my backup by restoring the full backup of my production database on a separate test server.
    I have taken following action for restore to test server:
    •     Copy full backup to Test Server on same folder where it was in Production Server.
    •     Copy parameter file to Test Server. (Edit control file location on it)
    •     Connect Rman
    •     Set DB with new DBID
    •     Startup Nomount (from new parameter file)
    RUN
    ALLOCATE CHANNEL c1 TYPE DISK;
    RESTORE CONTROLFILE FROM AUTOBACKUP;
    ALTER DATABASE MOUNT;
    Then we found following error:
    RMAN> RESTORE CONTROLFILE FROM AUTOBACKUP;
    Starting restore at 07-NOV-07
    allocated channel: ORA_DISK_1
    channel ORA_DISK_1: sid=9 devtype=DISK
    channel ORA_DISK_1: looking for autobackup on day: 20071107
    channel ORA_DISK_1: looking for autobackup on day: 20071106
    channel ORA_DISK_1: looking for autobackup on day: 20071105
    channel ORA_DISK_1: looking for autobackup on day: 20071104
    channel ORA_DISK_1: looking for autobackup on day: 20071103
    channel ORA_DISK_1: looking for autobackup on day: 20071102
    channel ORA_DISK_1: looking for autobackup on day: 20071101
    channel ORA_DISK_1: no autobackup in 7 days found
    RMAN-00571: ===========================================================
    RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
    RMAN-00571: ===========================================================
    RMAN-03002: failure of restore command at 11/07/2007 16:35:13
    RMAN-06172: no autobackup found or specified handle is not a valid copy or piece
    Can anyone guide me, how to restore control file?
    Irfan

    RMAN> RESTORE CONTROLFILE FROM AUTOBACKUP;
    Starting restore at 07-NOV-07
    allocated channel: ORA_DISK_1
    channel ORA_DISK_1: sid=9 devtype=DISK
    channel ORA_DISK_1: looking for autobackup on day:
    20071107
    channel ORA_DISK_1: looking for autobackup on day:
    20071106
    channel ORA_DISK_1: looking for autobackup on day:
    20071105
    channel ORA_DISK_1: looking for autobackup on day:
    20071104
    channel ORA_DISK_1: looking for autobackup on day:
    20071103
    channel ORA_DISK_1: looking for autobackup on day:
    20071102
    channel ORA_DISK_1: looking for autobackup on day:
    20071101
    channel ORA_DISK_1: no autobackup in 7 days found
    RMAN-00571:It seems to me its not finding the contolfile from 7 days before sysdate ,increase the window size using
    RMAN>restore controlfile from autobackup maxdays 15;Khurram

  • How to Restore a file In Yosemite's Time Machine?

    Since upgrading to Yosemite, I am having difficulty figuring out how to restore a file using Time Machine.  When I select a file, and click on a recent date, the selected date does Not remain selected, and the "Restore" button is grayed out.  How do I select a date and restore???

    Don't try to restore the file; restore the Note. Go in Mail to the mailbox where the note belongs. Enter Time Machine from there and step back until you find the Note.

  • How to restore .bu file

    hi,
    i created back up through SBO Backup (SAP Business One Service Manager )
    i got the Back up files and all Attachments folders.
    But i want to restore this (.bu) and .zip files into existing company database
    while creating time i got these files:
    one backup file - extension is .bu
    other all attachment files and word docs , bitmaps these files are  .Zip extension
    I want to restore these files .
    thnk you.

    SQL server 2005 : supporting back files type is : .bak and .tm
    My problem not solved
    But i got .bu (file type) backup. how can i restore this file ..
    Eg: these files are i got .
    1) backup file name is : Testdatabase091510140500.BU
    2) Attachments091510140536.zip
    3) BitMaps091510140537.zip
    4) ExcelDocs091510140539.zip
    5) WordDocs091510140539.zip
    how to restore these files into my existing company data base
    Regards
    Manoj

  • HT1766 how to restore data file from back up on iPhone 5 docs to go

    how to restore data file from back up on iPhone 5 docs to go

    If it backed up the lock file, then Lightroom was open when Time Machine ran, and the backup therefore may be corrupted.  You could try restoring that backup (without overwriting your week ago version) and see if it'll open.  If it does, you're off and running.  What methods have you tried?

  • How do you delete a VIP mailbox from the mail app?

    How do you delete a VIP mailbox from the mail app?

    From Mail help:
    Make a sender a VIP
    To keep track of messages you receive from especially important people, make them VIPs in Mail. You can have up to 100 VIPs.
    To make someone a VIP, move the pointer to the left of the sender’s name in the message header and click the star that appears. You can also move the pointer over the sender’s email address, click the arrow that appears, and choose “Add to VIPs” from the pop-up menu.A mailbox for the VIP is added to the Favorites bar. For example, if you make Dad a VIP sender, his messages are displayed in a VIP mailbox titled Dad.
    To remove VIP status from a sender, click the VIP’s star in a message. The star is removed and the sender’s VIP mailbox is removed from the Favorites bar.
    If a VIP has several email addresses in Contacts, messages from any of those addresses will appear in the VIP’s mailbox.
    If you use iCloud Contacts, your VIPs are available on your other Mac computers that use iCloud Contacts and have OS X Mountain Lion installed.
    So to remove a VIP mailbox, you would have to remove all its people, and then exit mail.

  • How to restore data files from a purchased app that isn't working

    I recently had to reset my iPad after an ios7 problem with hyperlinks.  The reset fixed the hyperlink problem but now I can't open excel or word files created in a purchased application, productivity suite.  When I click on the file, it starts to open then switches back to the app icon.  Tried deleting and reinstalling the app and now all the files are gone from my iPad.  I backed up my iPad to my desktop before deleting the app but can't figure out how to restore just the files I need. 

    You should be able to mount the partition once you've loaded up the live CD. Just figure out which one it is by using
    fdisk -l
    then mount it to /mnt or wherever you want it.
    As for moving/saving them, I'm not entirely sure how to get them onto an external server. You might have to mount another partition in order to install any apps that you need to connect to an external server, but wait for someone who really knows to answer before you try it. If you're only talking about 4 or 5 MB, I would just mount a USB stick and dump them on there.
    Last edited by Xyne (2008-09-28 03:38:02)

  • How to restore illustrator file after crash?

    how to restore adobe illustrator files after crash OS win 8, and I could backup

    To enable us to help you better, you need to provide as many details as you can about the problem you are experiencing.
    If you design your question effectively, you can get good information from people who are knowledgeable about the topic and who are happy to help you.
    Prepare your question. Think it through. Hasty-sounding questions get hasty answers, or none at all.
    What troubleshooting have you done so far?
    Asking an effective question will get you help faster read how here
    Suggestions for asking for help on a site.
    http://www.catb.org/~esr/faqs/smart-questions.html
    Wanikiya and Dyami--Team Zigzag

  • How to restore backup files to a new database?

    Hello all,
    Our database has stopped working because many config files and some control files were deleted or changed! You can see the full discussion here: ORA-01034 - Oracle not availabe
    We are using Oracle 11g. We got some comprehensive backup files and some incremental ones before this failure.
    Do these backup files contain config and control files too? or just contains data?
    And how I can recover the database using them?
    Thanks for your help

    Thank you so much for your attention.
    Yes exactly, I installed oracle on my laptop and copped its control files into the database and they didn't work
    1- Many backup files of level 0 and level 1. They've been created using these rman commands:
    echo database backup, level 1
    echo %DATE%
    echo %TIME%
    set datetimef=%date:~-4%_%date:~4,2%_%date:~7,2%_%time:~0,2%_%time:~3,2%_%time:~6,2%
    echo %datetimef%
    rman target / @F:\backup1.txt LOG F:\database-backup\rman-logs\%datetimef%.txt
    copy F:\database-backup\rman-logs\%datetimef%.txt F:\database-backup\rman-logs\current-log.txt
    and
    echo database backup, level 0
    echo %DATE%
    echo %TIME%
    set datetimef=%date:~-4%_%date:~4,2%_%date:~7,2%_%time:~0,2%_%time:~3,2%_%time:~6,2%
    echo %datetimef%
    rman target / @F:\backup0.txt LOG F:\database-backup\rman-logs\%datetimef%.txt
    copy F:\database-backup\rman-logs\%datetimef%.txt F:\database-backup\rman-logs\current-log.txt
    What have you done before getting "Oracle not available" message?
    One of group members tried to create a new database using Oracle Database Configuration Assistant and then she couldn't work with the new database (I guess she got some errors when she decided to connect to it using sqldeveloper) and then she deleted the new database using Oracle Database Configuration Assistant, and in the last part it asked her Do you want to delete everything related to the new database and she answered yes.
    What have you done after getting "Oracle not available" message?
    After that we get Oracle Not Available. When I tried to connect to the Oracle via SQLPlus (startup command) it told me that init file does not exist and I recreate that file and put in the right place, then checked some files located in the D:\app\Administrator\admin\iwatchdb\scripts and D:\app\Administrator\product\11.2.0\dbhome_5\NETWORK\ADMIN. Almost in all of that SID and addresses were changed and pointed to the new database, I just alter them and replaced the Yelp (the name of the new database) with iwatchdb (our main database). So the first error solved, and when I tried to start the database up it told me that control files do not exist! and I checked the address that sqlplus showd in the error and it was right! the control files were deleted from: D:\app\Administrator\oradata\iwatchdb (CONTROL01.CTL) and D:\app\Administrator\flash_recovery_area\iwatchdb (CONTROL02.CTL)
    - What is the latest error you get in the alert.log file?
    do you mean this file? D:\app\Administrator\diag\rdbms\iwatchdb\iwatchdb\alert\log.xml
    These are the latest ones:
    <msg time='2013-06-19T19:41:46.498-07:00' org_id='oracle' comp_id='rdbms'
    client_id='' type='UNKNOWN' level='16'
    host_id='DD77KKS1' host_addr='fe80::d4a:8bff:b402:6cfe%13' module=''
    pid='4692'>
    <txt>Trace dumping is performing id=[cdmp_20130619194146]
    </txt>
    </msg>
    <msg time='2013-06-19T19:41:46.540-07:00' org_id='oracle' comp_id='rdbms'
    msg_id='dbkh_generate_new_failure_alert:2777:3311820762' client_id='' type='ERROR'
    group='DRA' level='1' host_id='DD77KKS1'
    host_addr='fe80::d4a:8bff:b402:6cfe%13' module='MMON_SLAVE' pid='1384'>
    <txt>Checker run found 1 new persistent data failures
    </txt>
    </msg>
    <msg time='2013-06-19T19:41:46.658-07:00' org_id='oracle' comp_id='rdbms'
    client_id='' type='UNKNOWN' level='16'
    host_id='DD77KKS1' host_addr='fe80::d4a:8bff:b402:6cfe%13' module=''
    pid='4496'>
    <txt>ORA-00227: corrupt block detected in control file: (block 1, # blocks 1) ->(I copied control files from another database but it didn't work)
    ORA-00202: control file: &apos;D:\APP\ADMINISTRATOR\FLASH_RECOVERY_AREA\IWATCHDB\CONTROL02.CTL&apos;
    ORA-00227: corrupt block detected in control file: (block 1, # blocks 1)
    ORA-00202: control file: &apos;D:\APP\ADMINISTRATOR\ORADATA\IWATCHDB\CONTROL01.CTL&apos;
    </txt>
    </msg>
    <msg time='2013-06-19T19:41:46.659-07:00' org_id='oracle' comp_id='rdbms'
    msg_id='opiexe:3056:2780954927' client_id='' type='NOTIFICATION'
    group='admin_ddl' level='16' host_id='DD77KKS1'
    host_addr='fe80::d4a:8bff:b402:6cfe%13' module='sqlplus.exe' pid='4400'>
    <txt>ORA-205 signalled during: ALTER DATABASE   MOUNT...
    </txt>
    </msg>
    <msg time='2013-06-19T19:41:47.606-07:00' org_id='oracle' comp_id='rdbms'
    client_id='' type='UNKNOWN' level='16'
    host_id='DD77KKS1' host_addr='fe80::d4a:8bff:b402:6cfe%13' module=''
    pid='4692'>
    <txt>Trace dumping is performing id=[cdmp_20130619194147]
    </txt>
    </msg>
    <msg time='2013-06-19T19:42:45.282-07:00' org_id='oracle' comp_id='rdbms'
    msg_id='dbgripsto_sweep_staged_obj:14105:70631439' type='ERROR' group='ami_comp'
    level='8' host_id='DD77KKS1' host_addr='fe80::d4a:8bff:b402:6cfe%13'>
    <txt>Sweep [inc][9769]: completed
    </txt>
    </msg>
    <msg time='2013-06-19T19:42:45.599-07:00' org_id='oracle' comp_id='rdbms'
    msg_id='dbgripsto_sweep_staged_obj:14105:70631439' type='ERROR' group='ami_comp'
    level='8' host_id='DD77KKS1' host_addr='fe80::d4a:8bff:b402:6cfe%13'>
    <txt>Sweep [inc][9706]: completed
    </txt>
    </msg>
    <msg time='2013-06-19T19:42:45.907-07:00' org_id='oracle' comp_id='rdbms'
    msg_id='dbgripsto_sweep_staged_obj:14105:70631439' type='ERROR' group='ami_comp'
    level='8' host_id='DD77KKS1' host_addr='fe80::d4a:8bff:b402:6cfe%13'>
    <txt>Sweep [inc][9705]: completed
    </txt>
    </msg>
    <msg time='2013-06-19T19:42:45.917-07:00' org_id='oracle' comp_id='rdbms'
    msg_id='dbgripsto_sweep_staged_obj:14105:70631439' type='ERROR' group='ami_comp'
    level='8' host_id='DD77KKS1' host_addr='fe80::d4a:8bff:b402:6cfe%13'>
    <txt>Sweep [inc2][9769]: completed
    </txt>
    </msg>
    <msg time='2013-06-19T19:42:45.918-07:00' org_id='oracle' comp_id='rdbms'
    msg_id='dbgripsto_sweep_staged_obj:14105:70631439' type='ERROR' group='ami_comp'
    level='8' host_id='DD77KKS1' host_addr='fe80::d4a:8bff:b402:6cfe%13'>
    <txt>Sweep [inc2][9706]: completed
    </txt>
    </msg>
    <msg time='2013-06-19T19:42:45.920-07:00' org_id='oracle' comp_id='rdbms'
    msg_id='dbgripsto_sweep_staged_obj:14105:70631439' type='ERROR' group='ami_comp'
    level='8' host_id='DD77KKS1' host_addr='fe80::d4a:8bff:b402:6cfe%13'>
    <txt>Sweep [inc2][9705]: completed
    </txt>
    </msg>

  • How to restore photo file after empty trash

    photos file have been deleted and trash is empty.  please advise how to restore. many thx! cheers

    Hey there TizJacky,
    If I understand correctly there were pictures in your Mac OS trash which has been emptied, and want to restore them. In order to do this, you would need to have had Time Machine setup and backing up your computer before this occurred. This article will help you out if you did:
    Mac Basics: Time Machine backs up your Mac
    Thank you for using Apple Support Communities.
    All the very best,
    Sterling

  • How to Restore ".bak" file in Sql Azure...

    I'm new in windows azure. I have taken db backup from my local machine. how to restore database backup(.bak) in sql azure.

    Hello,
    You can't restore a backup file to SQL Azure; you don't have any file access to Azure and there is no such a restore option in SQL Azure.
    If you have the database on a on-premise SQL Server you can deploy it from your server to SQL Azure, there are several tools available for it.
    See e.g.:
    Data Migration to Windows Azure SQL Database: Tools and Techniques => From SQL Server
    Migrating a Database to SQL Azure using SSDT
    SQL Azure Deployments
    Olaf Helper
    Blog
    Xing

  • How to restore hidden files in Time Machine

    Hi,
    I am trying to set up a crontab job to run automatically when I log in, and want to put my original .login file back in my home dir.
    Anyone know how to restore a single hidden file? I don't really want to restore my entire Home directory structure.
    Steve

    Just open a terminal and access it directly.

  • How To Restore Hidden Files

    I have a strange problem. I'm trying to restore a file from yesterday that Adobe Photoshop puts in a temporary folder under /private - which is hidden in Time Machine. I've figured out how to display hidden folders in Time Machine. However, /private is still faded out and I can't access it despite executing the Terminal command:
    defaults write com.apple.finder AppleShowAllFiles TRUE;killall Finder
    The path of my file is /private/var/folders/mq/T/TemporaryItems/
    Does Time Machine even back up these files? If so, how can I access them so I can restore it? I lost a lot of work yesterday and I'm freaking out trying to find it. Thanks!

    Just open a terminal and access it directly.

  • I need to know how to restore a file from sessionstore-backups?

    I opened a link from an email and it over rided the last session I had open in FIrefox because it wasnt open when i clicked the link. I had 48 tabs open in the last session before i did this and cant seem to get them back. How do I restore a file from sessionstore-backups? The latest upgrade file based on the date probably has all of the tabs I need.

    Please post this question in the database forum for an appropriate response: General Database Discussions
    Regards,
    OTN

Maybe you are looking for

  • Total lock-ups with fan running - translate system.log file please!?

    Hi, all. My late 2005 2.3 gig dual G5 has been experiencing random lock ups for as long as I can remember. My system is up to date and I have tested each pair of the 5 gigs of ram that I have and the system freezes with each pair. It can happen at an

  • Doubts alv reports

    hi abapers please guide me. 1. diffrence between list display and grid display? 2. where we can call top-of-page event? 3. where we can do sub total and grandtotal in alvs? 4. how we can call logo in alvs? 5. how to crete check boxes in alv's? thanks

  • Why does my music on my ipod has red square with a red circle around it

    why does my list of music on my ipod have a red square with red circle by it

  • Call precompile​dDll in mobile module

    Hi, I need to call the precompiled dll in my mobile project. I got struck while building the application its gives a "error missing vi or c file" I have no idea what to do.since i am new to this. what method i need to follow to call the precompiled d

  • Waking from sleep problem since 10.4.6

    Since the most recent software updates my revB 12" Powerbook has been shutting down rather than waking up when I jiggle the mouse/touch the trackpad to wake it from sleep. Any ideas?