Drain the gray water tank and close the valve. Add the treatment of your choice to the tank by pouring it down a sink drain. Use a product that is either a mild detergent or enzymatic cleaner. Avoid home-remedy-type concoctions that might harm the plumbing or tank. Follow the manufacturer's instructions for the amount of tank treatment to use for cleaning purposes, as opposed to the maintenance dose.
Fill the tank approximately half way with freshwater. Disconnect the drain hose by twisting the hose connector free of the RV drain outlet. Twist on the termination cap in its place.
Drive or tow the RV for several miles to agitate the water in the holding tank. Find a stretch of road that will gently rock the RV back and forth, if possible, to help loosen stubborn deposits.
Park the RV and connect the drain hose. Use the campground drain or other sanitary sewer for the outflow; don't dump out the tank onto the ground. Make sure you use a standard large-bore drain hose in this instance, and not a garden hose, as there could be a considerable amount of thick residue in the outflow.
Open the gray tank valve and allow the tank to drain. Close the valve and fill the tank with freshwater, then drain the tank again to flush out any remaining debris.