Solved

Is there a way to share a single database between two different OS's

Posted on 2011-03-17
6
371 Views
Last Modified: 2012-05-11
I'm building a test system that I will be installing Server 2003 and Ubuntu on. I'm setting up both systems to test which one I would prefer to use as a web server. Sharing the same web page files between the two shouldn't be a problem(or maybe it is) but I was wondering if there is a way to share the same database between the two. I'm guessing that any sharing that is going to happen has to be limited to what both OS's will allow to be installed.
0
Comment
Question by:futr_vision
  • 4
  • 2
6 Comments
 
LVL 7

Expert Comment

by:Piloute
ID: 35157893
Hi,

Since you want to have one single database that is shared, you only have to care about the choice of a database that you can install on one of the two systems.

The other system (OS) will be able to query your database form a distinct OS, since there's no relation between running a database (that is running the binaries of your rdbms) and accessing the data of that database. Most of the databases can be accessed from any OS these days (using JDBC, ODBC, etc...).

Now, if you determine you want to keep the database from 'the other' machine on your final server, you will still need to copy the data over. Again, most of the dbs have clean exporting/dumping features that will allow you to copy the data over.

Cheers,
P
0
 
LVL 7

Expert Comment

by:Piloute
ID: 35157906
PS. And sharing your pages should be pretty easy if you store them on a drive that is accessible to both systems...

;)
0
 

Author Comment

by:futr_vision
ID: 35158376
One quick note. I'm not sure if I made this clear but both OS's will be o the same system and I will be booted into only one of them at a time. I referred to the two OS's being on systems when I really should have said they will be on partitions (actually their own hard drives) in a single system. A common  repository for the web pages and their assets is easy enough but can you do the equivalent with the DB?
0
What Security Threats Are You Missing?

Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

 
LVL 7

Expert Comment

by:Piloute
ID: 35158711
OK. I thought it would be 2 distinct machines. In this case are you using virtual machines ? In other words, are they running in the same time ? If yes, my previous answer is the right one.

If your system is a dual boot, and you wish to boot either to one or the other OS, then there's no way to do it with a single machine AND one single database.

You have 2 solutions :
- you install the database 'outside' your OSes and access it from them when you run tests. You need a 2nd computer for that.
- you install a virtualization tool, such VMware and you will be able to have both systems up and running in the same time. Once done, see my prevoius answer.

A database is a 'program' that runs and that needs a running OS in order to be available. So either you install it on a single OS, but this one must be always available. OR you install one database on each of the OSes, and then you duplicate the data (you will have 2 databases).


Cheers,
P
0
 

Author Comment

by:futr_vision
ID: 35161738
Thanks. Since one OS is Linux and the other is Windows I think MySQL is the only option I have unless of course there is a way to replicate the data between the two. if I used both MySQL and MS SQL Server how would I share the data between the two if that is possible. If i use MySQL on both what are my options?
0
 
LVL 7

Accepted Solution

by:
Piloute earned 250 total points
ID: 35165469
Using two different DBs is not the good solution since it will be a nightmare to copy data from one to the other. So make a choice. If I was you, I'd prefer MySQL since it works on both OSes.

If you go for MySQL, install the software and create the database on your first OS. Then install MySQL on the second OS.

Once the db is created on one side, you will be able to export and load from one to the other side with no fuss (check out the official docs on how to do it, since I used to work mostly with oracle and I don't know the syntax for MySQL). Check out this doc for example :
http://www.techrepublic.com/article/backing-up-and-restoring-mysql-databases/5259660

P
0

Featured Post

Find Ransomware Secrets With All-Source Analysis

Ransomware has become a major concern for organizations; its prevalence has grown due to past successes achieved by threat actors. While each ransomware variant is different, we’ve seen some common tactics and trends used among the authors of the malware.

Join & Write a Comment

Ever needed a SQL 2008 Database replicated/mirrored/log shipped on another server but you can't take the downtime inflicted by initial snapshot or disconnect while T-logs are restored or mirror applied? You can use SQL Server Initialize from Backup…
Never store passwords in plain text or just their hash: it seems a no-brainier, but there are still plenty of people doing that. I present the why and how on this subject, offering my own real life solution that you can implement right away, bringin…
Video by: Steve
Using examples as well as descriptions, step through each of the common simple join types, explaining differences in syntax, differences in expected outputs and showing how the queries run along with the actual outputs based upon a simple set of dem…
Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…

744 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

11 Experts available now in Live!

Get 1:1 Help Now