Re: [GENERAL] Database in RAM

Поиск
Список
Период
Сортировка
От Bruce Momjian
Тема Re: [GENERAL] Database in RAM
Дата
Msg-id 200105032307.f43N71O07138@candle.pha.pa.us
обсуждение исходный текст
Список pgsql-docs
> >         http://candle.pha.pa.us/main/writings/pgsql/performance/index.html
> >
> > It talks about memory usage and performance.
>
>
> Bruce, this is a very helpful and informative article.  Thanks!


Thanks.


> BTW, this command had no effect on my redhat 6.2 system (1GB RAM):
>
> # whoami
> root
> # uname -a
> Linux bingo 2.2.12-20smp #1 SMP Mon Sep 27 10:34:45 EDT 1999 i686 unknown
> # cat /proc/sys/kernel/shmall
> 4194304
> # echo 134217728 > /proc/sys/kernel/shmall
> # cat /proc/sys/kernel/shmall
> 4194304
>
> It is possible I hosed something about my system as I recently began my
> first whack at upgrading a linux kernel.

The SGML docs say that should work.  I don't know because I don't use
Linux here.  The SGML is at:

    http://postgresql.readysetnet.com/devel-corner/docs/admin/kernel-resources.html#SYSVIPC

Let me CC docs on this.

---------------------------------------------------------------------------


Linux

     The default shared memory limit (both SHMMAX and SHMALL) is 32 MB in 2.2 kernels, but it can be changed in the
     proc file system (without reboot). For example, to allow 128 MB:

     $ echo 134217728 >/proc/sys/kernel/shmall
     $ echo 134217728 >/proc/sys/kernel/shmmax

     You could put these commands into a script run at boot-time.

     Alternatively, you can use sysctl, if available, to control these parameters. Look for a file called
     /etc/sysctl.conf and add lines like the following to it:

     kernel.shmall = 134217728
     kernel.shmmax = 134217728

     This file is usually processed at boot time, but sysctl can also be called explicitly later.

     Other parameters are sufficiently sized for any application. If you want to see for yourself look into
     /usr/src/linux/include/asm-xxx/shmparam.h and /usr/src/linux/include/linux/sem.h.


--
  Bruce Momjian                        |  http://candle.pha.pa.us
  pgman@candle.pha.pa.us               |  (610) 853-3000
  +  If your life is a hard drive,     |  830 Blythe Avenue
  +  Christ can be your backup.        |  Drexel Hill, Pennsylvania 19026

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

Предыдущее
От: Bruce Momjian
Дата:
Сообщение: Re: Update for SHMALL
Следующее
От: Bruce Momjian
Дата:
Сообщение: Re: Readysetnet FTP mirror broken