Changes
Jump to navigation
Jump to search
Haas PhD Server Configuration (view source)
Revision as of 17:49, 12 July 2011
, 17:49, 12 July 2011no edit summary
yum groupremove "Mail Server"
yum groupremove "News Server"
===Install and Configure PostgreSQL===
To install Postgres with the PLs (Procedural Languages) do:
yum install postgresql postgresql-server postgresql-pl postgresql-libs
Start the service with:
/sbin/chkconfig postgresql on
/sbin/service postgresql start
Add the following to ''/etc/sysconfig/iptables'' to allow access through the firewall:
-A RH-Firewall-1-INPUT -m state --state NEW -m tcp -p tcp -s 128.32.66.0/24 --dport 5432 -j ACCEPT
-A RH-Firewall-1-INPUT -m state --state NEW -m tcp -p tcp -s 128.32.67.0/24 --dport 5432 -j ACCEPT
-A RH-Firewall-1-INPUT -m state --state NEW -m tcp -p tcp -s 128.32.74.0/24 --dport 5432 -j ACCEPT
-A RH-Firewall-1-INPUT -m state --state NEW -m tcp -p tcp -s 10.136.0.0/23 --dport 5432 -j ACCEPT
Restart the IPtables so the changes take effect:
service iptables restart
Now create some users on the database server:
su postgres
createuser root
createuser ed_egan
exit
Check the version of Postgres and Perl installed:
psql -c "select version();" template1
PostgreSQL 8.1.23
perl -v
v5.8.8
Now add the perl PL to the standard template so that all new databases will be perl enabled:
createlang plperl template1
Check the specs on the machine for the configuration:
cat /proc/meminfo
MemTotal: 8181356 kB
cat /proc/cpuinfo
2 x Quad core CPUs
cache size: 2048 KB
model name: Intel(R) Xeon(TM) CPU 2.80GHz
Review the performance tuning section on the [[Working with PostgreSQL]] page and make the following changes to ''/var/lib/pgsql/data/postgresql.conf'':
shared_buffers = 131072
#1073741824 => 131072 * 8 * 1024
work_mem = 262144
#1024 * 256 => 262144
maintenance_work_mem = 262144
#786432 => 6 * 1073741824 => 6 * 131072 * 8 * 1024
effective_cache_size = 786432
And restart Postgres:
/sbin/service postgresql restart
====Upgrade Python?====