i installed nginx on server(ubuntu 16.04) which already had apache2 and, done this following configuration,
->changed apache port 80 to 8888 so nginx would listen to 80
->restarted apache and nginx in sequence.
still getting apache default page when i type http://localhost i also stopped apache2 service and restarted nginx service to ensure only once server run at time but still getting apache default page on localhost request!!! which should be actually nginx default page cuase apache service is not running anymore.
One thing i found suspicious is 'htcacheclean' process is running,is that responsible for the returning Apache page?!
how this is happening is strange for me!! kindly share hint if you ever faced this kind of issue.
ss -tlnp return following for the port 80
State Recv-Q Send-Q Local Address:Port Peer Address:Port
LISTEN 0 0 *:80 **:* *
ss -tlnp | grep nginx command output shows nginx