public inbox for gentoo-user@lists.gentoo.org
 help / color / mirror / Atom feed
* [gentoo-user] switching production server from myswl to postgresql
@ 2011-12-21 20:11 Tanstaafl
  2011-12-21 20:18 ` Michael Mol
  2011-12-22 16:41 ` Michael Orlitzky
  0 siblings, 2 replies; 3+ messages in thread
From: Tanstaafl @ 2011-12-21 20:11 UTC (permalink / raw
  To: gentoo-user

Hi all,

Ok, this has been on my ToDo list for a while, and I'm thinking of 
tacking this over the holidays, since the office will be much slower 
than usual.

The only databases I have in use are for my mail server, which means 
postfix, courier-imap (soon to be dovecot 2.1 once it is released) and 
postfixadmin for maintaining the database.

First question - I can run both mysql and postgresql at the same time, 
right? I haven't found anything saying I can't, and mysql doesn't seem 
to 'block' installing postgresql, so I'm guessing I can.

Second question - has anyone ever converted an existing production mysql 
database to postgresql? If you have ever done this specifically for 
postfixadmin, I'd love to chat for a few minutes, but pointers to 
recent, accurate docs - even generically (not specifically for 
postfixadmin) for doing this would be appreciated.

Thanks,

Charles



^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [gentoo-user] switching production server from myswl to postgresql
  2011-12-21 20:11 [gentoo-user] switching production server from myswl to postgresql Tanstaafl
@ 2011-12-21 20:18 ` Michael Mol
  2011-12-22 16:41 ` Michael Orlitzky
  1 sibling, 0 replies; 3+ messages in thread
From: Michael Mol @ 2011-12-21 20:18 UTC (permalink / raw
  To: gentoo-user

Tanstaafl wrote:
> Hi all,
>
> Ok, this has been on my ToDo list for a while, and I'm thinking of
> tacking this over the holidays, since the office will be much slower
> than usual.
>
> The only databases I have in use are for my mail server, which means
> postfix, courier-imap (soon to be dovecot 2.1 once it is released) and
> postfixadmin for maintaining the database.
>
> First question - I can run both mysql and postgresql at the same time,
> right? I haven't found anything saying I can't, and mysql doesn't seem
> to 'block' installing postgresql, so I'm guessing I can.

Sure; they're different SQL engines. SQL isn't a standardized service 
that you'd expect to find at a particular location or port.

They are, however, not entirely compatible. The SQL spec is 
unfortunately vague, and even where it's relatively clear, popular 
engines have idiosyncrasies that can result in application written for 
one not quite working with another.

>
> Second question - has anyone ever converted an existing production mysql
> database to postgresql? If you have ever done this specifically for
> postfixadmin, I'd love to chat for a few minutes, but pointers to
> recent, accurate docs - even generically (not specifically for
> postfixadmin) for doing this would be appreciated.

This is going to almost entirely depend on the application you want to 
switch from being backed by mysql to postgresql. I'm not even sure 
'mysqldump' has an export mode that can be easily massaged to be an 
import mode for postgresql.

That said, the #postgresql IRC channel on FreeNode is one of the nicest 
IRC channel's I've interacted with.



^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [gentoo-user] switching production server from myswl to postgresql
  2011-12-21 20:11 [gentoo-user] switching production server from myswl to postgresql Tanstaafl
  2011-12-21 20:18 ` Michael Mol
@ 2011-12-22 16:41 ` Michael Orlitzky
  1 sibling, 0 replies; 3+ messages in thread
From: Michael Orlitzky @ 2011-12-22 16:41 UTC (permalink / raw
  To: gentoo-user

On 12/21/11 15:11, Tanstaafl wrote:
> Hi all,
> 
> Ok, this has been on my ToDo list for a while, and I'm thinking of
> tacking this over the holidays, since the office will be much slower
> than usual.
> 
> The only databases I have in use are for my mail server, which means
> postfix, courier-imap (soon to be dovecot 2.1 once it is released) and
> postfixadmin for maintaining the database.
> 
> First question - I can run both mysql and postgresql at the same time,
> right? I haven't found anything saying I can't, and mysql doesn't seem
> to 'block' installing postgresql, so I'm guessing I can.
> 
> Second question - has anyone ever converted an existing production mysql
> database to postgresql? If you have ever done this specifically for
> postfixadmin, I'd love to chat for a few minutes, but pointers to
> recent, accurate docs - even generically (not specifically for
> postfixadmin) for doing this would be appreciated.

Postfixadmin supports postgres, so you start by installing postgres
alongside your mysql installation, Next, run the postfixadmin scripts to
create the (empty) tables in your postgres database. All of the
postgres-specific stuff happens here, and postfixadmin does it for you.

After that, you just dump the mysql data, and load them into postgres.
Check out `man mysqldump` for some important options. This is the one I
remember off the top of my head:

  --compatible=name

    Produce output that is more compatible with other database systems
    or with older MySQL servers. The value of name can be ansi,
    mysql323, mysql40, postgresql...



^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2011-12-22 16:42 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-12-21 20:11 [gentoo-user] switching production server from myswl to postgresql Tanstaafl
2011-12-21 20:18 ` Michael Mol
2011-12-22 16:41 ` Michael Orlitzky

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox