cancel
Showing results for 
Search instead for 
Did you mean: 

SLOW remote end of Cluster: cause is remote DB

unknown-user
Champ on-the-rise
Champ on-the-rise
Hi all,

I have 2 servers in a cluster running Alf 3.2 Community with 11,000 pieces of content on Fedora 12 x32 with Sun Java 1.6u16 & a mySQL DB.

Users on the server that the database is installed on have no issues, Alf runs fine and their content is synced to the remote Alf installation via replicating-content, multi-casting & clustering.

The problem is: The remote location that points to the the Database host for its Database, is so slow it has become unusable. It takes 25-40 seconds just to open a space with 40 pieces of content in it. When a user needs to quickly view a file to get a name or number, opening a piece of content is painfully slow.

I then took a copy of the host DB and used it locally on the remote server, and the speed was as it should be, almost instantaneous, but of course, no replicating can be accomplished this way.

Does anyone have any suggestions to help speed up the read of the remote server to the host DB? Is there a way to have replication work with 2 local databases?

Thanks guys.
5 REPLIES 5

unknown-user
Champ on-the-rise
Champ on-the-rise
I have read that adding the line "skip-name-resolve" to the my.cnf file in Fedora may help to speed up remote connections to my alfresco mySQL database. Hopefully it works, and I will post the results when I am able to restart mySQL.

In the meantime, if anyone else has suggestions, I'm all ears ;D

unknown-user
Champ on-the-rise
Champ on-the-rise
Adding the line "skip-name-resolve" to my.cnf on the alfresco database host had ZERO effect on the speed of the remote alfresco installation.

Back to square one, has anyone else had this issue, or know how to solve it??

Thank you.

unknown-user
Champ on-the-rise
Champ on-the-rise
As it turns out, after doing a tcpdump I found that the mySQL call happens only during the last second before the space/data loads, so it looks like its not a DB issue. I am wondering if anyone knows what happens before the mySQL call is made and why it is slowing Alf down so much as to make it unusable?

jlabuelo
Champ on-the-rise
Champ on-the-rise
Hi

Was wondering if you found any solution to keep the DB in a remote server and the Alfresco application in another one? We are trying to get the architecture to work with the Alfresco 3.2 version, but as you say, with the DB in the remote server application is useless, moving it to the same server as application, works as expected.

Do you know which configuration steps we must follow to get this to work?

Thanks a lot in advance

unknown-user
Champ on-the-rise
Champ on-the-rise
What we ended up doing to solve this was creating a master to master mySQL database setup. No, its not really the remote database solution we had in mind originally, but it works just fine and is pretty fast.

We had to setup 2 vpn's between the servers. One is for the multicast address to broadcast on (make sure you have a cluster name set in repository.properties, and the that the ehcache file is activated), and the other is for the mysql master-master db & nfs shares.

NFS shares explained: On each server we have setup a directory and mounted it in fstab on the other server, and set the remote servers share to be the network content store in replicating-content-context.xml to be the nfs share directory.  

                     Example: On the main server in replicating-content-context.xml under networkcontentstore, we point to the directory  /opt/remoteserver/contentstore.
                                   On the main server,  /opt/remoteserver is mounted in fstab as  remoteserverIPaddress:/opt/Alfresco/alf_data        /opt/remoteserver    nfs
                      So in effect, you are mounting the remote servers alfresco contentstore into a directory on your main server, that gets replicated into your /opt/Alfresco/alf_data/contentstore via the replicating-content-context.xml being in place.

This is our solution to replicate content between servers in 2 different cities. If you upload content at the remote location, it is replicated via nfs into the main locations contentstore, and vice versa.

Since both locations have a local mySQL database, there are no ridiculous load times associated with accessing a single remote database (see earlier comments).

Setting up the Master-Master database wasn't too bad, I followed this link: http://www.howtoforge.com/mysql_master_master_replication
A few tweaks had to be made here and there, but most of the time spent setting it up was simply learning how the thing works in the first place.

That is how I got Alfresco working with full replication between 2 cities, 100 km's apart from each other. I was told in earlier posts that it couldn't be done… maybe they meant just in Alfresco… Anyways, its working now.