Re: SLES10 SP3 x86_64 - connection2:0: detected conn error (1011)

2009-12-14 Thread Anuarg Vora
I have got a reproducible test case for this.
It seems that SCSI layer returns DID_BUS_BUSY many times when 'conn error 
(1011)' is seen.

for p in `ls /dev/sd*`
do
dd if=$p of=/dev/zero count=1 
done
wait

# ./io-script
1+0 records in
1+0 records out
512 bytes (5.1 MB) copied, 0.177076 seconds, 28.9 MB/s

dd: reading `/dev/sdaa8': Input/output error
2976+0 records in
2976+0 records out

Dec 14 11:15:12 cdc-r710s3 iscsid: Kernel reported iSCSI connection 1:0 error 
(1011) state (3)
Dec 14 11:15:13 cdc-r710s3 kernel:  connection2:0: detected conn error (1011)
Dec 14 11:15:13 cdc-r710s3 iscsid: connection2:0 is operational after recovery 
(1 attempts)
Dec 14 11:15:13 cdc-r710s3 iscsid: Kernel reported iSCSI connection 2:0 error 
(1011) state (3)
Dec 14 11:15:14 cdc-r710s3 kernel:  connection1:0: detected conn error (1011)
...
Dec 14 11:15:14 cdc-r710s3 kernel: sd 9:0:0:13: SCSI error: return code = 
0x0002  == DID_BUS_BUSY
Dec 14 11:15:14 cdc-r710s3 kernel: end_request: I/O error, dev sdaa, sector 2976

I am unable to upload ethereal on 
http://groups-beta.google.com/group/open-iscsi/files

Regards,
Anurag

--- On Fri, 12/11/09, Anuarg Vora anurag_vo...@yahoo.com wrote:

 From: Anuarg Vora anurag_vo...@yahoo.com
 Subject: Re: SLES10 SP3 x86_64 - connection2:0: detected conn error (1011)
 To: open-iscsi@googlegroups.com
 Date: Friday, December 11, 2009, 12:22 AM
 Sorry, I do not see an upload option
 for me even after (signing-in).
 How to upload ?
 
 --- On Thu, 12/10/09, Mike Christie micha...@cs.wisc.edu
 wrote:
 
  From: Mike Christie micha...@cs.wisc.edu
  Subject: Re: SLES10 SP3 x86_64 - connection2:0:
 detected conn error (1011)
  To: open-iscsi@googlegroups.com
  Date: Thursday, December 10, 2009, 11:39 PM
  Anuarg Vora wrote:
   I did sent the ethereal trace yesterday.
   I am not sure why it didn't reach, is there any
 place
  I can upload it ?
   
  
  http://groups-beta.google.com/group/open-iscsi/files
  
  --
  
  You received this message because you are subscribed
 to the
  Google Groups open-iscsi group.
  To post to this group, send email to open-is...@googlegroups.com.
  To unsubscribe from this group, send email to
 open-iscsi+unsubscr...@googlegroups.com.
  For more options, visit this group at 
  http://groups.google.com/group/open-iscsi?hl=en.
  
  
  
 
 
       
 
 --
 
 You received this message because you are subscribed to the
 Google Groups open-iscsi group.
 To post to this group, send email to open-is...@googlegroups.com.
 To unsubscribe from this group, send email to 
 open-iscsi+unsubscr...@googlegroups.com.
 For more options, visit this group at 
 http://groups.google.com/group/open-iscsi?hl=en.
 
 
 


  

--

You received this message because you are subscribed to the Google Groups 
open-iscsi group.
To post to this group, send email to open-is...@googlegroups.com.
To unsubscribe from this group, send email to 
open-iscsi+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/open-iscsi?hl=en.




Write back cache

2009-12-14 Thread galitz

Hello,

I am connecting to iSCSI targets on a QNAP TS-439U.  They connect as
write-through cache enabled, but I cannot seem to tune the cache on
the QNAP side.  Is there a way to enable/configure write back cache on
the Linux initiator side?

I am actually doing this via XenServer, but they seem to be using
standard open-iscsi from what I can tell.

Thanks,
Geoff

--

You received this message because you are subscribed to the Google Groups 
open-iscsi group.
To post to this group, send email to open-is...@googlegroups.com.
To unsubscribe from this group, send email to 
open-iscsi+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/open-iscsi?hl=en.




Re: Make failed on Ubuntu9.10 with kernel_check, could anyone give me some suggestions except for building new kernel? :)

2009-12-14 Thread vagrant
It seems to be related to below url:
http://groups.google.com/group/open-iscsi/browse_thread/thread/06e3bf8da91c466a

A bug was logged and was similar to below descriptions:
https://bugs.launchpad.net/ubuntu/+source/open-iscsi/+bug/289470

Mark it as duplicate :)
Regards,

On Dec 11, 10:13 pm, vagrant yuchao1...@gmail.com wrote:
 open-scsi version: open-iscsi-2.0-871
 os enviroment: ubuntu-9.10
 kernel version: 2.6.31-15-generic

 Details below and thanks a lot. :)
 
 make -C kernel
 make[1]: Entering directory `/home/vagrant/Downloads/open-
 iscsi-2.0-871/kernel'
 make[1]: *** No rule to make target `linux_2_6_31', needed by
 `kernel_check'.  Stop.
 make[1]: Leaving directory `/home/vagrant/Downloads/open-iscsi-2.0-871/
 kernel'
 make: *** [kernel] Error 2
 

 vagr...@vagrant-laptop:~/Downloads/open-iscsi-2.0-871$ make
 make -C utils/sysdeps
 make[1]: Entering directory `/home/vagrant/Downloads/open-
 iscsi-2.0-871/utils/sysdeps'
 cc   -O2 -fno-inline -Wall -Wstrict-prototypes -g   -c -o sysdeps.o
 sysdeps.c
 make[1]: Leaving directory `/home/vagrant/Downloads/open-iscsi-2.0-871/
 utils/sysdeps'
 make -C utils/fwparam_ibft
 make[1]: Entering directory `/home/vagrant/Downloads/open-
 iscsi-2.0-871/utils/fwparam_ibft'
 cc -O2 -g -fPIC -Wall -Wstrict-prototypes -I../../include -I../../
 usr   -c -o fw_entry.o fw_entry.c
 cc -O2 -g -fPIC -Wall -Wstrict-prototypes -I../../include -I../../
 usr   -c -o fwparam_ibft_sysfs.o fwparam_ibft_sysfs.c
 cc -O2 -g -fPIC -Wall -Wstrict-prototypes -I../../include -I../../
 usr   -c -o prom_lex.o prom_lex.c
 stdout:1621: warning: ‘yyunput’ defined but not used
 stdout:1662: warning: ‘input’ defined but not used
 cc -O2 -g -fPIC -Wall -Wstrict-prototypes -I../../include -I../../
 usr   -c -o prom_parse.tab.o prom_parse.tab.c
 cc -O2 -g -fPIC -Wall -Wstrict-prototypes -I../../include -I../../
 usr   -c -o fwparam_ppc.o fwparam_ppc.c
 fwparam_ppc.c: In function ‘loop_devs’:
 fwparam_ppc.c:358: warning: passing argument 4 of ‘qsort’ from
 incompatible pointer type
 /usr/include/stdlib.h:710: note: expected ‘__compar_fn_t’ but argument
 is of type ‘int (*)(const char **, const char **)’
 make[1]: Leaving directory `/home/vagrant/Downloads/open-iscsi-2.0-871/
 utils/fwparam_ibft'
 make -C usr
 make[1]: Entering directory `/home/vagrant/Downloads/open-
 iscsi-2.0-871/usr'
 cc -O2 -g -Wall -Wstrict-prototypes -I../include -I. -DLinux -
 DNETLINK_ISCSI=8 -D_GNU_SOURCE   -c -o util.o util.c
 util.c: In function ‘daemon_init’:
 util.c:39: warning: ignoring return value of ‘chdir’, declared with
 attribute warn_unused_result
 util.c: In function ‘oom_adjust’:
 util.c:47: warning: ignoring return value of ‘nice’, declared with
 attribute warn_unused_result
 util.c:53: warning: ignoring return value of ‘write’, declared with
 attribute warn_unused_result
 util.c:54: warning: ignoring return value of ‘write’, declared with
 attribute warn_unused_result
 cc -O2 -g -Wall -Wstrict-prototypes -I../include -I. -DLinux -
 DNETLINK_ISCSI=8 -D_GNU_SOURCE   -c -o io.o io.c
 cc -O2 -g -Wall -Wstrict-prototypes -I../include -I. -DLinux -
 DNETLINK_ISCSI=8 -D_GNU_SOURCE   -c -o auth.o auth.c
 auth.c: In function ‘get_random_bytes’:
 auth.c:198: warning: ignoring return value of ‘read’, declared with
 attribute warn_unused_result
 auth.c:206: warning: ignoring return value of ‘read’, declared with
 attribute warn_unused_result
 auth.c:214: warning: ignoring return value of ‘read’, declared with
 attribute warn_unused_result
 cc -O2 -g -Wall -Wstrict-prototypes -I../include -I. -DLinux -
 DNETLINK_ISCSI=8 -D_GNU_SOURCE   -c -o login.o login.c
 cc -O2 -g -Wall -Wstrict-prototypes -I../include -I. -DLinux -
 DNETLINK_ISCSI=8 -D_GNU_SOURCE   -c -o log.o log.c
 log.c:333: warning: ‘__dump_char’ defined but not used
 cc -O2 -g -Wall -Wstrict-prototypes -I../include -I. -DLinux -
 DNETLINK_ISCSI=8 -D_GNU_SOURCE   -c -o md5.o md5.c
 cc -O2 -g -Wall -Wstrict-prototypes -I../include -I. -DLinux -
 DNETLINK_ISCSI=8 -D_GNU_SOURCE   -c -o sha1.o sha1.c
 cc -O2 -g -Wall -Wstrict-prototypes -I../include -I. -DLinux -
 DNETLINK_ISCSI=8 -D_GNU_SOURCE   -c -o iface.o iface.c
 iface.c:311: warning: ‘iface_get_next_id’ defined but not used
 cc -O2 -g -Wall -Wstrict-prototypes -I../include -I. -DLinux -
 DNETLINK_ISCSI=8 -D_GNU_SOURCE   -c -o idbm.o idbm.c
 cc -O2 -g -Wall -Wstrict-prototypes -I../include -I. -DLinux -
 DNETLINK_ISCSI=8 -D_GNU_SOURCE   -c -o sysfs.o sysfs.c
 cc -O2 -g -Wall -Wstrict-prototypes -I../include -I. -DLinux -
 DNETLINK_ISCSI=8 -D_GNU_SOURCE   -c -o host.o host.c
 cc -O2 -g -Wall -Wstrict-prototypes -I../include -I. -DLinux -
 DNETLINK_ISCSI=8 -D_GNU_SOURCE   -c -o session_info.o session_info.c
 cc -O2 -g -Wall -Wstrict-prototypes -I../include -I. -DLinux -
 DNETLINK_ISCSI=8 -D_GNU_SOURCE   -c -o iscsi_sysfs.o iscsi_sysfs.c
 cc -O2 -g -Wall 

Help:If open-iscsi can be installed on Linux and iscsi-target installed on Windows?

2009-12-14 Thread vagrant
Hi, All

I am a novice, and I successfully installed iscsi-target on Linux.
I just wonder if a Linux open-iscsi as a Host, and then install a
iscsi-target for win on Windows, can they be access to each other?
Thanks a lot.

Regards,

--

You received this message because you are subscribed to the Google Groups 
open-iscsi group.
To post to this group, send email to open-is...@googlegroups.com.
To unsubscribe from this group, send email to 
open-iscsi+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/open-iscsi?hl=en.




How to make a 2.6..*_compat.patch without sub-directory?

2009-12-14 Thread Yangkook Kim
I posted similar message on other thread, but let me ask the same question
with diffrent tittle.

I want to make a kernel compat patch without kernel/ sub-directory.
I used git diff to output the patch, but each header of outputted
patch includes kernel/ sub-directory like below.

e.g
diff --git a/kernel/libiscsi.c b/kernel/libiscsi.c
index 0b810b6..6ffb49c 100644
--- a/kernel/libiscsi.c
+++ b/kernel/libiscsi.c

git history shows me that other people have made a compat patch
without kernel/ sub-directory in headers.

Can anybody tell me how to do this?

Thanks,
Kim

--

You received this message because you are subscribed to the Google Groups 
open-iscsi group.
To post to this group, send email to open-is...@googlegroups.com.
To unsubscribe from this group, send email to 
open-iscsi+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/open-iscsi?hl=en.




Re: How to make a 2.6..*_compat.patch without sub-directory?

2009-12-14 Thread Erez Zilber
Use git diff --relative (when you're in the open-iscsi/kernel dir).

Erez

On Mon, Dec 14, 2009 at 8:25 PM, Yangkook Kim yangkook...@gmail.com wrote:
 I posted similar message on other thread, but let me ask the same question
 with diffrent tittle.

 I want to make a kernel compat patch without kernel/ sub-directory.
 I used git diff to output the patch, but each header of outputted
 patch includes kernel/ sub-directory like below.

 e.g
 diff --git a/kernel/libiscsi.c b/kernel/libiscsi.c
 index 0b810b6..6ffb49c 100644
 --- a/kernel/libiscsi.c
 +++ b/kernel/libiscsi.c

 git history shows me that other people have made a compat patch
 without kernel/ sub-directory in headers.

 Can anybody tell me how to do this?

 Thanks,
 Kim

 --

 You received this message because you are subscribed to the Google Groups 
 open-iscsi group.
 To post to this group, send email to open-is...@googlegroups.com.
 To unsubscribe from this group, send email to 
 open-iscsi+unsubscr...@googlegroups.com.
 For more options, visit this group at 
 http://groups.google.com/group/open-iscsi?hl=en.




--

You received this message because you are subscribed to the Google Groups 
open-iscsi group.
To post to this group, send email to open-is...@googlegroups.com.
To unsubscribe from this group, send email to 
open-iscsi+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/open-iscsi?hl=en.




[RESEND PATCH 1/1]cxgb3i: Fix a login over vlan issue

2009-12-14 Thread Rakesh Ranjan
From: Rakesh Ranjan rak...@chelsio.com

Fix a target login issue, when parent interface is vlan and we are using cxgb3i 
sepecific
private ip address in '/etc/iscsi/ifaces/' iface file.

Acked-by: Karen Xie k...@chelsio.com
Signed-off-by: Rakesh Ranjan rak...@chelsio.com
---
 drivers/scsi/cxgb3i/cxgb3i_offload.c |   34 +-
 1 files changed, 33 insertions(+), 1 deletions(-)

diff --git a/drivers/scsi/cxgb3i/cxgb3i_offload.c 
b/drivers/scsi/cxgb3i/cxgb3i_offload.c
index 26ffdcd..15a00e8 100644
--- a/drivers/scsi/cxgb3i/cxgb3i_offload.c
+++ b/drivers/scsi/cxgb3i/cxgb3i_offload.c
@@ -1440,6 +1440,10 @@ void cxgb3i_c3cn_release(struct s3_conn *c3cn)
 static int is_cxgb3_dev(struct net_device *dev)
 {
struct cxgb3i_sdev_data *cdata;
+   struct net_device *ndev = dev;
+
+   if (dev-priv_flags  IFF_802_1Q_VLAN)
+   ndev = vlan_dev_real_dev(dev);
 
write_lock(cdata_rwlock);
list_for_each_entry(cdata, cdata_list, list) {
@@ -1447,7 +1451,7 @@ static int is_cxgb3_dev(struct net_device *dev)
int i;
 
for (i = 0; i  ports-nports; i++)
-   if (dev == ports-lldevs[i]) {
+   if (ndev == ports-lldevs[i]) {
write_unlock(cdata_rwlock);
return 1;
}
@@ -1566,6 +1570,26 @@ out_err:
return -EINVAL;
 }
 
+/**
+ * cxgb3i_find_dev - find the interface associated with the given address
+ * @ipaddr: ip address
+ */
+static struct net_device *
+cxgb3i_find_dev(struct net_device *dev, __be32 ipaddr)
+{
+   struct flowi fl;
+   int err;
+   struct rtable *rt;
+
+   memset(fl, 0, sizeof(fl));
+   fl.nl_u.ip4_u.daddr = ipaddr;
+
+   err = ip_route_output_key(dev ? dev_net(dev) : init_net, rt, fl);
+   if (!err)
+   return (rt-u.dst)-dev;
+
+   return NULL;
+}
 
 /**
  * cxgb3i_c3cn_connect - initiates an iscsi tcp connection to a given address
@@ -1581,6 +1605,7 @@ int cxgb3i_c3cn_connect(struct net_device *dev, struct 
s3_conn *c3cn,
struct cxgb3i_sdev_data *cdata;
struct t3cdev *cdev;
__be32 sipv4;
+   struct net_device *dstdev;
int err;
 
c3cn_conn_debug(c3cn 0x%p, dev 0x%p.\n, c3cn, dev);
@@ -1591,6 +1616,13 @@ int cxgb3i_c3cn_connect(struct net_device *dev, struct 
s3_conn *c3cn,
c3cn-daddr.sin_port = usin-sin_port;
c3cn-daddr.sin_addr.s_addr = usin-sin_addr.s_addr;
 
+   dstdev = cxgb3i_find_dev(dev, usin-sin_addr.s_addr);
+   if (!dstdev || !is_cxgb3_dev(dstdev))
+   return -ENETUNREACH;
+
+   if (dstdev-priv_flags  IFF_802_1Q_VLAN)
+   dev = dstdev;
+
rt = find_route(dev, c3cn-saddr.sin_addr.s_addr,
c3cn-daddr.sin_addr.s_addr,
c3cn-saddr.sin_port,
-- 
1.6.0.6


--

You received this message because you are subscribed to the Google Groups 
open-iscsi group.
To post to this group, send email to open-is...@googlegroups.com.
To unsubscribe from this group, send email to 
open-iscsi+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/open-iscsi?hl=en.