setting permissions keeps failing