All of lore.kernel.org
 help / color / mirror / Atom feed
From: Patrick Mansfield <patmans@us.ibm.com>
To: linux-scsi@vger.kernel.org,
	James Bottomley <James.Bottomley@steeleye.com>
Subject: and some example usage of the attributes
Date: Wed, 9 Jul 2003 13:29:12 -0700	[thread overview]
Message-ID: <20030709132912.A7393@beaverton.ibm.com> (raw)
In-Reply-To: <20030709132757.A7360@beaverton.ibm.com>; from patmans@us.ibm.com on Wed, Jul 09, 2003 at 01:27:57PM -0700

Some example uses of the delete and scan attribute.

[root@elm3b79 root]# ls -l /sysfs/class/scsi_host/host2
total 0
-r--r--r--    1 root     root         4096 Jul  9 12:30 cmd_per_lun
--w-------    1 root     root            0 Jul  9 12:34 delete
lrwxrwxrwx    1 root     root           46 Jul  9 12:30 device -> ../../../devices/pci0000:01/0000:01:0c.0/host2
-r--r--r--    1 root     root         4096 Jul  9 12:30 host_busy
--w-------    1 root     root            0 Jul  9 12:36 scan
-r--r--r--    1 root     root         4096 Jul  9 12:30 sg_tablesize
-r--r--r--    1 root     root         4096 Jul  9 12:30 unchecked_isa_dma
-r--r--r--    1 root     root         4096 Jul  9 12:30 unique_id

[root@elm3b79 root]# ls /sysfs/class/scsi_host/host2/device
2:0:0:0   2:0:0:14  2:0:0:2   2:0:0:25  2:0:0:30  2:0:0:8   2:0:4:0  name
2:0:0:1   2:0:0:15  2:0:0:20  2:0:0:26  2:0:0:31  2:0:0:9   2:0:5:0  power
2:0:0:10  2:0:0:16  2:0:0:21  2:0:0:27  2:0:0:4   2:0:1:0   2:0:6:0
2:0:0:11  2:0:0:17  2:0:0:22  2:0:0:28  2:0:0:5   2:0:10:0  2:0:7:0
2:0:0:12  2:0:0:18  2:0:0:23  2:0:0:29  2:0:0:6   2:0:2:0   2:0:8:0
2:0:0:13  2:0:0:19  2:0:0:24  2:0:0:3   2:0:0:7   2:0:3:0   2:0:9:0

# Delete some devices

[root@elm3b79 root]# echo "0 9 0" > /root/xx; dd if=/root/xx of=/sysfs/class/scsi_host/host2/delete 
0+1 records in
0+1 records out
[root@elm3b79 root]# echo "0 0 0" > /root/xx; dd if=/root/xx of=/sysfs/class/scsi_host/host2/delete 
0+1 records in
0+1 records out
[root@elm3b79 root]# echo "0 0 22" > /root/xx; dd if=/root/xx of=/sysfs/class/scsi_host/host2/delete 
0+1 records in
0+1 records out

# Scan a target - for this target REPORT LUN is used

[root@elm3b79 root]# echo "0 0 -" > /root/xx; dd if=/root/xx of=/sysfs/class/scsi_host/host2/scan
0+1 records in
0+1 records out

# Scan the entire host

[root@elm3b79 root]# echo "- - -" > /root/xx; dd if=/root/xx of=/sysfs/class/scsi_host/host2/scan
0+1 records in
0+1 records out

-- Patrick Mansfield

      reply	other threads:[~2003-07-09 20:15 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-07-08 20:40 [PATCH] add sysfs attributes to scan and delete scsi_devices Patrick Mansfield
2003-07-08 20:41 ` examples using " Patrick Mansfield
2003-07-08 20:47 ` [PATCH] add " Christoph Hellwig
2003-07-08 22:36   ` Patrick Mansfield
2003-07-08 20:50 ` James Bottomley
2003-07-08 21:13   ` Christoph Hellwig
2003-07-08 22:24     ` Patrick Mansfield
2003-07-13 13:43       ` Christoph Hellwig
2003-07-09 20:27 ` [PATCH] take 2 " Patrick Mansfield
2003-07-09 20:29   ` Patrick Mansfield [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20030709132912.A7393@beaverton.ibm.com \
    --to=patmans@us.ibm.com \
    --cc=James.Bottomley@steeleye.com \
    --cc=linux-scsi@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.