Re: hundreds of schema vs hundreds of databases

Поиск
Список
Период
Сортировка
От Albe Laurenz
Тема Re: hundreds of schema vs hundreds of databases
Дата
Msg-id AFCCBB403D7E7A4581E48F20AF3E5DB2030576BB@EXADV1.host.magwien.gv.at
обсуждение исходный текст
Ответ на hundreds of schema vs hundreds of databases  (olivier <om@oliviermigeon.com>)
Ответы Re: hundreds of schema vs hundreds of databases  ("Merlin Moncure" <mmoncure@gmail.com>)
Re: hundreds of schema vs hundreds of databases  (Ron Johnson <ron.l.johnson@cox.net>)
Re: hundreds of schema vs hundreds of databases  (Guy Rouillier <guyr-ml1@burntmail.com>)
Список pgsql-general
> I have an application with some hundreds users, each one
> having the same
> data definitions, and each one storing up to 2 GB of data.
> A user have just access to his own data. His data will have its own
> tablespace.
>
> Therefore, it seems to me I have a choice between "one database per
> user" and "one schema per user in the same database".
>
> What is the best practice here ? Which solution will be the
> easiest to manage ?

Advantages of many databases:
- Each database is smaller.
- No danger of one user accessing another user's data (because of
  misconfigured permissions and similar).
- Guaranteed independence of each user's data.
- More scalable: If you decide that one machine or one cluster
  is not enough to handle the load, you can easily transfer some
  of the databases somewhere else.

Advantages of one database with many schemata:
- Fewer databases to administrate.

I'd probably go for many databases.

Yours,
Laurenz Albe

В списке pgsql-general по дате отправления:

Предыдущее
От: Jim Nasby
Дата:
Сообщение: Re: [HACKERS] Role members
Следующее
От: "Albe Laurenz"
Дата:
Сообщение: Re: Will a DELETE violate an FK?