Apple Event: May 7th at 7 am PT

Looks like no one’s replied in a while. To start the conversation again, simply ask a new question.

How do I move or backup MacOS X 10.7 Lion Server wikis?

Hi,


I'm running OS X 10.7 Lion Server primarily for the Wiki server feature. I have a Mac Pro running 10.7 Lion Server and I can access the Mac Pro wiki from anywhere. The problem is the Mac Pro wiki is empty and I originally created a 10.7 Server Wiki on my MacBook Pro laptop. How do I backup and move the 10.7 Wiki from my laptop to my Mac Pro tower also on 10.7 Server? I've seen articles online about migrating Wiki from 10.5-10.6 to 10.7, but I've found nothing on the process of moving a 10.7 Lion Server wiki to another machine also running 10.7 Lion Server. How do I accomplish this?


Thank you!

Mac OS X (10.7), Mac OS X 10.7 Lion Server

Posted on Aug 6, 2011 9:50 AM

Reply
37 replies

Mar 20, 2012 1:31 AM in response to leskovartem

Why I know that you will write that you have no backup ;-)


If you can´t boot from the old system then you can´t dump the last version of the database - and no, I will not show you how to modiy configurationfiles for that ... because this brings many security holes.


As long as you can mount / activate the old partition - you can also copy the daily dump from all databases which the system runs self. You lost maybe 24 hour but it is better then nothing - it also helps people to remind to make a backup.


The dumpall.psql.gz and dumpall.psql you will find in /Library/Server/PostgreSQL/Backup on the old partition. And don´t forget to copy the data folder of the wiki - see posts before.

Mar 20, 2012 4:20 AM in response to leskovartem

If the directory is empty it could also be that you don´t have any DB anymore ... who knows.


The following things are only ideas and highly experimental.


1.) Stop all services as described.

2.) Unloud the LaunchDaemon to be sure PostgreSQL is reall down using

sudo launchctl unload /System/Library/LaunchDaemons/org.postgresql.postgres.plist

3.) Backup the new pgsql directory using

sudo -u _postgres mv /var/pgsql /var/pgsql.old

4.) Move the old pgsql directory (the default name of your Lion partition is normally Macintosh HD - if not change it as needed) from the old volume to the new volume using

sudo -u _postgres cp -R "/Volumes/Macintosh HD/var/pgsql" /var/pgsq

5.) Restore the Wiki folder.

6.) Reboot and hope that it works.


The paths are typed on the fly - so check it before you use it. There was a binary update of PostgreSQL from 10.7.2 to 10.7.3 from version 9.0.4 to 9.0.5 - the DB cluster itself must normally not be migrated but it could be that something has changed in the config files. So if you get it to work, make single dumps of the DB´s, set up a clean install again and restore the DB´s.


AND START TO MAKE BACKUPS - IT MAKES YOUR LIFE AND THE LIFE OF OTHERS MORE EASY !

Mar 20, 2012 5:37 AM in response to leskovartem

Good to hear.


As information for all who has the same problem. It is really important to stop all running services, because launchd (.plist) restarts all servies if anotherone needs it.

And run sudo launchctl unload /System/Library/LaunchDaemons/org.postgresql.postgres.plist BEFORE you do anything in / with the pgsql folder. Otherwise it could be that you self corrupt your database - if the .plist was unloaded normally all open files / connections to them are closed.


@leskovartem : treat your new friend - TimeMachine - good.

How do I move or backup MacOS X 10.7 Lion Server wikis?

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple ID.