Why lsblk is not reliable for repair.

Let’s walk through a simple 4 NVMe scenario to show why this happens and how to correctly identify the failed disk.

You have a server with 4 NVMe drives

[ PCIe Slot Mapping ]

+---------------------------+

| Slot A: NVMe 0 |

| Slot B: NVMe 1 |

| Slot C: NVMe 2 |

| Slot D: NVMe 3 |

+---------------------------+

On first boot, everything looks healthy:

$ lsblk

nvme0n1 931G

nvme1n1 931G

nvme2n1 931G

nvme3n1 931G

Now let’s say the drive in Slot B fails. After a reboot, the kernel renumbers the remaining devices

$ lsblk

nvme0n1 931G

nvme1n1 931G <-- used to be nvme2n1

nvme2n1 931G <-- used to be nvme3n1

At a glance, it looks like nvme3n1 is the “bad drive” because it’s missing compared to the original layout but that’s not actually true. Device names are not fixed to physical slots.

That’s the whole trap.

Linux assigns NVMe device names in the order they’re discovered at boot. If a drive disappears

The list becomes shorter

Higher numbered devices shift down to fill the gap

This is different from SATA (/dev/sdX) where naming can also shift, but NVMe changes are more common due to how PCIe enumeration works.

So if you rely only on lsblk, you may remove the wrong disk.

Here’s a practical way to confirm the correct failed NVMe drive without guesswork.

dmesg | grep -i nvme

This usually shows errors like timeouts, disconnects, or controller resets. You’ll often see which PCIe address the failed device belonged to.

Example,

nvme nvme1: I/O 8 QID 3 timeout

nvme nvme1: Failed status: 0x2002

pci0000:3c:00.0: unable to enumerate NVMe device

Note the PCI address (3c:00.0 in this example).

sudo nvme list

Healthy output:

Node SN Model Namespace Usage

/dev/nvme0n1 AB12A3CD4E Samsung PM9A3 1.92TB 1 1.92TB

After failure, the missing serial number confirms which unit is gone.

Serial numbers are your friend they don’t lie or reorder.

This is the most reliable mapping method on Linux:

ls -l /dev/disk/by-path/

Example output (abbreviated):

pci-0000:3b:00.0-nvme0 -> ../../nvme0n1

pci-0000:3c:00.0-nvme1 -> ../../nvme1n1

pci-0000:3d:00.0-nvme2 -> ../../nvme2n1

pci-0000:3e:00.0-nvme3 -> ../../nvme3n1

If the drive for pci-0000:3c:00.0 is missing, you now know exactly which slot to pull.

No guesswork. No renumbering confusion.

TL;DR for Troubleshooting NVMe Failures

lsblk is helpful, but NVMe names shift after failures and reboots

#linux #computer #computerscience

Always check:

dmesg for PCIe/NVMe errors

nvme list for serial numbers

/dev/disk/by-path/ to map device → PCIe slot

If you rely on /dev/nvmeXn1 naming alone, you’re one mistake away from pulling the wrong drive.

San Francisco
2025/11/8 Edited to

... Read moreWhen troubleshooting NVMe drive failures, it's essential to understand that device naming in Linux is dynamic and can shift depending on hardware enumeration during boot. The lsblk command, while useful for listing block devices, depends on kernel-assigned device names such as /dev/nvme0n1, /dev/nvme1n1, etc. However, these names are assigned sequentially based on the detection order at boot time and are not permanently fixed to the physical PCIe slots or slots on the server. In scenarios with multiple NVMe drives, if one drive fails or is removed, subsequent devices can shift their names downward to fill the gap left by the missing device. For example, if the drive in Slot B (originally nvme1n1) fails, after reboot, nvme2n1 and nvme3n1 may be renamed to nvme1n1 and nvme2n1. This renumbering creates confusion when trying to identify which physical drive has actually failed, leading to the risk of replacing the wrong disk. To avoid this pitfall, administrators should supplement lsblk output with additional commands and checks: 1. **Check dmesg logs for NVMe errors:** Running `dmesg | grep -i nvme` shows kernel messages including I/O timeouts, device enumeration failures, and PCIe addresses associated with the failed device. These logs highlight which PCIe slot corresponds to the failed hardware. 2. **Use `nvme list` to view device serial numbers:** This command lists all detected NVMe devices alongside their serial numbers and metadata. After a failure, missing serial numbers can confirm which drive is absent, giving a more reliable identification than device names alone. 3. **Map devices with `/dev/disk/by-path/` links:** These symbolic links associate device nodes with their exact PCIe addresses, bridging the gap between logical device names and physical hardware locations. This is the most dependable method to confirm the exact slot of a failed NVMe drive. Together, these steps offer a comprehensive approach to safely and accurately troubleshoot NVMe drive issues in Linux environments. Relying solely on lsblk is risky due to the dynamic renaming caused by PCIe enumeration and drive failures. Instead, combining kernel messages, device serial numbers, and PCIe path mappings ensures administrators correctly identify and replace the faulty drive without guesswork or costly errors.

Related posts

Reliable cars for young Adults
#reliablerides #cars #newcar #toyotacamry #honda
Chantel

Chantel

1184 likes

Most reliable and funny quotes pt 2
#funnyquotes #memequotes #relatible
Ava 🎀👛🩰

Ava 🎀👛🩰

3409 likes

A person wearing a black t-shirt with a 'CarsNus' logo, overlaid with a red box stating 'The 5 Most Reliable Car Brands in the USA for 2026'. Blurred yellow cars are visible in the background.
A black Toyota sedan is parked in front of a dark wall, with a large 3D Toyota logo in the foreground. The word 'Toyota' is displayed prominently twice above the car.
A dark blue Subaru sedan is presented against a black and white background featuring the 'Subaru' logo. The car is shown from a front-three-quarter angle.
The 5 Most Reliable Car Brands in the USA for 2026
The 5 Most Reliable Car Brands in the USA for 2026 #vehicles
carsnus_com

carsnus_com

14 likes

The image shows a person's feet in white sneakers on a dark gym floor, with weights in the background, introducing "Weird manager moves that made me the most reliable leader."
An indoor scene with warm lighting, a wooden table, and a plant, illustrating the fourth tip: protecting a weekly "thinking block" for strategic decisions.
A white coffee cup on a saucer next to a laptop, illustrating the third tip: taking responsibility by saying "that was my call" when things went wrong.
How I became a reliable manager 🙌
#productivitytools #aitoolsforbusiness #aiassistant #adhdtips #productivity
Work Cheat Code

Work Cheat Code

5 likes

A woman stands at a gas pump displaying "20.00" and "6.252 Gallons," with text overlay "reliable cars for girls who don't know anything abt cars." The pump also shows fuel prices and ethanol content.
A collage of Hyundai Elantra cars, including black, white, and blue models, with interior and exterior shots. Text describes the Hyundai Elantra as stylish, easy to drive, affordable, and giving modern, luxury vibes.
A collage of Mazda3 cars, featuring interior views, a white model with a gold bow, a dark gray model, and a black model. Text describes the Mazda3 as cute, classy, super reliable, and turning heads effortlessly.
RELIABLE CARS 🥰🤌💋💋 .
Reliable cars for girls who know nothing about cars 🚗 🤩🤏🏾🤏🏾🩷💅🏾 . #baddiecars #girlslovecars #beautifulcars #reliablecars #cars
Keyy

Keyy

45 likes

HERE’S WHY 👇🏻👇🏻👇🏻👇🏻
✖️ “No days off” Why it’s misleading: This glamorizes overtraining and ignores how vital rest and recovery are for muscle growth, hormone balance, and nervous system health. What’s true instead: → Progress requires rest. Your muscles repair, your body resets, and your stress levels recalibr
killitwithkenz

killitwithkenz

4 likes

5 Ways to Repair a USB Drive Without Formatting
Can't open your USB drive and Windows wants to format it? Discover 5 reliable solutions to repair your drive and recover your files safely. #repair #usb #format #solution
SmoothTechie

SmoothTechie

2 likes

Reliable Nurse Tutor for BSN, MSN and DNP
Hello nursing students 👋🏻❕ #fyp #capellauniversity #nursingstudent #nursingschool #nursestudent
Skyler Fricks, RN

Skyler Fricks, RN

1 like

Ole reliable
#s10 #trucktok #chevy #fyp #projecttruck
6.2_vortec

6.2_vortec

0 likes

Reliable basics in my capsule wardrobe
A capsule wardrobe isn’t about owning less — it’s about owning smarter. These are the pieces I reach for weekly because they always deliver polish and ease. A crisp Ralph Lauren Oxford sets the tone, layered with a soft Quince trench and my go-to suede work bag for that effortless, “pulled-toget
BD

BD

28 likes

✨ Give Your Space the Clean It Deserves! ✨ Looking for a reliable, profession
Lauris30620

Lauris30620

18 likes

Time For Loc Surgery🥵: Retwist + Loc Repair🌱 Inspo
Monday was that day — my retwist and loc repair appointment! Let me just say, my loctitian never disappoints. Her vibe is unmatched: positive energy, spiritual wisdom, a place surrounded by plants, spiritual images, and the calming scent of incense filling the space. It’s such a peaceful escape.
Margarita

Margarita

47 likes

From Reliable at Work to Reliable for Me
I thought reliability meant strength. I was always the one they could count on, no matter how tired or drained I was. But the truth? I was disappearing in the process. Showing up at work didn’t mean I was showing up in my own life. It just meant I was pouring myself into something that would rep
entrepreneurialgigi

entrepreneurialgigi

0 likes

Gutter drainage repair
Making solid progress on today’s gutter install. Old system removed, fascia checked, and new gutters going up nice and level to ensure proper drainage. Clean lines, secure hangers, and attention to detail—because gutters aren’t just about looks, they protect your home from water damage. Stay tune
Benny

Benny

1 like

Most reliable…
#dadjokes #funnyjoke #momjokes #justajoke
Deersusan13

Deersusan13

32 likes

Best SSD Repair Tools for Windows | Fix SSD Errors
Looking for a reliable SSD repair tool to fix corrupted sectors, firmware issues, or bad blocks? This video covers the best free and paid tools to repair, optimize, and monitor your SSD’s health. #SSDRepairTool #FixSSD #SSDError #SSDHealth #WindowsTools #DiskRepair #DataRecovery #TechTutori
tech hu

tech hu

1 like

fast and reliable
#electricunicycle #euc
Mr David Electrical unicycles

Mr David Electrical unicycles

2 likes

✨ Easy Reliable Plants for Any Home 🪴
Plants add an earthy vibe to any home. Some are harder to care for than others. I’ve had my fair share of plant woes, but these are my successes! Dracaena: this plant has gone through a lot! It’s been in low light spaces, under watered, and some leaves got sick. But this little guy keeps on goin
Katrina Nicole

Katrina Nicole

17 likes

See more