remove redundant ports and things