1C-Bitrix Installation and Configuration
innodb_buffer_pool_size — the first thing we check on any server running Bitrix. The default MySQL value (128 MB) is a death sentence for an online store with a catalog of 10,000+ products. We set it to 70-80% of available RAM on a dedicated server, 50% on VPS. This single setting speeds up the site 2-3x compared to the default.
Choosing Server Infrastructure
BitrixVM — a virtual machine with a pre-installed stack: nginx + Apache, PHP-FPM, MySQL/MariaDB, Sphinx, Push server. For VPS — the best starting point. Everything is already configured for Bitrix, including OPcache, log rotation, and firewall. Management via a web panel on port 8890.
VPS/VDS — the sweet spot. Minimum configuration for a mid-size online store: 2 vCPU, 4 GB RAM, SSD. Optimal: 4 vCPU, 8 GB RAM. OS: Ubuntu 22.04 or Debian 12. If not BitrixVM — we configure the stack manually.
Shared hosting — only for business cards and landing pages. Requirements: PHP 8.0+, MySQL 5.7+ / MariaDB 10.0+, 512 MB RAM, .htaccess. 1C-Bitrix hosting partners guarantee compatibility.
Dedicated server — for high-load. Typical architecture: web server separate, database separate, Redis/Memcached separate. On the "Enterprise" edition — a web cluster with a load balancer.
Cloud (Yandex Cloud, VK Cloud, Selectel) — when load fluctuates. Sales events, seasonal peaks. Auto-scaling via Managed Kubernetes or simple vertical VM scaling.
Choosing an Edition — Where Mistakes Happen Most
| Edition | Best for | Key limitation |
|---|---|---|
| Start | Business cards, landing pages | No Iblocks 2.0, no product catalog |
| Standard | Corporate sites | No e-commerce module |
| Small Business | Small stores | 1 price type, 1 warehouse, no 1C exchange |
| Business | Mid-size stores, B2B | Multi-warehouse, multi-currency, CommerceML |
| Enterprise | High-load, cluster | Web cluster, CDN, multi-site |
A typical mistake: choosing "Small Business" for a store that in six months grows into B2B with wholesale pricing and three warehouses. Upgrading to "Business" means paying the price difference — data isn't lost, but it's better to plan ahead.
Server Stack Configuration
Web server. nginx as reverse proxy + Apache (mod_php) or nginx + PHP-FPM directly. The second option saves memory — Apache isn't needed. But some Bitrix modules use .htaccess, so for compatibility we sometimes keep Apache.
nginx configuration for Bitrix:
-
fastcgi_read_timeout 300— for long operations (1C import) -
client_max_body_size 1024m— large file uploads - Block access to
.settings.php,.settings_extra.php,bitrix/.settings.php— these contain database passwords - Rewrite rules from
urlrewrite.php— Bitrix generates them, but with nginx + PHP-FPM they need to be duplicated
PHP 8.0-8.2 with extensions: mbstring, curl, gd, xml, json, opcache, redis/memcached. Key php.ini settings:
-
opcache.memory_consumption=256— compiled script cache -
opcache.max_accelerated_files=20000— Bitrix has thousands of PHP files -
max_execution_time=300— catalog imports can take a while -
memory_limit=512M— for complex operations, 256M minimum -
upload_max_filesize=100M,post_max_size=128M
MySQL/MariaDB. Key my.cnf parameters:
-
innodb_buffer_pool_size— 70-80% RAM (already mentioned, but it's that important) -
innodb_log_file_size=256M— for large transactions -
tmp_table_size=256M,max_heap_table_size=256M— in-memory temporary tables -
thread_pool_size— match the number of CPU cores -
utf8mb4encoding — mandatory, otherwise emoji and special characters break
Caching. Redis is preferable to Memcached for Bitrix — it supports persistent connections and is more reliable. Configured in .settings_extra.php:
'cache' => ['value' => ['type' => ['class_name' => '\\Bitrix\\Main\\Data\\CacheEngineRedis']]]
'session' => ['value' => ['mode' => 'default', 'handlers' => ['general' => ['type' => 'redis']]]]
SSL — Non-Negotiable
Let's Encrypt via certbot — 90% of cases. Auto-renewal via cron, certificate refreshes every 60 days.
nginx configuration for HTTPS:
- HTTP → HTTPS redirect (301)
- HSTS:
Strict-Transport-Security "max-age=31536000; includeSubDomains" - TLS 1.2/1.3, disable TLS 1.0/1.1
- OCSP Stapling — speeds up SSL handshake
In Bitrix: switch to HTTPS in "Settings → Main Module → Parameters → Use SSL," update sitemap.xml, canonical URLs.
Mail Configuration — Keeping Out of Spam
The standard PHP mail() function is a gamble. Emails are sent on behalf of the server without authentication — mail providers cut them on approach.
-
SMTP — connect via main module settings or the
mailmodule. Yandex Mail for domain, Mail.ru for business, or your own mail server -
SPF —
v=spf1 include:_spf.yandex.net ~all(for Yandex). Without SPF — Gmail and Mail.ru automatically send to spam - DKIM — 2048-bit key, added to DNS as a TXT record
-
DMARC — start with
p=nonefor monitoring, switch top=quarantineafter a month
Test deliverability via mail-tester.com — aim for a score of 9+/10.
Cron — Background Tasks
Bitrix agents run on page hits by default. On a low-traffic site, an agent might not fire for hours. We switch to cron:
* * * * * /usr/bin/php /var/www/bitrix/modules/main/tools/cron_events.php
What else we put on cron:
- 1C exchange — every 15-60 minutes, depending on catalog size
-
Search reindexing —
search.reindexonce per hour -
Backups —
mysqldump+ rsync of files, with rotation (keep 7 daily + 4 weekly) -
Cleanup — temporary files in
/bitrix/cache/, expired cart entries, unconfirmed registrations
Security
File system:
- Owner:
www-data, directories755, files644 - Upload:
775for web server write access - nginx: block access to
\.settings\.php$,\.settings_extra\.php$,/bitrix/php_interface/dbconn\.php$
Bitrix Proactive Protection:
- WAF — enable it, verify it doesn't block legitimate requests (AJAX forms sometimes get caught)
- Activity monitoring — brute force protection: lockout after 5 failed attempts
- File integrity check — detects core file modifications
- Intrusion log — monitor it, set up email notifications
Admin panel:
- User groups: administrator, content manager, SEO, store operator — each with their own permissions
- Two-factor authentication for admins — via Google Authenticator or OTP
- Restrict access to
/bitrix/admin/by IP via nginx — for the security-conscious (and justified)
Post-Installation Verification
-
Performance monitor (
/bitrix/admin/perfmon_panel.php) — aim for 30+ points. Below 20 means serious configuration issues - System check — automated verification of all parameters. Red items — fix immediately, yellow — case by case
- Security scanner — checks for common vulnerabilities
- PageSpeed Insights — TTFB < 200ms on VPS, LCP < 2.5s
- Test 1C exchange — if integration is planned, verify CommerceML exchange before launch
Timelines
| Task | Timeline |
|---|---|
| Installation on shared hosting | 2-4 hours |
| Installation on VPS with stack configuration | 1-2 days |
| Installation on dedicated with architecture planning | 2-5 days |
| SSL + mail + cron + security | 1-2 days |
| Backup and monitoring setup | 0.5-1 day |
At the end — documentation with all settings: software versions, php.ini and my.cnf parameters, cron tasks, DNS records, access credentials. The next administrator won't have to guess what was configured and how.







