If you are restarting the web server on a live website, you should do it gracefully.

A graceful restart tells the web sever to finish any active connections before restarting. This means that active visitors to your site will be able to finish downloading anything already in progress before the server restarts.

If you are running Apache, you do this with the graceful command:

$ sudo /etc/init.d/apache2 graceful