All of lore.kernel.org
 help / color / mirror / Atom feed
* IDE Hot-Swap, does it work?
@ 2001-10-11 20:10 Mike Panetta
  2001-10-12 20:28 ` IDE Hot-Swap, does it work?, Conspiracy is afoot! Mike Panetta
  0 siblings, 1 reply; 6+ messages in thread
From: Mike Panetta @ 2001-10-11 20:10 UTC (permalink / raw)
  To: linux-kernel

Is IDE Hot-Swap supported in any fashion in
linux?  If so what are the recommended controllers
and enclosures to use?  Are there any standards
for IDE enclosures like there are for SCSI (SAF-TE
SES)?  

In addition, I have noticed that there is an
hdparm command that will allow me to rescan
an interface, but I cannot get it to do anything
other than lock my machine up with the promise
card I have.  Anyone have insight into this?

Thanks,
Mike


-- 

----- End forwarded message -----

-- 

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: IDE Hot-Swap, does it work?, Conspiracy is afoot!
  2001-10-11 20:10 IDE Hot-Swap, does it work? Mike Panetta
@ 2001-10-12 20:28 ` Mike Panetta
  2001-10-12 21:29   ` Wakko Warner
  0 siblings, 1 reply; 6+ messages in thread
From: Mike Panetta @ 2001-10-12 20:28 UTC (permalink / raw)
  To: linux-kernel; +Cc: andre

Ok, I have played with this a bit since I have recieved no
real respose other than one other person having the same
question, here is what I have found out...

I have a piece of hardware that does have hot-swap IDE
chassis on it, so atleast the IDE bus xcvers should be
able to handle the swapping, as the connection to the
drive is disabled before the can comes all the way out
of the slot.

 - I can remove a drive while the system is on and I have
   a software raid 5 on the 4 drives, everything is ok
   after about 2 minutes the system recovers and the software
   raid fails the drive I removed.  This makes sense.
 - After a few minutes I replace the drive I had just failed
   by removing it, and I try to readd it to the system via
   raidhotadd.  One of 2 things happens in this instance,
   depending on what kernel I have loaded.  
    - If I have kernel 2.4.2-2 loaded (a stock redhat 7.1
      kernel), the drive reappears, and can be added back
      to the raid (and is added back).
    - If I am running kernel 2.4.10 or any later (AC or non)
      the machine fails to ever be able to read from the disk
      again.  I cannot readd the disk to the arry, nor can I
      fdisk it (or access it in any other way).
 - None of this solves the adding of a drive to the system
   where there was none before boot...  I tried the hdparm -R
   stuff but its useless and hangs my box no matter what I give
   it as paramaters.  This of course may be because I do not
   know how to use it very well...

If anyone can help it would be greatly appreciated.  I am
really beginning to believe that IDE will never be as capable
as SCSI in this reguard, atleast not in linux, espically as
any (even if it was broken) support that used to be in the
kernel has disappeared. Please someone convince me otherwise!
Atleast point me in the correct direction as to what in the
kernel would have to be changed to make this work...

Thanks,
Mike

-- 

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: IDE Hot-Swap, does it work?, Conspiracy is afoot!
  2001-10-12 20:28 ` IDE Hot-Swap, does it work?, Conspiracy is afoot! Mike Panetta
@ 2001-10-12 21:29   ` Wakko Warner
  2001-10-12 22:14     ` IDE Hot-Swap, does it work?, Conspiracy is afoot! (more questions) Pozsar Balazs
  0 siblings, 1 reply; 6+ messages in thread
From: Wakko Warner @ 2001-10-12 21:29 UTC (permalink / raw)
  To: Mike Panetta, linux-kernel, andre

I've done this with my IDE cdrom in my laptop.  It's hot swappable and I
asked about this at one time.  In the source package for hdparm (i know it's
in the debian's source package) there's a script for hot add/remove of ide
devices.  there's a nice warning attached about ide hotswap

> Ok, I have played with this a bit since I have recieved no
> real respose other than one other person having the same
> question, here is what I have found out...
> 
> I have a piece of hardware that does have hot-swap IDE
> chassis on it, so atleast the IDE bus xcvers should be
> able to handle the swapping, as the connection to the
> drive is disabled before the can comes all the way out
> of the slot.
> 
>  - I can remove a drive while the system is on and I have
>    a software raid 5 on the 4 drives, everything is ok
>    after about 2 minutes the system recovers and the software
>    raid fails the drive I removed.  This makes sense.
>  - After a few minutes I replace the drive I had just failed
>    by removing it, and I try to readd it to the system via
>    raidhotadd.  One of 2 things happens in this instance,
>    depending on what kernel I have loaded.  
>     - If I have kernel 2.4.2-2 loaded (a stock redhat 7.1
>       kernel), the drive reappears, and can be added back
>       to the raid (and is added back).
>     - If I am running kernel 2.4.10 or any later (AC or non)
>       the machine fails to ever be able to read from the disk
>       again.  I cannot readd the disk to the arry, nor can I
>       fdisk it (or access it in any other way).
>  - None of this solves the adding of a drive to the system
>    where there was none before boot...  I tried the hdparm -R
>    stuff but its useless and hangs my box no matter what I give
>    it as paramaters.  This of course may be because I do not
>    know how to use it very well...
> 
> If anyone can help it would be greatly appreciated.  I am
> really beginning to believe that IDE will never be as capable
> as SCSI in this reguard, atleast not in linux, espically as
> any (even if it was broken) support that used to be in the
> kernel has disappeared. Please someone convince me otherwise!
> Atleast point me in the correct direction as to what in the
> kernel would have to be changed to make this work...
> 
> Thanks,
> Mike
> 
> -- 
> -
> To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
> Please read the FAQ at  http://www.tux.org/lkml/
-- 
 Lab tests show that use of micro$oft causes cancer in lab animals

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: IDE Hot-Swap, does it work?, Conspiracy is afoot! (more questions)
  2001-10-12 21:29   ` Wakko Warner
@ 2001-10-12 22:14     ` Pozsar Balazs
  2001-10-12 22:28       ` Mike Panetta
  2001-10-13  2:28       ` Wakko Warner
  0 siblings, 2 replies; 6+ messages in thread
From: Pozsar Balazs @ 2001-10-12 22:14 UTC (permalink / raw)
  To: Wakko Warner; +Cc: Mike Panetta, linux-kernel, andre


I've been too asked this question two times in the list, and i haven't
received any useful answer.

Wakko, could you tell me in detail how to use hdparm -R and -U, because i
couldn't get it work. Does it (or shoudl it) work for harddisks too?

What chipset/hardware supports ide-hot-swap, and which of these are
supported in linux?
Under The Other Operating System 2000 i have seen this working on a few
machines for example on an asus cusl2 mobo, so that chipset (i think
intel 815e) at least can got to do this job.

Please someone with more knowledge enlighten me, beaces i really hate
rebooting just to remove or add a harddisk.

On Fri, 12 Oct 2001, Wakko Warner wrote:

> I've done this with my IDE cdrom in my laptop.  It's hot swappable and I
> asked about this at one time.  In the source package for hdparm (i know it's
> in the debian's source package) there's a script for hot add/remove of ide
> devices.  there's a nice warning attached about ide hotswap
>
> > Ok, I have played with this a bit since I have recieved no
> > real respose other than one other person having the same
> > question, here is what I have found out...
> >
> > I have a piece of hardware that does have hot-swap IDE
> > chassis on it, so atleast the IDE bus xcvers should be
> > able to handle the swapping, as the connection to the
> > drive is disabled before the can comes all the way out
> > of the slot.
> >
> >  - I can remove a drive while the system is on and I have
> >    a software raid 5 on the 4 drives, everything is ok
> >    after about 2 minutes the system recovers and the software
> >    raid fails the drive I removed.  This makes sense.
> >  - After a few minutes I replace the drive I had just failed
> >    by removing it, and I try to readd it to the system via
> >    raidhotadd.  One of 2 things happens in this instance,
> >    depending on what kernel I have loaded.
> >     - If I have kernel 2.4.2-2 loaded (a stock redhat 7.1
> >       kernel), the drive reappears, and can be added back
> >       to the raid (and is added back).
> >     - If I am running kernel 2.4.10 or any later (AC or non)
> >       the machine fails to ever be able to read from the disk
> >       again.  I cannot readd the disk to the arry, nor can I
> >       fdisk it (or access it in any other way).
> >  - None of this solves the adding of a drive to the system
> >    where there was none before boot...  I tried the hdparm -R
> >    stuff but its useless and hangs my box no matter what I give
> >    it as paramaters.  This of course may be because I do not
> >    know how to use it very well...
> >
> > If anyone can help it would be greatly appreciated.  I am
> > really beginning to believe that IDE will never be as capable
> > as SCSI in this reguard, atleast not in linux, espically as
> > any (even if it was broken) support that used to be in the
> > kernel has disappeared. Please someone convince me otherwise!
> > Atleast point me in the correct direction as to what in the
> > kernel would have to be changed to make this work...
> >
> > Thanks,
> > Mike
> >
> > --
> > -
> > To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
> > the body of a message to majordomo@vger.kernel.org
> > More majordomo info at  http://vger.kernel.org/majordomo-info.html
> > Please read the FAQ at  http://www.tux.org/lkml/
> --
>  Lab tests show that use of micro$oft causes cancer in lab animals
> -
> To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
> Please read the FAQ at  http://www.tux.org/lkml/
>

-- 
Pozsar Balazs.


^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: IDE Hot-Swap, does it work?, Conspiracy is afoot! (more questions)
  2001-10-12 22:14     ` IDE Hot-Swap, does it work?, Conspiracy is afoot! (more questions) Pozsar Balazs
@ 2001-10-12 22:28       ` Mike Panetta
  2001-10-13  2:28       ` Wakko Warner
  1 sibling, 0 replies; 6+ messages in thread
From: Mike Panetta @ 2001-10-12 22:28 UTC (permalink / raw)
  To: Pozsar Balazs; +Cc: Wakko Warner, Mike Panetta, linux-kernel, andre

On Sat, Oct 13, 2001 at 12:14:01AM +0200, Pozsar Balazs wrote:
> 
> I've been too asked this question two times in the list, and i haven't
> received any useful answer.
> 
> Wakko, could you tell me in detail how to use hdparm -R and -U, because i
> couldn't get it work. Does it (or shoudl it) work for harddisks too?
> 

I have been using this basic command form, but I think it may be
incorrect:

    hdparm -R [io addr ix hex] 0|[ctrl addr in hex] 0|[irq] /dev/hd?

if this is the wrong way to do it please tell me.

I am wondering how hard it would be to change the ioctl so
that it accepts an index, or nothing (it just scans) instead
of requiring the (sometimes hard to find) IO addres and such.
I know that the lagacy IO addresses never change, but the
PCI ones can be anything.  Or maybe this just does not work
with PCI IDE cards at all?  I do not know.

Thanks,
Mike

-- 

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: IDE Hot-Swap, does it work?, Conspiracy is afoot! (more questions)
  2001-10-12 22:14     ` IDE Hot-Swap, does it work?, Conspiracy is afoot! (more questions) Pozsar Balazs
  2001-10-12 22:28       ` Mike Panetta
@ 2001-10-13  2:28       ` Wakko Warner
  1 sibling, 0 replies; 6+ messages in thread
From: Wakko Warner @ 2001-10-13  2:28 UTC (permalink / raw)
  To: Pozsar Balazs; +Cc: Mike Panetta, linux-kernel, andre

[-- Attachment #1: Type: text/plain, Size: 1212 bytes --]

Pozsar Balazs wrote:
> Wakko, could you tell me in detail how to use hdparm -R and -U, because i
> couldn't get it work. Does it (or shoudl it) work for harddisks too?

I'm not sure if it supports hdds or not, As far as I can see, it basically
rescans for the device you're doing.  I attach the contrib script (comes in
hdparm's source tree but not generally included

> What chipset/hardware supports ide-hot-swap, and which of these are
> supported in linux?
> Under The Other Operating System 2000 i have seen this working on a few
> machines for example on an asus cusl2 mobo, so that chipset (i think
> intel 815e) at least can got to do this job.

I think it would work on all ide chipsets, but i'm not sure.  I have hot
plugged IDE into standard systems and hdds not designed for it.  You do run
a risk of hardware damage which I has never happened for me (but could
happen to me next time I try or it could happen to you.  Be warned).  For
this, I've had a system who's / is not an ide disk (I have a machine
mounting / over nfs) and I load/unload ide modules.

I'd like to see support for this similar to /proc/scsi/scsi to rescan

-- 
 Lab tests show that use of micro$oft causes cancer in lab animals

[-- Attachment #2: idectl --]
[-- Type: text/plain, Size: 807 bytes --]

#!/bin/sh

HDPARM=/sbin/hdparm
MAX_IDE_NR=1

IDE_IO_0=0x1f0
IDE_IO_1=0x170

USE_IDE_DEV_0=/dev/hdc
USE_IDE_DEV_1=/dev/hda

usage () {
	if [ $# -gt 0 ]; then
		echo $* >&2
		echo
	fi

	echo "usage: $0 ide-channel-nr [off|on|rescan]" 2>&1
	exit 1
}

IDE_NR=$1
MODE=$2

do_register=0
do_unregister=0


if [ ! "$IDE_NR" ] || [ $IDE_NR -lt 0 ] || [ $IDE_NR -gt $MAX_IDE_NR ]; then
	usage "Unrecognized IDE-channel number"
fi

case "$MODE" in
on )		do_register=1 ;;
off )		do_unregister=1 ;;
rescan )	do_unregister=1; do_register=1 ;;
* )			usage "Unrecognized command" ;;
esac

eval "IDE_IO=\$IDE_IO_$IDE_NR"
eval "USE_IDE_DEV=\$USE_IDE_DEV_$IDE_NR"

[ $do_unregister -eq 1 ] && eval "$HDPARM -U $IDE_NR $USE_IDE_DEV > /dev/null"
[ $do_register -eq 1 ] && eval "$HDPARM -R $IDE_IO 0 0 $USE_IDE_DEV > /dev/null"


^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2001-10-13  2:21 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2001-10-11 20:10 IDE Hot-Swap, does it work? Mike Panetta
2001-10-12 20:28 ` IDE Hot-Swap, does it work?, Conspiracy is afoot! Mike Panetta
2001-10-12 21:29   ` Wakko Warner
2001-10-12 22:14     ` IDE Hot-Swap, does it work?, Conspiracy is afoot! (more questions) Pozsar Balazs
2001-10-12 22:28       ` Mike Panetta
2001-10-13  2:28       ` Wakko Warner

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.