@# Quotes DB     useful, funny, interesting





Google
 
Web www.quotesdb.info
Undernet  |  EFnet  |  Quakenet  |  Freenode  |  Dalnet  |  Ircnet  |  Galaxynet
Page: 1 2 3 4 5 6 7 8 9 10 11



Comments:

<0> boredboy: this seems like a easier way to handle dynamic date within a dynamic section as well =)
<1> a database on one server, and another on a different server
<2> uniltor_force_ are you using that TRUE that fedt stuck on there?
<0> data*
<3> btw, if you don't wanna keep using mysql_select_db(), you can always do SELECT blah FROM db.table
<3> sometimes that's easier
<3> but this doesn't really apply to you...
<2> but hmm...if hes using a different server for the 2nd call, php should be opening up a new connection anyways
<2> i thought anyways
<1> I thought that, until I discovered Im having to reopen connections evertime I want to run a query on a different server
<3> are you or not adding in that boolean?
<2> anyways uniltor_force_, try adding that TRUE for the 4th parameter
<1> 2 secs, I'll just have a peep
<4> uniltor_force_, paste how you use: mysql_(p)connect
<4> dont tell me you use same $var;
<1> $var ?



<1> what do you mean by that ?
<5> uniltor_force_: how about you pastebin the code for us to look at (http://www.pastebin.ca) ?
<1> its ok guys, adding that TRUE seems to work :)
<1> thanks a lot, that saves a hell of a lot of pissing about opening connections all over the place
<3> well, doing it right sure makes it easy
<2> but doing it wrong makes it fun
<5> oh yea, especially when the script manages to delete 2 million rows instead of 2!
<1> just going to have a peep into what that TRUE actually does
<2> [23:58:03] <mod_spox> resource mysql_connect ( [string server [, string username [, string p***word [, bool new_link [, int client_flags]]]]] )
<2> [23:58:03] <mod_spox> Open a connection to a MySQL Server
<2> [23:58:05] <mod_spox> http://www.php.net/mysql-connect
<2> [23:58:13] <4> "bool new_link" <-
<2> i think they covered it all about what that true does
<6> it means 'not false'
<1> well opening up loads of new links might not be a good think if theres repeat calls to it
<1> Blake7984: it wasnt covered enought for what I need to know
<2> going to the php.net link would have explained it all
<1> I mean, is that a new link for everytime its called, or only a new link per database, and repeated calls to same database will return same connection
<1> that php.net link does not explain what Ive just said
<1> ie I had 3 databases and called it 10 times on each database....is that 3 connections or 30
<2> probably 30
<1> probably, maybe, Im looking into it now
<2> that TRUE means new link.....as in new each time.......so close the old links and its not a problem
<5> eh, I'm lost. you are creating a new link for each query???
<2> im out
<3> yeah, wtf?
<3> it's mysql_query([query],[link]);
<3> so you'd have link and either $con1, $con2, $con3, whatever
<3> and=as
<1> obvoisly yeah
<6> but if they're all the same database server, just mysql_select_db to the other one
<1> there different db servers
<1> and for example...
<1> if you made your first connection...
<3> they're on different host
<3> s
<1> then ran a query on your first connection, pulled back 20k rows
<1> then in a loop, opened up a second db connection on a different server
<1> based on values in the first db results
<1> so you can then run queries in the loop on the other databases
<1> without using TRUE, it wouldnt be a problem...
<1> but with TRUE it could be a potential problem
<5> your logic sounds a bit flawed to me. The connection details for the other server can only be gained from the query you run on the first connection?
<3> that sounds really ****ed, man
<1> they are yep
<5> odd
<1> which second database I open depends on what values I pull bac from the first
<1> basically my system is huge, so I come accross lots of arhitecture problems like this....
<1> one database systems are simple
<1> its not that weird a situation....
<5> no it's not, why you're having a problem is weird
<6> what are you using two database servers for?
<6> that's what i'm wondering
<1> to break the work load up
<6> that's retarded
<6> you realize you can cluster mysql
<1> I use 8 database servers and growing
<6> dude, cluster
<6> replication
<6> all that ****
<1> nope



<6> nope what?
<6> why not?
<5> evulish: heh, obviously this is easier ;)
<1> clustering copies the data
<3> do you have like a godaddy host or something?
<1> I might cluser my servers soon...but each one contains unique data in the databases
<3> they like to put each of your databases on a different server
<1> never head of godady
<6> that's retarded
<1> its not retarted...you dont have nay idea of my setup
<6> yeah, it's pretty retarded
<3> you don't have any idea on how you're doing any of this...so i wouldn't worry about it
<5> uniltor_force_: the databases get replicated. not everything on the entire server, unless you set it up. so you can keep some databases unique (if for some odd reason you need it)
<6> you basically set up a management node, a bunch of sql nodes, and a bunch of data nodes
<5> but either way, I don't understand why you set up a system the way you have
<1> I know how to setup a big system dude
<6> uniltor_force_, no, you really don't appear to.
<1> ok
<5> evulish: actually, do you use mysql clustering anywhere? I tried to get the guys here to go for it (even setup a dev system), but their "server experts" said it's not stable or being used
<1> lets say that my site is a huge online game with different "worlds" withthe data in mysql
<1> each server holds say 500 worlds
<7> evening
<1> and I need to process a load of data in a cron job at say 5pm each day for an hour
<6> Boredboy, we only have two mysql servers and one's a hot backup.. so no. but we have probably $6 million or more in our oracle cluster
<6> we have 3 e25ks for it :P
<1> all the data in one database does not scale as the number of worlds grows
<6> i think that's $3 million in servers alone
<3> uniltor_force_: can i play your game?
<5> evulish: heh, I don't think I could persuade them to migrate to oracle (yet)
<6> uniltor_force_, what does any of that have to do with why you don't cluster?
<1> because if I clustered all the servers each would have the same data
<1> can you not see that ?
<6> what's wrong with that?
<1> its not scaleble
<6> what the ****
<6> you're dumb
<1> can you not see that though
<1> I put 500 game worlds on each server...
<5> uniltor_force_: basically, what we are asking is why do you have separate servers for individual databases instead of replicating those databases across all servers
<1> there all independant
<6> clustering is MADE TO SCALE
<6> that's the entire IDEA behind clustering
<6> you can just throw more and more machines into the cluster
<1> I do
<5> evulish: I give up, I suggest you do too ;)
<3> hahaha
<1> yeah, as your obvoisly cant understand
<5> now if I could find that trainee and bitch to him about why his slave mysql server isn't configured correctly ....
<6> i think we have 3 e25ks, 5 6800s, and a few racks of 880s
<6> all sun
<6> uniltor_force_, no, it's you that doesn't understand.
<6> uniltor_force_, i'm about 100% sure that the databases i work with get much more use than yours
<6> and they're clustered
<1> but I doubt it runs a cron job that processes a big batch on all its data
<1> and if your data doubled so wou;d the time tacken to do your batch
<6> we have 100,000 clients requesting updates once a second, we transfer easily over a million dollars a day
<1> we have 250,000 members, of which about 150,000 visit daily
<6> and the data gets updated multiple times a second
<6> these aren't visits
<6> these are constant polls, every single second
<1> yep, but not in a batch job
<6> what the **** does a batch job have to do with anything
<1> what I just said
<6> ..
<1> processes all my game worlds daily
<1> if I had them all in the same database, it wouldnt scale
<3> your game sounds too successful for your coding
<1> as in the bottleneck is disk IO for mysql read write queries
<6> uniltor_force_, you realize that's what a cluster would increase
<4> really bad db design...
<6> i mean, decrease
<1> the cluster would just process the same data but on difefrent machines
<6> the data nodes would store the databases in memory
<1> ok.....so i'll give you this scenario


Name:

Comments:

Please enter the result of the sum 63 + 46 (to avoid spam):






Return to #php
or
Go to some related logs:

sarekke
ruskije gay
chat mircl
#worldchat
#worldchat
DRAC RIB ILO ip address
#allnitecafe
american idol taped at
toothpast+iodide
#kl



Home  |  disclaimer  |  contact  |  submit quotes