bug in function get_random_bytes()

2012-11-02 Thread rahul
Guys, There seems to be a bug in function get_random_bytes(). I reported this earlier as well but somehow it didn't appear here. get_random_bytes(unsigned char *data, unsigned int length) { long r; unsigned n; int fd; fd = open(/dev/urandom, O_RDONLY); while (length 0) {

Re: Disabling startup on Centos 5.8

2012-11-02 Thread Vanush Misha Paturyan
Hi Richard, On 1 November 2012 21:19, rich...@aggress.net wrote: Hi, My iSCSI target is broken and I need to disable open-iscsi from starting up as it sits in a loop trying to connect without timing out. However.. I'm seemingly unable to do this.. I've disabled all services via chkconfig

Re: Disabling startup on Centos 5.8

2012-11-02 Thread Mike Christie
On 11/01/2012 04:19 PM, rich...@aggress.net wrote: Hi, My iSCSI target is broken and I need to disable open-iscsi from starting up as it sits in a loop trying to connect without timing out. Are you sure it does not timeout? The default timeout is long, but it should timeout eventually.

Re: [PATCH v2 2/3] ISCSID: Added the extraction of the session boot info

2012-11-02 Thread Eddie Wai
On Thu, 2012-11-01 at 19:57 -0500, Mike Christie wrote: On 10/24/2012 06:30 PM, Eddie Wai wrote: + + /* Extract boot info */ + strlcpy(boot_content, boot_initiator, sizeof(boot_content)); + if (sysfs_get_str(session, ISCSI_SESSION_SUBSYS, +

Re: Automatic deleting of LUNs possible?

2012-11-02 Thread Amit
Michael Christie michaelc@... writes: On Oct 30, 2012, at 7:31 PM, amit.uttam@... wrote: [snip] scsi_sz=`sg_readcap /dev/sdko | grep address | sed s'/.*blocks=//'` kernel_sz=`cat /sys/block/sdko/device/block\:sdko/size` if (($scsi_sz==$kernel_sz)); then echo Good. else

Re: Automatic deleting of LUNs possible?

2012-11-02 Thread Boaz Harrosh
On 10/31/2012 10:32 PM, Michael Christie wrote: On Oct 30, 2012, at 7:31 PM, amit.ut...@gmail.com wrote: I apologize if this has been asked in the list before, I did some research but did not find a clear answer/recommendation. Currently, I use udev to monitor new devices added by the

Re: Automatic deleting of LUNs possible?

2012-11-02 Thread Mike Christie
On 11/02/2012 02:20 PM, Boaz Harrosh wrote: On 10/31/2012 10:32 PM, Michael Christie wrote: On Oct 30, 2012, at 7:31 PM, amit.ut...@gmail.com wrote: I apologize if this has been asked in the list before, I did some research but did not find a clear answer/recommendation. Currently, I use

Re: Automatic deleting of LUNs possible?

2012-11-02 Thread Mike Christie
On 11/02/2012 01:52 PM, Amit wrote: Michael Christie michaelc@... writes: On Oct 30, 2012, at 7:31 PM, amit.uttam@... wrote: [snip] scsi_sz=`sg_readcap /dev/sdko | grep address | sed s'/.*blocks=//'` kernel_sz=`cat /sys/block/sdko/device/block\:sdko/size` if

Timeout settings not working?

2012-11-02 Thread Ian Pilcher
I am trying to set up a purely virtual dm-multipath demo environment with Open-iSCSI and tgtd. tgtd is running on a Fedora 17 host, on which I have also created two Open vSwitch bridges to serve as storage networks. The guest is RHEL 6.3 (kernel-2.6.32-279.11.1.el6.x86_64 and

Re: Timeout settings not working?

2012-11-02 Thread Mike Christie
On 11/02/2012 03:20 PM, Ian Pilcher wrote: I am trying to set up a purely virtual dm-multipath demo environment with Open-iSCSI and tgtd. tgtd is running on a Fedora 17 host, on which I have also created two Open vSwitch bridges to serve as storage networks. The guest is RHEL 6.3

Re: Timeout settings not working?

2012-11-02 Thread Ian Pilcher
On 11/02/2012 03:36 PM, Mike Christie wrote: Run iscsiadm -m node -T yourtarget -p ip to see the per portal value being used. The iscsid.conf values are used when we create new portal/node records. If you want to update a setting on a existing record either rediscover the target (this

Re: Automatic deleting of LUNs possible?

2012-11-02 Thread Boaz Harrosh
On 11/02/2012 12:47 PM, Mike Christie wrote: Yeah, I updated the iscsi dev loss tmo patch and posted it to the list. I think I hit some bugs with lots of sessions and lots of removals at the same time due to some workqueue/threading stuff or scsi locking issues. I did not get a chance to look