Added support for dynamic memory calculations and updating kernel settings.

postgresql_shared_buffers = 40% of system memory
postgresql_effective_cache_size = 75% of system memory

shmall = number of pages available on machine
shmmax = number of bytes available on machine
file-max = 100000 allowed open files