Skip to content

Instantly share code, notes, and snippets.

View Tiggar's full-sized avatar

Jan Brückmann Tiggar

View GitHub Profile
@Tiggar
Tiggar / README.md
Last active August 29, 2015 14:10 — forked from nschum/README.md

OS X Yosemite Messages database merger

Early betas of OS X Yosemite had a bug where the library of old messages wasn't migrated. Instead a new library was created and all old messages were gone.

The bug has been fixed, but if you were affected, you still have two separate libraries. This script merged them for me. Use it at your own risk! You might end up worse than before. Backup everything beforehand. Twice.

This is what your ~/Library/Messages folder will look like if you're affected:

  • chat.db
(*
Script adapted from Wake on WAN - by Mark Muir (2008-04-01)
http://forums.dealmac.com/read.php?4,2751523
*)
property MAC_address : "00:25:4b:9f:63:c8"
property WAN_IP_address : "255.255.255.255"
on run
set command to "/usr/bin/php -r " & quoted form of ("$mac = " & quoted form of MAC_address & "; $ip = " & quoted form of WAN_IP_address & "; " & "
root@bajama:~/ > cd /volume1/timemachine/
root@bajama:/volume1/timemachine/ > l
total 16K
drwxrwxrwx 4 root root 4.0K Mar 7 15:53 ./
drwxr-xr-x 27 root root 4.0K Mar 7 00:33 ../
drwxrwxrwx 2 root users 4.0K Feb 4 20:39 @eaDir/
drwxrwsrwx 4 tm_mbair_iah users 4.0K Mar 7 15:53 IahOnAir.sparsebundle/
sudo mount_afp afp://tm_mbair_iah:securepassword1234@bajama/timemachine /Volumes/TMBackup
sudo mount_afp afp://TimeMachine:**PROTECTED**@hostname/TMBackup /Volumes/somefolder
/dev/rdisk5s2: fsck_hfs run at Thu Mar 7 16:56:29 2013
/dev/rdisk5s2: journal_replay(/dev/disk5s2) returned 0
/dev/rdisk5s2: ** /dev/rdisk5s2
/dev/rdisk5s2: Executing fsck_hfs (version diskdev_cmds-557~393).
** Checking Journaled HFS Plus volume.
** Detected a case-sensitive volume.
The volume name is Time Machine Backups
** Checking extents overflow file.
** Checking catalog file.
** Rebuilding catalog B-tree.
** Checking volume information.
** The volume Time Machine Backups was repaired successfully.
CheckHFS returned 0, fsmodified = 1
iahonair:~ besucher$ cd /Volumes/
iahonair:Volumes besucher$ mkdir TMBackup
iahonair:~ root# fsck_hfs -drfy -c 750 /dev/disk1s2
exit - leaves root
umount /Volumes/TMBackup