Upper critical field and irreversibility line determined by transport measurement of the new superconductor MgB2