1. ubuntu 16.04.4
2. 1С берем на сайте 8.3.12.1529 при наличии договора ИТС
3. PostgreSQL версия 9.6.7.1-1C дистрибутив, дополнительные модули при наличии договора ИТС
4. Фонты берем etersoft по кнопке получить (после бесплатной регистрации wine.local для ubuntu 16.04 64 бит)
5. Драйверы hasp берем etersoft
1. Устанавливаем ubuntu 16.04.3 desktop без swap файла, т.е. размечаем вручную весь диск ext4 root.
Настройки виртуальной машины - RAM (32GB)
Сеть - сетевой мост.
Проще всего пробросить в виртуальную машину лицензии 1С:Предприятия 8 посредством локального hasp.
Настройки ubuntu пользователь (привязка в скриптах) user пароль 12345, имя компьютера любое, позже мы его сменим скриптом, как и ip адрес.
После установки, Ctrl +Alt + T (окно терминала)
$ sudo apt update -y
$ sudo apt upgrade -y
$ sudo apt install mc ssh samba -y
Возможно sudo apt upgrade -y не пройдет из за блокировки, тогда sudo reboot и повторите с начала.
$ lsusb
Bus 001 Device 002: ID 80ee:0021 VirtualBox USB Tablet
Bus 001 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Пробросить hasp средствами VirtualBox
$ lsusb
Bus 001 Device 004: ID 0529:0001 Aladdin Knowledge Systems HASP copy protection dongle
Bus 001 Device 003: ID 0529:0001 Aladdin Knowledge Systems HASP copy protection dongle
Bus 001 Device 002: ID 80ee:0021 VirtualBox USB Tablet
Bus 001 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
2. Настройка сети скриптом.
Узнаем ip и имя адаптера
$ ip a
2: enp0s3: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UP group default qlen 1000
link/ether 08:00:27:53:b6:81 brd ff:ff:ff:ff:ff:ff
inet 192.168.0.169/24 brd 192.168.0.255 scope global enp0s3
Откроем firefox (в ubuntu), откроем эту страничку и скопируем в буфер скрипт настройки сети:
$ nano network.sh
Скопируем из буфера следующий скрипт, в котором Вам нужно исправить ip, адрес шлюза и имя адаптера в соответствии со своей сетью:
#!/bin/bash
# настройка ip и hostname
#----------------------------------------------------------------------
_hostname="kamin"
# real computer
#_iface="enp0s31f6"
# kvm iface
#_iface="ens3"
# virtualbox iface
_iface="eno1"
#_iface="enp1s0"
_address="192.168.0.174"
#_address="192.168.1.90"
_gateway="192.168.0.1"
#_gateway="192.168.1.1"
_netmask="255.255.255.0"
_nameserver="8.8.8.8"
#----------------------------------------------------------------------
#add a swap file to an Ubuntu 16.04
#sudo fallocate -l 1G /swapfile
#sudo chmod 600 /swapfile
#sudo mkswap /swapfile
#sudo swapon /swapfile
#sudo cp /etc/fstab /etc/fstab.bak
#sudo echo '/swapfile none swap sw 0 0' | sudo tee -a /etc/fstab
# отключим сетевой менеджер
#sudo systemctl stop NetworkManager.service
#sudo systemctl disable NetworkManager.service
# настроим статический ip
sudo cat > /tmp/interfaces <<EOF
# This file describes the network interfaces available on your system
# and how to activate them. For more information, see interfaces(5).
source /etc/network/interfaces.d/*
# The loopback network interface
auto lo
iface lo inet loopback
# The primary network interface
#auto $_iface
#iface $_iface inet dhcp
iface $_iface inet static
address $_address
netmask $_netmask
gateway $_gateway
dns-nameservers $_nameserver
auto $_iface
EOF
sudo cp /tmp/interfaces /etc/network
#sudo rm /etc/resolv.conf
#sudo /bin/su -c "echo 'nameserver $_nameserver' > /etc/resolv.conf"
# изменим hostname и ip
sudo cat > /tmp/hosts <<EOF
127.0.0.1 localhost
$_address $_hostname
EOF
sudo cp /tmp/hosts /etc
# изменим hostname
sudo hostname $_hostname
sudo /bin/su -c "echo $_hostname > /etc/hostname"
# отключим ip6
sudo /bin/su -c "echo 'net.ipv6.conf.all.disable_ipv6 = 1' >> /etc/sysctl.conf"
sudo /bin/su -c "echo 'net.ipv6.conf.default.disable_ipv6 = 1' >> /etc/sysctl.conf"
sudo /bin/su -c "echo 'net.ipv6.conf.lo.disable_ipv6 = 1' >> /etc/sysctl.conf"
#sudo /bin/su -c "echo 'net.ipv4.ip_forward = 1' >> /etc/sysctl.conf"
sudo /bin/su -c "echo 'vm.swappiness=0' >> /etc/sysctl.conf"
#sudo /bin/su -c "echo 'vm.vfs_cache_pressure = 50' >> /etc/sysctl.conf"
sudo sysctl -p
# перезагрузим сеть
sudo systemctl restart networking.service
#sudo systemctl start networking.service
#sudo systemctl enable networking.service
# Настройка sudo journalctl -b sudo journalctl -b -1 sudo journalctl --list-boots
sudo sed -i 's/#Storage=auto/Storage=persistent/' /etc/systemd/journald.conf
# Отключение уведомлений службы Apport (/var/crash)
sudo sed -i 's/enabled=1/enabled=0/' /etc/default/apport
# Настройка ftp пользователь: test пароль: test
sudo apt install pure-ftpd -y
sudo groupadd ftpgroup
sudo usermod -aG ftpgroup user
sudo ln -s /etc/pure-ftpd/conf/PureDB /etc/pure-ftpd/auth/50pure
sudo mkdir /home/user/test
sudo chown -R user:ftpgroup /home/user/test
#sudo pure-pw useradd test -u user -d /home/user/test
# Заведем пользователя ftp test с паролем test
sudo echo -e "test\ntest\n" | sudo pure-pw useradd test -u user -d /home/user/test
sudo pure-pw mkdb
sudo service pure-ftpd restart
# ubuntu
# Отключим службу ondemand
# (для разгона cpu)
# cat /proc/cpuinfo | grep MHz
# systemctl status ondemand
sudo systemctl stop ondemand
sudo systemctl disable ondemand
# shutdown -r now
Сохраним файл network.sh
------------------------------------------
Сделаем исполняем
$ chmod +x network.sh
Выполним:
$ ./network.sh
------------------------------------------
или так:
$ sudo sh network.sh
------------------------------------------
Перезагрузимся
$ sudo reboot
$ sudo apt install ntp
3. Установка СУБД PostgreSQL версия 9.6.7-1.1С и 1c скриптом:
После перезагрузки по сети можно подключиться любым ftp клиентом к ftp серверу на нашей виртуальной машине (по ip или или имени ud1604) пользователь test пароль test и загрузить файлы установки:
Файлы необходимые для установки (предварительно нужно скачать по указанным в начале статьи ссылкам):
postgresql_9.6.7_1.1C_amd64_addon_deb.tar.bz2
postgresql_9.6.7_1.1C_amd64_deb.tar.bz2
deb64.tar.gz #переименуем так 64 битный сервер для deb
client.deb64.tar.gz #переименуем так 64 битный клиенте для deb
fonts-ttf-ms_1.0-eter4ubuntu_all.deb
haspd_7.60-eter1debian_amd64.deb
haspd-modules_7.60-eter1debian_amd64.deb
Исправим bug
Several regex warnings when installing latest postgres update
sudo nano /usr/sbin/pam_getenv
строка 78 заменить
$val =~ s/(?<!\\)\${([^}]+)}/$ENV{$1}||""/eg;
на
$val =~ s/(?<!\\)\$\{([^}]+)\}/$ENV{$1}||""/eg;
Откроем firefox (в ubuntu), откроем эту страничку и скопируем в буфер скрипт установки СУБД PostgreSQL версия 9.6.5-4.1С и 1c:
$ nano install_post967_1.sh
Скопируем из буфера следующий скрипт:
#!/bin/sh
sudo apt-get install libicu55 postgresql-common -y
sudo cp /usr/share/hunspell/ru_RU.aff /usr/share/hunspell/ru_RU.aff.copy
sudo sed -e '1s/^\xef\xbb\xbf//' /usr/share/hunspell/ru_RU.aff
mkdir -p /tmp/post
cp /home/user/test/postgresql_9.6.7_1.1C_amd64_deb.tar.bz2 /tmp/post/
cp /home/user/test/postgresql_9.6.7_1.1C_amd64_addon_deb.tar.bz2 /tmp/post/
cd /tmp/post
tar -xvf postgresql_9.6.7_1.1C_amd64_deb.tar.bz2
cd postgresql-9.6.7-1.1C_amd64_deb
sudo dpkg -i *.deb
cd /tmp/post/
tar -xvf postgresql_9.6.7_1.1C_amd64_addon_deb.tar.bz2
cd postgresql-9.6.7-1.1C_amd64_addon_deb
sudo dpkg -i *.deb
sudo -u postgres psql -U postgres -c "alter user postgres with password 'pass';"
sudo cp /etc/postgresql/9.6/main/postgresql.conf /etc/postgresql/9.6/main/postgresql.conf.bak
# установка 1с
mkdir -p /tmp/1ctmp
cd /tmp/1ctmp
sudo apt install imagemagick -y
#sudo apt install -y unixodbc libgsf-1-114 libglib2.0
sudo apt install libfreetype6 libgsf-1-common unixodbc glib2.0
#ubuntu
#sudo apt install ttf-mscorefonts-installer -y
#debian
#wget http://ftp.ru.debian.org/debian/pool/contrib/m/msttcorefonts/ttf-mscorefonts-installer_3.6_all.deb
sudo apt install -y xfonts-utils cabextract
#sudo dpkg -i ttf-mscorefonts-installer_3.6_all.deb
# фонты от Etersoft
#ubuntu
cp /home/user/test/fonts-ttf-ms_1.0-eter4ubuntu_all.deb /tmp/1ctmp
sudo dpkg -i fonts-ttf-ms_1.0-eter4ubuntu_all.deb
sudo apt -f -y install
#debian
#cp /home/user/Загрузки/fonts-ttf-ms_1.0-eter4debian_all.deb /tmp/1ctmp
#sudo dpkg -i fonts-ttf-ms_1.0-eter4debian_all.deb
cp /home/user/test/deb64.tar.gz /tmp/1ctmp
#cp /home/user/test/client.deb64.tar.gz /tmp/1ctmp
tar xvzf deb64.tar.gz
tar xvzf client.deb64.tar.gz
sudo dpkg -i 1c*.deb
sudo apt -f -y install
sudo chown -R usr1cv8:grp1cv8 /opt/1C
sudo echo -e "pass\npass\n" | sudo passwd usr1cv8
sudo service srv1cv83 start
#sudo service srv1cv83 status
sudo apt install -y libc6-i386
mkdir /tmp/hasp
cd /tmp/hasp
#cp /home/user/test/haspd_7.60-eter1debian_amd64.deb /tmp/hasp
#cp /home/user/test/haspd-modules_7.60-eter1debian_amd64.deb /tmp/hasp
cp /home/user/test/haspd_7.60-eter1ubuntu_amd64.deb /tmp/hasp
cp /home/user/test/haspd-modules_7.60-eter1ubuntu_amd64.deb /tmp/hasp
#wget http://download.etersoft.ru/pub/Etersoft/HASP/last/x86_64/Debian/8/haspd_7.60-eter1debian_amd64.deb
#wget http://download.etersoft.ru/pub/Etersoft/HASP/last/x86_64/Ubuntu/16.04/haspd_7.40-eter10ubuntu_amd64.deb
#wget http://download.etersoft.ru/pub/Etersoft/HASP/last/x86_64/Debian/8/haspd-modules_7.60-eter1debian_amd64.deb
#wget http://download.etersoft.ru/pub/Etersoft/HASP/last/x86_64/Ubuntu/16.04/haspd-modules_7.40-eter10ubuntu_amd64.deb
sudo dpkg -i *.deb
sudo apt-get install -f -y
sudo service haspd start
#sudo service haspd status
#sudo shutdown -r now
Сохраним файл install_post967_1.sh
Сделаем исполняем
$ chmod +x install_post967_1.sh
Выполним:
$ ./install_post967_1.sh
или
$ sudo sh install_post967_1.sh
$ dpkg -l | grep 9.6.7-1.1C | awk -F' ' '{print $2}' | sudo xargs apt-mark hold
Не встал скриптом imagemagick?
Без строчки ниже будет ругаться при входе в 1с
$ sudo apt-get install imagemagick -y
$ sudo reboot
$ sudo systemctl status postgresql.service
● postgresql.service - PostgreSQL RDBMS
Loaded: loaded (/lib/systemd/system/postgresql.service; enabled; vendor preset: enabled)
Active: active (exited) since Ср 2018-03-14 16:45:43 MSK; 7min ago
Process: 1430 ExecStart=/bin/true (code=exited, status=0/SUCCESS)
Main PID: 1430 (code=exited, status=0/SUCCESS)
Tasks: 0
Memory: 0B
CPU: 0
CGroup: /system.slice/postgresql.service
мар 14 16:45:43 kamin systemd[1]: Starting PostgreSQL RDBMS...
мар 14 16:45:43 kamin systemd[1]: Started PostgreSQL RDBMS.
user@kamin:~$
$ sudo ss -tunpl | grep 5432
tcp LISTEN 0 128 *:5432 *:* users:(("postgres",pid=1269,fd=6))
$ sudo systemctl start postgresql.service
$ sudo systemctl restart postgresql.service
$ sudo systemctl stop postgresql.service
$ sudo systemctl status srv1cv83.service
● srv1cv83.service - LSB: Starts and stops the 1C:Enterprise daemons
Loaded: loaded (/etc/init.d/srv1cv83; bad; vendor preset: enabled)
Active: active (exited) since Ср 2018-03-14 16:45:46 MSK; 11min ago
Docs: man:systemd-sysv-generator(8)
Process: 1215 ExecStart=/etc/init.d/srv1cv83 start (code=exited, status=0/SUCCESS)
Tasks: 0
Memory: 0B
CPU: 0
мар 14 16:45:41 kamin systemd[1]: Starting LSB: Starts and stops the 1C:Enterprise daemons...
мар 14 16:45:41 kamin su[1267]: Successful su for usr1cv8 by root
мар 14 16:45:41 kamin su[1267]: + ??? root:usr1cv8
мар 14 16:45:41 kamin su[1267]: pam_unix(su:session): session opened for user usr1cv8 by (uid=0)
мар 14 16:45:46 kamin srv1cv83[1215]: Starting 1C:Enterprise 8.3 server: OK
мар 14 16:45:46 kamin systemd[1]: Started LSB: Starts and stops the 1C:Enterprise daemons.
$ sudo ss -tlnp | grep :15
LISTEN 0 128 *:1560 *:* users:(("rphost",pid=1402,fd=23))
LISTEN 0 128 *:1540 *:* users:(("rphost",pid=1402,fd=15),("ragent",pid=1305,fd=15))
LISTEN 0 128 *:1541 *:* users:(("rmngr",pid=1325,fd=12))
LISTEN 0 128 :::1560 :::* users:(("rphost",pid=1402,fd=22))
LISTEN 0 128 :::1540 :::* users:(("rphost",pid=1402,fd=14),("ragent",pid=1305,fd=14))
LISTEN 0 128 :::1541 :::* users:(("rmngr",pid=1325,fd=11))
Зашарить папку по сети
$ sudo chmod -R 777 /home/share/
$ sudo chown -R root:sambashare /home/share/
$ sudo cp -b -f /etc/samba/smb.conf /etc/samba/smb.conf.bak
$ sudo nano /etc/samba/smb.conf
Добавить в конец
[files]
path = /home/share/
comment = No comment
read only = no
available = yes
browseable = yes
writable = yes
guest ok = yes
public = yes
printable = no
locking = no
strict locking = no
Сохранить
Перезагрузить службу
$ sudo service smbd restart
COPY logcfg.xml /home/usr1cv8/.1cv8/1C/1cv8/conf/ |
$ sudo mkdir -p /home/usr1cv8/.1cv8/1C/1cv8/conf/ S sudo nano /home/usr1cv8/.1cv8/1C/1cv8/conf/logcfg.xml <?xml version="1.0" encoding="UTF-8"?> <config xmlns="http://v8.1c.ru/v8/tech-log"> <log location="/home/usr1cv8/log" history="96"> <event> <eq property="name" value="DBPOSTGRS"/> </event> <event> <eq property="name" value="SDBL"/> </event> <event> <eq property="name" value="EXCP"/> </event> <property name="all"/> </log> </config> Сохранить. |
$ sudo mkdir -p /home/usr1cv8/dumps/ |
$ sudo mkdir -p /home/usr1cv8/log/ |
$ sudo chown -R usr1cv8:grp1cv8 /home/usr1cv8/ |
$ echo 'usr1cv8 soft core unlimited' | sudo tee -a /etc/security/limits.conf |
$ echo 'usr1cv8 hard core unlimited' | sudo tee -a /etc/security/limits.conf |
$ echo 'kernel.core_pattern=/home/usr1cv8/dumps/core.%e.%p ' | sudo tee -a /etc/sysctl.conf |
$ sudo sysctl -p |
Для автоматического создания бекапов:
Зададим папку, если не делали раньше,
$ sudo cp /etc/fstab /etc/fstab.bak
Добавить/исправить
UUID=17e12f79-7076-47bf-8c0f-0e7bd4d588d8 /home/user/test/backup ext4 defaults 0 2
Сохранить.
Папка с бэкапами будет доступна по ftp (test test)
Подготовка:
$ sudo mkdir /home/user/test/backup
#$ sudo chmod -R 777 /home/user/test/backup
$ sudo chown -R user:user /home/user/test/backup
$ sudo poweroff
Здесь полезно сделать "консервы".
До подключения базы 1с легко менять ip адрес и название сервера.
Сделаем выгрузку post967.ova
Перезагрузимся, если не делали выгрузку или просто загрузим виртуалку.
Можно подключать базу 1С postgres пароль pass
(вместо astra имя своего сервера)
Для 32 Gb RAM иначе не запустится!!!
sudo cp /etc/postgresql/9.6/main/postgresql.conf /etc/postgresql/9.6/main/postgresql.conf.bak
sudo nano /etc/postgresql/9.6/main/postgresql.conf
Заменить:
#------------------------------------------------------------------------------
data_directory = '/var/lib/postgresql/9.6/main' # use data in another directory
hba_file = '/etc/postgresql/9.6/main/pg_hba.conf' # host-based authentication file
ident_file = '/etc/postgresql/9.6/main/pg_ident.conf' # ident configuration file
external_pid_file = '/var/run/postgresql/9.6-main.pid' # write an extra PID file
listen_addresses = '*' # what IP address(es) to listen on;
port = 5432 # (change requires restart)
max_connections = 1000 # (change requires restart)
unix_socket_directories = '/var/run/postgresql' # comma-separated list of directories
ssl = false # (change requires restart)
ssl_cert_file = '/etc/ssl/certs/ssl-cert-snakeoil.pem' # (change requires restart)
ssl_key_file = '/etc/ssl/private/ssl-cert-snakeoil.key' # (change requires restart)
#------------------------------------------------------------------------------
# RESOURCE USAGE (except WAL)
#------------------------------------------------------------------------------
#shared_buffers = 128MB # min 128kB
shared_buffers = 12288MB
#temp_buffers = 8MB # min 800kB
temp_buffers = 32MB
#work_mem = 4MB # min 64kB
work_mem = 32MB
#maintenance_work_mem = 64MB # min 1MB
maintenance_work_mem = 512MB
dynamic_shared_memory_type = posix # the default is the first option
#max_files_per_process = 1000 # min 25
max_files_per_process = 24576
#shared_preload_libraries = 'online_analyze, plantuner' # (change requires restart)
shared_preload_libraries = 'online_analyze, plantuner, auto_explain'
# - Background Writer -
#bgwriter_delay = 200ms # 10-10000ms between rounds
bgwriter_delay = 10ms
#bgwriter_delay = 20ms
#bgwriter_lru_maxpages = 100 # 0-1000 max buffers written/round
bgwriter_lru_maxpages = 800
#bgwriter_lru_multiplier = 2.0 # 0-10.0 multiplier on buffers scanned/round
bgwriter_lru_multiplier = 8.0
# - Asynchronous Behavior -
#effective_io_concurrency = 1 # 1-1000; 0 disables prefetching
effective_io_concurrency = 2
#------------------------------------------------------------------------------
# WRITE AHEAD LOG
#------------------------------------------------------------------------------
#wal_level = minimal # minimal, replica, or logical
wal_level = hot_standby
fsync = on # flush data to disk for crash safety
#synchronous_commit = on # synchronization level;
synchronous_commit = off
#commit_delay = 0 # range 0-100000, in microseconds
commit_delay = 1000
#checkpoint_completion_target = 0.5 # checkpoint target duration, 0.0 - 1.0
checkpoint_completion_target = 0.9
#------------------------------------------------------------------------------
# REPLICATION
#------------------------------------------------------------------------------
#max_wal_senders = 0 # max number of walsender processes
max_wal_senders = 4
#wal_keep_segments = 0 # in logfile segments, 16MB each; 0 disables
wal_keep_segments = 1024
#------------------------------------------------------------------------------
# QUERY TUNING
#------------------------------------------------------------------------------
# - Planner Cost Constants -
#random_page_cost = 4.0 # same scale as above
random_page_cost = 2.0
#random_page_cost = 1.5
#cpu_operator_cost = 0.0025 # same scale as above
cpu_operator_cost = 0.0005
#effective_cache_size = 4GB
effective_cache_size = 12288MB
from_collapse_limit = 20
join_collapse_limit = 20 # 1 disables collapsing of explicit
# JOIN clauses
#------------------------------------------------------------------------------
# ERROR REPORTING AND LOGGING
#------------------------------------------------------------------------------
log_destination = 'stderr' # Valid values are combinations of
logging_collector = on # Enable capturing of stderr and csvlog
log_directory = 'pg_log' # directory where log files are written,
log_filename = 'postgresql-%a.log' # log file name pattern,
#log_filename = 'postgresql-%Y-%m-%d.log'
log_truncate_on_rotation = on # If on, an existing log file with the
log_rotation_age = 1d # Automatic rotation of logfiles will
log_rotation_size = 0 # Automatic rotation of logfiles will
#log_min_duration_statement = -1 # -1 is disabled, 0 logs all statements
log_min_duration_statement = 0
# - What to Log -
#log_checkpoints = off
log_checkpoints = on
#log_connections = off
log_connections = on
#log_disconnections = off
log_disconnections = on
#log_line_prefix = '%t [%p-%l] %q%u@%d ' # special values:
log_line_prefix = '%t [%p]: [%l-1] user=%u,db=%d,app=%a,client=%h '
#log_lock_waits = off # log lock waits >= deadlock_timeout
log_lock_waits = on
log_statement = 'none' # none, ddl, mod, all
#log_temp_files = -1 # log temporary files equal or larger
log_temp_files = 0
log_timezone = 'W-SU'
#------------------------------------------------------------------------------
# RUNTIME STATISTICS
#------------------------------------------------------------------------------
stats_temp_directory = '/var/run/postgresql/9.6-main.pg_stat_tmp'
#------------------------------------------------------------------------------
# AUTOVACUUM PARAMETERS
#------------------------------------------------------------------------------
autovacuum = on # Enable autovacuum subprocess? 'on'
#log_autovacuum_min_duration = -1 # -1 disables, 0 logs all actions and
log_autovacuum_min_duration = 0
#autovacuum_max_workers = 3 # max number of autovacuum subprocesses
autovacuum_max_workers = 4
#autovacuum_naptime = 1min # time between autovacuum runs
autovacuum_naptime = 20s
#autovacuum_vacuum_scale_factor = 0.2 # fraction of table size before vacuum
autovacuum_vacuum_scale_factor = 0.02
#autovacuum_analyze_scale_factor = 0.1 # fraction of table size before analyze
autovacuum_analyze_scale_factor = 0.01
#------------------------------------------------------------------------------
# CLIENT CONNECTION DEFAULTS
#------------------------------------------------------------------------------
datestyle = 'iso, dmy'
timezone = 'W-SU'
lc_messages = 'ru_RU.UTF-8' # locale for system error message
lc_monetary = 'ru_RU.UTF-8' # locale for monetary formatting
lc_numeric = 'ru_RU.UTF-8' # locale for number formatting
lc_time = 'ru_RU.UTF-8' # locale for time formatting
default_text_search_config = 'pg_catalog.russian'
#------------------------------------------------------------------------------
# LOCK MANAGEMENT
#------------------------------------------------------------------------------
#max_locks_per_transaction = 150 # min 10
max_locks_per_transaction = 256
#------------------------------------------------------------------------------
# VERSION/PLATFORM COMPATIBILITY
#------------------------------------------------------------------------------
# - Previous PostgreSQL Versions -
#escape_string_warning = on
escape_string_warning = off
#standard_conforming_strings = on
standard_conforming_strings = off
#------------------------------------------------------------------------------
# ERROR HANDLING
#------------------------------------------------------------------------------
#------------------------------------------------------------------------------
# CONFIG FILE INCLUDES
#------------------------------------------------------------------------------
#------------------------------------------------------------------------------
# CUSTOMIZED OPTIONS
#------------------------------------------------------------------------------
#online_analyze.threshold = 50
online_analyze.threshold = 500
#online_analyze.scale_factor = 0.1
online_analyze.scale_factor = 0.3
online_analyze.enable = off
online_analyze.verbose = off
online_analyze.local_tracking = on
online_analyze.min_interval = 10000
online_analyze.table_type = 'temporary'
plantuner.fix_empty_table = on
#------------------------------------------------------------------------------
Сохранить.
$ sudo systemctl restart postgresql.service
$ sudo systemctl restart srv1cv83.service
.
$ nano changeip.sh
Скопируем из буфера следующий скрипт, в котором Вам нужно исправить ip и адрес шлюза в соответствии со своей сетью:
#!/bin/bash
# настройка ip и hostname
#----------------------------------------------------------------------
_hostname="kamin"
# real computer
#_iface="enp0s31f6"
# kvm iface
#_iface="ens3"
# virtualbox iface
#_iface="enp0s3"
_iface="enp1s0"
_address="192.168.1.95"
_gateway="192.168.1.1"
_netmask="255.255.255.0"
_nameserver="8.8.8.8"
#----------------------------------------------------------------------
# настроим статический ip
sudo cat > /tmp/interfaces <<EOF
# This file describes the network interfaces available on your system
# and how to activate them. For more information, see interfaces(5).
source /etc/network/interfaces.d/*
# The loopback network interface
auto lo
iface lo inet loopback
# The primary network interface
#auto $_iface
#iface $_iface inet dhcp
iface $_iface inet static
address $_address
netmask $_netmask
gateway $_gateway
dns-nameservers $_nameserver
auto $_iface
EOF
sudo cp /tmp/interfaces /etc/network#sudo rm /etc/resolv.conf
#sudo /bin/su -c "echo 'nameserver $_nameserver' > /etc/resolv.conf"
# изменим hostname и ip
sudo cat > /tmp/hosts <<EOF
127.0.0.1 localhost
$_address $_hostname
EOF
sudo cp /tmp/hosts /etc
# изменим hostname
sudo hostname $_hostname
sudo /bin/su -c "echo $_hostname > /etc/hostname"
# перезагрузим сеть
sudo systemctl restart networking.service
Сохраним файл changeip.sh
Сделаем исполняем
$ chmod +x changeip.sh
Выполним:
$ ./changeip.sh
1С И Linux: Установка 1С 8.3.12.1529 Субд Postgresql Версия 9.6.7-1.1C Ubuntu 16.04.4 >>>>> Download Now
ОтветитьУдалить>>>>> Download Full
1С И Linux: Установка 1С 8.3.12.1529 Субд Postgresql Версия 9.6.7-1.1C Ubuntu 16.04.4 >>>>> Download LINK
>>>>> Download Now
1С И Linux: Установка 1С 8.3.12.1529 Субд Postgresql Версия 9.6.7-1.1C Ubuntu 16.04.4 >>>>> Download Full
>>>>> Download LINK tH