Automatic restart of server after power failure?

I set up a Mac mini with the server running at my old firm. I have the computer set to restart automatically after a power failure, and Panorama X as a login item. (At the moment, it is not connected to a UPS, although I hope that will change when it is put into service and not just doing a test.). But I wonder if there is a way to get the server to start as a login item also? I am sure, given the history of the utility feed for that building, that there will be occasional outages. I am also teaching someone there how to restart it manually.
BTW, I have confirmed that the server works just fine when I am connected to the office over a VPN. The last network piece is to connect from the other Smith Duggan office, which I will do later today, and I can’t see any reason why that will not work also.

Later:
I have an idea to try. I made an alias for PanoramaX Server.app and put that in the Applications folder. That allowed me to select it as a login item in System Preferences, which may eliminate the need for a manual restart. I do recall reading that the preferred method of starting the server is through the preferences, so maybe my approach is not so good?
(I don’t know why the original message switched to bold; I did not do that on purpose.)

It was the dashes at the end of the first part of the post that did it. I removed them so it is just plain text now.

Thanks, Gary.
My server idea is not working on my computer. It appears that PanoramaX Server starts automatically when the computer starts (I see the icon in the dock). Then I start PanoramaX. Then I open a server-connected database, and PanoramaX freezes and I have to use ForceQuit to kill it. (I repeated these steps several times with the same result.) So I cannot get both PanoramaX Server and PanoramaX working automatically on the computer after a restart with this approach.

That’s what I expected.

That’s disappointing.

Once it is installed, it should be ok to start Panorama X Server by double clicking on it, and I would have expected your alias trick to work.

The purpose of using the Preference panel to launch the server is that if it has never launched before, it installs it, and if it is already installed, it updates it to match the client version before launching. If it is already installed, and the client version hasn’t changed, all it does is launch it, same as double clicking on it.

There’s one other potential benefit of using the Preference panel – it gives you the option of launching thru Terminal.app. This can also be done manually, but it’s much more convenient to let the Preference panel take care of all the details for you.


I guess now I’m going to have to figure out how to monitor what is happening when the system automatically relaunches an app when rebooting. How the hell am I going to do that?

With both PanoramaX and PanoramaX Server set as login items, I wonder if PanoramaX Server launches before PanoramaX, or at least before PanoramaX is finished loading. I don’t know if I can control the order that they launch, but possibly that could help with this issue. Written by someone who knows almost nothing about this subject; but I used the SWAG method.

I found an applet called Delay Start. You put that in you list of login items, and you can add an app to the Delay Start list and set a time delay. It did allow PanoramaX to start, then 15 second later, it started PanoramaX Server. Unfortunately, this did not work any better than not using Delay Start.
And for now, I am moving on. We’ll just do a manual restart of the Server if and when a power failure occurs and later use a UPS to avoid the problem that way.

I tried a somewhat different approach to this and instead made an empty database file I with only a .Initialize procedure with:

openanything "~/Library/Application Support/PanoramaX/Server/PanoramaX Server.app"

I shared this file and saved it next to the PanoramaX enterprise app and then added this file to my startup items. When I restarted it opened PanoramaX and then the .Initialize opened the Server. I got a notice that the file did not connect (I think that’s what it said?) but I was then able to open and connect all my files manually. Don’t know if this helps but at least it did not cause a freeze.

Note that only the file with the .Initialize procedure was added to the startup items - no PanoramaX apps.

If this does work it would probably be more straightforward to just make a shell script to do this.

~/Library/Application Support/PanoramaX/Server/PanoramaX Server.app/Contents/MacOS/PanoramaX

I’m not sure if ~ works in shell scripts, might have to explicitly specify the account folder.

/Users/jimrea/Library/Application Support/PanoramaX/Server/PanoramaX Server.app/Contents/MacOS/PanoramaX