How to fix Time Machine when it can’t mount the backup volume

I have a server running FreeNAS that I am using it as my Time Capsule for Time Machine backups. Every once and a while the Apple File Protocol share gets corrupted and Time Machine can’t mount the volume after I select it.

To fix this problem we will need to mount the volume as an SMB share and delete some files. NOTE: To do this you will have to enable SMB on your FreeNAS and this is beyond the scope of this post but I have posted some links below that should help.

Alright, let’s get started.

  1. Open Finder
  2. In Finder click Go -> Connect to Server
  3. In the Server Address box type smb:// (Be sure and use  your FreeNAS server IP address)
  4. Open up a Terminal and do the following:

Filesystem              512-blocks       Used Available Capacity  Mounted on
/dev/disk0s2             976101344  876318600  99270744    90%    /
devfs                          219        219         0   100%    /dev
map -hosts                       0          0         0   100%    /net
map auto_home                    0          0         0   100%    /home
//admin@ 1892063336 1394844408 497218928    74%    /Volumes/NAS

$cd /Volumes/NAS/

$mkdir applestuff

$mv .AppleDouble ./applestuff

$mv .AppleDesktop ./applestuff

$mv .AppleDB ./applestuff

$mv .DS_Store ./applestuff

Just to be safe we moved the hidden files and directories to a directory we created called applestuff. Once you are able to successfully mount the volume again with Time Machine you can delete the applestuff directory. These hidden files and directories will automatically get recreated again upon successful mount.

That is it. You should now be able to mount the volume again using Time Machine. Below are a couple of links on how setup FreeNAS for Time Machine backups and how to enable the SMB protocol.

How to setup FreeNAS as a Time Capsule.

How to enable SMB file sharing on FreeNAS.

Adding jar files to Seam deployment

If you look in the /lib directory of your seam-gen project you will see several jar files that Seam makes available. All of these jars are included in the classpath but keep in mind that just because these jar files are in the lib directory doesn’t mean they will be packed and deployed to the app server.

Seam uses the deployed-jars.list for WAR projects and deployed-jars-war.list and deployed-jars-ear.list for EAR projects to select which jars are packaged and deployed. These files are located in the root directory of your project.

If you want to add a jar file to your Seam deployment all you have to do is add the jar file name to the deployed-jars file and redeploy. If you are adding a jar file that is located somewhere else besides the lib directory you will also have to make sure the jar is in your classpath.

Backing up and Restoring Oracle XE

At work we use Oracle as our production database and Oracle XE as our development database on our laptops/desktops. I recently received a new laptop and needed to move Oracle XE and all of the data from my old machine to my new machine. After some searching around I found a very simple method.

  1. Install a fresh copy of Oracle XE on the new machine.
  2. On the old machine run the “Backup Database” command which is located in the Windows Start Bar.
  3. Copy the following folders and files from the old machine to the new machine.
    • c:\oraclexe\app\oracle\flash_recovery_area\XE\AUTOBACKUP\*
    • c:\oraclexe\app\oracle\flash_recovery_area\XE\BACKUPSET\*
    • c:\oraclexe\app\oracle\product\10.2.0\server\database\SPFILE2INIT.ORA
  4. On the new machine run the “Restore Database” command which is located in the Windows Start Bar.

That is all there is to it. You should now have all of your schemas and data on your new machine.