Re: 2 servers 1 common data base
On Thu, Jun 10, 2010 at 10:27 AM, Joerg Bruehe wrote: > |> There may be some merit to this in a specialized setup (SAN systems - > |> I'm not convinced of them, but don't claim expert knowledge about them), > As a slight aside, I'd like to offer you two major advantages of SAN systems: 1. More spindles, thus lower latency 2. Thin provisioning - akin to sparse files, you only lock the space you really use, not what you reserve. Both are of course at their most useful in large environments. -- Bier met grenadyn Is als mosterd by den wyn Sy die't drinkt, is eene kwezel Hy die't drinkt, is ras een ezel
Re: 2 servers 1 common data base
Hi! camelia botez wrote: > We have 2 mysql servers - one active , second standby. > The data base is on nsf storage file system mounted on the active server. > We want to turn on active the second server and to be able to use both > servers with the same nfs mounted data base. NFS may be good for many purposes, but using it for database storage is not among them. Rather than write from scratch, I'll quote my own postings to this list of 2009-Aug-7 and 2009-Aug-10: |> I would *never* use NFS storage for any DBMS (except for some testing): |> NFS access is slower than local disk access, and it adds more components |> to the critical path. So your operations get slower, reliability |> decreases, and (in case of any trouble) analysis becomes more difficult. |> |> I cannot imagine any setup where you have a machine strong enough to run |> your DBMS on it, but not capable of driving sufficient local disks. |> |> The typical argument for having centralized disks serving many machines |> is based on economies of scale (huge disks), flexibility (partitioning), |> and centralized management (RAID replacement, backup). |> There may be some merit to this in a specialized setup (SAN systems - |> I'm not convinced of them, but don't claim expert knowledge about them), |> but IMO not using general-purpose machines and NFS. |> |> Whatever the economical advantages during normal operation may be, you |> should not forget the huge costs you would incur if any in-between |> component breaks and your database stops operating. |> This may be tolerable for some applications, depending on the required |> availability, but simply intolerable for others. |> ... my main objection against using NFS for database storage is not |> performance, it is complexity: |> If your database server does not use local disks but NFS, then the |> network between the database server and the NFS server as well as that |> server suddenly become essential components for your database setup. |> As any component may fail, you increase the risk to your DB. |> |> You may reduce the individual risk by selecting better hardware, dual |> controllers, dual cabling, mirrored machines, ... as much as you like, |> the result will still be higher complexity and higher risks than if you |> had applied similar enhancements to your database server and its local |> disks. Regarding to your technical question: > Just now when I try to start mysqld on the second server I get an error > that says data base cannot be opened is locked by another mysql instance. > What can be done to run on both servers mysqld simultaneously and use > the same data base? One of the technical limitations of many NFS implementations is locking: The concept of NFS is to be a stateless system (on the NFS server), and that is not compatible with supporting file locks. So it may be that NFS denies a lock request from the remote machine, or you may have a NFS implementation that supports locking, and the request is denied because the local instance already holds a lock. Running two MySQL servers simultaneously on the same data files is even worse than trying NFS: An instance of the MySQL server assumes it is the only entity that accesses the data files, and manipulating overlapping data from two instances is a sure way to damage the data structures. So rather than trying to overcome that hurdle, you should be glad it is protecting you. Jörg -- Joerg Bruehe, MySQL Build Team, joerg.bru...@sun.com Sun Microsystems GmbH, Komturstrasse 18a, D-12099 Berlin Geschaeftsfuehrer: Juergen Kunz Amtsgericht Muenchen: HRB161028 -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/mysql?unsub=arch...@jab.org
Re: 2 servers 1 common data base
On Thu, Jun 10, 2010 at 07:09, camelia botez wrote: >What can be done to run on both servers mysqld simultaneously and use the >same data base? You are probably asking the wrong question here. Let's take a step back and ask you another question: What is it you want to achieve on a non-technical level? My gutfeeling tells me you want to have a HA-setup, so that when your database server dies, another one will take over. If that is the case, there's a bunch of tools that can help you do that. You could use classic replication up to a certain point, but active-passive master-master is probably more like what you want to achieve. For that, you can use a tool like MMM (http://mysql-mmm.org) for instance, which will make your life much easier. hope this helps! === Walter Heck Engineer @ Open Query (http://openquery.com) -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/mysql?unsub=arch...@jab.org
Re: 2 servers 1 common data base
Yups. If you want to have two active servers, you'll need to set up master-master replication and give each server it's own datastore. Note that there's a load of caveats if you want to write to both servers, though - read up on the documentation. 2010/6/10 Benedikt Schackenberg > hello, you can not simultaneously fix two deamons to a data directory. a > mysql daemon always has exclusive access to the data directory. > > Am 10.06.2010 07:09, schrieb camelia botez: > > and use >> the same data bas >> > > -- > S&P data GmbH > T 06131 218111 > F 06131 218112 > E schackenb...@termindoc.de > W www.termindoc.de > > Unser Impressum finden Sie unter http://www.termindoc.de/Impressum.htm > > Alle Willenserklärungen der S&P data GmbH bedürfen zu ihrer Wirksamkeit > der Schriftform versehen mit zwei Originalunterschriften. > > Kommunikation über E-mail > Bei der Kommunikation über E-mail ist nicht in jedem Fall auszuschliessen, > dass Dritte unbefugt Kenntnis von den versandten Informationen nehmen. > Soweit Sie per E-mail mit uns Kontakt aufnehmen, nehmen wir an, dass Ihnen > diese Risiken bekannt und Sie dennoch damit einverstanden sind, dass wir > Ihnen per E-mail antworten. Anderenfalls bitten wir Sie, uns einen anderen > Kommunikationsweg zu benennen. > > Für viele der Dateien, die Sie von uns erhalten, benötigen Sie zum > Betrachten den Acrobat Reader, den Sie hier erhalten können. > http://www.adobe.de/products/acrobat/readstep2.html > GF: Benedikt Schackenberg und Christian Peiter > AG & Sitz: Mainz am RheinHandelsregister: HR-B > 8608 Umsatzsteuer ID: DE126633578 > > > -- > MySQL General Mailing List > For list archives: http://lists.mysql.com/mysql > To unsubscribe:http://lists.mysql.com/mysql?unsub=vegiv...@tuxera.be > > -- Bier met grenadyn Is als mosterd by den wyn Sy die't drinkt, is eene kwezel Hy die't drinkt, is ras een ezel
Re: 2 servers 1 common data base
hello, you can not simultaneously fix two deamons to a data directory. a mysql daemon always has exclusive access to the data directory. Am 10.06.2010 07:09, schrieb camelia botez: and use the same data bas -- S&P data GmbH T 06131 218111 F 06131 218112 E schackenb...@termindoc.de W www.termindoc.de Unser Impressum finden Sie unter http://www.termindoc.de/Impressum.htm Alle Willenserklärungen der S&P data GmbH bedürfen zu ihrer Wirksamkeit der Schriftform versehen mit zwei Originalunterschriften. Kommunikation über E-mail Bei der Kommunikation über E-mail ist nicht in jedem Fall auszuschliessen, dass Dritte unbefugt Kenntnis von den versandten Informationen nehmen. Soweit Sie per E-mail mit uns Kontakt aufnehmen, nehmen wir an, dass Ihnen diese Risiken bekannt und Sie dennoch damit einverstanden sind, dass wir Ihnen per E-mail antworten. Anderenfalls bitten wir Sie, uns einen anderen Kommunikationsweg zu benennen. Für viele der Dateien, die Sie von uns erhalten, benötigen Sie zum Betrachten den Acrobat Reader, den Sie hier erhalten können. http://www.adobe.de/products/acrobat/readstep2.html GF: Benedikt Schackenberg und Christian Peiter AG & Sitz: Mainz am RheinHandelsregister: HR-B 8608 Umsatzsteuer ID: DE126633578 -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/mysql?unsub=arch...@jab.org
2 servers 1 common data base
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 We have 2 mysql servers - one active , second standby. The data base is on nsf storage file system mounted on the active server. We want to turn on active the second server and to be able to use both servers with the same nfs mounted data base. Just now when I try to start mysqld on the second server I get an error that says data base cannot be opened is locked by another mysql instance. What can be done to run on both servers mysqld simultaneously and use the same data base? - -- Camelia Botez Unix/Linux/HPC administrator Weizmann Institute of Science Tel: 972-89344964 -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.5 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iQEVAwUBTBBzhSE/LWeWdItOAQJFEAgAg5zq+ocqLnQxJT0PxSmvJ6bSMRA3hESg jAE5x5/55gbRQEMW5py3TD5PToBLROsdza4JlVyfQ/zo62ePaB2uX5zSNcPrN3hs VVclktDFwejCkDdmKH4a/p9284K3UhPgNItmSFQKNsAZJhznoIs9ld5jZ8MiQWjP ZPjjalhII/IMQTODTGwzs00uW1wAXsQcATJlE/JdjwqKaBx6Xq64IQNgj4CNxeMS 2leZiINK/aAL9oi1Qssqx/AzfOm9Cz5+hSKkqxWW7DahoLtDw02zRwf8ERgzuRXS 2GaTXqbRicLzFYXvFJBruNKnMvNfap3Q3YhuzcLVWQ7aSUxeyBSEPg== =SiGe -END PGP SIGNATURE- -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/mysql?unsub=arch...@jab.org