Spain agrees to open port to 600 migrants in Mediterranean