In the present study, effect of nanoparticle sedimentation on characteristics of natural convection heat transfer inside a completely porous cavity filled with Al2O3/water nanofluid was investigated over time, and entropy generation was analyzed from the viewpoint of the second law of thermodynamics. In order to simulate this phenomenon using a two-phase mixture model, a new solver was developed in OpenFOAM framework based on driftFluxFoam and buoyantBoussinesqPimpleFoam solvers. Effects of Rayleigh number (Ra = 10(4) - 10(7)), Darcy number (Da = 10(-5) - 10(-2)) characteristics were further analyzed. Numerical results indicated very long sedimentation time for low porosities and extended cavity lengths. Also, with increasing the values of L, Ra and Da, natural convection heat transfer, circulation, and irreversibility of the process increased significantly. It was further seen that, the Nusselt number decreased during the nanoparticle sedimentation process. Formation of sediment layers at the bottom of the enclosure reduced the streamlines, as compared to the primary streamlines, thereby decreasing natural convection and rotational flow while contributing to conductive heat transfer. (C) 2019 Elsevier B.V. All rights reserved.