Possibilities:
1. it could take time so be patient
2. if necessary, try the upgrade later (server could be busy)
3. deactivate all plugins and try again
4. might need to increase the memory allocated to PHP
5. may need to resort to manual upgrade as described in Upgrading WordPress
Note: on one site I had to increase PHP memory to 64M, on another site it took about 8 minutes to upgrade, on another site it went real quick.
----------------------------
Methods for increasing the amount of memory a PHP script may consume
1. If you have access to your PHP.ini file, change the line in PHP.ini
If your line shows 32M try 64M:
memory_limit = 64M ; Maximum amount of memory a script may consume (64MB)
2. If you don't have access to PHP.ini try adding this to an .htaccess file:
php_value memory_limit 64M
3. Try adding this line to your wp-config.php file:
Increasing memory allocated to PHP
define('WP_MEMORY_LIMIT', '64M');
4. Talk to your host.