Setting up iscsi on MacOSX: Difference between revisions
Jump to navigation
Jump to search
Created page with " sudo -s pkg install network/iscsi/target svcadm enable -s stmf svcadm enable -s iscsi/target zfs create -o mountpoint=none rpool/iscsi zfs create -V 8G -s rpool/iscsi/yo..." |
No edit summary |
||
(5 intermediate revisions by the same user not shown) | |||
Line 13: | Line 13: | ||
itadm create-target | itadm create-target | ||
itadm list-target | itadm list-target | ||
to remove | |||
<nowiki>root@monkey:~# sbdadm list-lu | |||
Found 2 LU(s) | |||
GUID DATA SIZE SOURCE | |||
-------------------------------- ------------------- ---------------- | |||
600144f0080027fb38cc50ae100c0001 322122547200 /dev/zvol/rdsk/data/iscsi/pheebslaptop | |||
600144f0080027fb38cc50ae39150002 107374182400 /dev/zvol/rdsk/data/iscsi/mountainlion</nowiki> | |||
root@monkey:~# sbdadm delete-lu 600144f0080027fb38cc50ae100c0001 | |||
root@monkey:~# sbdadm delete-lu 600144f0080027fb38cc50ae39150002 | |||
root@monkey:~# itadm list-target | |||
TARGET NAME STATE SESSIONS | |||
iqn.1986-03.com.sun:02:51e91201-10d8-48bc-f2be-aee5ec4e52fd online 0 | |||
iqn.1986-03.com.sun:02:414e4719-89e4-4fb3-c1db-be6d60d9e6a6 online 0 | |||
root@monkey:~# stmfadm offline-target iqn.1986-03.com.sun:02:51e91201-10d8-48bc-f2be-aee5ec4e52fd | |||
root@monkey:~# stmfadm offline-target iqn.1986-03.com.sun:02:414e4719-89e4-4fb3-c1db-be6d60d9e6a6 | |||
root@monkey:~# itadm delete-target iqn.1986-03.com.sun:02:51e91201-10d8-48bc-f2be-aee5ec4e52fd | |||
root@monkey:~# itadm delete-target iqn.1986-03.com.sun:02:414e4719-89e4-4fb3-c1db-be6d60d9e6a6 | |||
http://www.snsftp.com/public/globalsan/Legacy/ -> use 4.1 as it's free and works. 5.1 is licensed and doesn't work on Lion. |
Latest revision as of 08:15, 27 March 2013
sudo -s pkg install network/iscsi/target svcadm enable -s stmf svcadm enable -s iscsi/target zfs create -o mountpoint=none rpool/iscsi zfs create -V 8G -s rpool/iscsi/yourmom sbdadm create-lu /dev/zvol/rdsk/rpool/iscsi/yourmom sbdadm list-lu
Use that GUID from the sbdadm output (my GUID below):
stmfadm add-view 600144f096c28d0000004dbeb9df0001 itadm create-target itadm list-target
to remove
root@monkey:~# sbdadm list-lu Found 2 LU(s) GUID DATA SIZE SOURCE -------------------------------- ------------------- ---------------- 600144f0080027fb38cc50ae100c0001 322122547200 /dev/zvol/rdsk/data/iscsi/pheebslaptop 600144f0080027fb38cc50ae39150002 107374182400 /dev/zvol/rdsk/data/iscsi/mountainlion
root@monkey:~# sbdadm delete-lu 600144f0080027fb38cc50ae100c0001 root@monkey:~# sbdadm delete-lu 600144f0080027fb38cc50ae39150002 root@monkey:~# itadm list-target TARGET NAME STATE SESSIONS iqn.1986-03.com.sun:02:51e91201-10d8-48bc-f2be-aee5ec4e52fd online 0 iqn.1986-03.com.sun:02:414e4719-89e4-4fb3-c1db-be6d60d9e6a6 online 0 root@monkey:~# stmfadm offline-target iqn.1986-03.com.sun:02:51e91201-10d8-48bc-f2be-aee5ec4e52fd root@monkey:~# stmfadm offline-target iqn.1986-03.com.sun:02:414e4719-89e4-4fb3-c1db-be6d60d9e6a6 root@monkey:~# itadm delete-target iqn.1986-03.com.sun:02:51e91201-10d8-48bc-f2be-aee5ec4e52fd root@monkey:~# itadm delete-target iqn.1986-03.com.sun:02:414e4719-89e4-4fb3-c1db-be6d60d9e6a6
http://www.snsftp.com/public/globalsan/Legacy/ -> use 4.1 as it's free and works. 5.1 is licensed and doesn't work on Lion.