{"id":691,"date":"2014-12-26T14:37:26","date_gmt":"2014-12-26T13:37:26","guid":{"rendered":"http:\/\/it.tuxie.eu\/?p=691"},"modified":"2015-01-27T16:04:37","modified_gmt":"2015-01-27T15:04:37","slug":"disable-firewallselinux-centos-7-and-similar","status":"publish","type":"post","link":"http:\/\/it.tuxie.eu\/?p=691","title":{"rendered":"Disable firewall+SELinux (CentOS 7 and similar&#8230;)"},"content":{"rendered":"<p>You know that feeling within testing where you need to virtualize at least one database server and you&#8217;re still facing connection issues? Call me piggie, but when I&#8217;m doing anything in a <strong>localhost realm<\/strong>, I&#8217;m skipping creating rules and always disable firewall and SELinux.<\/p>\n<p><!--more--><\/p>\n<p>1) SELinux<\/p>\n<p>Be sure you have disabled value in this file:<\/p>\n<p>[crayon lang=&#8220;shell&#8220;]<br \/>\n[db2inst1@localhost ~]$ cat \/etc\/selinux\/config<\/p>\n<p># This file controls the state of SELinux on the system.<br \/>\n# SELINUX= can take one of these three values:<br \/>\n#     enforcing \u2013 SELinux security policy is enforced.<br \/>\n#     permissive \u2013 SELinux prints warnings instead of enforcing.<br \/>\n#     disabled \u2013 No SELinux policy is loaded.<br \/>\nSELINUX=disabled<br \/>\n# SELINUXTYPE= can take one of these two values:<br \/>\n#     targeted \u2013 Targeted processes are protected,<br \/>\n#     minimum \u2013 Modification of targeted policy. Only selected processes are protected.<br \/>\n#     mls \u2013 Multi Level Security protection.<br \/>\nSELINUXTYPE=targeted<br \/>\n[\/crayon]<\/p>\n<p>2) Firewall &#8211; few steps:<br \/>\n[crayon lang=&#8220;shell&#8220;]<br \/>\n[root@localhost db2inst1]# systemctl disable firewalld<br \/>\nrm \u2018\/etc\/systemd\/system\/dbus-org.fedoraproject.FirewallD1.service\u2019<br \/>\nrm \u2018\/etc\/systemd\/system\/basic.target.wants\/firewalld.service\u2019<br \/>\n[root@localhost db2inst1]# systemctl stop firewalld<br \/>\n[root@localhost db2inst1]# systemctl status firewalld<br \/>\nfirewalld.service \u2013 firewalld \u2013 dynamic firewall daemon<br \/>\n   Loaded: loaded (\/usr\/lib\/systemd\/system\/firewalld.service; disabled)<br \/>\n   Active: inactive (dead)<\/p>\n<p>Dec 26 14:14:57 localhost.localdomain systemd[1]: Starting firewalld \u2013 dynamic firewall daemon\u2026<br \/>\nDec 26 14:14:58 localhost.localdomain systemd[1]: Started firewalld \u2013 dynamic firewall daemon.<br \/>\nDec 26 14:19:07 localhost.localdomain systemd[1]: Stopping firewalld \u2013 dynamic firewall daemon\u2026<br \/>\nDec 26 14:19:09 localhost.localdomain systemd[1]: Stopped firewalld \u2013 dynamic firewall daemon.<br \/>\n[root@localhost db2inst1]#<br \/>\n[\/crayon]<\/p>\n<p>All done.<\/p>\n<p>-a-<\/p>\n<p>&nbsp;<\/p>\n","protected":false},"excerpt":{"rendered":"<p>You know that feeling within testing where you need to virtualize at least one database server and you&#8217;re still facing connection issues? Call me piggie, but when I&#8217;m doing anything in a localhost realm, I&#8217;m skipping creating rules and always &hellip; <a href=\"http:\/\/it.tuxie.eu\/?p=691\">Continue reading <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":[],"categories":[4],"tags":[],"_links":{"self":[{"href":"http:\/\/it.tuxie.eu\/index.php?rest_route=\/wp\/v2\/posts\/691"}],"collection":[{"href":"http:\/\/it.tuxie.eu\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/it.tuxie.eu\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/it.tuxie.eu\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/it.tuxie.eu\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=691"}],"version-history":[{"count":0,"href":"http:\/\/it.tuxie.eu\/index.php?rest_route=\/wp\/v2\/posts\/691\/revisions"}],"wp:attachment":[{"href":"http:\/\/it.tuxie.eu\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=691"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/it.tuxie.eu\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=691"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/it.tuxie.eu\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=691"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}