Hello,
Thank you!! I re-checked my configuration and you were right, although I didnt have that variable setted I did have "$CFG->dataroot" and it was pointing to the wrong location.
Just in case it happens to anyone else, that variable I think should point to your moodledata folder. I dont know what the difference between $CFG->dataroot and $CFG->datadir is, but as soon as i pointed $CFG->dataroot to the right location i was able to upgrade Moodle.
Thanks again!!