Add final block id; fix chmod bug.