包檢查:
root@opensolaris:~# pkg info SUNWstmf
Name: SUNWstmf
Summary: Sun Common Multiprotocol SCSI Target
Category: System/Hardware
State: Installed
Publisher: opensolaris.org
Version: 0.5.11
Build Release: 5.11
Branch: 0.111
Packaging Date: Fri May 8 16:37:12 2009
Size: 2.28 MB
FMRI: pkg:/SUNWstmf@0.5.11,5.11-0.111:20090508T163712Z
root@opensolaris:~# pkg info SUNWiscsidm
Name: SUNWiscsidm
Summary: Sun iSCSI Data Mover
Category: System/Hardware
State: Installed
Publisher: opensolaris.org
Version: 0.5.11
Build Release: 5.11
Branch: 0.111
Packaging Date: Fri May 8 16:10:41 2009
Size: 711.90 kB
FMRI: pkg:/SUNWiscsidm@0.5.11,5.11-0.111:20090508T161041Z
root@opensolaris:~#
root@opensolaris:~# pkg info SUNWiscsit
Name: SUNWiscsit
Summary: Sun iSCSI COMSTAR Port Provider
Category: System/Hardware
State: Installed
Publisher: opensolaris.org
Version: 0.5.11
Build Release: 5.11
Branch: 0.111
Packaging Date: Fri May 8 16:10:47 2009
Size: 647.71 kB
FMRI: pkg:/SUNWiscsit@0.5.11,5.11-0.111:20090508T161047Z
root@opensolaris:~#
空間創建:
root@opensolaris:~# zfs create -V 1G mypool/vol
root@opensolaris:~# zpool list mypool
NAME SIZE USED AVAIL CAP HEALTH ALTROOT
mypool 74G 475K 74.0G 0% ONLINE -
root@opensolaris:~# zfs list mypool/vol
NAME USED AVAIL REFER MOUNTPOINT
mypool/vol 1G 71.8G 16K -
root@opensolaris:~#
安裝 storage-server 和SUNWiscsit
root@opensolaris:~# pkg info SUNWiscsit
Name: SUNWiscsit
Summary: Sun iSCSI COMSTAR Port Provider
Category: System/Hardware
State: Installed
Publisher: opensolaris.org
Version: 0.5.11
Build Release: 5.11
Branch: 0.111
Packaging Date: Fri May 8 16:10:47 2009
Size: 647.71 kB
FMRI: pkg:/SUNWiscsit@0.5.11,5.11-0.111:20090508T161047Z
root@opensolaris:~#
root@opensolaris:~# pkg info storage-server
pkg: no packages matching the following patterns you specified are
installed on the system. Try specifying -r to query remotely:
storage-server
root@opensolaris:~#
root@opensolaris:~# pkg install storage-server
DOWNLOAD PKGS FILES XFER (MB)
Completed 16/16 845/845 28.58/28.58
PHASE ACTIONS
Install Phase 1657/1657
root@opensolaris:~#
root@opensolaris:~# svcs -a |grep stmf
disabled 16:10:50 svc:/system/stmf:default
root@opensolaris:~# svcadm enable stmf
root@opensolaris:~# svcs -a |grep stmf
online 16:13:25 svc:/system/stmf:default
root@opensolaris:~#
root@opensolaris:~# stmfadm list-state
Operational Status: online
Config Status : initialized
root@opensolaris:~#
root@opensolaris:/dev/zvol/rdsk/mypool# pwd
/dev/zvol/rdsk/mypool
root@opensolaris:/dev/zvol/rdsk/mypool# ls -al
total 5
drwxr-xr-x 4 root root 4 2009-12-04 16:10 .
drwxr-xr-x 4 root root 4 2009-12-04 11:41 ..
drwxr-xr-x 3 root root 3 2009-12-04 16:10 iscsi
lrwxrwxrwx 1 root root 39 2009-12-04 16:10 vol -> ../../../../devices/pseudo/zfs@0:1c,raw
root@opensolaris:/dev/zvol/rdsk/mypool# sbdadm create-lu /dev/zvol/rdsk/mypool/vol
Created the following LU:
GUID DATA SIZE SOURCE
-------------------------------- ------------------- ----------------
600144f0d9cf880000004b18c5c30001 1073676288 /dev/zvol/rdsk/mypool/vol
root@opensolaris:/dev/zvol/rdsk/mypool#
l
root@opensolaris:/dev/zvol/rdsk/mypool# stmfadm add-view 600144f0d9cf880000004b18c5c30001
root@opensolaris:/dev/zvol/rdsk/mypool#
root@opensolaris:/dev/zvol/rdsk/mypool# stmfadm list-view -l 600144f0d9cf880000004b18c5c30001
View Entry: 0
Host group : All
Target group : All
LUN : 0
root@opensolaris:/dev/zvol/rdsk/mypool#
root@opensolaris:/dev/zvol/rdsk/mypool# svcadm enable iscsi/target
root@opensolaris:/dev/zvol/rdsk/mypool# svcs iscsi/target
STATE STIME FMRI
online 16:21:11 svc:/network/iscsi/target:default
root@opensolaris:/dev/zvol/rdsk/mypool#
root@opensolaris:/dev/zvol/rdsk/mypool# itadm create-target
Target iqn.1986-03.com.sun:02:4a34aae0-f41e-6b82-9af0-eb7e8db6cec1 successfully created
root@opensolaris:/dev/zvol/rdsk/mypool#
測試機是winXP
現在最新的Initiator-2.08-build3825-x86fre.exe
安裝之
Discovery –> add-->opensolaris的IP. default port 3260
Target –> “Log On” 如果發現”Connected”就對了
管理工具--》存儲--》磁盤管理--》發現新增的disk。
剩下的內容就是初始化,格式化,不說了
記錄一下!
基本上smb方式, iSCSI都測試了,就是權限問題了。繼續研究
没有评论:
发表评论