Linux - HardwareThis forum is for Hardware issues.
Having trouble installing a piece of hardware? Want to know if that peripheral is compatible with Linux?
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
I am planning on replacing a server that one of its purposes is to archive some weekly backup data, which I currently copy to USB hard drives for permanent storage. I am looking to replace with a new server that supports Hot Swap SATA. Are there any issues if hot swapping a SATA drive like I was changing the USB drive (plug in, mke2fs, mount, copy data, umount, unplug)? I've used hot swap SATA in RAID 5 arrays before that worked good for redundancy, but that was below the OS level - obviously the new backup archive drive would not be part of the RAID array.
I have not done this, but I rather suspect you'll have a problem in that the drive won't be automatically detected and mounted since it will appear in a location that UDEV isn't watching.
I think you'll have to force a rescan of the bus after inserting the drive. This should cause the new drive to be detected.
You can do this by going to /sys/class/scsi/scsi_host and examining the entries. One of them will be the entry for the SATA port you've connected your drive bay to. When you figure out which one it is, cd into that directory, then enter this command: echo "- - -" >scan
This will cause the system to rescan that bus and your new drive should be detected. Then you make your file system, etc, and you should be good to go.
edit:
If you are using the ahci driver for sata, I understand that it does support hotplugging. In this event, your drive should be detected automatically.
Okay, that makes sense. Looking at what I'm planning on buying for a server, motherboard SATA is Intel ICH9R which should be the AHCI driver, hardware RAID card is 3ware 3w_9xxx driver - so I think I will be able hot swap either way I connect the drives.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.