If you look at the pipe that is going into the filter pump you will notice that it has a tee that is peceeded by two or three pipes comming up from the ground. Those will be from the skimmer, main drain, and if you have one from the cleaner. If you observe the flow of water in the skimmer then change the valve so there is no more water flowing that will be the one going to the main drain or cleaner. Repeat the process to eliminate which one is the cleaner. Which ever one is left is the main drain.