  We present X-ray spectral analysis of five Chandra and XMM-Newton
observations of the gravitationally-lensed blazar PKS1830-211 from 2000 to
2004. We show that the X-ray absorption toward PKS1830-211 is variable, and the
variable absorption is most likely to be intrinsic with amplitudes of about
2-30e22 cm^-2 depending on whether or not the absorber is partially covering
the X-ray source. Our results confirm the variable absorption observed
previously, although interpreted differently, in a sequence of ASCA
observations. This large variation in the absorption column density can be
interpreted as outflows from the central engine in the polar direction,
consistent with recent numerical models of inflow/outflows in AGNs. In
addition, it could possibly be caused by the interaction between the blazar jet
and its environment, or the variation from the geometric configuration of the
jet. While the spectra can also be fitted with a variable absorption at the
lens redshift, we show that this model is unlikely. We also rule out the simple
microlensing interpretation of variability which was previously suggested.
