The invention relates to an oxygen separator (10), comprising at least one oxygen separation device (12, 14) comprising an oxygen separation sorbent (16, 18) for separating oxygen from an oxygen comprising gas, wherein the oxygen separation device (12, 14) comprises a gas inlet (24, 28) at a primary side being connected to an inlet conduct (20) for guiding a flow of oxygen comprising gas into the oxygen separation device (12, 14) and having a gas outlet (34, 36) at a secondary side being connected to an outlet conduct (30, 32) for guiding a flow of oxygen enriched gas out of the oxygen separation device (12, 14), wherein the secondary side of the oxygen separation device (12, 14) is further connected to a source of purging gas for guiding purging gas through the oxygen separation device (12, 14) and wherein the primary side of the oxygen separation device (12, 14) is connected to an exhaust conduct (70, 72) for guiding exhaust gas out of the oxygen separator (10), wherein the oxygen separator (10) further comprises a pressure adjusting device (40) for creating a pressure difference between the primary side and the secondary side of the oxygen separation device (12, 14), and wherein a gas sensor (82) is provided in the exhaust conduct (70, 72, 73) for determining the concentration of at least one component of the exhaust gas. Such an oxygen separator (10) provides an improved controlling behavior. The invention further relates to a method of generating oxygen from an oxygen comprising gas.