{"id":6430,"date":"2026-10-07T10:34:21","date_gmt":"2026-10-07T08:34:21","guid":{"rendered":"https:\/\/www.hostx.ro\/kb\/"},"modified":"2026-10-07T10:34:21","modified_gmt":"2026-10-07T08:34:21","password":"","slug":"cum-activez-sau-configurez-logul-de-erori-in-mysql-mariadb","status":"publish","type":"docs","link":"https:\/\/www.hostx.ro\/kb\/cum-activez-sau-configurez-logul-de-erori-in-mysql-mariadb\/","title":{"rendered":"Cum activez sau configurez logul de erori \u00een MySQL \/ MariaDB?"},"content":{"rendered":"<p>Logul de erori MySQL\/MariaDB \u00eenregistreaz\u0103 pornirile\/opririle serverului \u0219i erorile critice \u2014 esen\u021bial pentru a diagnostica de ce serviciul de baze de date se blocheaz\u0103 sau nu porne\u0219te. Configurarea necesit\u0103 acces <strong>root<\/strong> la server (VPS\/dedicat).<\/p>\n<h3>1. Verific\u0103 unde este logul curent<\/h3>\n<p>Conecteaz\u0103-te la consola MySQL \u0219i ruleaz\u0103:<\/p>\n<pre><code>SHOW VARIABLES LIKE 'log_error';<\/code><\/pre>\n<p>Loca\u021bia implicit\u0103 este de obicei <code>\/var\/log\/mysqld.log<\/code> (MySQL) sau <code>\/var\/lib\/mysql\/hostname.err<\/code> (MariaDB).<\/p>\n<h3>2. Activeaz\u0103\/seteaz\u0103 logul \u00een fi\u0219ierul de configurare<\/h3>\n<p>Editeaz\u0103 <code>\/etc\/my.cnf<\/code> (sau un fi\u0219ier din <code>\/etc\/my.cnf.d\/<\/code>) \u0219i adaug\u0103 \u00een sec\u021biunea <code>[mysqld]<\/code>:<\/p>\n<pre><code>[mysqld]\r\nlog_error = \/var\/log\/mysqld.log\r\n# op\u021bional, nivel de detaliu (1=erori, 2=erori+avertismente, 3=+note)\r\nlog_error_verbosity = 2<\/code><\/pre>\n<h3>3. Reporne\u0219te serviciul<\/h3>\n<pre><code>systemctl restart mysqld     # sau: systemctl restart mariadb<\/code><\/pre>\n<h3>4. Consult\u0103 logul<\/h3>\n<pre><code>tail -f \/var\/log\/mysqld.log<\/code><\/pre>\n<p><strong>Sfat:<\/strong> pentru interog\u0103ri lente, activeaz\u0103 separat <em>slow query log<\/em> (<code>slow_query_log=1<\/code>, <code>long_query_time=2<\/code>) pentru a identifica interog\u0103rile care \u00eencarc\u0103 serverul.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Logul de erori MySQL\/MariaDB \u00eenregistreaz\u0103 pornirile\/opririle serverului \u0219i erorile critice \u2014 esen\u021bial pentru a diagnostica de ce serviciul de baze de date se blocheaz\u0103 sau nu porne\u0219te. Configurarea necesit\u0103 acces root la server (VPS\/dedicat). 1. Verific\u0103 unde este logul curent Conecteaz\u0103-te la consola MySQL \u0219i ruleaz\u0103: SHOW VARIABLES LIKE &#8216;log_error&#8217;; Loca\u021bia implicit\u0103 este de obicei &#8230; <a title=\"Cum activez sau configurez logul de erori \u00een MySQL \/ MariaDB?\" class=\"read-more\" href=\"https:\/\/www.hostx.ro\/kb\/cum-activez-sau-configurez-logul-de-erori-in-mysql-mariadb\/\" aria-label=\"Cite\u0219te mai multe despre Cum activez sau configurez logul de erori \u00een MySQL \/ MariaDB?\">Cite\u0219te mai mult<\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"closed","template":"","meta":{"inline_featured_image":false,"whmcs_kb_id":0,"footnotes":""},"doc_category":[112],"doc_tag":[231,227,289,438,235,248],"class_list":["post-6430","docs","type-docs","status-publish","hentry","doc_category-mysql-cpanel-whm","doc_tag-baza-de-date","doc_tag-configurare","doc_tag-linux","doc_tag-mariadb","doc_tag-mysql","doc_tag-troubleshooting"],"year_month":"2026-10","word_count":161,"total_views":0,"reactions":{"happy":0,"normal":0,"sad":0},"author_info":{"name":"benyhill","author_nicename":"benyhill","author_url":"https:\/\/www.hostx.ro\/kb\/author\/benyhill\/"},"doc_category_info":[{"term_name":"MySQL","term_url":"https:\/\/www.hostx.ro\/kb\/docs-category\/mysql-cpanel-whm\/"}],"doc_tag_info":[{"term_name":"baz\u0103 de date","term_url":"https:\/\/www.hostx.ro\/kb\/docs-tag\/baza-de-date\/"},{"term_name":"configurare","term_url":"https:\/\/www.hostx.ro\/kb\/docs-tag\/configurare\/"},{"term_name":"Linux","term_url":"https:\/\/www.hostx.ro\/kb\/docs-tag\/linux\/"},{"term_name":"MariaDB","term_url":"https:\/\/www.hostx.ro\/kb\/docs-tag\/mariadb\/"},{"term_name":"MySQL","term_url":"https:\/\/www.hostx.ro\/kb\/docs-tag\/mysql\/"},{"term_name":"Troubleshooting","term_url":"https:\/\/www.hostx.ro\/kb\/docs-tag\/troubleshooting\/"}],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v28.7 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>Configurare log erori MySQL MariaDB - Centrul de suport HostX<\/title>\n<meta name=\"description\" content=\"Activare \u0219i configurare log erori MySQL\/MariaDB pentru diagnosticare probleme server. Localizare fi\u0219ier, set\u0103ri \u00een my.cnf \u0219i monitorizare erorilor.\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.hostx.ro\/kb\/cum-activez-sau-configurez-logul-de-erori-in-mysql-mariadb\/\" \/>\n<meta property=\"og:locale\" content=\"ro_RO\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Configurare log erori MySQL MariaDB - Centrul de suport HostX\" \/>\n<meta property=\"og:description\" content=\"Activare \u0219i configurare log erori MySQL\/MariaDB pentru diagnosticare probleme server. Localizare fi\u0219ier, set\u0103ri \u00een my.cnf \u0219i monitorizare erorilor.\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.hostx.ro\/kb\/cum-activez-sau-configurez-logul-de-erori-in-mysql-mariadb\/\" \/>\n<meta property=\"og:site_name\" content=\"Centrul de suport HostX\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Timp estimat pentru citire\" \/>\n\t<meta name=\"twitter:data1\" content=\"1 minut\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/www.hostx.ro\\\/kb\\\/cum-activez-sau-configurez-logul-de-erori-in-mysql-mariadb\\\/\",\"url\":\"https:\\\/\\\/www.hostx.ro\\\/kb\\\/cum-activez-sau-configurez-logul-de-erori-in-mysql-mariadb\\\/\",\"name\":\"Configurare log erori MySQL MariaDB - Centrul de suport HostX\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/www.hostx.ro\\\/kb\\\/#website\"},\"datePublished\":\"2026-10-07T08:34:21+00:00\",\"description\":\"Activare \u0219i configurare log erori MySQL\\\/MariaDB pentru diagnosticare probleme server. Localizare fi\u0219ier, set\u0103ri \u00een my.cnf \u0219i monitorizare erorilor.\",\"breadcrumb\":{\"@id\":\"https:\\\/\\\/www.hostx.ro\\\/kb\\\/cum-activez-sau-configurez-logul-de-erori-in-mysql-mariadb\\\/#breadcrumb\"},\"inLanguage\":\"ro-RO\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\\\/\\\/www.hostx.ro\\\/kb\\\/cum-activez-sau-configurez-logul-de-erori-in-mysql-mariadb\\\/\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/www.hostx.ro\\\/kb\\\/cum-activez-sau-configurez-logul-de-erori-in-mysql-mariadb\\\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Prima pagin\u0103\",\"item\":\"https:\\\/\\\/www.hostx.ro\\\/kb\\\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"InfoCentru\",\"item\":\"https:\\\/\\\/www.hostx.ro\\\/kb\\\/docs\\\/\"},{\"@type\":\"ListItem\",\"position\":3,\"name\":\"Cum activez sau configurez logul de erori \u00een MySQL \\\/ MariaDB?\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/www.hostx.ro\\\/kb\\\/#website\",\"url\":\"https:\\\/\\\/www.hostx.ro\\\/kb\\\/\",\"name\":\"Centrul de suport HostX\",\"description\":\"tutoriale gazduire web, domenii web \u0219i servere\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\\\/\\\/www.hostx.ro\\\/kb\\\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"ro-RO\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Configurare log erori MySQL MariaDB - Centrul de suport HostX","description":"Activare \u0219i configurare log erori MySQL\/MariaDB pentru diagnosticare probleme server. Localizare fi\u0219ier, set\u0103ri \u00een my.cnf \u0219i monitorizare erorilor.","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.hostx.ro\/kb\/cum-activez-sau-configurez-logul-de-erori-in-mysql-mariadb\/","og_locale":"ro_RO","og_type":"article","og_title":"Configurare log erori MySQL MariaDB - Centrul de suport HostX","og_description":"Activare \u0219i configurare log erori MySQL\/MariaDB pentru diagnosticare probleme server. Localizare fi\u0219ier, set\u0103ri \u00een my.cnf \u0219i monitorizare erorilor.","og_url":"https:\/\/www.hostx.ro\/kb\/cum-activez-sau-configurez-logul-de-erori-in-mysql-mariadb\/","og_site_name":"Centrul de suport HostX","twitter_card":"summary_large_image","twitter_misc":{"Timp estimat pentru citire":"1 minut"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"WebPage","@id":"https:\/\/www.hostx.ro\/kb\/cum-activez-sau-configurez-logul-de-erori-in-mysql-mariadb\/","url":"https:\/\/www.hostx.ro\/kb\/cum-activez-sau-configurez-logul-de-erori-in-mysql-mariadb\/","name":"Configurare log erori MySQL MariaDB - Centrul de suport HostX","isPartOf":{"@id":"https:\/\/www.hostx.ro\/kb\/#website"},"datePublished":"2026-10-07T08:34:21+00:00","description":"Activare \u0219i configurare log erori MySQL\/MariaDB pentru diagnosticare probleme server. Localizare fi\u0219ier, set\u0103ri \u00een my.cnf \u0219i monitorizare erorilor.","breadcrumb":{"@id":"https:\/\/www.hostx.ro\/kb\/cum-activez-sau-configurez-logul-de-erori-in-mysql-mariadb\/#breadcrumb"},"inLanguage":"ro-RO","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.hostx.ro\/kb\/cum-activez-sau-configurez-logul-de-erori-in-mysql-mariadb\/"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/www.hostx.ro\/kb\/cum-activez-sau-configurez-logul-de-erori-in-mysql-mariadb\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Prima pagin\u0103","item":"https:\/\/www.hostx.ro\/kb\/"},{"@type":"ListItem","position":2,"name":"InfoCentru","item":"https:\/\/www.hostx.ro\/kb\/docs\/"},{"@type":"ListItem","position":3,"name":"Cum activez sau configurez logul de erori \u00een MySQL \/ MariaDB?"}]},{"@type":"WebSite","@id":"https:\/\/www.hostx.ro\/kb\/#website","url":"https:\/\/www.hostx.ro\/kb\/","name":"Centrul de suport HostX","description":"tutoriale gazduire web, domenii web \u0219i servere","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.hostx.ro\/kb\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"ro-RO"}]}},"knowledge_base_info":[],"knowledge_base_slug":[],"_links":{"self":[{"href":"https:\/\/www.hostx.ro\/kb\/wp-json\/wp\/v2\/docs\/6430","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.hostx.ro\/kb\/wp-json\/wp\/v2\/docs"}],"about":[{"href":"https:\/\/www.hostx.ro\/kb\/wp-json\/wp\/v2\/types\/docs"}],"author":[{"embeddable":true,"href":"https:\/\/www.hostx.ro\/kb\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.hostx.ro\/kb\/wp-json\/wp\/v2\/comments?post=6430"}],"version-history":[{"count":1,"href":"https:\/\/www.hostx.ro\/kb\/wp-json\/wp\/v2\/docs\/6430\/revisions"}],"predecessor-version":[{"id":7295,"href":"https:\/\/www.hostx.ro\/kb\/wp-json\/wp\/v2\/docs\/6430\/revisions\/7295"}],"wp:attachment":[{"href":"https:\/\/www.hostx.ro\/kb\/wp-json\/wp\/v2\/media?parent=6430"}],"wp:term":[{"taxonomy":"doc_category","embeddable":true,"href":"https:\/\/www.hostx.ro\/kb\/wp-json\/wp\/v2\/doc_category?post=6430"},{"taxonomy":"doc_tag","embeddable":true,"href":"https:\/\/www.hostx.ro\/kb\/wp-json\/wp\/v2\/doc_tag?post=6430"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}