{"id":509,"date":"2024-07-30T12:08:58","date_gmt":"2024-07-30T12:08:58","guid":{"rendered":"https:\/\/www.hyderabadwebhosting.co.in\/tutorials\/?p=509"},"modified":"2024-07-30T12:12:57","modified_gmt":"2024-07-30T12:12:57","slug":"firewalld-service-unit-is-masked","status":"publish","type":"post","link":"https:\/\/www.hyderabadwebhosting.co.in\/tutorials\/firewalld-service-unit-is-masked\/","title":{"rendered":"Failed to start firewalld service unit is masked \u2013 How we fix it!"},"content":{"rendered":"<p>This article deal with if the firewalld service unit is masked and failed to start.<\/p>\n<div id=\"ez-toc-container\" class=\"ez-toc-v2_0_83 counter-hierarchy ez-toc-counter ez-toc-grey ez-toc-container-direction\">\n<div class=\"ez-toc-title-container\">\n<p class=\"ez-toc-title\" style=\"cursor:inherit\">Table of Contents<\/p>\n<span class=\"ez-toc-title-toggle\"><a href=\"#\" class=\"ez-toc-pull-right ez-toc-btn ez-toc-btn-xs ez-toc-btn-default ez-toc-toggle\" aria-label=\"Toggle Table of Content\"><span class=\"ez-toc-js-icon-con\"><span class=\"\"><span class=\"eztoc-hide\" style=\"display:none;\">Toggle<\/span><span class=\"ez-toc-icon-toggle-span\"><svg style=\"fill: #999;color:#999\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\" class=\"list-377408\" width=\"20px\" height=\"20px\" viewBox=\"0 0 24 24\" fill=\"none\"><path d=\"M6 6H4v2h2V6zm14 0H8v2h12V6zM4 11h2v2H4v-2zm16 0H8v2h12v-2zM4 16h2v2H4v-2zm16 0H8v2h12v-2z\" fill=\"currentColor\"><\/path><\/svg><svg style=\"fill: #999;color:#999\" class=\"arrow-unsorted-368013\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"10px\" height=\"10px\" viewBox=\"0 0 24 24\" version=\"1.2\" baseProfile=\"tiny\"><path d=\"M18.2 9.3l-6.2-6.3-6.2 6.3c-.2.2-.3.4-.3.7s.1.5.3.7c.2.2.4.3.7.3h11c.3 0 .5-.1.7-.3.2-.2.3-.5.3-.7s-.1-.5-.3-.7zM5.8 14.7l6.2 6.3 6.2-6.3c.2-.2.3-.5.3-.7s-.1-.5-.3-.7c-.2-.2-.4-.3-.7-.3h-11c-.3 0-.5.1-.7.3-.2.2-.3.5-.3.7s.1.5.3.7z\"\/><\/svg><\/span><\/span><\/span><\/a><\/span><\/div>\n<nav><ul class='ez-toc-list ez-toc-list-level-1 ' ><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-1\" href=\"https:\/\/www.hyderabadwebhosting.co.in\/tutorials\/firewalld-service-unit-is-masked\/#Causes_for_failed_to_start_firewalld_service_unit_is_masked\" >Causes for failed to start firewalld service unit is masked<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-2\" href=\"https:\/\/www.hyderabadwebhosting.co.in\/tutorials\/firewalld-service-unit-is-masked\/#How_to_fix_failed_to_start_firewalld_service_unit_is_masked\" >How to fix failed to start firewalld service unit is masked?<\/a><ul class='ez-toc-list-level-3' ><li class='ez-toc-heading-level-3'><a class=\"ez-toc-link ez-toc-heading-3\" href=\"https:\/\/www.hyderabadwebhosting.co.in\/tutorials\/firewalld-service-unit-is-masked\/#Unmask\" >Unmask<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-3'><a class=\"ez-toc-link ez-toc-heading-4\" href=\"https:\/\/www.hyderabadwebhosting.co.in\/tutorials\/firewalld-service-unit-is-masked\/#Mask_link_is_broken\" >Mask link is broken<\/a><\/li><\/ul><\/li><\/ul><\/nav><\/div>\n<h2><span class=\"ez-toc-section\" id=\"Causes_for_failed_to_start_firewalld_service_unit_is_masked\"><\/span>Causes for failed to start firewalld service unit is masked<span class=\"ez-toc-section-end\"><\/span><\/h2>\n<p>We mask the firewall to prevent the firewall from starting from other services.<\/p>\n<p>This error occurs when we try to enable the firewalld that is masked.<\/p>\n<p>The error can also occur if the mask symbolic link is broken.<\/p>\n<p>We resolve the error by unmasking the firewalld and starting the service.<\/p>\n<h2><span class=\"ez-toc-section\" id=\"How_to_fix_failed_to_start_firewalld_service_unit_is_masked\"><\/span>How to fix failed to start firewalld service unit is masked?<span class=\"ez-toc-section-end\"><\/span><\/h2>\n<p>Recently one of our customers contacted us saying he was unable to enable firewalld in the server. And also was getting the same error.<\/p>\n<p>Now let\u2019s discuss how our Support Engineers resolve the error for our customers.<\/p>\n<h3><span class=\"ez-toc-section\" id=\"Unmask\"><\/span>Unmask<span class=\"ez-toc-section-end\"><\/span><\/h3>\n<p>On analyzing the firewalld service we found a mask firewall set. Thus to resolve the error we unmask the firewalld service. We can enable the firewall service if it is not masked.<\/p>\n<p>To unmask the service we use the command<\/p>\n<pre><code>systemctl unmask --now firewalld<\/code><\/pre>\n<p>After executing the command we get the output as<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter wp-image-510 size-full\" src=\"https:\/\/www.hyderabadwebhosting.co.in\/tutorials\/wp-content\/uploads\/2024\/07\/firewalld.png\" alt=\"firewalld service unit is masked\" width=\"472\" height=\"58\" srcset=\"https:\/\/www.hyderabadwebhosting.co.in\/tutorials\/wp-content\/uploads\/2024\/07\/firewalld.png 472w, https:\/\/www.hyderabadwebhosting.co.in\/tutorials\/wp-content\/uploads\/2024\/07\/firewalld-300x37.png 300w\" sizes=\"auto, (max-width: 472px) 100vw, 472px\" \/><\/p>\n<p>&nbsp;<\/p>\n<p>Now we enable the firewalld service using the command<\/p>\n<pre><code>systemctl enable firewalld<\/code><\/pre>\n<p>Finally, we start the firewalld service using the command<\/p>\n<pre><code>systemctl start firewalld<\/code><\/pre>\n<h3><span class=\"ez-toc-section\" id=\"Mask_link_is_broken\"><\/span>Mask link is broken<span class=\"ez-toc-section-end\"><\/span><\/h3>\n<p>One of the common reasons for the error is when starting the service the masked link is broken. Thus we need to link the mask location once again to resolve the error.<\/p>\n<p>To unmask the service we use the command.<\/p>\n<pre><code>systemctl unmask firewalld<\/code><\/pre>\n<p>Thus, if the service still fails to unmask we need to manually mask it first. The location will change based on the Linux flavors.<\/p>\n<pre><code>ln -s \/etc\/systemd\/system\/firewalld.service \/dev\/null<\/code><\/pre>\n<p>Thus we unmask it. Then we start the service using the command<\/p>\n<pre><code>systemctl start firewalld<\/code><\/pre>\n<p>Finally, we find the status using<\/p>\n<p><code>firewall-cmd --state<\/code><\/p>\n<p>From the above steps and commands we will know how to unmask firewalld and to restart the service.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>This article deal with if the firewalld service unit is masked and failed to start. Causes for failed to start firewalld service unit is masked We mask the firewall to prevent the firewall from starting from other services. This error occurs when we try to enable the firewalld that is masked. The error can also [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[],"class_list":["post-509","post","type-post","status-publish","format-standard","hentry","category-uncategorized"],"_links":{"self":[{"href":"https:\/\/www.hyderabadwebhosting.co.in\/tutorials\/wp-json\/wp\/v2\/posts\/509","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.hyderabadwebhosting.co.in\/tutorials\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.hyderabadwebhosting.co.in\/tutorials\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.hyderabadwebhosting.co.in\/tutorials\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.hyderabadwebhosting.co.in\/tutorials\/wp-json\/wp\/v2\/comments?post=509"}],"version-history":[{"count":8,"href":"https:\/\/www.hyderabadwebhosting.co.in\/tutorials\/wp-json\/wp\/v2\/posts\/509\/revisions"}],"predecessor-version":[{"id":518,"href":"https:\/\/www.hyderabadwebhosting.co.in\/tutorials\/wp-json\/wp\/v2\/posts\/509\/revisions\/518"}],"wp:attachment":[{"href":"https:\/\/www.hyderabadwebhosting.co.in\/tutorials\/wp-json\/wp\/v2\/media?parent=509"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.hyderabadwebhosting.co.in\/tutorials\/wp-json\/wp\/v2\/categories?post=509"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.hyderabadwebhosting.co.in\/tutorials\/wp-json\/wp\/v2\/tags?post=509"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}