Hi,
For SMF, the solution was quite simple and i'm to blame for my lack of attention because it's right at the contribs page of SMF where it says "Changing the Forum Base URL".
So, i followed the instructions, i.e., i edited "Settings.php" with vi in /opt/SMF and then just changed the domain, which in my case was the new ip address.
Then i tested it, and everything was ok again!
Regarding phpBB2, i didn't found yet the solution, since there's no indications in the respective contribs page.
I've taken a look within the files in /opt/phpBB2 and /opt/phpBB2/admin but i haven't reached a solution yet.
I'll keep trying, but if someone already knows where exactly what file must b edited to change the domain, please post it here!
Regards and thanks for your time!