redirect solaris database from linux database..


 
Thread Tools Search this Thread
Operating Systems Solaris redirect solaris database from linux database..
# 1  
Old 03-25-2011
redirect solaris database from linux database..

hi..

i have a need .. my php runs on my linux redhat box with mysql.. i want my php code to refer another mysql database
which is in solaris 10 x86... can u tell me the procedure ..
how it can be done through php .. sorry am new to php...
is it possible to redirect from linux mysql to solaris mysql...?
# 2  
Old 03-25-2011
It's simple enough and doesn't really care whether the target is Linux or Solaris or whatever. What host you connect to is part of the mysql_open or mysqli_open or mysqli->open, etc. command. Right now it probably connects to "localhost", meaning, the local machine. Change that to the domain name of the server you want it to connect to.

That server must actually allow TCP connections to mysql, of course.
# 3  
Old 03-25-2011
thanks ...
can u tell me In which file should i change...
# 4  
Old 03-25-2011
Unfortunately there's not any one place they needed to put it. You could try grepping for mysql_open or mysqli_open or "new mysqli" in your PHP files. See these docs for what the code might look like. They might also be using the older mysql_connect system.
# 5  
Old 03-25-2011
k thanks a lot... Smilie

---------- Post updated at 11:49 PM ---------- Previous update was at 11:48 PM ----------

do u know the procedure to install php in solaris 10 x86... i tried both using ./configure and tried with package too.. both ended in failure...
# 6  
Old 03-25-2011
Has your goal changed? You don't need PHP to have a Solaris mysql server.

Compiling your own packages is generally a last resort. Building and installing something manually can be dangerous if you don't know what you're doing since it doesn't have an "uninstall" function like a package manager does.

What exactly did you try and in what way did it not work? Always be specific.
# 7  
Old 03-25-2011
actually i tried install mysql.. which i succeed and then apache,tomcat,oracle .. i installed all the above ...

but PHP is the only thing i didn install in my solaris server...

i tried to install php from sunfreeware package.. and then googled and tried to compile and build php .. i failed in both...

i dono how to install php on my solaris 10 x 86..

now i have a php soure file in linux.. and DB in solaris ... which i can successfully connect using ur guidance..

do u know the steps to install php in solaris 10 x86...
Login or Register to Ask a Question

Previous Thread | Next Thread

8 More Discussions You Might Find Interesting

1. Solaris

Recover Solaris 11 pkg database

Hi, I was messing with pkgsrc and wanted to start fresh so I manually deleted the /var/pkg directory on Solaris 11 :eek: (of course I was supposed to delete the /var/db folder instead)... Anyways... I've basically bricked the Solaris11 Package Manager. Do you know if there is any way to... (1 Reply)
Discussion started by: testers1717
1 Replies

2. Shell Programming and Scripting

CRON Job to copy database and replace existing database

I have a reseller account with hostgator, which means i have WHM and Cpanel. I have set up a staging environment for one of my wordpress installations (client website), which is essentially sitting at staging.domain.com (live site is at domain.com). The staging website is a complete copy of the... (1 Reply)
Discussion started by: nzrobert
1 Replies

3. Solaris

Can't create database after Oracle Database installation

I installed Oracle 10 software on Solaris 11 Express, everything was fine execpt I can't create database using dbca.rsp file. I populated file with following options. OPERATION_TYPE = "createDatabase" GDBNAME = "solaris_user.domain.com" SID = "solaris_user" TEMPLATENAME = "General... (0 Replies)
Discussion started by: solaris_user
0 Replies

4. Solaris

Solaris system and database migration help

HI, let me explain you the current situation. We have three server with OS Solaris and oracle products. Following is the somewhat detail, 1st Server= oracle DB 2nd Server= Oracle Warehouse builder 3rd Server= Oracle Business Intelligence Enterprise Manager Question: these three... (0 Replies)
Discussion started by: malikshahid85
0 Replies

5. Solaris

Restore a database on solaris..

hi All, Can anyone help me with the set of commands which are used to restore maybe a sybase database on solaris.. (1 Reply)
Discussion started by: sankasu
1 Replies

6. HP-UX

sqlite database in HP-UX vs Linux

Hi everybody, We have a cgi application which accesses sqlite database. It works fine in Linux environment but the same code doesn't enter data into the database when done in HP-UX environment. Should the codes vary depending on whether it is Linux or HP-UX. Regards Ruma (1 Reply)
Discussion started by: perlprg
1 Replies

7. Solaris

[help]oracle database error on solaris 8

hi experts, i have some problem with my oracle database 8.1.7 running on sun solaris 8, after 2 days or more i cannot login into database and needed to restart the database, below shown the error : ERROR: ORA-00604: error occurred at recursive SQL level 2 ORA-04031: unable to allocate 4200... (5 Replies)
Discussion started by: bucci
5 Replies

8. UNIX for Dummies Questions & Answers

oracle database on solaris and linux

what is the difference in running oracle database on solaris and linux operating system (3 Replies)
Discussion started by: ganga
3 Replies
Login or Register to Ask a Question