<div dir="ltr">I've run into things similar and it depends on what you're running.  If it's udev, make a rule in /etc/udev/rules.d/numbered-rule.rules with<div><span class="gmail-token gmail-assign-left" style="font-family:"Fira Code","Fira Mono",Menlo,Consolas,"DejaVu Sans Mono",monospace;font-size:1em;word-spacing:normal;background-color:rgb(250,250,250);box-sizing:border-box;border-width:0px;border-style:solid;border-color:rgb(64,120,242);color:rgb(64,120,242)">SUBSYSTEM</span><span class="gmail-token" style="font-family:"Fira Code","Fira Mono",Menlo,Consolas,"DejaVu Sans Mono",monospace;font-size:1em;word-spacing:normal;background-color:rgb(250,250,250);box-sizing:border-box;border-width:0px;border-style:solid;border-color:rgb(64,120,242);color:rgb(64,120,242)">==</span><span class="gmail-token" style="font-family:"Fira Code","Fira Mono",Menlo,Consolas,"DejaVu Sans Mono",monospace;font-size:1em;word-spacing:normal;background-color:rgb(250,250,250);box-sizing:border-box;border-width:0px;border-style:solid;border-color:rgb(80,161,79);color:rgb(80,161,79)">"block"</span><span style="font-family:"Fira Code","Fira Mono",Menlo,Consolas,"DejaVu Sans Mono",monospace;font-size:1em;word-spacing:normal;background-color:rgb(250,250,250);color:rgb(56,58,66);box-sizing:border-box;border-width:0px;border-style:solid;border-color:rgb(56,58,66)">, </span><span class="gmail-token gmail-assign-left" style="font-family:"Fira Code","Fira Mono",Menlo,Consolas,"DejaVu Sans Mono",monospace;font-size:1em;word-spacing:normal;background-color:rgb(250,250,250);box-sizing:border-box;border-width:0px;border-style:solid;border-color:rgb(64,120,242);color:rgb(64,120,242)">ACTION</span><span class="gmail-token" style="font-family:"Fira Code","Fira Mono",Menlo,Consolas,"DejaVu Sans Mono",monospace;font-size:1em;word-spacing:normal;background-color:rgb(250,250,250);box-sizing:border-box;border-width:0px;border-style:solid;border-color:rgb(64,120,242);color:rgb(64,120,242)">==</span><span class="gmail-token" style="font-family:"Fira Code","Fira Mono",Menlo,Consolas,"DejaVu Sans Mono",monospace;font-size:1em;word-spacing:normal;background-color:rgb(250,250,250);box-sizing:border-box;border-width:0px;border-style:solid;border-color:rgb(80,161,79);color:rgb(80,161,79)">"add"</span><span style="font-family:"Fira Code","Fira Mono",Menlo,Consolas,"DejaVu Sans Mono",monospace;font-size:1em;word-spacing:normal;background-color:rgb(250,250,250);color:rgb(56,58,66);box-sizing:border-box;border-width:0px;border-style:solid;border-color:rgb(56,58,66)">, ENV</span><span class="gmail-token" style="font-family:"Fira Code","Fira Mono",Menlo,Consolas,"DejaVu Sans Mono",monospace;font-size:1em;word-spacing:normal;background-color:rgb(250,250,250);color:rgb(56,58,66);box-sizing:border-box;border-width:0px;border-style:solid;border-color:rgb(56,58,66)">{</span><span style="font-family:"Fira Code","Fira Mono",Menlo,Consolas,"DejaVu Sans Mono",monospace;font-size:1em;word-spacing:normal;background-color:rgb(250,250,250);color:rgb(56,58,66);box-sizing:border-box;border-width:0px;border-style:solid;border-color:rgb(56,58,66)">ID_FS_UUID</span><span class="gmail-token" style="font-family:"Fira Code","Fira Mono",Menlo,Consolas,"DejaVu Sans Mono",monospace;font-size:1em;word-spacing:normal;background-color:rgb(250,250,250);color:rgb(56,58,66);box-sizing:border-box;border-width:0px;border-style:solid;border-color:rgb(56,58,66)">}</span><span class="gmail-token" style="font-family:"Fira Code","Fira Mono",Menlo,Consolas,"DejaVu Sans Mono",monospace;font-size:1em;word-spacing:normal;background-color:rgb(250,250,250);box-sizing:border-box;border-width:0px;border-style:solid;border-color:rgb(64,120,242);color:rgb(64,120,242)">==</span><span class="gmail-token" style="font-family:"Fira Code","Fira Mono",Menlo,Consolas,"DejaVu Sans Mono",monospace;font-size:1em;word-spacing:normal;background-color:rgb(250,250,250);box-sizing:border-box;border-width:0px;border-style:solid;border-color:rgb(80,161,79);color:rgb(80,161,79)">"123e4567-e89b-12d3-a456-426614174000"</span><span style="font-family:"Fira Code","Fira Mono",Menlo,Consolas,"DejaVu Sans Mono",monospace;font-size:1em;word-spacing:normal;background-color:rgb(250,250,250);color:rgb(56,58,66);box-sizing:border-box;border-width:0px;border-style:solid;border-color:rgb(56,58,66)">, </span><span class="gmail-token gmail-assign-left" style="font-family:"Fira Code","Fira Mono",Menlo,Consolas,"DejaVu Sans Mono",monospace;font-size:1em;word-spacing:normal;background-color:rgb(250,250,250);box-sizing:border-box;border-width:0px;border-style:solid;border-color:rgb(64,120,242);color:rgb(64,120,242)">NAME</span><span class="gmail-token" style="font-family:"Fira Code","Fira Mono",Menlo,Consolas,"DejaVu Sans Mono",monospace;font-size:1em;word-spacing:normal;background-color:rgb(250,250,250);box-sizing:border-box;border-width:0px;border-style:solid;border-color:rgb(64,120,242);color:rgb(64,120,242)">=</span><span class="gmail-token" style="font-family:"Fira Code","Fira Mono",Menlo,Consolas,"DejaVu Sans Mono",monospace;font-size:1em;word-spacing:normal;background-color:rgb(250,250,250);box-sizing:border-box;border-width:0px;border-style:solid;border-color:rgb(80,161,79);color:rgb(80,161,79)">"sda"</span></div><div><span class="gmail-token" style="font-family:"Fira Code","Fira Mono",Menlo,Consolas,"DejaVu Sans Mono",monospace;font-size:1em;word-spacing:normal;background-color:rgb(250,250,250);box-sizing:border-box;border-width:0px;border-style:solid;border-color:rgb(80,161,79);color:rgb(80,161,79)">or whatever.  Dunno if this does what you want, but you can pretty much do something like this to handle that kinda thing if you're running udev.</span></div></div><br><div class="gmail_quote gmail_quote_container"><div dir="ltr" class="gmail_attr">On Sat, May 17, 2025 at 10:20 PM der.hans via PLUG-discuss <<a href="mailto:plug-discuss@lists.phxlinux.org">plug-discuss@lists.phxlinux.org</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">Am 17. May, 2025 schwätzte Ryan Petris via PLUG-discuss so:<br>
<br>
> You can't, unfortunately. The only thing in /dev you can technically<br>
> rename are network interfaces; the rest you can only add symlinks for,<br>
> which is what for instance /dev/disk/by-partlabel/* is.<br>
<br>
A shame, I like long path names :)<br>
<br>
> Why do you care what mdadm shows for device names anyway? If you're<br>
> concerned that it will pick up the wrong disk on reboot, it won't<br>
> because internally it's using its own identifiers to find the right<br>
> drives, and will snow you whatever /dev/sd* it happens to end up<br>
<br>
It picked up the wrong devices when powering the drive bay down and up<br>
again. mdadm was showing and trying to use the orginal sd names rather<br>
than the newly assigned names.<br>
<br>
I will experiment more with mdadm. It's been a while since I used it, so<br>
was expecting some reacquaintance exercises to be necessary.<br>
<br>
ciao,<br>
<br>
der.hans<br>
<br>
> on when running mdadm commands. If you want to figure out which<br>
> /dev/sd* device belongs to your disk label, you can just run `readlink<br>
> /dev/disk/by-partlabel/raid...`.<br>
<br>
<br>
><br>
> On Sat, May 17, 2025, at 6:46 PM, der.hans via PLUG-discuss wrote:<br>
>> moin moin,<br>
>><br>
>> I'm using a USB JBOD enclosure to build a RAID set.<br>
>><br>
>> Restarting the enclosure ends up with the drives on new names, e.g. sda,<br>
>> sdb and sdc come back sdd, sde and sdf.<br>
>><br>
>> I added labels to my disk partitions and was hoping to use them, e.g.<br>
>> /dev/disk/by-partlabel/raid{0,1,2}, but mdadm turned them back to<br>
>> /dev/sd{d,e,f} names as members of the array<br>
>><br>
>> Anyone know how I can either get /dev/sd names not to change for removable<br>
>> media or get mdadm to accept the names I want to use?<br>
>><br>
>> I'd rather the latter.<br>
>><br>
>> ciao,<br>
>><br>
>> der.hans<br>
>> --<br>
>> #  <a href="https://www.SpiralArray.com" rel="noreferrer" target="_blank">https://www.SpiralArray.com</a>   <a href="https://www.PhxLinux.org" rel="noreferrer" target="_blank">https://www.PhxLinux.org</a><br>
>> #  <arclight> Delicious red tape, like a Twizzler but flat. And adhesive.<br>
>> ---------------------------------------------------<br>
>> PLUG-discuss mailing list: <a href="mailto:PLUG-discuss@lists.phxlinux.org" target="_blank">PLUG-discuss@lists.phxlinux.org</a><br>
>> To subscribe, unsubscribe, or to change your mail settings:<br>
>> <a href="https://lists.phxlinux.org/mailman/listinfo/plug-discuss" rel="noreferrer" target="_blank">https://lists.phxlinux.org/mailman/listinfo/plug-discuss</a><br>
>><br>
><br>
<br>
-- <br>
#  <a href="https://www.SpiralArray.com" rel="noreferrer" target="_blank">https://www.SpiralArray.com</a>   <a href="https://www.PhxLinux.org" rel="noreferrer" target="_blank">https://www.PhxLinux.org</a><br>
#  "Luckily, this is a comic book, for which no idea is too complex."<br>
#    -- Larry Gonick from The Cartoon History of the United States---------------------------------------------------<br>
PLUG-discuss mailing list: <a href="mailto:PLUG-discuss@lists.phxlinux.org" target="_blank">PLUG-discuss@lists.phxlinux.org</a><br>
To subscribe, unsubscribe, or to change your mail settings:<br>
<a href="https://lists.phxlinux.org/mailman/listinfo/plug-discuss" rel="noreferrer" target="_blank">https://lists.phxlinux.org/mailman/listinfo/plug-discuss</a><br>
</blockquote></div><div><br clear="all"></div><div><br></div><span class="gmail_signature_prefix">-- </span><br><div dir="ltr" class="gmail_signature">James McPhee<br><a href="mailto:jmcphe@gmail.com" target="_blank">jmcphe@gmail.com</a></div>