Here's how to go lighter than magnesium: Make stakes out of plastic.

Only problem is, hard rocky ground. Seems it's always there where I pitch a tent. To punch through the hardest rockiest soil, bring one (1) 6-inch steel nail. Drill a stake hole with the nail, pull it back out, insert the super lightweight plastic stake. Pre-drilling the hole also keeps the plastic stake from breaking as it's being inserted and hits something.

Also, plastic is safer than Mg.