Codeigniter分页仅获取无法导航第二页和第三页的第一页

i have an issue with codeigniter pagination, the same technique i did in the older codeigniter version it works fine but not in this latest version(3.1.9). The first front page fetch data fine but when i click on page 2, 3 or 4 still it display those of the first front row data.

Here is my controller:

$total_rows = $this->estate_model->estate_count();
    $config = pagination_configuration(base_url("real_estate"), $total_rows, 10, 3, 5, true);
    $this->pagination->initialize($config);
    $page = ($this->uri->segment(2)) ? $this->uri->segment(3) : 0;
    $page_num = $page-1;
    $page_num = ($page_num<0)?'0':$page_num;
    $page = $page_num*$config["per_page"];
    $data["links"] = $this->pagination->create_links();
    $obj_result = $this->estate_model->get_all_active_estate($config["per_page"], $page);

Model:

public function  get_all_active_estate($limit, $start)
{
    $this->db->select('*');
    $this->db->from('estate');
    $this->db->where('status', 'active');
    $this->db->limit($limit, $start);
    $Q = $this->db->get();
    if ($Q->num_rows() > 0) {
        $return = $Q->result();
    } else {
        $return = 0;
    }
    $Q->free_result();
    return $return;
}

Please help.. thank you

try $page = ($this->uri->segment(3)) ? $this->uri->segment(3) : 0;

instead

$page = ($this->uri->segment(2)) ? $this->uri->segment(3) : 0;