For a variety of reasons you should not work on your production server to do such an upgrade.
If you MUST work on your production server you COULD make a sub directory on your production server, duplicate your database and do all of the work there if you so desired too if you are not sure... Not suggested but still better than actively working on the active production server. If you use a sub directory on your active server and get everything working it is simple to move it back.