They often didn't.
Each camp used its own catalogue system, with msot sticking to the infamous "tattoo a number into someone's arm" approach. Auschwitz for example operated that way - but one should of course be aware that even just talking about concentration camps you are looking at holding camps, prison camps, labor camps, extermination camps, all of which might not only operate differently between the various classifications of camp but also within the subsets themselves - Jasenovac in occupied Yugoslavia (the only true extermination camp not located in Poland or the USSR) operated quite differently from Auschwitz or Treblinka, for example. It is disputed to what extent Jasenovac and the Croatian Ustasa's doing overall were part of the main German-led Holocaust or whether the Croatians had their own genocidal side branch going.
So, everything I am discussing from here on out will be taking the example of Auschwitz unless specifically stated otherwise. And of course, this is gonna get depressing - but you knew that.
Anyway, we first start where new inmates in the extermination camps would have also started: At the "ramp". The prisoners fit for service were taken in for further exploitation, the rest was brought straight to the chambers - no number tattoed into their arm, no paperwork wasted on registering them or taking their identity. Hundreds of thousands, if not more than a million, were lost to history at Auschwitz alone that way.
Now, tattoos had not always been part of Auschwitz's procedure, but as the number of bodies piled up among the force singled out for forced labor, the ever-industrious and uber-efficient SS found themselves unable to identify which useful slave they had just lost to disease, malnourishment, exhaustion, guard violence or whatever cause of death was out to get the prisoners in camp. Prisoner numbers were only on the clothing at that point, and a prisoner without clothing immediately became unidentifiable.
They got the inspiration of tattoos from their previous practice of using indelible ink to note a prisoner's number on the prisoner's chest when the prisoner was sentenced to death by execution.
So they started tattooing, mostly on the outer left forearm. This process, originally done with a metal stamp, was later performed by a classic tattoo needle. Mostly, simple black ink was used, but in rare cases the number was also brutally scratched into the skin as a permanent scar. This photograph by Frankie Fouganthin depicts the usual tattoo as most inmates would have had it: black ink, left outer forarm.
The numbers counted up all the way to, as according to ushmm.org, 202499. Add to that special numbering lines, like "A1" through "A20000", "B1" through "B20000" et cetera. Sinti and Roma were given the special unlimited numbering scheme starting with the letter "Z", short for Zigeuner, a German word meaning "Gypsy" (with similar undertones).
All in all, nearly half a million numbers were given out and more or less catalogued well. That does not come close to the number of people killed at Auschwitz, with most historians estimating a baseline of 1.1 million fatalities within 1.3 million overall prisoners ever having stayed in the camp, if just temporarily. Assuming that this number is accurate and putting the number of given tattoos at 450,000 (both numbers sound in the ballpark), that would leave 650,000 nameless dead whose families never got closure - and I am still exclusively talking about Auschwitz, as I am not nearly as well-versed when it comes to Jasenovac, Belzec, Majdanek, Kulmhof, Treblinka, Bronnaja Gora, Maly Trostinez or Sobibor, all of which were dedicated extermination camps (or in Maly Trostinez's case more like an extermination site) with their own stories and classification systems.
Okay, so let's assume that your relative was one of the lucky few who got the privilege to work themselves to death rather than being gassed to death immediately. How would you go about finding them? You likely wouldn't, unless you had specific information about the camp they stayed in and their prisoner number. You might be able to find out your loved one perished, but that is something you would likely have realized in the years it took you to even access this information. The Nazis did not make it a practice to note the burial sites down, so finding your loved one's grave would prove difficult - and even if you pulled it off, your loved one would likely be in a mass grave with a dozen if not multiple dozens of others.
Depressing stuff overall.