The Y(1S), Y(2S), and Y(3S) production cross sections in proton-proton collisions at root s = 7 TeV are measured using a data sample collected with the CMS detector at the LHC, corresponding to an integrated luminosity of 3.1 +/- 0.3 pb(-1). Integrated over the rapidity range vertical bar y vertical bar < 2, we find the product of the Y(1S) production cross section and branching fraction to dimuons to be sigma(pp -> Y(1S)X) center dot B(Y(1S) -> mu(+)mu(-)) = 7.37 +/- 0.13(-0.42)(+0.61) +/- 0.81 nb, where the first uncertainty is statistical, the second is systematic, and the third is associated with the estimation of the integrated luminosity of the data sample. This cross section is obtained assuming unpolarized Y(1S) production. With the assumption of fully transverse or fully longitudinal production polarization, the measured cross section changes by about 20%. We also report the measurement of the Y(1S), Y(2S), and Y(3S) differential cross sections as a function of transverse momentum and rapidity.