There are many reasons why jobs fail on a server; here are a few of the common ones and ideas on how to avoid them. Also, ensure that your document has the Generate Log File option selected in the General tab of Document Properties as this makes identifying the issue a lot easier. The default log file created by QlikView Server is rarely of any help, but the document log file gives us more helpful error messages at approximately the script line that failed.
If you are connected to a database using OLE DB, you have the option of supplying a username and password for database access. One common failure here is that the password may have expired. It is better to set up your connection to use the NT authentication and have the account running the QlikView Distribution service added to the database list of authenticated users. (Only read access is required most of the time.)