Ultrabay use with an advanced dock (T61).
-
newyorkpaulie
- Sophomore Member
- Posts: 202
- Joined: Fri Sep 29, 2006 6:49 am
- Location: new york (duhh)
Ultrabay use with an advanced dock (T61).
Can drives in the ultrabay drive slot in the advanced dock be safely removed/inserted while the machine is running? I was not able to do this with my T30 so I'm hesitant to try this without first checking here.
-
Cigarguy
- ThinkPadder

- Posts: 1435
- Joined: Thu Aug 09, 2012 3:08 pm
- Location: Calgary, Alberta, Canada
Re: Ultrabay use with an advanced dock (T61).
A T61, being PATA at the Ultrabay interface, hot swapping is a no no. It's OK to do this on most SATA interface but I would not recommend it on PATA.
-
newyorkpaulie
- Sophomore Member
- Posts: 202
- Joined: Fri Sep 29, 2006 6:49 am
- Location: new york (duhh)
Re: Ultrabay use with an advanced dock (T61).
But my ultrabay devices take SATA drives. Does that mean it's OK to swap?Cigarguy wrote:A T61, being PATA at the Ultrabay interface, hot swapping is a no no. It's OK to do this on most SATA interface but I would not recommend it on PATA.
-
Cigarguy
- ThinkPadder

- Posts: 1435
- Joined: Thu Aug 09, 2012 3:08 pm
- Location: Calgary, Alberta, Canada
Re: Ultrabay use with an advanced dock (T61).
Yes the Ultrabay adapter takes SATA drives, but the Ultrabay adapter hooks up to the computer via a PATA to SATA adapter. So natively it is a PATA connection. You can try it for youself. Take it out with the machine on. Your T61 will whine at you and will not recognize any device in there until you restart.
-
newyorkpaulie
- Sophomore Member
- Posts: 202
- Joined: Fri Sep 29, 2006 6:49 am
- Location: new york (duhh)
Re: Ultrabay use with an advanced dock (T61).
Well I didn't get the whine, but you're right about its not seeing the swapped drive. Thanks.Cigarguy wrote:Yes the Ultrabay adapter takes SATA drives, but the Ultrabay adapter hooks up to the computer via a PATA to SATA adapter. So natively it is a PATA connection. You can try it for youself. Take it out with the machine on. Your T61 will whine at you and will not recognize any device in there until you restart.
-
jcvjcvjcvjcv
- Senior Member

- Posts: 722
- Joined: Tue Jun 26, 2007 8:42 pm
- Location: Amsterdam, The Netherlands
Re: Ultrabay use with an advanced dock (T61).
I can remove and insert the optical drive of my T61 as often as I like and it will always get recognized without reboot. Can't speak for the HDD in Ultrabay adapters though. Only have one optical drive and one ultrabay battery.
W520
T61
T61
Re: Ultrabay use with an advanced dock (T61).
I'm also curious as to why it would be problematic via the dock, when it works without issues with the ultrabay on the laptop itself (which is also PATA).
Maybe the problem is with hard drives? I only really tried it with opticals/floppies.
Maybe the problem is with hard drives? I only really tried it with opticals/floppies.
Current: X220 4291-4BG, T410 2537-R46, T60 1952-F76, T60 2007-QPG, T42 2373-F7G
Collectibles: T430s (IPS FHD + Classic Keyboard), X32 (IPS Screen)
Retired: X61 7673-V2V, A31p w/ Ultrabay Numpad
Past: Z61t 9440-A23, T60 2623-D3U, X32 2884-M5U
Collectibles: T430s (IPS FHD + Classic Keyboard), X32 (IPS Screen)
Retired: X61 7673-V2V, A31p w/ Ultrabay Numpad
Past: Z61t 9440-A23, T60 2623-D3U, X32 2884-M5U
-
Cigarguy
- ThinkPadder

- Posts: 1435
- Joined: Thu Aug 09, 2012 3:08 pm
- Location: Calgary, Alberta, Canada
Re: Ultrabay use with an advanced dock (T61).
I use 3 Ultrabay adapter with a HDD in my T61s. The few times that I disconnect and reconnect the Ultrabay adapter it did not like it and would not recognize it until I reset the system. Sounds like it varies depending on device. Best way to know is to try it on your machine and see what happens.
Re: Ultrabay use with an advanced dock (T61).
If Windows doesn’t detect the Ultrabay HDD when it’s reinserted you can use the Rescan button in Device Manager to reinstall the drive – saves rebooting.
X301 -- X201s -- X2faux1s -- X201 -- x230 -- T61 -- T60p -- T42p
-
newyorkpaulie
- Sophomore Member
- Posts: 202
- Joined: Fri Sep 29, 2006 6:49 am
- Location: new york (duhh)
Re: Ultrabay use with an advanced dock (T61).
Do you know of a way to duplicate this with Linux? (not a Windows fan)91011 wrote:If Windows doesn’t detect the Ultrabay HDD when it’s reinserted you can use the Rescan button in Device Manager to reinstall the drive – saves rebooting.
Re: Ultrabay use with an advanced dock (T61).
See thinkwiki.org/wiki/How_to_hotswap_Ultrabay_devices for details and also thinkwiki.org/wiki/Talk:How_to_hotswap_Ultrabay_devices for further discussion about that topic.newyorkpaulie wrote:Do you know of a way to duplicate this with Linux? (not a Windows fan)
I actually had the ultrabay_eject script from this site working in Debian on various T61's and actually could hotswap HDD's this way.
With most recent kernels (3.7 and 3.8, maybe even 3.6) this doesn't appear to be working for me anymore, even after having updated the DEVPATH to the recenty changed value, as explained in the script's comment section.
Still investigating what is failing here.
Broken T23 2647-9RG | A few 14.1" T61 Frankenpads | Two 15" Frankenpad T61+ with UXGA IPS Display
Re: Ultrabay use with an advanced dock (T61).
I always do hot-swapping on my ultrabay when my T61 is running ...
Well I guess because I activate the AHCI mode ...
tested on my T61, when I put 7200 rpm HDD or SSD inside the ultrabay (with 2504 dock ) ...
works fine on winXP x86 and Win7 x64
I just select "eject" and then the pop-up message show up, telling me that it's now safe to remove the hardware (the ultrabay) ... and I can insert the optical drive back, and the system will recognized the optical drive ..
Well I guess because I activate the AHCI mode ...
tested on my T61, when I put 7200 rpm HDD or SSD inside the ultrabay (with 2504 dock ) ...
works fine on winXP x86 and Win7 x64
I just select "eject" and then the pop-up message show up, telling me that it's now safe to remove the hardware (the ultrabay) ... and I can insert the optical drive back, and the system will recognized the optical drive ..
Hello world.
-
newyorkpaulie
- Sophomore Member
- Posts: 202
- Joined: Fri Sep 29, 2006 6:49 am
- Location: new york (duhh)
[SOLVED] Re: Ultrabay use with an advanced dock (T61).
The answer then is to first "unmount" (Linux) or "safely remove" (Windows) the drive in the docking station's Ultrabay slot. Since I did not (really) have to do this with the bay in the PC itself I had the wrong idea that this step wasn't necessary when swapping out Ultrabays in the Dock.aoitenshi wrote:I always do hot-swapping on my ultrabay when my T61 is running ...
Well I guess because I activate the AHCI mode ...
tested on my T61, when I put 7200 rpm HDD or SSD inside the ultrabay (with 2504 dock ) ...
works fine on winXP x86 and Win7 x64
I just select "eject" and then the pop-up message show up, telling me that it's now safe to remove the hardware (the ultrabay) ... and I can insert the optical drive back, and the system will recognized the optical drive ..
Re: Ultrabay use with an advanced dock (T61).
Investigation complete, and here is my solution for Debian Linux on a T61, based on the information and scripts found in the aforementioned Thinkwiki resource at thinkwiki.org/wiki/How_to_hotswap_Ultrabay_devices#Script_for_Ultrabay_eject:
Save as "/etc/udev/rules.d/50-thinkpad-ultrabay.rules":
Save as "/usr/local/sbin/ultrabay_eject":
Save as "/usr/local/sbin/ultrabay_insert":
Should (hopefully) work out of the box on at least a T61. Works for me so far. Please try it out and correct my silly errors.
Hope this helps, so enjoy!
EDIT: For those who can read German, an article about this topic is now available at the German language Thinkwiki at thinkwiki.de/Linux_UltraBay_Hotswap.
Save as "/etc/udev/rules.d/50-thinkpad-ultrabay.rules":
Code: Select all
# Change the DEVPATH variable to match your system, if it doesn't match your ThinkPad model
# The DEVPATH value used here should hopefully be working out of the box on any T6x ThinkPad.
# To find the correct value for your ThinkPad, insert the UltraBay optical drive and execute:
# udevadm info --query=path --name=/dev/sr0 | perl -pe 's!/block/...$!!'
SUBSYSTEMS=="block", DEVPATH=="/devices/pci0000:00/0000:00:1f.1/ata4/host3/*", ENV{UDISKS_SYSTEM_INTERNAL}="0"
ENV{EVENT}=="undock", KERNEL=="dock.1", ACTION=="change", SUBSYSTEM=="platform", RUN+="/usr/local/sbin/ultrabay_eject"
ENV{EVENT}=="dock", KERNEL=="dock.1", ACTION=="change", SUBSYSTEM=="platform", RUN+="/usr/local/sbin/ultrabay_insert"
Code: Select all
#!/bin/bash
#set -x
# Sources:
# http://www.thinkwiki.org/wiki/How_to_hotswap_Ultrabay_devices#Script_for_Ultrabay_eject
# http://www.thinkwiki.org/wiki/Talk:How_to_hotswap_Ultrabay_devices
SCRIPTNAME="$(basename $0)"
# Change the DEVPATH variable to match your system, if it doesn't match your ThinkPad model
# The DEVPATH value used here should hopefully be working out of the box on any T6x ThinkPad.
# To find the correct value for your ThinkPad, insert the UltraBay optical drive and execute:
# udevadm info --query=path --name=/dev/sr0 | perl -pe 's!/block/...$!!'
if [ "$DEVPATH" = "" ]
then
DEVPATH="/devices/pci0000:00/0000:00:1f.1/ata4/host3/target3:0:0/3:0:0:0"
fi
shopt -s nullglob
export DISPLAY=:0.0 # required for notify-send
DISP0_USER=$(who | grep "tty" | awk '{ print $1 }')
DISP0_USER_HOME=`getent passwd ${DISP0_USER} | cut -d':' -f6`
export XAUTHORITY=${DISP0_USER_HOME}/.Xauthority # also required for notify-send
ULTRABAY_SYSDIR=/sys$DEVPATH
# Find generic dock interface for UltraBay
dock=$(dirname $(/bin/grep -l ata_bay /sys/devices/platform/dock.?/type))
if [ ! -n "$dock" -a -d "$dock" ]; then
logger "$SCRIPTNAME": cannot locate bay dock device
notify-send -u critical -t 100000 "ThinkPad Ultrabay eject failed" "Cannot locate bay dock device"
exit 1
fi
# Umount the filesystem(s) backed by the given major:minor device(s)
unmount_rdev() { perl - "$@" <<'EOPERL' # let's do it in Perl
for $major_minor (@ARGV) {
$major_minor =~ m/^(\d+):(\d+)$/ or die;
push(@tgt_rdevs, ($1<<8)|$2);
}
# Sort by reverse length of mount point, to unmount sub-directories first
open MOUNTS,"</proc/mounts" or die "$!";
@mounts=sort { length($b->[1]) <=> length($a->[1]) } map { [ split ] } <MOUNTS>;
close MOUNTS;
foreach $m (@mounts) {
($dev,$dir)=@$m;
next unless -b $dev; $rdev=(stat($dev))[6];
next unless grep($_==$rdev, @tgt_rdevs);
system("umount","-v","$dir")==0 or $bad=1;
if ($bad == 1) {
system("logger","ultrabay_eject","ERROR unmounting",$dev,$dir);
system("notify-send -u critical -t 100000 \"Error unmounting $dir\" \"Unmounting of $dir on $dev failed!\"");
} else {
system("logger","ultrabay_eject","unmounted",$dev,$dir);
system("notify-send -u normal -t 5000 \"Unmounted $dir\"");
};
}
exit 1 if $bad;
EOPERL
}
# Get the UltraBay's /dev/foo block device node
ultrabay_dev_node() {
UDEV_PATH="`readlink -e "$ULTRABAY_SYSDIR/block/"*`" || return 1
UDEV_NAME="`udevadm info --query=name --path=$UDEV_PATH`" || return 1
echo /dev/$UDEV_NAME
}
if [ $( cat $dock/docked ) == 0 ]; then
logger "$SCRIPTNAME": dock reports empty
else
if [ -d $ULTRABAY_SYSDIR ]; then
logger "$SCRIPTNAME": dock occupied, shutting down storage device $DEVPATH
sync
# Unmount filesystems backed by this device
## This seems to be very inelegant and prone to failure
unmount_rdev `cat $ULTRABAY_SYSDIR/block/*/dev \
$ULTRABAY_SYSDIR/block/*/*/dev` \
|| {
logger "$SCRIPTNAME": umounting failed
notify-send -u critical -t 100000 "ThinkPad Ultrabay eject failed" "Please do not pull the device, doing so could cause file corruption and possibly hang the system. Unmounting of the filesystem on the ThinkPad Ultrabay device failed. Please put the eject leaver back in place, and try to unmount the filesystem manually. If this succeeds you can try the eject again"
exit 1;
}
sync
# Nicely power off the device
DEVNODE=`ultrabay_dev_node` && hdparm -Y $DEVNODE
# Let HAL+KDE notice the unmount and let the disk spin down
sleep 0.5
# Unregister this SCSI device:
sync
echo 1 > $ULTRABAY_SYSDIR/delete
else
logger "$SCRIPTNAME": bay occupied but incorrect device path $DEVPATH
notify-send -u critical -t 100000 "ThinkPad Ultrabay eject failed" "Bay occupied but incorrect device path"
exit 1
fi
fi
# We need to sleep here to wait for the bay and the drive to disconnect
sleep 1
# Undocking the UltraBay:
logger "$SCRIPTNAME": undocking $dock
if [ "$(cat $dock/docked)" != "0" ]; then
echo 1 > $dock/undock
else
# Tell the user we're OK once done
logger "$SCRIPTNAME": successfully completed
notify-send -u normal -t 10000 "Safe to remove device" "The ThinkPad Ultrabay device can now be safely removed"
exit 0
fi
Code: Select all
#!/bin/bash
#set -x
# Source:
# http://www.thinkwiki.org/wiki/How_to_hotswap_Ultrabay_devices#Script_for_Ultrabay_eject
# http://www.thinkwiki.org/wiki/Talk:How_to_hotswap_Ultrabay_devices
SCRIPTNAME="$(basename $0)"
export DISPLAY=:0.0 # required for notify-send
DISP0_USER=$(who | grep "tty" | awk '{ print $1 }')
DISP0_USER_HOME=`getent passwd ${DISP0_USER} | cut -d':' -f6`
export XAUTHORITY=${DISP0_USER_HOME}/.Xauthority # also required for notify-send
# Change the DEVPATH variable to match your system, if it doesn't match your ThinkPad model
# The DEVPATH value used here should hopefully be working out of the box on any T6x ThinkPad.
# To find the correct value for your ThinkPad, insert the UltraBay optical drive and execute:
# udevadm info --query=path --name=/dev/sr0 | perl -pe 's!/block/...$!!'
if [ "$DEVPATH" = "" ]
then
DEVPATH="/devices/pci0000:00/0000:00:1f.1/ata4/host3/target3:0:0/3:0:0:0"
fi
ULTRABAY_SYSDIR=/sys$DEVPATH
# Get the UltraBay's /dev/foo block device node
ultrabay_dev_node() {
UDEV_PATH="`readlink -e "$ULTRABAY_SYSDIR/block/"*`" || return 1
UDEV_NAME="`udevadm info --query=name --path=$UDEV_PATH`" || return 1
echo /dev/$UDEV_NAME
}
DOCKDEVICE=$(lsscsi | grep $(ultrabay_dev_node) | tr -s " ")
# Find generic dock interface for UltraBay
dock=$(dirname $(/bin/grep -l ata_bay /sys/devices/platform/dock.?/type))
if [ ! -n "$dock" -a -d "$dock" ]; then
logger "$SCRIPTNAME": cannot locate bay dock device
notify-send -u critical -t 100000 "ThinkPad Ultrabay device docking failed" "Cannot locate bay dock device"
exit 1
fi
# Tell the user we're OK once done
if [ "$(cat $dock/docked)" = "1" ]; then
sync
logger "$SCRIPTNAME": Scanning ThinkPad Ultrabay for new device
echo 0 0 0 > /sys/class/scsi_host/host3/scan
logger "$SCRIPTNAME": Docking of ThinkPad Ultrabay device successfully completed.
notify-send -u normal -t 10000 "Docking ThinkPad Ultrabay device completed" "The ThinkPad Ultrabay device is now available for use."
exit 0
else
logger "$SCRIPTNAME": ThinkPad Ultrabay device docking failed
notify-send -u normal -t 10000 "Docking ThinkPad Ultrabay device failed" "Docking the ThinkPad Ultrabay device failed. Please check what went wrong and fix it."
exit 1
fi
Hope this helps, so enjoy!
EDIT: For those who can read German, an article about this topic is now available at the German language Thinkwiki at thinkwiki.de/Linux_UltraBay_Hotswap.
Broken T23 2647-9RG | A few 14.1" T61 Frankenpads | Two 15" Frankenpad T61+ with UXGA IPS Display
Re: Ultrabay use with an advanced dock (T61).
Some great work there, it will be an asset to the community 
Re: Ultrabay use with an advanced dock (T61).
Well he isn't asking about swapping the ultrabay in his T61, rather hotswapping the ultrabay drive in the dock bay.Cigarguy wrote:A T61, being PATA at the Ultrabay interface, hot swapping is a no no. It's OK to do this on most SATA interface but I would not recommend it on PATA.
I own a T60 running linux, I can hotswap the ultrabay disk adapter in the laptop bay (it works as PATA though) and if I plug the disk adapter in the advanced dock, it it detected as USB Mass Storage device:
Code: Select all
[681428.942731] usb 1-6.1: Product: CY4611B V2.50RC16
[681428.942736] usb 1-6.1: Manufacturer: IBM
[681428.942742] usb 1-6.1: SerialNumber: 00000A517286
[681428.943307] usb-storage 1-6.1:1.0: USB Mass Storage device detected
[681428.949697] scsi16 : usb-storage 1-6.1:1.0Re: Ultrabay use with an advanced dock (T61).
Really! So the Ultrabay in the dock is connected via USB?ericvb69 wrote:Cigarguy wrote:if I plug the disk adapter in the advanced dock, it it detected as USB Mass Storage device:
Current: X220 4291-4BG, T410 2537-R46, T60 1952-F76, T60 2007-QPG, T42 2373-F7G
Collectibles: T430s (IPS FHD + Classic Keyboard), X32 (IPS Screen)
Retired: X61 7673-V2V, A31p w/ Ultrabay Numpad
Past: Z61t 9440-A23, T60 2623-D3U, X32 2884-M5U
Collectibles: T430s (IPS FHD + Classic Keyboard), X32 (IPS Screen)
Retired: X61 7673-V2V, A31p w/ Ultrabay Numpad
Past: Z61t 9440-A23, T60 2623-D3U, X32 2884-M5U
-
- Similar Topics
- Replies
- Views
- Last post
-
-
Can I use an Intel Centrino Advanced-N 6205 wifi card in my T60?
by Muse » Wed Mar 15, 2017 2:22 pm » in ThinkPad T6x Series - 1 Replies
- 1575 Views
-
Last post by axur-delmeria
Fri Mar 17, 2017 2:12 am
-
-
-
Does the T60 use the same screws as the T61?
by thinkpac » Sat Apr 08, 2017 8:05 pm » in ThinkPad T6x Series - 2 Replies
- 744 Views
-
Last post by RealBlackStuff
Sat Apr 08, 2017 9:05 pm
-
-
-
How to build an advanced FrankenPad
by ThinkDan2004 » Sun Jun 04, 2017 7:30 am » in ThinkPad T6x Series - 14 Replies
- 699 Views
-
Last post by ThinkDan2004
Fri Jun 23, 2017 3:06 pm
-
-
- 2 Replies
- 1775 Views
-
Last post by blue42
Fri Dec 30, 2016 2:51 pm
Who is online
Users browsing this forum: No registered users and 11 guests





