Mass merchants and club retailers are gaining market share in a mission-critical category that supermarket operators have long controlled.