From: John Robinson <john.robinson@anonymous.org.uk>
To: Leslie Rhorer <lrhorer@satx.rr.com>
Cc: 'Phil Turmel' <philip@turmel.org>, linux-raid@vger.kernel.org
Subject: Re: Determining which spindle is out of order
Date: Sun, 07 Nov 2010 21:22:20 +0000 [thread overview]
Message-ID: <4CD7188C.2000206@anonymous.org.uk> (raw)
In-Reply-To: <B9.A1.19545.A1017DC4@cdptpa-omtalb.mail.rr.com>
On 07/11/2010 20:46, Leslie Rhorer wrote:
[...]
>> I did another version, with regular expressions to accommodate the
>> variations. Please give it a shot.
>
> The regular expression doesn't work, here, but the rest of the
> script now works on the older server. I replaced the find statement with
>
> find /sys/devices/ -name "scsi_host*" |check_host
>
> and it works.
I also changed the find command again and it also works, with one nit,
which is probably just CentOS/RHEL being odd. See the following output:
# ~john/projects/lsdrv/lsdrv
Controller device @ pci0000:00/0000:00:1f.2 [ahci]
SATA controller: Intel Corporation 82801JI (ICH10 Family) SATA AHCI
Controller
host7: [Empty]
host6: [Empty]
host5: [Empty]
host4: /dev/sdc ATA ST31000528AS {SN: 9VP4XCQP}
host3: /dev/sdb ATA SAMSUNG HD103UJ {SN: S1PVJ1CQ602162 }
host2: /dev/sda ATA Hitachi HDS72101 {SN: JP2921HQ0J0PZA}
Controller device @ pci0000:00/0000:00:1e.0/0000:05:01.1 [aic7xxx]
SCSI storage controller: Adaptec AHA-3960D / AIC-7899A U160/m (rev 01)
host9: [Empty]
Controller device @ pci0000:00/0000:00:1e.0/0000:05:01.0 [aic7xxx]
SCSI storage controller: Adaptec AHA-3960D / AIC-7899A U160/m (rev 01)
host8: [Empty]
Controller device @ pci0000:00/0000:00:1c.4/0000:03:00.0 [pata_marvell]
IDE interface: Marvell Technology Group Ltd. 88SE6121 SATA II
Controller (rev b2)
host1: [Empty]
sginfo(open): No such file or directory
file=/dev/sr0, or no corresponding sg device found
Is sg driver loaded?
host0: /dev/sr0 HL-DT-ST DVD-RAM GH22NP20
The various links in sysfs refer to sr0 but I don't have a /dev/sr0, I
have /dev/scd0. I guess that's the udev rules Red Hat chose. Anyway, my
fix was to add 2>/dev/null into the sginfo command, which makes the
warning go away - sginfo -s /dev/scd0 gives me no serial anyway.
The only other improvement would be better formatting for controllers
with multiple devices, e.g. IDE interfaces, port multipliers and real
SCSI cards, which could have 2, 5 or 15 devices attached so displaying
the SCSI device ID could be helpful in those cases. It doesn't apply to
me but I thought of it when someone had both primary and slave devices
on their IDE controller, and someone else mentioned port multipliers.
Cheers,
John.
next prev parent reply other threads:[~2010-11-07 21:22 UTC|newest]
Thread overview: 39+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-11-03 14:13 Determining which spindle is out of order Nat Makarevitch
2010-11-03 14:38 ` Roman Mamedov
2010-11-03 15:17 ` Graham Mitchell
2010-11-03 16:05 ` Roman Mamedov
2010-11-03 19:00 ` Jon Hardcastle
2010-11-03 14:43 ` John Robinson
2010-11-03 14:45 ` Tim Small
2010-11-03 15:59 ` Jon Hardcastle
2010-11-03 17:17 ` Bill Davidsen
2010-11-03 20:03 ` Tim Small
2010-11-03 15:29 ` Mikael Abrahamsson
2010-11-03 21:54 ` Phil Turmel
2010-11-03 22:26 ` Roman Mamedov
2010-11-04 9:29 ` Tom Carlson
2010-11-06 10:22 ` Leslie Rhorer
2010-11-06 15:12 ` Phil Turmel
[not found] ` <4CD57867.4010207@anonymous.org.uk>
2010-11-06 16:02 ` Phil Turmel
2010-11-06 16:11 ` Mathias Burén
2010-11-06 16:45 ` Jan Ceuleers
2010-11-06 19:39 ` Phil Turmel
2010-11-06 20:16 ` Leslie Rhorer
2010-11-06 20:23 ` Mr. James W. Laferriere
2010-11-07 7:51 ` Jan Ceuleers
2010-11-07 12:53 ` John Robinson
2010-11-07 13:21 ` Phil Turmel
2010-11-07 13:43 ` John Robinson
2010-11-07 14:43 ` Phil Turmel
2010-11-07 15:04 ` Mathias Burén
2010-11-07 15:19 ` John Robinson
2010-11-07 18:39 ` Phil Turmel
2010-11-07 20:46 ` Leslie Rhorer
2010-11-07 21:22 ` John Robinson [this message]
2010-11-08 18:59 ` John Robinson
2010-11-07 21:24 ` Andreas Dröscher
2010-11-08 21:05 ` Mr. James W. Laferriere
2010-11-07 20:52 ` Roman Mamedov
2010-11-09 14:40 ` Phil Turmel
2010-11-06 19:58 ` Leslie Rhorer
2010-11-06 21:17 ` John Robinson
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=4CD7188C.2000206@anonymous.org.uk \
--to=john.robinson@anonymous.org.uk \
--cc=linux-raid@vger.kernel.org \
--cc=lrhorer@satx.rr.com \
--cc=philip@turmel.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).