Tracking Forums, Newsgroups, Maling Lists
Home Scripts Tutorials Tracker Forums
 
  HOME    TRACKER    MYSQL




Sharing A Database Between Two Servers


I have 2 harddrives, one with linux and windows, and the other holds all my php and sql databases. I set up the databases with windows and everything is fine. Now I want to be able to just have the linux version of mysql look at that same database on the second harddrive and work with the database. The error I get is "Can't open file:

'**.ibd' (errno: 1): "** being any of my tables. Is it possible to configure them to work together in anyway? I dont want to manually have to dump the database and then reload it every time i switch between the OSs... any suggestions?




View Complete Forum Thread with Replies

See Related Forum Messages: Follow the Links Below to View Complete Thread
Sharing A MYSQL Database
I tried searching for information, but didnt exactly know where to look, meaning which keywords. I did try though hehe

I have a site (or am building) that hosts free accounts for stop motion projects. Now I am developing a script so that everybody can upload movies and stuff to their own account ( which is a subdomain name with their own database and stuff). I want that database to be one main database. I could of course set up a new database and tables for each account, but that would be VERY time consuming... (unless anybody knows an automic way of doing it.)

My question is:

How can I create a script that can be put on their site, but accesses the database of the main site. I cant just put the username and password in a config.inc.php file on each site, cause then they can all access MY database and fool around with it.

Sharing Database Tables Between Windows & Linux
I'm new to MySQL (using v4.1) and have a dual boot machine with Windows and Debian Linux (Etch).

My goal is to share a table named "wordpress" between Linux and Windows by storing it on a FAT32 mount (I realise this limits me to 4GB in total).

From what I can see at the moment, the "wordpress" tables live under /var/lib/mysql/wordpress.

Numerous searches have revealed how to backup data, but I haven't seen any clues on how to permanently reloate a database to another location.

Two MySql Servers, One Database
I have two MySql servers, one in my local PC and one as a testing server in the next room. Using DW 2004 I can use the "put" and "get" to get my PHP files from one PC to the next quicky. How can i do that with the two MySql servers? So if I change the Structure of a table or and data to the Mysql database on my local PC, it will send the changes to the testing server.

Design Of Database Servers
Database design is well covered in undergrad CS. But does anyone know of
a textbook that deals with the design of database servers (and probably
touches on databases themselves), and perhaps deals with interpreting SQL inquiries?

The motivation for this is that I wish to write a database server for a
proprietary operating system (it resembles POSIX, but is not completely compliant)
for an embedded processor system that exchanges queries from clients also
employing embedded processors. Stored data is all in one place.
I'm a little familiar with the MySQL source code, but I don't
wish to replicate something that complex. The sort of investment
I'm talking about should involve no more than three man, er, person-months
by an experienced C++ programmer with plenty of experience in systems
and database programming for both Microsoft and Linux platforms.

Charset Problems Copying Database Between Servers
I am trying to copy a database from one web host to another using the export/import functions in phpmyadmin.

The MySQL connection collation for both servers is utf8_unicode_ci.
The database collation for both databases is latin1_swedish_ci.

One of the problematic fields is "page_title" in the table "wikipage".
The collation of the field is latin1_bin but the data stored is in utf-8 (that is no problem).
In one row in the original database, the page_title field contains the following value: Firefox/Grå_kasse
In the new database, the same value is: Firefox/Grå_kasse

As you see, the value is changed during copy.

I use phpMyAdmin - 2.9.1.1 for both export and import. The charset used for the exported/imported file is utf-8.
I copy from a server running MySQL 5.0.24a to a server running MySQL 4.1.21-log

My guess is, that the problem is during import, not export. That's because in the exported file, the string mentioned above looks like this: Firefox/Grå_kasse

What am I doing wrong?

Comparison Of Open Source Database Servers
We need to compare the open souce Databases- MySQL and PostgerSQL based on features as well as on performance.

If anyone has done such a comparison, please share your knowledge with us.

TABLE SHARING
i need to share a table between SQL Server 2005 DB and MySql DB. the table is on on SQL Server 2005 DB and i want "watch" it in MySQL DB.

Sharing Table
Is it possible to share a single table between two databases? For example, I want a single seller table common to a database about houses for sale and a separate database about land for sale.

Entities Sharing A Look Up Table.
I have created a "country" lookup table, and I have two different entities that both have a "country" field in their respective tables. My question is this:

Are there any disadvantages in having two seperate entities pick up their relevant countryname from the same country look-up table? Is it even allowed? And lastly, as the country table doesnt contain any other fields, the country field acts as a primary key on it's own, correct?

Sharing Data Across Two Databases
I am having trouble deciding how to best handle this situation. I have two separate applications each with their own database, but would like for them to share the same user account information. If a user registers for one application, they should also have an account on the other application.

Using views to share the same user table across both databases is not an option as I am using MySQL 4.

Any suggestions on how I should best handle this?

Sharing Login Details
There is no decent image gallery that can be put with Joomla or Mambo CMS so I am wanting to add a separate pop up page to use a 4images (http://4homepages.de) image gallery.

HOWEVER,

I don't want my users to log in twice to two different databases!

I'm sure there is a way of doing this. (both the CMS and the Gallery are on the same server, and they can both use the same Database.

Sharing Login Details
There is no decent image gallery that can be put with Joomla or Mambo CMS so I am wanting to add a separate pop up page to use a 4images (http://4homepages.de) image gallery.
I don't want my users to log in twice to two different databases!
I'm sure there is a way of doing this. (both the CMS and the Gallery are on the same server, and they can both use the same Database. )

Sharing Data Across Multiple Sites
Sorry if this has been addressed on this board, but I am getting some serious Hour glass action, when I attempt to search this board.

I am attempting to put multiple sites together that utilize one common database with common tables. I wanted to get some advise on how the table can be implemented efficiently.

The concept is I have multiple sites that share the same code and database. I will assign a site ID to distinguish between the sites. Some Article data will be shared across the sites. Example: I have a site for Bass Guitar, Lead Guitar, Keyboard, Saxophone, etc. A component of the site will be articles written about music theory, that can span all these sites. How can I implement a solution that allows One article to be placed on all these sites based on the site ID.

I was thinking of one of two ways (and ofcourse there might be an even easier way, i haven't thought about)

Option 1
Having a field in the database named after each site or siteID, and in my query having a WHERE Clause in the code based on the siteID ie: "WHERE Bass = 1" for the bass site, and on the Saxophone site the same code would be there "WHERE Sax = 1" that way on each site If the article has a 1 in the field, it would display. I don't think it is efficient and if I where to use this concept across a large number of sites, it would very quickly become a nightmare to maintain.

Option 2
Having a field that receives a comma delimited data, that can be parsed with SQL and displaying the results if the data is present. With option two I do not know how to do it with SQL any insight? Is this efficient?

Sharing Data Between MySQL And SQL Server
I have a client who is using SQL Server for a database over 3 geographically diverse locations. Each location has a copy of the database which is updated constantly across their WAN.

I have a single location MySQL database

We have a need to share one table between the two structures.

Is there any way that MySQL and SQLServer can share and mutually update a table between the two.

( I can't just leave the data on their server because if they take their db down, for whatever reason, the missing table will cause serious problems and effectivly shut down work on our operations. )

Sharing MySQL Install Between Multiboot Machines (windows)
On Windows, I multiboot W2k, WXP. All 2 have MySQL install but in different
directories and partitions. I (unfortunately) also have 2 instances of one database.

Is there a way for MySQL to share a common installation and database?

I suppose it is possible. If so, and if I install MySQL in W2K first, what are the steps to
import the database install into XP?
Will I need to install in XP again, and just import the databases? Or just create a
windows shortcut to database directory so it's automaticaly imported into XP MySQL?

Two Servers
I run two MySQL servers on Windows with the two services.
I read in the docs that it exists a way to identify the servers in my.cnf by
groups and about a tool from Linux to manage the groups.
How can I start a server on Windows through the my.cnf/my.ini 's groups?


Different Db Servers
db masters,

Can I use databases from different servers ?

I mean, for example, I have two sites :

www.site1.com --- hosted by providerA
www.site2.com --- hosted by providerB


The site2 uses databases from providerA for running queries or updating tables

2 Mysql Servers
I have a Mysql server lets call it "Production", but also do lots of development when traveling (offline) on my laptop, where i also have mysql instance installed + php + apache .... both MySql are 5 and same build running on windows.

What would be the best way to "replicate" Mysql from my laptop to the server when I get connected. One way solution (from Laptop to Server) would be great, but both ways (whichever is newer gets replicated would be excellent). thought about replication but i undertood that the master 'version' will always be writen to slave.

We need to consider any kind of changes, table changes, dbs change, users, data, etc...

Hope you can give me a light, it is not a large amount of data, and i would not mind a very manual process, as long i can script it or if it is a few steps only.

Redundant Servers
So physical Server A has a mysql database running on it, and physical Server B has an identical database running on it. so if one of the physical servers goes down, I can get information from the other mysql server.

I also want them to keep identical information on each other, so if a user updates his password, it's updated in both databases in real time....and when one of the servers comes back online, it gets rebuilt by server that stayed up.

Multiple Servers
How do I configure my phpmysadmin to administer mysql databases on multiple servers?

Join Across Servers
Can you join two tables across different servers in mySQL, or am I
dreaming of Oracle?

Two Master Servers
I am using two master servers that are synchronized with each other so that if one of them gets disconnected, the other one could take over and no data is lost.
Now my problem is doing backup on the servers. Say I am doing backup on Master 1 and after backup, I will delete the data. So, since Master 2 is synchronized with Master 1, will the deleted data be written back to Master 1?
My batch file is something like this.
echo Executing MYSQL BACKUP
mysqldump -uroot -proot --result-file=%SAVPATH%%FILENAME%".sql" database1
echo Executing MYSQL DELETE
mysql -uroot -proot datalog < "C:Program FilesMySQLMySQL Server 5.0inscript.sql"
Script.sql will call the command "DELETE from table1" for me.

Slave Servers
i have do replication with 1 master server to 3 slave servers.
And i want to grant the 3 slave servers only select option for all user;

Running Two Servers
--=__Part1A441A35.0__=
Content-Type: text/plain; charset=US-ASCII
Content-Transfer-Encoding: 7bit

I am looking into installing 2 mysql servers on the same windows 2000
PC. From what I have found, it is usually possible to have 2 different
versions on the same machine. (Usually one for testing and the other for
production). However, I am trying to run 2 production servers, one for
personal family info, and the other for business opportunity.
Being that I just started using mysql, is it possible then to have the
same version installed twice, or how do I accomplish my task?

Running 2 Msql Servers
I want to run two mysql server on the same win xp machine independent of each other: one on 3306 and one on 3309. How and what files do I have to modify to set the second server port to 3309 permanently.

Consolidating MySQL Servers
My organization currently has 2 different MySQL database servers. We
are in the process of moving the databases from Server A to Server B
and have Server B be our primary database server. I've done some
research on the web and believe the best option is to use the
"mysqldump" command to remotely recreate Server A's databases on to
Server B.

Can anyone please advise whether this is the best option? Also, using
the "mysqldump" command, are there any overwrite issues, such as
existing tables on Server B being overwritten by tables with the same
names from Server A. Would these tables be simply overwritten or
would there be any type of warning prompt?

Master Servers Merge
I want to make query to merge table1 from master server A and table2 from master server B (ex: select * from table1, table2) because my site becomes heavy traffic and database gets bigger. It means I need to separate tables and create new database on other master server B. Do you know how to make "merge" from master server A and B?

MySQL Databases And 2 Servers?
We are planning to reprogramm our search machine and website. Since we
have call agents who query the same database as the customers do, we
had the idea of splitting the database to 2 servers.

The call agents can update customer data with our intern webinterface,
which not only concerns tables that are for the call agents, but also
concerns tables of the search machine, holding company data such as
address, search words, etc.

O.k., now my questions. Since the customer himself can administer his
own data, as well as the call agent (or media agent), I was thinking
of doing following:
* I have 2 servers. Server 1 is responsible for the search machine and
just serves customers searching for a company or for products. The
MySQL database is there just for querying.
* Server 2 serves call agents, as well customers who want to change
their data, reading and writing.
* Since the search machine should of course show updated data the call
agent or the customer have eventually changed, the data from server 2
must be synchronized with the MySQL databese of server 1. (e.g. at
midnight)

Questions:
-------------
0. Is the above described the right way?
1. What do I have to consider when planning the database structure?
2. How do I synchronize? Can I copy specific tables from one server to
another using cronjobs (crontables)? Since this is absolute newland to
me, how?

Any expert knowledge or experience with MySQL replication or MySQL
clusters? I think replication is just thought for mirroring, or am I
mistaken?

MySQL Databases And 2 Servers?
We are planning to reprogramm our search machine and website. Since we
have call agents who query the same database as the customers do, we
had the idea of splitting the database to 2 servers.

The call agents can update customer data with our intern webinterface,
which not only concerns tables that are for the call agents, but also
concerns tables of the search machine, holding company data such as
address, search words, etc.

O.k., now my questions. Since the customer himself can administer his
own data, as well as the call agent (or media agent), I was thinking
of doing following:

* I have 2 servers. Server 1 is responsible for the search machine and
just serves customers searching for a company or for products. The
MySQL database is there just for querying.
* Server 2 serves call agents, as well customers who want to change
their data, reading and writing.
* Since the search machine should of course show updated data the call
agent or the customer have eventually changed, the data from server 2
must be synchronized with the MySQL databese of server 1. (e.g. at
midnight)

Questions:
-------------
0. Is the above described the right way?
1. What do I have to consider when planning the database structure?
2. How do I synchronize? Can I copy specific tables from one server to
another using cronjobs (crontables)? Since this is absolute newland to
me, how?

Any expert knowledge or experience with MySQL replication or MySQL
clusters? I think replication is just thought for mirroring, or am I
mistaken?

Join Tables On Other Servers
Is it possible to, for example, join a table in a database on another server in a select?

Multiple Servers On The Same Host
Well i want to run multiple servers on the same host, has somebody a Howto for this?
Code:

Multiple MySQL Servers
If you need multiple MySQL servers running, what's the difference between installing MySQL once and running multiple servers (by issuing multiple mysqld commands with their own options), versus actually installing two or more DIFFERENT instances of the same version of MySQL?

What is typically done? What are the advantages/disadvantages of either method?

Mysql On Windows Servers
Will mysql work with microsoft server products? Does it lose any funtionality? Would it be better to use mssql?

Multiple MySql Servers
Trying to install MySql 4.1 to our Linux server that already has
version 4 installed. I created a my.cnf file and set the following
params:

datadir = /usr/local/mysql-4.1/data/
port = 3304
socket = /var/run/mysql4.1/mysql4.1.sock
pid-file = /var/run/mysql4.1/mysql4.1.pid
log = /var/log/mysql4/mysql4.1.log


The current installation is running from a different port and the data
dir, socket, pid-file, and log are in different locations.

I then attempt to start MySQL like this:

../mysqld_safe --defaults_file=/path/to/my.cnf --user=mysql &

I get the following error:

/var/run/mysqld/mysqld.pid: Permission denied
rm: cannot unlink `/var/run/mysqld/mysqld.pid': Permission denied
Fatal error: Can't remove the pid file: /var/run/mysqld/mysqld.pid
../mysqld_safe: /var/log/mysqld.log: Permission denied
Please remove it manually and start ./mysqld_safe again
mysqld daemon not started

It's as if it is ignoring the "--defaults_file" parameter and using the
same my.cnf file that the previous installation has.

Two Servers On Windows And My.cnf/my.ini Groups
I run two MySQL servers on Windows with the two services.
I read in the docs that it exists a way to identify the servers in my.cnf by
groups and about a tool from Linux to manage the groups.
How can I start a server on Windows through the my.cnf/my.ini 's groups?

MySQL And Free Web Servers
can you use MySql on web Servers like
Freewebs.com,Yahoo!geocities, aol home town ans sites like that.

Scripts, Databases And Servers
Is it possible to have a script in server1 calling a database located in server2 (both remote servers)?
I made a try but it didn't work.
PHP Code:

 $hostname_owner = "mysql.server.com"; // this is remote
$database_owner = "database";
$username_owner = "owner";
$password_owner = "passw";
$owner = mysql_connect($hostname_owner, $username_owner, $password_owner) or trigger_error(mysql_error(),E_USER_ERROR); 

Moving Databases Across Servers
I just found out that my host is running an old version of mysql, and I think that's why alot of the things I've written aren't working. I've got host space at another server with a newer version of MYsql, and I'd like to transfer most of my work over there.
...But I don't want to have to completely rebuild all my databases and their entire contents.Is there some simple way anyone knows to download the tables & contents of a database from one host and then put it back up on another?

One (phisical) DB And 2 MySQL Servers
Is it possible, that couple of MySQL servers wcan work simultaniously with one (phisical) DB?
My task is following:
I have to computers and thay both have one (and the same)å SCIS Raid harddisk.
This all together shall be a MySQL Server.
have can MySQL be installed so, that DB will be placed in one pace (SCIS Raid), and MySQL works simultaneously on both computers.
what concerns MySQL Cluster, as much as i've understood it is designed to store one DB in different places - distributed by cluster nodes. It is too much for me, isn't it

Can You RIGHT JOIN A List? (from Two Different Servers And Databases)
One database provides a list of items to be used in a query against another database's table. The two different database are on two different servers.

Can I get the list from one query and use it as a LEFT JOIN query in another?

Like:

select items from database1.table1

<loop through in php to get list>

select fish from database2.table2
RIGHT JOIN <somehow add list here from table1>

I've tried using the list in an IN where clause but I need ALL those in the list and only those from table2 where there's a match, else, NULL.


Replication With Multiple Servers In Mysql ?
I want to establish replication between multiple (currently three) servers.
Updates/inserts/deletes may happen on all of them. The idea I came up with
was to do a "circle"-replication. The problem with this is, that if one
server fails the rest may not get updates (until the server is back,
obviously).

Does anybody have an idea how to establish such a replication in a fail-save
manner ? Code:

SELECT From Different Databases/servers Tables
I can't find the exact MySQL instructions to get data from tables located on a different database in the same engine and/or on different databases in different engines. I am working to a migration from Informix. In Informix a table name is defined as:

<tbl_name> (as usual)

or

<db_name>:<tbl_name> (same engine, different db)

or

<db_name>@<server>:<tbl_name>
(different engine, different db)

How can, if possible, replicate this syntax in MySQL ??

MySQL Percentages And Use Indexes On Servers
Working on a MySQL based project: ¿where can i find charts of utilization, percentages of servers using MySQL, comparison charts, etc.? Two days on Google, but nothing.

Apache &amp; MySQL In Differentes Servers.
I've been running a slow Debian machine, with Apache + PHP + MySQL. But, with the time and usage, it's getting to slow to use MySQL. So, now I have another machine (running Debian too), and i've installed MySQL there with all the databases and users moved on to, it works perfectly (with phpmyadmin). What I want is to have the first machine running apache + php, and in the other MySQL. How can i do that ?

I've tested making a mysql_connect from a page hosted in the first machine to the other one running MySQL but i didn't work, couldn't connect. I've tried redirecting mysql port to the other machine (iptables) and that didn't work either...

Resuming... I want all my users to work with the first machine, they have their accounts in there and all their files, their pages, etc... And the database running in the other machine.

Replication With Multiple Servers In Mysql
I want to establish replication between multiple (currently three) servers.
Updates/inserts/deletes may happen on all of them. The idea I came up with
was to do a "circle"-replication. The problem with this is, that if one
server fails the rest may not get updates (until the server is back,
obviously).Does anybody have an idea how to establish such a replication in a fail-save
manner?

Replication With Multiple Servers In Mysql
I want to establish replication between multiple (currently three) servers.
Updates/inserts/deletes may happen on all of them. The idea I came up with
was to do a "circle"-replication. The problem with this is, that if one
server fails the rest may not get updates (until the server is back,
obviously).
Does anybody have an idea how to establish such a replication in a fail-save
manner?

Bulk Copy Between Two Mysql Servers
I want to transfer data between two mysql servers running on two between machines and i want to add this option in may application. so can any one tell me throught which commands i can do this.

Two MySQL Servers Share Data
Is it possible to have who MySQL servers contact eachother at a certain time intervul and send data to each other?

For example: Mysql A is empty. Mysql B is used for all kinds of things. I want Mysql B to send certain tables to Mysql A every 5-10 minutes.

Detecting MySQL Servers On LAN's
I want to build a script/app to make an inventory of all computers that run MySQL servers. And if possible return their versions. I would be running this script/app from a Windows system, so I would like to use VBScript or Visual Basic 6.0. This way the people I am working with will be able to understand what I am programming too. Further more it would be nice if I couldn't only detect the Windows machines, but also other systems (mainly Linux). Can this be done? And how?


Copyright © 2005-08 www.BigResource.com, All rights reserved