The Grammarphobia Blog explains that the origin of the expression is pretty much what you would expect. It literally means fighting “…with the use of one’s teeth and nails as weapons; by biting and scratching.” It also explains that it means to attack or defend “…vigorously, fiercely, with one’s utmost efforts, with all one’s might.” The first recorded mention was by Sir Thomas More in 1535 while he was waiting execution. I typically don’t make editorial comments about expressions, but think fighting “tooth and nail” against an executioner or someone with an axe, spear, or gun means you are merely trying to maintain some semblance of dignity or prolonging the inevitable.