Fix database access on server