adapted to ubuntu