Показаны сообщения с ярлыком RedHat. Показать все сообщения
Показаны сообщения с ярлыком RedHat. Показать все сообщения

2014/12/03

Postgresql init file for RHEL cluster with multi services on one node

ОКРУЖЕНИЕ: Redhat 6.4; Postgresql 9.2, 9.3
ЦЕЛЬ: Запускать несколько Postgresql ДБ сервисов на одной ноде Redhat кластера И/ИЛИ  Запускать Postgresql датабаза сервис на каждой ноде Redhat кластера 
ПРОБЛЕМА: Наличие только одного Postgresql init файла. Несовместимая конфигурация по умолчанию Postgresql.
РЕШЕНИЕ:
Создать индивидульную директорию для каждого Postgresql сервиса.
/var/lib/pgsql/9.2/ --> /var/lib/pgsql/mydb01/9.2/ и  /var/lib/pgsql/mydb02/9.2/
Создать индивидульный init скрипт для каждого Postgresql сервиса.
/etc/init.d/postgresql  -->  /etc/init.d/postgresql-mydb01 и /etc/init.d/postgresql-mydb02
init скрипт можно скачать отсюда. По примеру заменяем MM_CHANGE_TO_CURRENT_DB_DIR на mydb01
ССЫЛКИ: Postgresql init file

2013/11/15

Ruby installation issue - Protected multilib versions

CURRENT CONFIGURATION:
RHEL 6.4 x64 on Amazon AWS VPC

OBJECTIVE:
Install Ruby 2.0.0

ISSUE:
Error running 'requirements_centos_libs_install gcc-c++ readline-devel zlib-devel libyaml-devel libffi-devel openssl-devel autoconf automake libtool bison',
please read /usr/local/rvm/log/1384535887_ruby-2.0.0-p247/package_install_gcc-c++_readline-devel_zlib-devel_libyaml-devel_libffi-devel_openssl-devel_autoconf_automake_libtool_bison.log
Requirements installation failed with status: 1.
Log file:
Error: Multilib version problems found. This often means that the root
cause is something else and multilib version checking is just
pointing out that there is a problem. Eg.:
1. You have an upgrade for libyaml which is missing some
dependency that another package requires. Yum is trying to
solve this by installing an older version of libyaml of the
different architecture. If you exclude the bad architecture
yum will tell you what the root cause is (which package
requires what). You can try redoing the upgrade with
--exclude libyaml.otherarch ... this should give you an error
message showing the root cause of the problem.
2. You have multiple architectures of libyaml installed, but
yum can only see an upgrade for one of those arcitectures.
If you don't want/need both architectures anymore then you
can remove the one with the missing update and everything
will work.
3. You have duplicate versions of libyaml installed already.
You can use "yum check" to get yum show these errors.
...you can also use --setopt=protected_multilib=false to remove
this checking, however this is almost never the correct thing to
do as something else is very likely to go wrong (often causing
much more problems).
Protected multilib versions: libyaml-0.1.3-1.el6.i686 != libyaml-0.1.3-1.1.el6.x86_64
You could try using --skip-broken to work around the problem
You could try running: rpm -Va --nofiles --nodigest

SOLUTION:
Try installation command first time.
curl -L https://get.rvm.io | bash -s stable --ruby=2.0.0
Receive the error message.
Continue installation with commands:
yum downgrade -y libyaml
yum install -y --setopt=protected_multilib=false libyaml-devel
curl -L https://get.rvm.io | bash -s stable --ruby=2.0.0

LINKS:
Ruby Version Manager (RVM)

2013/07/07

Копирование Fedora, CentOS, RedHat на VMware

ОКРУЖЕНИЕ: VMware ESXi 5.1, CentOS 6, RedHat 6, Fedora 19
ЦЕЛЬ: Подготовить виртуальную машину для копирования или клонирования с VMware ESXi на VMware ESXi .
ПРОБЛЕМА: Не работает сеть после копирования или клонирования
РЕШЕНИЕ:
# Выполняется от пользователя root
# Скопировать конфигурционные файлы в домашнюю директорию
yes | cp -f /etc/udev/rules.d/70-persistent-net.rules ~/.
yes | cp -f /etc/sysconfig/network-scripts/ifcfg-eth0 ~/.
# Изменить конфигурционные файлы
sed -i 's/^SUBSYSTEM/#SUBSYSTEM/g' /etc/udev/rules.d/70-persistent-net.rules
sed -i 's/^UUID/#UUID/g' /etc/sysconfig/network-scripts/ifcfg-eth0
sed -i 's/^MACADDR/#MACADDR/g' /etc/sysconfig/network-scripts/ifcfg-eth0
sed -i 's/^HWADDR/#HWADDR/g' /etc/sysconfig/network-scripts/ifcfg-eth0
# Почистить перед копированием
rm -rf $(find /tmp -type f)
rm -rf $(find /var/log -type f)
rm -rf $(find /home -type f -name ".bash_history")
rm -fr ~/.bash_history
# Выключить виртуальную машину
poweroff
Скоприровать или экспортировать виртуальную машину.
Восстановить конфигурционные файлы на мастере (если нужно):
yes | cp -f ~/70-persistent-net.rules /etc/udev/rules.d/
yes | cp -f ~/ifcfg-eth0 /etc/sysconfig/network-scripts/
СКАЧАТЬ: