check path exists.