From 1d56a043033a63c99ca65d75ae009733fff350d8 Mon Sep 17 00:00:00 2001 From: jbjohnso Date: Wed, 26 Mar 2008 13:17:16 +0000 Subject: [PATCH] Fix off-by-one size error in iSCSI device setup. git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/trunk@893 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd --- xCAT-server-2.0/lib/xcat/plugins/iscsi.pm | 1 + 1 file changed, 1 insertion(+) diff --git a/xCAT-server-2.0/lib/xcat/plugins/iscsi.pm b/xCAT-server-2.0/lib/xcat/plugins/iscsi.pm index 563b47ef9..295cb25d5 100644 --- a/xCAT-server-2.0/lib/xcat/plugins/iscsi.pm +++ b/xCAT-server-2.0/lib/xcat/plugins/iscsi.pm @@ -109,6 +109,7 @@ sub process_request { $rsp{data}=["Creating $fileloc ($lunsize MB)"]; $callback->({node=>[\%rsp]}); %rsp=(name=>[$node]); + $lunsize -= 1; my $rc = system("dd if=/dev/zero of=$fileloc bs=1M count=1 seek=$lunsize"); if ($rc) { $rsp{error}=["dd process exited with return code $rc"];