Sun Announces Support for PostgreSQL
jadavis writes "Sun announces 24x7 support for PostgreSQL on Solaris 10. From the article: 'Today Sun announced that it will be integrating the Postgres open source data base into the Solaris 10 OS and providing world-wide 24x7 support for customers who wish to develop and deploy open source database solutions into their enterprise environments. Sun is working with the PostgresSQL community to take advantage of the advanced technologies in the Solaris 10 OS, such as Predictive Self-Healing, Solaris Containers and Solaris Dynamic Tracing (DTrace).'"
First Apache, now Postgres?... What's next, will solaris understand cursor keys? Ship with BASH? What's the world comming to?
See also the article about ZFS.
http://www.sun.com/software/solaris/news/111705.j
More about Postgres specifically:
http://www.sun.com/software/solaris/postgres.jsp
...the advanced technologies in the Solaris 10 OS, such as Predictive Self-Healing...
Yes, this is a technology that is able to predict when breaks will happen, and carry out the repairs before the problems ever surface.
Ask me about repetitive DNA
I think the general consensus on /. is that PostgreSQL is superior to MySQL (technically as well as license-wise), so this would be a Good Thing.
This announcement is much bigger than just Postgres Integration, it also includes Xen virtualisation and Red package application support. This will surely make Solaris more attractive than RedHat now on x86-64
bæ8Ã0sÃOE?5r©oÂÃ?âz:ÃÃAÃ?ÃOEÂ6fXÃ?]Â
This sounds good, but you can't say that Sun's behaviour recently has been spotless...
Nuffsaid
________
Don't know about his cat, but Schroedinger is definitely dead.
This 24x7 support thing scares me. Think of all the sleepless nights!
I think the general consensus on /. is that PostgreSQL is superior to MySQL
Flat-files and grep is superior to MySQL.
"It's only going to fall on deaf ears anyway" Deaf ears? Please provide coordinates so we can point the VLA at your planet and hear more...
Nobody gives a shit about some obscure product recently reviewed
Maybe the few millions users of solaris do actually care?
Tip: What you don't care about may have some interest for someone else.
In other words: You are not the center of the world (even though it looks like it from you narrow point of view).
Write boring code, not shiny code!
Better Postgress than never. Stay tuned for the SQL.
Who uses Solaris 10?
== Jez ==
Do you miss Firefox? Try Pale Moon.
While your comment is cute in an esoteric sort of fashion, considering the fact that even the vast majority of slashdot visitors are IE users, I doubt Solaris supporting a new type of SQL qualifies as front page news.
/. visitors that both use Solaris and give two shits about support for PostgreSQL are even farther from it than either of us.
I'm not the center of the world. Neither are you. However, I think we can both agree that the number of
no
Someone needs to do more research. I have found PostgreSQL to be just as easy to start up as MySQL. There are PHP and GUI administration tools available also.
I believe that Oracle is most often installed on Sun Solaris servers, so I am wondering whether Oracle should be worried by this announcement from Sun to offer extensive support for PostgreSQL. It seems that open source databases (Firebird, MySQL, PostgreSQL) are becoming greater threat to commercial ones like Oracle and DB2. Anyway, I think that PostgreSQL is great fit for Sun, because they will have relatively low development costs, but will nevertheless enable them to sell more hardware.
And what would be the problem serving Postgres in a multi-user enviroment? Doesn't it also have users with database permissions? I'll say more, you can have table level permissions in PGSQL and different schemas within a database with varying permissions. There's a lot to be said about MySQL, but not that it is capable of more than PGSQL.
Interesting. Could this be an indication of things to come?
Sun haven't been particularly enthusiastic about open source in the past. Most of the time they give the impressiosn of not really knowing what to do with it - like a kid with a really great new toy only they don't know how to use it. Take OO.o for example and the older funky licensing. They seemed to suffer from some weird love-hate dichotomy.
Sun used to be real big, well, I mean "bigger" - but really lost their way. Now we have Open Solaris, re-licensed OO.o, the funky new Niagra uber-processor (can't wait to see if^H^Hhow it works) and now what appears to be a very cool corporate offering of a OSS database - and a commitment to commit all modifications back to the project as well.
Did someone at Sun suffer from one of those wossnames...epithany thingies?
"...So I hung back and lurked. For 18 months. Can't beat a good old-fashioned lurking."
There is a blog from a Sun Engineer about databases, etc.. He talks about PostgreSQL, how to improve its performance, etc... You can find it here
You are missing the point. If articles had to represent some demographic then we'd all be reading articles about IE and Windows (to slightly paraphrase your comment). I don't use Solaris but I still enjoy the article.
It is exciting news for Postgres users. The prospect of Sun coming aboard and actually contributing is great. And 24x7 support will get more people aboard.
That sound you hear, to coin a phrase, is Sun, cutting off Red Hat's air supply.
No folly is more costly than the folly of intolerant idealism. - Winston Churchill
Well my question is an honest one. I have never ever seen a webhost with PostgreSQL, and the ones I know all say it's because it's hard to set it up in a multiuser environment. The support for user rights in the database is only part of the problem, you also need frontends and administration tools for both the webhost and the users. I've never seen any such solutions. And if they exist, why aren't webhosts using them?
Please see my above comment, #14061391.
What Larry Ellison thinks of this announcement...
There are no loopholes. It's either legal or it's not.
http://www.postgresql.org/support/professional_hos ting
A list of webhosts that support pgsql.
42
I think you could extend that argument to anyone who finds /. exciting.
Anybody know which version of Postgres they will supply? SUN have a history of including antique versions of things into Solaris (look at their Tomcat versions for instance).
Both of my friends, who run CPanel cheap webhosting companies, offer PostgreSQL. For free. It's a little elephant icon right next to the MySQL icon in CPanel. I can assure you, they do exist. A quick check in the CPanel user manual shows a whole section devoted to PostgreSQL. As to how hard it is to set up from scratch - I couldn't say. But here's one way multiple users can use it extremely easily and quickly.
roflmao! Thats true, I think MySQL is a glorified version of MS Access with a TCP Server on the front... PostgreSQL on the other hand is the open-source oracle...
To be completely honest, I don't even know why I'm punching my karma in the throat like this.
The evidence suggests that you are stupid.
Anyway, thank you for fulfilling my prediction.
How will MySQL respond? I'd be sad to lose our investment over the last five years, but commercially the words "Oracle" or "Sun" just radiate comfort factor to less well informed customers.
Pining for the fjords
What I wonder is if you should get such support and just use it as fallback for your problems on different architectures. That way you could test if your problem is specific to your setup and if you can reproduce it, you can use Suns fix and port it back to your real problem.
Are there any other big vendors with such specific OSS support?
Because Solaris is a real Operating System targeted at professionals. The people who will be installing and configuring PostgreSQL on Solaris 10 will have problems with the configuration. Those who are used to playing Sysadmin on their Gentoy box running MySQL will obviously find the idea of configuring PostgreSQL hard.
Vs pgAdminIII ?
Nice GUI admin tool. I like that much better than silly web applications.
beeing multiuser is just as easy in postgresql as mysql..
But if you for some unknown reason must have a web tool, there is phppgadmin
Although I am seeing some high-end financial-transactional based systems running Redhat lately, I am glad that Sun has its ear close to the ground.
I moved to PosgreSQL 2 years ago, and this has re-affirmed my confidence in Sun in embracing open source initiatives.
I guess it was absolutely something that had to happen, to re-invent yourself. IBM did it, Apple did it.
The future for Sun should be interesting in the next couple of years, I most certainly will be watching.
Maybe we should buy shares in Sun? Sitting on $3.68, Apple NOW sitting on $64.52.
Most times these days on centos I only have to run 'yum update' 'yum install blah' or 'cpan -i blah' with very occasionally having to do it manually or mess about a bit to get things working.. is it as trivial with solaris now or would I be spending twice as much time configuring and looking after the servers?
Probably safer to stick with what I (sort of) know but just curious about solaris.. last I used it was 7 or 8 years ago I think.
after some point, the administration of postgresql is imho much clearer than the mysql version ... and as for setting it up, if you can read the manual, you should be fine :)
but i don't think you should choose a database by how hard it is to set up (people that 5 years ago tried to install oracle on redhat , like me, know what means a hard to set up database), instead you should choose the database by it's capabilities for your applications. if you need simple fast selects, go mysql, if you need very deep recursive selects and stored functions, go for postgresql or any other real database.
mysql is picking up pretty fast lately, but it's still behind. if they have a stable version with optimized subqueries and heavily tested stored procedures, it's worth a look.
I'd tell you the chances of this story being a dupe, but you wouldn't like it.
Sun is playing some silly "half ass" open source game when it come to opening up solaris. Until supposedly next summer, it won't be possible to have the full opensolaris code. By then it will be too late. And furthermore it's unclear whether Sun will be maintaining a commercial version of Solaris alongside OpenSolaris that contains every component worth having. Nobody wants to use subpar operating systems, especially if they have to substitute components, this also has the effect of eroding uniformity.
I'd love to try out opensolaris, but until maybe spring 2006 it's not a workable OS.
I think what you have run into is the slashdot nerd-ego. There are a ton of /.rs that think they are gods gift to technology. They like to hear themselves talk about "nerdy" things so they get these articles about software they will never touch and pretend to read it just hard enough so they can spout off about it to a cube neighbor.
/. editors should have a nice article about firefox (since they released v 1.5rc3)
I know at least one person will tell me about this article today and:
1) they have never set up postgresql.
2) they have never set up solaris.
3) they sure as hell havn't set up postgresql on solaris.
perhaps
or google (since a link "Try searching for test on Google Book Search") is now in my results
or any number of other tech related happenings.
Despite whatever flavor of the week they are licking.
- ditch the forte crap and vendor lockin scheme
- stop shipping your own bastardized Perl
- ultrasparc performance is terrible. Address it.
- get the X11 libraries and headers fixed - completely.
- find a termcap that works with the rest of the world
- fully support samba for chrissakes
- DROP the java front ends for everything. We get gray waiting for loadtimes.
- Get ldap working without so many support applications (clean up all the netscape crap or get rid of it)
- better yet, clean up the OS subsystem and make your platform work better with OSS software (eg: gcc)
Join the Slashcott! Feb 10 thru Feb 17!
LOL! not sure why that made me laugh so damned hard.
what?
Actually I read /. everyday and Solaris is my favourite operating system, I have used Sybase, Mysql on Solaris 8 and 9, I have used Postgresql many times in linux and I am now looking forward to installing postgresql on my solaris boxes. But beyond that what is important about this article isn't so much that it doesn't relate directly to /. users as perhaps many of them don't use Solaris or Postgresql, but how it relates to Sun moving even further into the world of open source, they are now directly offering support and at low cost for an opensource database, this is hugely important because it gives a good indication that Sun is really truely commiting to OSS, rather than the lip service they have offered in the past.
GeekServ Unix Consulting Services (http://www.geekserv.com)
your webhosts are losers, time to move on
There are places where the networks are not touching,and there are places where they are-Boeing's Lori Gunter
Independantly, Oracle bought the company the provides the innobase substructure for MySQL.
--dave
davecb@spamcop.net
I can't believe this made the front page but the cool new ZFS filesystem didn't!
Um, kill -HUP forces postgres to reload config, it works for some (all?) configuration changes, and I didn't notice it being a real restart- clients don't get disconnected.
Fix me if I'm wrong, i didn't use this feature much. But it worked for me when I needed it.
--Coder
Oracle has recently cozied up to Sun Solaris. I wonder what Oracle's reaction to this Sun/PostgreSQL announcement is, especially since Oracle recently tried to take out MySQL?
One advantage to firebird is that it has an embedded version whilst PostgreSQL doesn't.
Currently I use SQLite but I am thinking of moving to firebird embedded for its extra functionality.
Based on upvotes, Ageism is the only "-ism" Slashdotters care about and think isn't SJW
the silly name. I mean, what *was* wrong with just "Postgres"? It's a bit embarassing to be the open-source advocate and have to say silly sounding names like this. "How is that spelled?" Why do Linux people feel compelled to spell everything beginning with "gn", "k", or with some recursive acronym? Sigh...
I was wondering if it was possible to write stored procedure / functions in C# with postgreSQL. I know that with oracle and SQL server it's possible but for obvious reason ( $$, and I don't care about the SQL server express edition ), it's not really possible for me :P
I know it's a bit OT but I haven't really saw anything with google >_
- DROP the java front ends for everything. We get gray waiting for loadtimes.
Sometimes I think Sun really didn't think out the Java GUI experience very well before implementing it. The reason you get those blank screens during load times is how swing threads. It uses the same thread for event handling as for screen redrawing. From a programming stand point, I'm sure it makes it much simplier to use their API's for simple GUI's. However, when you've got tools written for system administration that will almost definatly take some time to process an event, it makes for a bad end user experience. Java is a great language. However, their poor implementation of the GUI API's makes the end user experience bad. And ultimately people who use java programs think the whole language sucks because of a bad user experience with the GUI.
If an officer ever threatens to taze you, say you have a pacemaker.
"better yet, clean up the OS subsystem and make your platform work better with OSS software (eg: gcc)"
This one is funny. When Sun first did their 64-bit port of Solaris, the kernel guys used (drum roll please) gcc. Sun's C compiler wasn't up to speed, and it would take them too long to do it.
That was, what, 5-6 years ago? Clearly they missed an excellent opportunity to expand gcc then, but that would compete with their internal C compiler. Which ought to be killed off due to the stupid license manager which hinders every single compilation (so much so, that the Solaris O.S. buildmeisters have turned it off).
I swear, that License Manager has killed more good Sun products than anything else. Sun's dev tools for one. Teamware for another (Teamware was the first version of Bitkeeper; and both just rock). Too many PHB's at Sun these days it would seem. What a pity.
Agreed. It would be a killer feature for Postgres. An embedded postgres would allow developers to include an extremely capable RDBMS that could easily be distributed as a library linked with an app... but which would allow easy migration to a full server-style postgres installation -- especially considering the BSD license used for Postgres. No fucking around with complicated installs and setting up... just bang... it works on the users system, but allows for future growth.
Just look at the usage SQLite gets... Microsoft does something similar with MSDE (which is just a mildly crippled SQL Server).
I think your comment may need clarification.
Clearly, Postgres works fine in multi-user installations. I am inferring that you probably mean that MySQL is easier to administer in the kind of multi-customer environments you have on boxes doing web hosting duty.
Of course, I have no idea whether this is true or not, since that's not the business I'm in. However, I suspect the historical popularity of MySQL as a rudimentary, low footprint data store for dynamic web sites means that there is more expertise in the web developer community. What you know is always simpler to admin. It may also mean that there are more tools, and more mature tools, for administering in web hosting environments.
I see both systems converging towards parity over time, in the core set of features that people find most useful in most every day applications. The kind of applications I do have very complex queries, and Postgres was a better choice for them because MySQL lacked support for complex queries -- up until recently. The only reason I didn't use Postgres much was that it wasn't on Windows, which my clients use. Up until recently. Postgres had spatial (GIS) data capabilities and MySQL didn't -- up until recently. The list goes on and on.
You can look at what people need in a database platform as a kind of pyramid, with widespread requirements at the bottom, and exotic or "enterprise" requirements at the top. Both platforms had somewhat incomplete foundations up to now, with a few second tier and third tier bits poking up here and there: object relational, spatial, replication etc. I'd say that as of 2005, the foundations of both products' pyramids are complete, and appear to be solid.
In 2006 I predict that people will start noticing this, and the products will establish a strong track record outside the kind of web and open source millieu and in the traditional bread and butter space for RDBMS vendors: IT. They won't displace SQL Server because of its integration with Microsoft's tool stack, but they'll make a dent. MySQL in particular will be integrated with many open source projects in the way SQL Server is a natural choice if you're working exclusively with Microsoft. If I were a betting man I'd lay money on MySQL and Postgres getting what peole in the software business is called "traction" by the end of next year.
If I were to put the relationship between MySQL and Postgres in familiar terms, I think they'll end up like Linux and BSD respectively. MySQL will have much broader popular appeal, and Postgres will appeal to a more select community with somewhat different values and culture.
Post may contain irony: discontinue use if experiencing mood swings, nausea or elevated blood pressure.
What you say is true, but not complete.
The factions in Sun continually swap positions. I think they have a bi-weekly meeting of VPs where they pull "Hate M$", "Billy G. is our friend", "Love Linux", "Kill Linux", and "BSD Rules" cards out of a hat then push that position until the next drawing.
Then, just for fun, they completely reorg the company every month.
When they made the Postgres engine SQL compliant, they changed the name to PostgreSQL.
Finally. Sun hasn't shipped a C compiler with its OS since SunOS 4.1.3 (circa 1990).
For integer ops, anyway. For FP ops, well, it sucks. But that shouldn't matter for things like web servers and most DB apps.
. xml
http://www.sun.com/processors/UltraSPARC-T1/index
32 simultaneous threads of execution, 72W to drive the chip. How much power does a quad Zeon draw?
Dell's gonna shit their pants.
Our shop is mostly Solaris (8) and RHEL with Oracle 9i. We're currently looking at upgrading our Solaris boxes to Solaris 10.
The problem? Oracle 9i is not supported on Solaris 10. It's supported on RHEL and earlier versions of Solaris.
So at the moment, it's not doable for us. But from the tinkering I've done with Solaris 10, it's actually pretty cool. I've got it running on an Ultra 10 under my desk and have been evaluating ot for a couple of months now. I'll tell you it's much lighter than previous Solaris versions (well, 7 on. 2.6 was pretty zippy in comparison later versions).
How is a "Red Hat binary" different from a "Linux binary"? What will it take to make Debian Linux binaries run on Solaris 10 with this Container tech running? Will Debian Linux binaries run on Debian Solaris with the Container running?
--
make install -not war
Lets face it - Oracle isnt kicking Sun's butt - its IBM. Ever since the dot com bubble burst and IBM finally found its game, the sun has been setting (or eclipsed (ha-ha!)) with IBM stealing more and more of Sun's customers and grabbing new accounts. Part of the problem for Sun is that IBM has the ability to sell solutions. You want a software stack to handle applications? IBM has it (WebSphere, DB2, etc). You want a software stack to manage infrastructure? IBM has that too (all the Tivoli stuff). You want office productivity infrastructure? IBM has that too (Lotus stuff). And along with all these go IBM servers.
This is Sun's attempt to come back into the market by saying - hey - we have a database solution too. Next thing you know, they'll be throwing their support behind (or buying out) a vendor of J2EE containers.....
There is no such thing as luck. Luck is nothing but an absence of bad luck.
The announcement cites Postgres as Sun's RDBMS, bundled and supported. It also cites Solaris as Oracle's preferred (64bit) OS. Is Solaris now the best environment for developing relational apps on Postgres, then moving to Oracle for release versions? Will the Sun tech, support and Oracle partnership make the port from Postgres -> Oracle easy, even "automated"?
--
make install -not war
Yes, you think that's insecure, but the truth of the matter is that giving individual users their own MySQL username and password does not make it any less insecure. I am of the opinion that it's better not to lull people into a false sense of security: if they can see how sharp the blade is, they will be more careful when using a powerful tool.
Fact: it's trivial for any user with an account on a box to read any other user's files, even in their cgi-bin, since they must necessarily all be visible to the Apache daemon user {www-data on Debian systems}. And there's no way to obfuscate the database password: ultimately, the script has to send it to the server in the clear, so all you have to do is make a copy of the relevant file and replace a line that looks something like with That's bad enough in itself; but if the hosting company has decided to use the same password for MySQL and Linux login {and therefore POP3, FTP and maybe even shell access if they're on Gold} -- and there is at least one hosting company out there that are doing this {I had a reseller account with them once; I shan't name them} -- then Sir Hacksalot has the power to compromise more than just your database. One doesn't need to be terrifically "l33t" to find out which hosting company a competitor is using {as hard as it may be for you geeks who all have your own servers in your back bedrooms [and no hosting customers, except your own sisters' girly photo blogs, average 3 unique visitors per month, all bots] to believe this, there a lot of businesses who use hosting companies -- and more than a few who get their hosting done through cheapskate resellers}, get another account on the same box, and cause as much trouble as one can with a MySQL-based site.
The only way around this is for every user to run their own instance of the Apache server as themself, on a different non-privileged port; and to have a transparent proxy on port 80 that redirects requests to the appropriate port based on the host name. This way, users' files don't need to be readable to anyone save that user. Although it still would not be wise to use the same password for the two services, because a database password can still be exposed by careless use of chmod. And I wouldn't like to think how that is going to affect performance.
Je fume. Tu fumes. Nous fûmes!
Perhaps because MySQL is already included in Solaris?
$ pkginfo | grep MySQL
system SUNWmysqlr mysql - MySQL Database Management System (root component)
system SUNWmysqlt mysql - MySQL Database Management System (test component)
system SUNWmysqlu mysql - MySQL Database Management System (usr component)
You can write SP for PostgreSQL in some half dozen languages...perhaps more, but I would be very surprised in C# were one of them...at least at this point. IIRC, Java is now an option. With so many language options already available for PostgreSQL, do you really need C# in the mix?
Actually there is completely no point whatsoever in setting up MySQL as multiuser in a simple web hosting environment. You may as well just tell everyone to use "root" and no password.
Yes, you think that's insecure, but the truth of the matter is that giving individual users their own MySQL username and password does not make it any less insecure. I am of the opinion that it's better not to lull people into a false sense of security: if they can see how sharp the blade is, they will be more careful when using a powerful tool.
That's a really bad idea IMO.
Fact: it's trivial for any user with an account on a box to read any other user's files, even in their cgi-bin, since they must necessarily all be visible to the Apache daemon user {www-data on Debian systems}.
That's not a fact, but it is the sign the server hasn't been configured very well.
The only way around this is for every user to run their own instance of the Apache server as themself, on a different non-privileged port; and to have a transparent proxy on port 80 that redirects requests to the appropriate port based on the host name.
Shared web hosting platforms should really be using some implementation of per-customer compartmentalisation at the OS level if the users are allowed SSH access, or to run CGI's. Solaris 10 supports this natively, there are at least two separate native implementations of something very similar for Linux, Windows 2003 even supports this to some degree I gather (though not to quite the same extent) and then there are tools like VMWare.
Of course, running your MySQL server on an entirely separate hardware from your web server is also a Good Thing(TM), especially when someone manages to (most likely inadvertently) DoS your SQL server.
However, failing that, any web server used by multiple customers to run CGI's should at the very least be configured to use something like suexec, which has been a standard feature of Apache for about 8 years or so.
Using suexec (or gsexec, or cgwrap, or similar tool as appropriate for whatever web server your using) is precisely intended to prevent CGI's running as one user from accessing or modifying files (including other CGI's) that belong to another user.
Sun working with BSD makes sense from a historical perspective as well. The original Sun OS was build on BSD, as Bill Joy, the technical founder was a big guy in the BSD world, and left to start Sun on BSD technology. Sun migrated from BSD to AT&T Unix after several releases.
As a result, their are probably elements of a BSD culture in Sun.
In addition, the GPL space makes it harder for a traditional software player to compete. The GPL makes sense for PURE hardware players (of which Sun is not, and in x86 space, it is REALLY tough to be a hardware player, only a few have done it, because Intel grabs the bulk of the profits leaving profits only for the most efficient manufacturers, and Dell dominates supply-chain management), as it elements the costs of software development... Dell wins in a GPL game, as costs come down from not paying for an OS, some of the savings get passed on to customers, some comes out as profits. Other players that don't dominate in supply chain issues aren't as well off.
In addition, the corporate GPL'd OS game is a services game. There is no real money in the OS license, so you have to sell support contracts. Now support contracts are high margin... IF YOU ARE REALLY GOOD. You have to be good enough that you don't have to do much on the support end... as each time support is used, your margins get eaten... it's an insurance model, and its a tough game to play.
The BSDs are more "corporate friendly," as the company can work with the BSD-core group to push up changes (otherwise you have to maintain forks, which is expensive, which doesn't really get you a competitive edge. So you have a financial incentive to push fixes upstream, but build add-ons or enhancements that you keep proprietary. In PostgreSQL and Apache, this works fine, as people develop these add-ons, they either release them to the world at large, in which case they are incorporated, or they keep them to themselves, and the core team has gotten a demo of what "can be done" for free... As Linux demonstrated, redoing known technology is SUBSTANTIALLY easier than building new technology.
Sun playing in BSD land makes a LOT of economic and cultural sense.
Alex
Being the only one at Sun who knows what's going on around you. :-)
We moved from MySQL to PostgreSQL a few years ago, and couldn't be happier. The secret is to do it intelligently...
:= thread_count + 1; ON DELETE to THREADS, find the topic and thread_count := thread_count - 1; It's trivial when you get the hang of it, but then your system is lightning fast.
First, just do a straight port, get PostgreSQL running your MySQL data.
Buy a beefier server, because at this stage, PostgreSQL WILL be slower. For raw reading of simple databases (the old joke that MySQL isn't a real database isn't AS true anymore, but is in the ideas), MySQL is faster. PostgreSQL shines as you build more complicated system.
Second, use explain and start optimizing your system. MySQL develop tends to do series of queries, because the MySQL protocol is nearly "free." Doing 5 queries and doing the joins in the software in MySQL tends to be fast, but is REALLY slow in PostgreSQL. So start building more complicated queries using joins server side. At this stage, PostgreSQL catches up (or nearly so) with MySQL.
Third, learn PL/pgSQL. This lets you do a LOT of optimizations with triggers and functions. For example, if you need to look things up in 3 tables to get the Primary Keys, then query a third table, in MySQL you do 3 SELECTS, store the values in variables, then the final SELECT to get the data. In PostgreSQL that would be painfully slow (the connection costs kill you), so you do a massive join, which is okay if you have enough RAM and configure PostgreSQL to use it, but it sucks up memory. Then you build the PL/pgSQL function. This lets you do it the "old way" grabbing the data, keeping it in variables INSIDE the database, then doing the query. This is REALLY REALLY REALLY fast in PostgreSQL, keeps the RAM usage reasonable, etc. Sure you can throw 4-8 GBs at RAM cheaply, but when you start doing a bunch of really big JOINs and SORTs, you can't always get PostgreSQL to use it smartly.
Fourth, at triggers whereever possible. If you ever run a COUNT or other aggregate, re-think. For example, in a forum (trivial case, but fun), you may want to display the number of threads in a topic. Well, running a SELECT COUNT(*) on the threads JOIN topics will BE BALLS slow on PostgreSQL... HOWEVER, you instead do a trigger that keeps a count in the TOPIC called threads. You would do this in MySQL by having a second INSERT when you do a thread, but in PostgreSQL, you let the database handle it. ON INSERT to THREADS, find the topic and thread_count
Also, optimize your INSERTs. In areas where you currently check IF "is this already here" THEN UPDATE ELSE INSERT, you do that in stored Functions. function insert_or_update (values) that does an UPDATE and if it fails, INSERT, or otherwise does the logic server side.
Once you learn to do real database programming, even at the rudimentary level I described, PostgreSQL SCREAMS. If you are building web sites/web applications, they SCREAM. However, if you treat PostgreSQL the way most treat MySQL, as a data dump, you'll be miserable at the performance.
Final neat idea that we never implemented... but will one day. We were planning to use PL/php (there is a PL/perl) for a performance hack. For each major script that does a bunch of queries, even with optimizations, there is a final hack you COULD THEORETICALLY do... this is a hack, admittedly. Basically, instead of doing queries, define an associated array with all the data you want. In development, do a bunch of queries and put the data into the array, then process it. For optimization, move those queries to the server. Then you build the array in PL/php, serialize it, and return it as text. Now you call the PL/php function (SELECT get_FooPage_Info(page_identifier) that returns a text value, the serialized array. Now you have one database connection, it does ALL the work INSIDE the database process, and in PHP land, you just work off the array).
PostgreSQL is EXTREMELY powerful for areas where most people use
I remember attending a presentation from Sun personel demoing their portal mail system, how they prided themselves at not competing with the application providers who develop for Solaris. I remember Oracle was mentioned specifically by name. They provided a counter-example in Microsoft, who produces both SQL-Server and the operating system.
Oh well.
So confused -- Sun becomes more evil by supporting PostgreSQL ?
I've used both firebird and postgresql for the last 7 years or so. My only complaint with firebird was that the Java JDBC driver was so much slower than the postgresql driver (this was a couple of years ago). I've been using PostgreSQL exclusively for the past 3 years or so. It isn't as easy to admin as Firebird, but also offers more functionality. For example, PostgreSQL lets you define procedures in nearly any language (python, perl, java, c, c++, etc). PostgreSQL's PL/SQL stored procedure language is (I hear) close to Oracles. Not that Oracles stored proc language is the end-all be-all, but consistency is nice.
Why not? Seriously. The more languages, the better. That way, programmers can code in whatever they are most comfortable with.
You need to restart your computer. Hold down the Power button for several seconds or press the Restart button.
Why would you do that? Instead, create a new secondary group for each customer, and put only them and Apache into that group. chgrp all of their web files to that group. Give said files mode 640. Voila: Apache can read (but not write) all of their web data, but nothing in their home directory. No other customers will be in that group, so they don't get access.
The scenario you described would be trivially crackable, but who in their right mind would run a setup like that?
Dewey, what part of this looks like authorities should be involved?
That is one reason I like Windows hosting.
On IIS 6.0, you can run each application pool under the user's account. Then you setup NTFS permissions so that only the user's account has access. No other account can then get access, no matter what credentials are used (NETWORK SERVICE, SYSTEM, etc).
For connecting to the MSSQL database, Integrated Security is used, so that only the web application pool user (the user's account) has access to the database.
No passwords are ever in clear text, and user's files and databases are completely isolated.
Cue the W1nd0z posts, but with Windows 2003 and IIS 6.0, sites are now just as secure as a Linux and Apache setup. The NT4.0/IIS4.0 days are gone. Microsoft finally has a good server platform.
"HOWEVER, you need to learn to spend more time programming your database... However, you will spend LESS time programming yours sites/applications... It's a tradeoff"
That's fine if you just have a small site - one or a handful of servers.
The trouble is webapp CPU is much cheaper than DB server CPU. You can very easily keep adding webappservers and hook them to your DB server.
But AFAIK you can't add capacity as easily or cheaply to your DB server. Please do correct me if I'm wrong - give me links.
Of course Sun will be happy to provide the 64 CPU 128GB single system image server for your database (with attached storage etc), if you end up needing it - which you might if you start running a lot of PHP in your database.
So whilst I'm fine with doing stuff in the DB (esp to maintain data integrity), I don't think it's such a good idea to put so much processing in the DB, especially if the language doesn't perform that well (has PHP improved in speed significantly?).
Exactly, I am confortable with C#, I learnt java in school, I did some applications and web app in java, I did a training session ( don't know how it's called exactly in english ) of 4 weeks about java, and I hate this language with a passion, in fact as much as php or VB.
I dislike other languages too, I tried out perl, C / C++, vb and php ( obviously ), I appreciated that oracle was supporting now developpement of stored procedure in C#, I didn't really go far not much time, but in comparaison of PL/SQL, it was really interresting.
PostgreSQL is very extensible. There is currently no pl/csharp, but adding such a language is not an invasive change. There is a "CREATE LANGUAGE" command that lets you create the procedural language of your choice by supplying a C handler function.
Of cource, you need to be able to embed the interpreter. I think if you did, you'd get all the languages that are part of the CLR.
Social scientists are inspired by theories; scientists are humbled by facts.
So let me get this straight you hate java but you love C#. The two languages are damn near identical. What you are really trying to say is you seen some MS marketing material that said C# was really great so you believed it.
Got Code?
1/I prefer much more visual studio than eclipse. .net framework, I have to use lgpl or worse gpl library if I don't want to spend 80% of my time developping librairies.
2/I hate having an useless framework.
3/For me there is strickly no difference between C/C++ and java ( see point 2 ).
4/C# and java are at the same time close to each other and totally different.
5/Licence wise, to have the same feature than the
6/Javadoc is not really useable.
Actually, there is a project for this ... the PL/mono project.
It's a bit stalled at the moment, though. Maybe you could help out?
I'm glad to see this. It seems MySQL gets way too much attention these days in the open source community. Not that it is a junky database server or anything, but I've been using Postgres for 4 years now and the system simply amazes me with every new release. It's power, ease of setup & maintenence and incredible stability (as far as I see it) is simply unmatched in the "free" database world. I would take it any day over an MSSQL Server. It's nice to see a company like Sun decide to include it in it's system and support it.
The PL's (like PL/PGSQL) are not for optimizations. They are for building triggers, etc.
Ok, there are a few areas where PostgreSQL performance sucks. Try doing an outer join between a moderately sized table (few million rows) and an empty table (zero rows). The result will be a nested loop join which will eat up your processor time for an insanely large time. The answer here is either to add a row to the empty table and vacuum analyze or rewrite your query to avoid the join against the empty table since this is meaningless anyway (this bad plan is a corner case in an optimization to prevent bad plans when tables grow rapidly between vacuum analyze routines).
A second area is that it is possible to create overly complex systems that are impossible to properly optimize. I have run into these cases before. Views of aggregates of views of aggregates are a great example. One should generally try to keep everything as simple as possible.
However.... Your suggestion that web server processing power is always cheaper than DB processing power is interesting but there are times when processing on the db server is cheaper than processing on the web server. For example:
1) If you can efficiently do joins and save the round trips, do them on the db side.
2) Data integrity is best enforced on the DB side if you have more than one app inserting or updating data in a DB. This is in addition to front-side checking and ensures that a bug in one app doesn't screw up data for another.
3) Look into PgPool and Slony-I for load balancing solutions that should enable you to add processing power for select statements at least as easily as you add processing power for web servers. This is best done when you have an app with lots of reads and a few writes (most web apps are this way). If you need something more complex, these technologies can be used to create more complex replication and load balancing solutions including multimaster replication systems in any architecture you can imagine with whatever conflict resolution algorythms you wish to use.
In short, it is not always true that adding processing power on the web server end is the least costly way to approach this.
LedgerSMB: Open source Accounting/ERP
It wasn't relevant to my previous point but I run Solaris on one of my boxes and postgresql on another. This story is relevant to me. I was just venting about my coworkers who will tell me about shit that I know more about after they have read /.
As to your Sun moving further point, there are better indications in the news like Sun releasing Sun Studio 11 for Free. I haven't used it yet and I know it's not OSS yet but I bet it beats the pants off of eclipse + c++ plugin, kdevelop, or anjuta. This is a far better gift to open source than postgresql support, yet it probably won't receive a bit of news on /. I would submit it but that always seems useless. I don't think my article submissions ever have enough mistakes to qualify.
I always make one important suggestion in these areas:
Use the DB to present and maintain your data.
Put evertything that spans multiple transactions outside the db. For example, don't use your DB to send registration emails out to customers when they sign up on your web site! Use a message table, a client, and notify instead.
Everything else should be put where it is most maintainable. This means that stored procs that expose specific functions to many apps should be put in the db, and the rest shoudl be put in the app.
LedgerSMB: Open source Accounting/ERP
In fact, though, I prefer to keep database work as portable as possible. The exact thing that db suppliers don't want you to do...
Pining for the fjords
Hey, don't get me wrong here. If language support is coming for C#, great! Just the same, which is the original point I was hoping to make, with so many rich choices already available, I find it hard to believe that C# is the only thing holding someone back.
Long story short, PostgreSQL supports the entire gambit of languages (and idioms) already...if C# support is deal breaker, then I suspect something is really going on here.
suexec
each virtual host is assigned it's own user
for a while there it sounded like you knew what you were talking about
There are places where the networks are not touching,and there are places where they are-Boeing's Lori Gunter
> but with Windows 2003 and IIS 6.0, sites are now just as secure as a Linux and Apache setup.
that isn't saying much, privilege escalation problems appear regularly for both systems
root/administrator is a design fault, no amount of patching will ever get round that one
There are places where the networks are not touching,and there are places where they are-Boeing's Lori Gunter
major features of solaris 10 haven't been released yet, and that will make vendors think twice before certifiying products for it
The problem with that method you describe -- separate groups per user with www-data as a member of each one -- is that each user's scripts, running as the www-data user -- which can read files from any user's web space -- will still be able to read any other user's files.
In other words, it won't work.
Je fume. Tu fumes. Nous fûmes!
Yeah, but not having root / administrator at all would be worse.
Any "normal" user account which is allowed to do anything only root should be doing, is potentially as big a security risk as root. Even enabling root access in hardware isn't ideal, since it will create problems around servers in co-lo.
It's a double edged sword that cuts both ways.
Je fume. Tu fumes. Nous fûmes!
Now I've seen the documentation, that does actually look as though it would do the business.
..... looks like it might be really easy to mess up and end up with a system that either won't execute CGI scripts at all, or isn't as well-protected as you think it might be.
It does say something that it's turned off by default, though
Je fume. Tu fumes. Nous fûmes!
"major features of solaris 10 haven't been released yet, and that will make vendors think twice before certifiying products for it"
Major features that haven't been released yet: ZFS, Linux app support.
Major features that have: DTrace, Containers, network performance, small system performance, granular security, signed binaries, unified threading model, fault manager, sevice management facility, new GNOME-based desktop, orders of magnitude better support for x86 systems, support for x64...
1,700+ apps currently committed for support on Solaris 10, so apparently not every vendor is thinking twice, and deciding instead to go for it -- especially since Sun guarantees that their existing apps are compatible with Solaris 10.
So I'm not sure what you mean by "it's not done yet." It's not like there are loose wires dangling from the ceiling or something; it means there's a great operating system you can use today (use since last February, actually), knowing that it's going to get even better as time goes on, without breaking anything you're already doing.
I am using PostgreSQL 7.4, although one machine in production is still 7.3. We don't have the resources to test and deploy a 8.1 migration at this time, but we are keeping an eye on it.
The 8.x series shows tremendous progress, but the 7.4 branch is stable and not undergoing major changes. When 8.x stabilizes, we'll consider a modernization project.
Alex
Generally, keep the data put into schemas for the areas that they function in... instead of 1 DB/app, you have 1 DB, and 1 schema/app. Doesn't seem like much of a difference, but you don't have lots of connections to different DBs, and your app's data can talk to each other WHEN stuff needs to trigger around.
:)
Then, if you are getting hairy, create schemas for app-specific stuff. You can start by wrapping the main calls if needed (a SQL store-procedure that just calls the parent with SECURITY DEFINER) can help keep stuff clean. In this case, you may have app-specific optimizations, but they are all in one place, and talk to the "parent schema" which is still generic.
Latency = lost money... end of story...
Alex
you must be joking, there's still patches being released to fix major stability issues. And after ZFS and the Linux support proves stable for a few months then I'd say it's close to being "done". Anyone who adopts a version of an operating system that hasn't been released for more than a year is foolish.