[clug] Kubuntu startup

Chris Smart clug at christophersmart.com
Wed Aug 31 15:46:08 MDT 2011


On 31/08/11 09:20, Keith Sayers wrote:
> 	I run a system with two hard drives - one for systems software and the other for 
> data.  The former carries Kubuntu 10.4 and it would obviously be handy if I could 
> automagically mount the data drive on startup.  I have found and ticked the 'Enable 
> automatic mounting of removable media' systems option but now have to enter the root 
> password to get past the Splash screen - could anyone suggest a way to obviate that, 
> please?

Most likely the authentication dialog you're seeing is coming from
PolicyKit, which wants authentication to mount. If you click "more info"
on the authentication dialog box it should tell you want you're
authenticating for.

If you want to overwrite this (so that you don't need to put in a
password), then you most likely need to create a PolicyKit override file
for whatever function it is that PolicyKit is run when the drive is
mounted. It's probably org.freedesktop.udisks.filesystem-mount (at a guess).

Depending on your distro, policy overrides can go in somewhere like:
/etc/polkit-1/localauthority/50-local.d/

Or the root, if that doesn't work:
/var/lib/polkit-1/localauthority/50-local.d/

You might (as root) create a file (called "10-mount-my-drive.pkla") that
looks like this:
[Mount My Drive]
Identity=unix-user:[YOUR-USERNAME]
Action=org.freedesktop.udisks.filesystem-mount
ResultAny=yes
ResultInactive=yes
ResultActive=yes

This way when KDE tries to mount the drive and PolicyKit rules are
loaded, this one will say to always return "yes" for authentication
against that rule (meaning you are automatically authenticated without a
password) and the mount should just work.

That's just a thought, anyway.

-c


More information about the linux mailing list