{"id":1618,"date":"2023-08-17T13:27:33","date_gmt":"2023-08-17T04:27:33","guid":{"rendered":"http:\/\/biochemistry.isc.chubu.ac.jp\/labo\/suzuki\/?p=1618"},"modified":"2023-08-17T13:35:05","modified_gmt":"2023-08-17T04:35:05","slug":"post-1618","status":"publish","type":"post","link":"http:\/\/biochemistry.isc.chubu.ac.jp\/labo\/suzuki\/archives\/1618","title":{"rendered":"\u3053\u3093\u306b\u3061\u306fMIRACLE LINUX"},"content":{"rendered":"<p>CentOS7\u306e\u30b5\u30dd\u30fc\u30c8\u7d42\u4e86\u304c\u8fd1\u3065\u304d\u3001\u3044\u308d\u3044\u308d\u306a\u30bd\u30d5\u30c8\u306e\u30d0\u30fc\u30b8\u30e7\u30f3\u304c\u53e4\u304f\u306a\u308b\u4e2d\u3001MIRACLE LINUX\u3092\u4f7f\u3063\u3066\u307f\u308b\u3053\u3068\u306b\u3057\u307e\u3057\u305f\u3002<\/p>\n<h3>\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb<\/h3>\n<ol>\n<li><a href=\"https:\/\/www.miraclelinux.com\/distribution\/download\">MIRACLE LINUX\u306e\u30c0\u30a6\u30f3\u30ed\u30fc\u30c9\u30da\u30fc\u30b8<\/a>\u304b\u3089\u30df\u30cb\u30de\u30eb\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u30a4\u30e1\u30fc\u30b8\u3092\u30c0\u30a6\u30f3\u30ed\u30fc\u30c9\u3002<\/li>\n<li>dd\u3067USB\u30e1\u30e2\u30ea\u3078\u30b3\u30d4\u30fc\u3002<\/li>\n<li>USB\u30e1\u30e2\u30ea\u3092\u5dee\u3057\u3066\u3001\u30b3\u30f3\u30d4\u30e5\u30fc\u30bf\u3092\u518d\u8d77\u52d5\u3002\u30a4\u30f3\u30b9\u30c8\u30fc\u30e9\u30fc\u306e\u6307\u793a\u306b\u5f93\u3063\u3066\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u5b8c\u4e86\u3002<\/li>\n<\/ol>\n<h3>\u30d5\u30a1\u30a4\u30a2\u30a6\u30a9\u30fc\u30eb\u306e\u8a2d\u5b9a<\/h3>\n<p>\u3053\u308c\u307e\u3067iptables\u3067\u884c\u3063\u3066\u3044\u307e\u3057\u305f\u304c\u3001firewalld\u306b\u79fb\u884c\u3059\u308b\u3053\u3068\u306b\u3057\u307e\u3057\u305f\u3002<\/p>\n<h4>\u73fe\u5728\u306e\u8a2d\u5b9a\u3092\u8abf\u3079\u308b<\/h4>\n<pre class=\"code\"># firewall-cmd --list-all\npublic (active)\n  target: default\n  icmp-block-inversion: no\n  interfaces: enp10s0 enp11s0\n  sources:\n  services: cockpit dhcpv6-client dns http https samba ssh\n  ports: 2022\/tcp 8000\/tcp\n  protocols:\n  forward: yes\n  masquerade: no\n  forward-ports:\n  source-ports:\n  icmp-blocks:\n  rich rules:\n<\/pre>\n<h4>\u30dd\u30fc\u30c8\u3092\u958b\u304f<\/h4>\n<p>\u64cd\u4f5c\u3057\u305f\u5f8c\u306ffirewall-cmd &#8211;reload\u3067\u6709\u52b9\u306b\u3059\u308b\u3002<\/p>\n<ul>\n<li>httpd\u306e\u30dd\u30fc\u30c8\u3092\u958b\u304f\u3002\n<pre class=\"code\"># firewall-cmd --zone=public --add-service=http --permanent\n# firewall-cmd --zone=public --add-service=https --permanent\n<\/pre>\n<\/li>\n<li>DNS\u306e\u30dd\u30fc\u30c8\u3092\u958b\u304f\u3002\n<pre class=\"code\"># firewall-cmd --zone=public --add-service=dns --permanent\n<\/pre>\n<\/li>\n<li>samba\u306e\u30dd\u30fc\u30c8\u3092\u958b\u304f\u3002\n<pre class=\"code\"># firewall-cmd --zone=public --add-service=samba --permanent\n<\/pre>\n<\/li>\n<li>sshd\u30922022\u756a\u30dd\u30fc\u30c8\u3067\u3082\u5f85\u6a5f\u3055\u305b\u3066\u3044\u308b\u306e\u3067\u3001\u305d\u306e\u30dd\u30fc\u30c8\u3092\u958b\u304f\u3002\n<pre class=\"code\"># firewall-cmd --zone=public --add-port=2022\/tcp --permanent\n<\/pre>\n<\/li>\n<\/ul>\n<h3>SELinux\u306e\u8a2d\u5b9a<\/h3>\n<p>\u898f\u5b9a\u5024\u3068\u306f\u7570\u306a\u308b\u3053\u3068\u3092\u3055\u305b\u308b\u3068\u304d\u306b\u306fSELinux\u306b\u5f15\u3063\u304b\u304b\u308b\u3053\u3068\u304c\u591a\u3044\u3002<\/p>\n<ul>\n<li>SELinux\u306e\u72b6\u614b\u3092\u8abf\u3079\u308b\u3068\u304d\u306f getenforce\u3002\u6709\u52b9\u306b\u3059\u308b\u3068\u304d\u306f setenforce 1\u3001\u7121\u52b9\u306b\u3059\u308b\u3068\u304d\u306fsetenforce 0\u3002<\/li>\n<li>Apache\u306eReverseProxy\u3092\u6709\u52b9\u306b\u3059\u308b(httpd\u304c\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u63a5\u7d9a\u3067\u304d\u308b\u3088\u3046\u306b\u3059\u308b)\u3002\n<pre class=\"code\"># setsebool -P httpd_can_network_connect=1\n<\/pre>\n<\/li>\n<li>Apache\u304c8000\u756a\u30dd\u30fc\u30c8\u3092\u4f7f\u3048\u308b\u3088\u3046\u306b\u3059\u308b\u3002\n<pre class=\"code\"># semanage port -a -t http_port_t -p tcp 8000\n<\/pre>\n<\/li>\n<li>Apache\u306eDocumentRoot\u3092\u5909\u66f4\u3059\u308b(\/var\/www\/html\u3068\/opt\/www\u3092\u540c\u3058\u8a2d\u5b9a\u306b\u3059\u308b)\u3002<a href=\"https:\/\/tex2e.github.io\/blog\/selinux\/selinux-httpd-change-documentroot\">[\u53c2\u8003]<\/a>\n<pre class=\"code\"># semanage fcontext -a -e \/var\/www\/html \/opt\/www\n# restorecon -R -v \/opt\/www\n<\/pre>\n<\/li>\n<li>Samba\u304c\u5171\u6709\u30c7\u30a3\u30ec\u30af\u30c8\u30ea\u3092\u4f7f\u3048\u308b\u3088\u3046\u306b\u3059\u308b(\/var\/www\/html\u3068\/opt\/www\u3092\u540c\u3058\u8a2d\u5b9a\u306b\u3059\u308b)\u3002\n<pre class=\"code\"># semanage fcontext -a -t samba_share_t \"\/opt\/data(\/.*)?\"\n<\/pre>\n<\/li>\n<\/ul>\n","protected":false},"excerpt":{"rendered":"<p>CentOS7\u306e\u30b5\u30dd\u30fc\u30c8\u7d42\u4e86\u304c\u8fd1\u3065\u304d\u3001\u3044\u308d\u3044\u308d\u306a\u30bd\u30d5\u30c8\u306e\u30d0\u30fc\u30b8\u30e7\u30f3\u304c\u53e4\u304f\u306a\u308b\u4e2d\u3001MIRACLE LINUX\u3092\u4f7f\u3063\u3066\u307f\u308b\u3053\u3068\u306b\u3057\u307e\u3057\u305f\u3002 \u30a4\u30f3\u30b9\u30c8\u30fc\u30eb MIRACLE LINUX\u306e\u30c0\u30a6\u30f3\u30ed\u30fc\u30c9\u30da\u30fc\u30b8\u304b\u3089\u30df\u30cb\u30de\u30eb\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[16],"tags":[],"_links":{"self":[{"href":"http:\/\/biochemistry.isc.chubu.ac.jp\/labo\/suzuki\/wp-json\/wp\/v2\/posts\/1618"}],"collection":[{"href":"http:\/\/biochemistry.isc.chubu.ac.jp\/labo\/suzuki\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/biochemistry.isc.chubu.ac.jp\/labo\/suzuki\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/biochemistry.isc.chubu.ac.jp\/labo\/suzuki\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/biochemistry.isc.chubu.ac.jp\/labo\/suzuki\/wp-json\/wp\/v2\/comments?post=1618"}],"version-history":[{"count":8,"href":"http:\/\/biochemistry.isc.chubu.ac.jp\/labo\/suzuki\/wp-json\/wp\/v2\/posts\/1618\/revisions"}],"predecessor-version":[{"id":1627,"href":"http:\/\/biochemistry.isc.chubu.ac.jp\/labo\/suzuki\/wp-json\/wp\/v2\/posts\/1618\/revisions\/1627"}],"wp:attachment":[{"href":"http:\/\/biochemistry.isc.chubu.ac.jp\/labo\/suzuki\/wp-json\/wp\/v2\/media?parent=1618"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/biochemistry.isc.chubu.ac.jp\/labo\/suzuki\/wp-json\/wp\/v2\/categories?post=1618"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/biochemistry.isc.chubu.ac.jp\/labo\/suzuki\/wp-json\/wp\/v2\/tags?post=1618"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}