{"id":8233,"date":"2020-07-18T20:53:29","date_gmt":"2020-07-18T12:53:29","guid":{"rendered":"https:\/\/www.linuxcool.com\/?p=8233"},"modified":"2020-07-18T20:53:32","modified_gmt":"2020-07-18T12:53:32","slug":"iscsiadm","status":"publish","type":"post","link":"https:\/\/www.linuxcool.com\/iscsiadm","title":{"rendered":"iscsiadm\u547d\u4ee4 – iscsi\u7ba1\u7406\u5de5\u5177"},"content":{"rendered":"\n

iscsiadm\u5b9e\u7528\u7a0b\u5e8f\u662f\u4e00\u4e2a\u547d\u4ee4\u884c\u5de5\u5177\uff0c\u5141\u8bb8\u53d1\u73b0\u548c\u767b\u5f55iSCSI\u76ee\u6807\uff0c\u4ee5\u53ca\u8bbf\u95ee\u548c\u7ba1\u7406open-iscsi\u6570\u636e\u5e93\u3002<\/p>\n\n\n\n

Open-iscsi\u6ca1\u6709\u4f7f\u7528 iSCSI RFC \u6240\u5b9a\u4e49\u7684\u672f\u8bednode\uff0c\u5176\u4e2d\u8282\u70b9\u662f\u6307\u5355\u4e2aiSCSI\u542f\u52a8\u5668\u6216\u76ee\u6807\u3002Open-iscsi\u4f7f\u7528\u672f\u8bednode\u6765\u6307\u4ee3\u76ee\u6807\u4e0a\u7684\u95e8\u6237\u3002<\/p>\n\n\n\n

\u8bed\u6cd5\u683c\u5f0f\uff1a<\/strong>iscsiadm [\u53c2\u6570]<\/p>\n\n\n\n

\u5e38\u7528\u53c2\u6570\uff1a<\/strong><\/p>\n\n\n\n

-m discovery<\/td>\u6307\u5b9a\u6a21\u5f0f\u4e3adiscovery<\/td><\/tr>
-p<\/td>\u6307\u5b9a\u76ee\u6807\u670d\u52a1\u5668IP\u548c\u7aef\u53e3<\/td><\/tr>
-o<\/td>\u5f00\u542f\u8ba4\u8bc1\u6a21\u5f0f<\/td><\/tr>
-t st<\/td>\u6267\u884c\u626b\u63cf\u64cd\u4f5c\u7684\u7c7b\u578b<\/td><\/tr><\/tbody><\/table><\/figure>\n\n\n\n

\u53c2\u8003\u5b9e\u4f8b<\/strong><\/p>\n\n\n\n

\u53d1\u73b0iSCSI\u76ee\u6807\u670d\u52a1\u5668\uff1a<\/p>\n\n\n\n

[root@linuxcool ~]# iscsiadm -m discovery -t sendtargets -p 192.168.1.1:3260<\/pre>\n\n\n\n

\u767b\u5f55iSCSI\u670d\u52a1\u5668\u8282\u70b9\uff1a<\/p>\n\n\n\n

[root@linuxcool ~]# iscsiadm -m node \u2013T iqn.1997-05.com.test:raid -p 192.168.1.1:3260 -l<\/pre>\n\n\n\n

\u8bbe\u7f6e\u5f00\u673a\u81ea\u52a8\u767b\u5f55\uff1a<\/p>\n\n\n\n

[root@linuxcool ~]# iscsiadm -m node \u2013T iqn.1997-05.com.test:raid -p 192.168.1.1:3260 --op update -n node.startup -v automatic<\/pre>\n\n\n\n

\u6ce8\u9500\u6240\u6709\u8fde\u63a5\uff1a<\/p>\n\n\n\n

[root@linuxcool ~]# iscsiadm -m node --logoutall=all<\/pre>\n","protected":false},"excerpt":{"rendered":"

iscsiadm\u5b9e\u7528\u7a0b\u5e8f\u662f\u4e00\u4e2a\u547d\u4ee4\u884c\u5de5\u5177\uff0c\u5141\u8bb8\u53d1\u73b0\u548c\u767b\u5f55iSCSI\u76ee\u6807\uff0c\u4ee5\u53ca\u8bbf\u95ee\u548c\u7ba1\u7406open-iscsi\u6570\u636e […]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":[],"categories":[7],"tags":[],"_links":{"self":[{"href":"https:\/\/www.linuxcool.com\/wp-json\/wp\/v2\/posts\/8233"}],"collection":[{"href":"https:\/\/www.linuxcool.com\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.linuxcool.com\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.linuxcool.com\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.linuxcool.com\/wp-json\/wp\/v2\/comments?post=8233"}],"version-history":[{"count":4,"href":"https:\/\/www.linuxcool.com\/wp-json\/wp\/v2\/posts\/8233\/revisions"}],"predecessor-version":[{"id":8237,"href":"https:\/\/www.linuxcool.com\/wp-json\/wp\/v2\/posts\/8233\/revisions\/8237"}],"wp:attachment":[{"href":"https:\/\/www.linuxcool.com\/wp-json\/wp\/v2\/media?parent=8233"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.linuxcool.com\/wp-json\/wp\/v2\/categories?post=8233"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.linuxcool.com\/wp-json\/wp\/v2\/tags?post=8233"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}