From owner-freebsd-scsi Wed Jul 4 22:15:15 2001 Delivered-To: freebsd-scsi@freebsd.org Received: from beppo.feral.com (beppo.feral.com [192.67.166.79]) by hub.freebsd.org (Postfix) with ESMTP id EB31037B401 for ; Wed, 4 Jul 2001 22:15:11 -0700 (PDT) (envelope-from mjacob@feral.com) Received: from beppo (mjacob@beppo [192.67.166.79]) by beppo.feral.com (8.11.3/8.11.3) with ESMTP id f655F6S26484; Wed, 4 Jul 2001 22:15:06 -0700 (PDT) (envelope-from mjacob@feral.com) Date: Wed, 4 Jul 2001 22:15:04 -0700 (PDT) From: Matthew Jacob X-Sender: mjacob@beppo Reply-To: mjacob@feral.com To: Xubin He Cc: scsi@freebsd.org Subject: Re: target mode usage quick primer In-Reply-To: <20010705034040.23800.qmail@web13007.mail.yahoo.com> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-scsi@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.org Go chdir to /dev and do the appropriate MAKEDEV magic? On Wed, 4 Jul 2001, Xubin He wrote: > Dear Matthew, > Thank you very much for your detail information.It is > really helpful. Now when I boot the target side > machine,I can see the message > "(targbh0:ahc0:0:-1:-1):Lun now enabled for target > mode", which means that the system has already been > set to target mode.But when I tried to run > ./scsi_target -p 0 -t 0 -l 3 to test the target mode, > I got an error message "/dev/targ.ctl:no such file or > directory."Do you have any idea about this error?Sorry > for bothering you again. Have a great holiday. > ---Ben > --- Matthew Jacob wrote: > > > > On Wed, 4 Jul 2001, Ben wrote: > > > > > This message was sent from Geocrawler.com by "Ben" > > > > > > > > > > > Dear Matthew, > > > I have connected two PCs running FreeBSD 4.3 > > > each with an adaptec 39160 adapter.These two > > > apaters are connected through a SCSI cable. One > > > of the SCSI ID is set to 6,the other is set to 7. > > > I am trying to make one machine running under > > > target mode. What I did is to change > > > AHC_TMODE_ENABLE to 1 and rebuild the > > > kernel.After I reboot these two systems,nothing > > > is new. Could you point out how I shold test the > > > target mode?Thank you very much. > > > Ben > > > > You need the drivers > > > > device scsi_target > > device scsi_targ_bh > > > > in your kernel as well as enabling target mode > > support in either the > > Adaptec driver or the the QLogic driver. Note that > > while the QLogic > > driver supports simultaneous initiator/target mode > > operation, the last > > I checked, the Adaptec doesn't, so for your h/w, you > > have to have the > > initiator side *not* have AHC_TMODE_ENABLE on. You > > might probably want > > to put > > > > device pt > > > > in the initiator side. > > > > Once you boot the target mode side, you'll eee > > wildcard enabling > > via the targbh driver so that commands to > > non-existent luns have > > somebody to actually respond. > > > > Then go off and compile > > /usr/share/examples/scsi_target/scsi_target.c > > and enable a lun for real. > > > > Then boot the initiator side or camcontrol rescan > > the initiator side. > > > > -matt > > > > > > > __________________________________________________ > Do You Yahoo!? > Get personalized email addresses from Yahoo! Mail > http://personal.mail.yahoo.com/ > To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-scsi" in the body of the message