installing ZM 1.24.x and a fork on same machine ?

Forum for questions and support relating to the 1.24.x releases only.
Locked
bdmcnxn
Posts: 11
Joined: Sun Jan 16, 2011 7:18 am

installing ZM 1.24.x and a fork on same machine ?

Post by bdmcnxn »

Hi,

Wondering if some of the ZM developers on list could comment on whether it is possible to run the stock ZM 1.24.x, and a fork of same, simultaneously on the same machine s.t., I could access those like this --

http://localhost/zm (stock)
http://localhost/zmfork (fork) or
http://localhost:9090/zm (alternative way for fork)

And what all I might need to change ? For the first option of fork (i.e. URL being ../zmfork), wondering if running the "./configure" script changing all occurances of "zm" to "zmfork" (s.a. for database name, database credentials etc.) would do the trick ? Note that fork may also have different binaries (zmc etc.), and "make install" may overwrite the stock ones. Any way to avoid that ?

The reason for trying to something this dirty is to see if I can do a near seamless version migration, and also because I don't have another machine at the moment.

thanks,
bdm
User avatar
jdhar
Posts: 125
Joined: Fri Oct 01, 2010 9:15 pm
Location: California

Re: installing ZM 1.24.x and a fork on same machine ?

Post by jdhar »

bdmcnxn wrote: The reason for trying to something this dirty is to see if I can do a near seamless version migration, and also because I don't have another machine at the moment.
If your reason is just to migrate versions, there are easier ways to do it. I constantly migrate between 1.24.1, .2 and .3. I keep all of their source in separate directories, and when I want to switch versions, I just run a simple script that runs configure and installs the appropriate one. Since running zmupdate preserves database integrity, there's no issue in doing this:

Code: Select all

#!/bin/bash
echo "Enter old version..."
read OLDVER
echo "Enter new version..."
read NEWVER
echo "Using old version $OLDVER, new version $NEWVER"
OLDDIR=$(pwd)/ZoneMinder-$OLDVER
NEWDIR=$(pwd)/ZoneMinder-$NEWVER

echo "Old directory: $OLDDIR, New Directory: $NEWDIR"
echo "Stopping ZM"
sudo /etc/init.d/zoneminder stop

echo "Making $NEWVER"
cd $NEWDIR
sudo make install

echo "Updating DB"
sudo zmupdate.pl --version=$OLDVER

echo "Starting ZoneMinder"
sudo /etc/init.d/zoneminder start
This is of course if your purpose is to just migrate versions a lot. If it's to actually run simultaneously, you would have to do what you described, and also change the install paths, but some binaries are referenced w/o an absolute path, so I don't see any easy way to do that.[/code]
eyeZm, Native iPhone App for ZoneMinder: http://www.eyezm.com

Version 1.3 now available on iTunes, introduces Montage view, HTTPS/SSL support and H264 native streaming!

Subscribe to RSS feed for updates: http://www.eyezm.com/rssfeed.xml
bdmcnxn
Posts: 11
Joined: Sun Jan 16, 2011 7:18 am

Post by bdmcnxn »

Thanks jdhar. Finally I decided to put each ZM version on a different VM image, however for sequential testing, your script would be quite useful.
Locked