added: auto management for ports file