Re: Correct way to transfer V1.4 rules to V2.0?

Robert Ladyman <it-Mr0VS1uEpT87VdE/[email protected]>
Newsgroups gmane.comp.security.ipcop.devel
Organization File-Away Limited
Message-ID <[email protected]>
> On Sunday 25 September 2011 20:46:20 Robert Ladyman wrote:
> > I'm not proposing from backup to 2.0, but from existing 1.4 settings
> > to 2.0, which will be a LOT easier.
> 
> That's it, Robert. 1.4 settings that can be read into a v2.0 install
> would be magic.  My understanding is that once a v2.0 box is
> configured, then the backup/restore functions will work as intended - I
> hope. :-)
> G.

Progress report:-

Currently, the scripts (not finished all the settings yet) I have are working 
with a local copy of 1.4 /var/ipcop/* files and a local copy of 2.0 
/var/ipcop/*. For instance:-

python   faconvert.py  -f  ../1point4/   -t   ../2point0/ 

uses the 1.4 settings from (-f)  directory "1point4" and updates the settings 
files in (-t) "2point0"

you can copy the IPCOP settings files from the old and new machines by:

scp -r -P 222 root@someipaddress:/var/ipcop/*  /some/local/dir

and with ... -P 8022 for version 2 boxes (to a different directory, of 
course).

This is quite handy as you can preserve settings on a central box, but it's 
perhaps not as easy as restoring from a backup. I suspect that you could:-

* Copy a set of default version 2 files to your 1.4 box
* Run the script
* Copy off the version 2 files to a virtual machine running version 2
* Use that virtual machine to create a (V2) backup
* Install using that (V2) backup

The issue that might be a sticking point is the embedding of MAC addresses and 
card types in the /var/ipcop/ethernet/ settings which might not match your new 
machine. I'll have a think about that: perhaps a switch for 'going to be using 
this hardware' or not or you might have to set up a vanilla version 2 box and 
then copy over the files (that way, the vanilla install will have the correct 
hardware configuration).

I have not tried this python script with a Windows machine yet: you would need 
to have python installed for it to work. On linux it's a no-brainer (and 
probably on Macs, too).

Alternatively, you can run the python code on the old (1.4) box against a copy 
of the new settings files for version 2 that you've copied to it, for update, 
as 1.4 has python on board. The existing 1.4 files will be untouched. I cannot 
find python on the 2.0 box - I assume it's not there (is that so?).

Regards,

-- 
Robert Ladyman
File-Away Limited
3 Ralston Business Centre, Newtyle, Blairgowrie
Perthshire  PH12 8TL SCOTLAND
Tel: +44 (0) 1828 898 158
Mobile: +44 (0) 7732 771 649
http://www.file-away.co.uk

============================================
Registered Office: 32 Church Street, Newtyle, Blairgowrie
Perthshire, PH12 8TZ SCOTLAND
Registered in Scotland, Company Number SC222086


------------------------------------------------------------------------------
All the data continuously generated in your IT infrastructure contains a
definitive record of customers, application performance, security
threats, fraudulent activity and more. Splunk takes this data and makes
sense of it. Business sense. IT sense. Common sense.
http://p.sf.net/sfu/splunk-d2dcopy1
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.