Topic: fa sync with local and remote
i would like to fa install in local server and in my website is there anyway to sync mysql between two ?
without conflicting invoice and order number
Experience is the name everyone gives to their mistakes!
It's much more fun, when you can discuss your problems with others...
You are not logged in. Please login or register.
FrontAccounting forum → Setup → fa sync with local and remote
i would like to fa install in local server and in my website is there anyway to sync mysql between two ?
without conflicting invoice and order number
I'm not sure why you'd want to do that. It is a web application, after all.
But if you really need two separate instances, you could have them use the same database. (Assuming that FA handles the locking required and that your database is accessible from outside.)
Updating two databases independently and then trying to merge the changes is going to be a mess.
You can use MySQL Replication.
Replication enables data from one MySQL database server (the master) to be replicated to one or more MySQL database servers (the slaves). Replication is asynchronous - slaves need not be connected permanently to receive updates from the master. This means that updates can occur over long-distance connections and even over temporary or intermittent connections such as a dial-up service. Depending on the configuration, you can replicate all databases, selected databases, or even selected tables within a database.
There are a lot of tools for MySQL replication.
It's not going to be easy to setup but it something that can be done.
Start by reading the MySQL documentation here: http://dev.mysql.com/doc/refman/5.1/en/replication.html
I have done exactly this. I'm using master/master replication on the MySQL db. I did this because our internet connection in both of our branches is very flakey, and also so that we have an automatic offsite backup that we can use live if a machine goes out for some reason. There is, however, an issue you should know about....
When the internet goes down, if both branches make, say, a general ledger entry then you get a replication error because the primary key is the next one, so both branches use the same number for their GL entries. It's probably the same with sales/purchases, but so far I've only seen the GL issue, and it's a nightmare to correct.
So, the replication works nicely as long as the connection is there, but that's catch 22 because if the connection is there then you don't need the replicated database - you could just work from one instance of FA. If the connection goes down then the 2 locations will be writing different GL data with the same transaction number and you'll get replication errors and lose data.
What we need (in the next version?) is the primary keys written with a machine specific number, i.e 102323, 4, 5 etc from server 1, and 2022323,4,5 etc from server 2.
FA team, this won't take much programming... are you OK to include this in the core? It would be a major feature to have a system that can be replicated and on top of the IT benefit it's like automatic consolidation from a Finance point of view. I am happy to help with the coding if you like.
It's better connect your system with proxy and access it from anywhere across the web and your local system.
See also this thread which has info on configuring mysql to create unique primary keys across separate instances.
FrontAccounting forum → Setup → fa sync with local and remote
Powered by PunBB, supported by Informer Technologies, Inc.
Currently installed 4 official extensions. Copyright © 2003–2009 PunBB.