0

i have a debian11 ssd server which is installed in RAID 1 MIRRORING

i use the server as webhost and for better performance (whith high volume of users) i need to use RAID 0 so data wil be split across 2 drivers

2 x 1TB disks

QUESTION IS: How to convert from RAID 1 to RAID 0 without reinstalling the server

New contributor
wuqn yqow is a new contributor to this site. Take care in asking for clarification, commenting, and answering. Check out our Code of Conduct.
10
  • 3
    You understand that because you are using SSDs you are unlikely to get significantly better performance with RAID0 than RAID1, but in return you are significantly increasing the probability that your filesystem will die due to a disk failure (possibly as much as x4)?
    – roaima
    Jun 23 at 15:32
  • 1
    For practical purposes it's impossible to do it live, and I presume you have some sort of hosting provider which means you can reinstall the server using RAID0. TLDR: You cannot, you need to reinstall. Jun 23 at 15:40
  • 1
    Also, RAID 0 only improves write performance for large files, neither of which are your problems in a web service. Bulk read performance for RAID 0 and RAID 1 is the same (both allow interleaving reads from both drives), and random access read performance will be better for RAID 1 because reads can be sent to the less busy drive. Jun 23 at 15:40
  • 1
    Did you do some analysis to find out what's the bottleneck in your case? SSD? Network? CPU?
    – Bodo
    Jun 23 at 15:51
  • 2
    @ArtemS.Tashkinov I believe it's possible: split the mirror and then append the now-spare disk as a non-interleaved extension to what is half a RAID1. Whether it's possible to do it satisfactorily without a reboot I'm not sure, but I wouldn't want to try it. Without the interleaving there's little point as there's be next to no performance increase
    – roaima
    Jun 23 at 15:58

1 Answer 1

0

In my (unfortunately deleted post) I showed the results of testing mdadam (included in Debian) RAID1, RAID0, RAID10, and single disk. The expected RAID1 performance -slightly slower write speed than single disk and nearly same read speed as RAID0- was not observed. After a deep search on the Internet I found an explanation that it is not an error, but a feature. The reason is to give kernel a chance to do two parallel reads for two independent program. This is not the case in the BSD unix (FreeBSD, NET-BSD, OpenBSD) while it does not use mdadam subsystem. But I must agree that while using SSD the disk performance (RAID0,1 none) may not be your main problem. You did not described the server component: web-server (Apache/Lighttp/...), application module (PHP/python/...), database (mysql/postgres/...), number of CPU cores, amount of RAM, what kind of services it realises (static pages/dynamic pages/heavy downloads/...)

If I strictly answer your question: migration from RAID1 to RAID0 cannot be realised on-line. You have to stop the server, make backup to an external disk, then reconfigure the RAID0. It could be more easy, if you have some independent system disk. If not, you must reconfigure the RAID while installing the new Linux OS.

But with respect to comments above, it is highly recommended NOT to do this. The RAID1 is mainly used on server for better data protection.

Your Answer

wuqn yqow is a new contributor. Be nice, and check out our Code of Conduct.

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.