Dolomite is a calcium magnesium carbonate - CaMg(CO3)2. Many ancient rock units (dolostones) were long known to be composed of dolomite. Strangely, dolomite couldn't be found forming in modern oceans. Modern seas do precipitate aragonite, a calcium carbonate. Cores drilled on coral atolls show that dolomite occurs at depth, below beds composed of calcite (hexagonal CaCO3), which in turn occur at depth below beds composed of aragonite (orthorhombic CaCO3). Dolomite appears to form principally by the addition of Mg to pre-existing limestones (rocks composed of CaCO3). Dolomite is also now known to precipitate directly from water in a few localities (e.g., some oceanic tidal flats and some lakes).
Dolomite has a hardness of about 3.5 to 4 on the Mohs Hardness Scale. It tends to form pinkish or whitish curved rhombic crystals ("saddle dolomite" - see sample below). Dolomite will bubble in acid if powdered first.
Dolomite (field of view ~4.5 cm across). The dark specks are pyrite (FeS2 - iron sulfide).