A read-only user or a user in a read-only database is not permitted to disable read-only mode on

在启动spark的时候,遇到的问题。从字面意思可以看到是只读文件,拒绝连接。我们猜想可能是权限不够。因为sparkSql的文件在spark的安装目录下面。与bin统计的目录。有一个metastore_db,进去以后会看到一个db.lck的文件,权限应该不是当前用户的所属。切换到对应的用户下面,修改属组和属主即可。

再次启动即可成功!

A read-only user or a user in a read-only database is not permitted to disable read-only mode on