在基于debian的linuxmint系统上,我门刚装好系统的时候,每次开机之后,打开nautilius,挂载分区的时候都会显示一个对话框,内容是:“Authentication is required to mount the device”。也即是说,每次打开我的电脑的硬盘分区的时候都会需要权限(即授权)。其实这个安全机制在这里并没有什么用对于大多数人来说。因为打开分区是我们经常做的事,而且经常输入管理员的密码是很麻烦的。那么怎么去掉这个权限控制呢?
进入/usr/share/polkit-1/actions目录里,里面就是用来设置各种权限的配置文件。找到一个名为org.freedesktop.udisks.policy的文件,右键点击它用管理员的身份打开,然后把(代码开头部分)下面的红色部分的字体全换成yes即可。编辑完成保存,无需重启即可生效。
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE policyconfig PUBLIC
"-//freedesktop//DTD PolicyKit Policy Configuration 1.0//EN"
"http://www.freedesktop.org/standards/PolicyKit/1.0/policyconfig.dtd">
<policyconfig>
<vendor>The udisks Project</vendor>
<vendor_url>http://udisks.freedesktop.org/</vendor_url>
<icon_name>drive-removable-media</icon_name>
<action id="org.freedesktop.udisks.filesystem-mount">
<description>Mount a device</description>
<description xml:lang="da">Montér en enhed</description>
<description xml:lang="de">Ger?t einh?ngen</description>
<message>Authentication is required to mount the device</message>
<message xml:lang="da">Autorisering er p?kr?vet for at montere et fil system</message>
<message xml:lang="de">Zugriffsrechte werden ben?tigt um das Ger?t einzuh?ngen</message>
<defaults>
<allow_any> no</allow_any>
<allow_inactive> no</allow_inactive>
<allow_active> auth_admin_keep</allow_active>
</defaults>
</action>
<action id="org.freedesktop.udisks.filesystem-mount-system-internal">
<description>Mount a system-internal device</description>
<description xml:lang="da">Montér en intern enhed</description>
<description xml:lang="de">Eingebautes Ger?t einh?ngen</description>
<message>Authentication is required to mount the device</message>
<message xml:lang="da">Autorisering er p?kr?vet for at montere et fil system</message>
<message xml:lang="de">Zugriffsrechte werden ben?tigt um das Ger?t einzuh?ngen</message>
<defaults>
<allow_any> no</allow_any>
<allow_inactive> no</allow_inactive>
<allow_active> auth_admin_keep</allow_active>
</defaults>
</action>
如果你的系统是ubuntu系统的话,则打开文件/usr/share/polkit-1/actions/org.freedesktop.devicekit.disks.policy,修改下面的红色字体为yes,然后保存即可。
if you wannt to make your system to mounted the partition without authentication,you shou open their diretory and edit the polity file .just repleace the red-color words above with yes ,it will take effect without reboot.still any question ,plz send me email by bkdwei@163.com.
进入/usr/share/polkit-1/actions目录里,里面就是用来设置各种权限的配置文件。找到一个名为org.freedesktop.udisks.policy的文件,右键点击它用管理员的身份打开,然后把(代码开头部分)下面的红色部分的字体全换成yes即可。编辑完成保存,无需重启即可生效。
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE policyconfig PUBLIC
"-//freedesktop//DTD PolicyKit Policy Configuration 1.0//EN"
"http://www.freedesktop.org/standards/PolicyKit/1.0/policyconfig.dtd">
<policyconfig>
<vendor>The udisks Project</vendor>
<vendor_url>http://udisks.freedesktop.org/</vendor_url>
<icon_name>drive-removable-media</icon_name>
<action id="org.freedesktop.udisks.filesystem-mount">
<description>Mount a device</description>
<description xml:lang="da">Montér en enhed</description>
<description xml:lang="de">Ger?t einh?ngen</description>
<message>Authentication is required to mount the device</message>
<message xml:lang="da">Autorisering er p?kr?vet for at montere et fil system</message>
<message xml:lang="de">Zugriffsrechte werden ben?tigt um das Ger?t einzuh?ngen</message>
<defaults>
<allow_any> no</allow_any>
<allow_inactive> no</allow_inactive>
<allow_active> auth_admin_keep</allow_active>
</defaults>
</action>
<action id="org.freedesktop.udisks.filesystem-mount-system-internal">
<description>Mount a system-internal device</description>
<description xml:lang="da">Montér en intern enhed</description>
<description xml:lang="de">Eingebautes Ger?t einh?ngen</description>
<message>Authentication is required to mount the device</message>
<message xml:lang="da">Autorisering er p?kr?vet for at montere et fil system</message>
<message xml:lang="de">Zugriffsrechte werden ben?tigt um das Ger?t einzuh?ngen</message>
<defaults>
<allow_any> no</allow_any>
<allow_inactive> no</allow_inactive>
<allow_active> auth_admin_keep</allow_active>
</defaults>
</action>
如果你的系统是ubuntu系统的话,则打开文件/usr/share/polkit-1/actions/org.freedesktop.devicekit.disks.policy,修改下面的红色字体为yes,然后保存即可。
- <action id="org.freedesktop.devicekit.disks.filesystem-mount-system-internal">
- <description>Mount a system-internal device</description>
- <description xml:lang="da">Montér en intern enhed</description>
- <description xml:lang="de">Eingebautes Ger?t einh?ngen</description>
- <message>Authentication is required to mount the device</message>
- <message xml:lang="da">Autorisering er p?kr?vet for at montere et fil system</message>
- <message xml:lang="de">Zugriffsrechte werden ben?tigt um das Ger?t einzuh?ngen</message>
- <defaults>
- <allow_any>no</allow_any>
- <allow_inactive>no</allow_inactive>
- <allow_active>auth_admin_keep</allow_active>
- </defaults>
- </action>
if you wannt to make your system to mounted the partition without authentication,you shou open their diretory and edit the polity file .just repleace the red-color words above with yes ,it will take effect without reboot.still any question ,plz send me email by bkdwei@163.com.