Upgraded Packages And Ports, Can't Shutdown From Mate Menu Bar

Polytropon freebsd at edvax.de
Wed Dec 25 20:34:04 UTC 2019


On Wed, 25 Dec 2019 13:12:41 -0600, Valeri Galtsev wrote:
> 
> 
> > On Dec 25, 2019, at 1:07 PM, B J <va6bmj at gmail.com> wrote:
> > 
> > I just upgraded all the packages and ports on one of my machines.  It still
> > runs 12.0 under Mate.  The only glitch was when the package upgrade halted
> > due to, apparently, an attempt to install something from two different
> > sources in the same place.
> > 
> > I restarted the package upgrade and it continued from where it left off,
> > with no mention of the aforementioned conflict.
> > 
> > My question is how I can fix it so that I can shut down my machine using
> > the Mate menu bar.  I can shut it down from Terminal, using:
> > 
> > shutdown -h now
> > 
> > I don't recall seeing anything about this on the mailing list.
> > 
> > Any ideas?  Suggestions?  Thank you.
> > 
> 
> I would go through the whole routine:
> 
> freebsd-update fetch
> freebsd-update install
> 
> [ reboot where necessary]
> 
> pkg update
> pkg autoremove
> pkg upgrade -f
> 
> The last will reinstall all packages, which may fix the thing.
> Last but one may clean-up what you may not need anymore.

Also check for the HAL / DBus / <something>Kit XML configuration
file, maybe it got overwritten during the update? Verify that
HAL and DBus are running, otherwise it seems that MATE won't
enable the power button icon and action.

File /usr/local/etc/PolicyKit/PolicyKit.conf:

<config version="0.1">
	<match action="org.freedesktop.hal.power-management.shutdown">
		<match user="USERNAME">
			<return result="yes"/>
		</match>
	</match>
</config>

Replace USERNAME with your actual username.

Or using group membership for the "operator" group (which you
are surely in, because you can shutdown the system using the
terminal):

<config version="0.1">
	<define_admin_auth group="operator" />
	<match action="org.freedesktop.hal.power-management.shutdown">
		<return result="yes" />
	</match>
	<match action="org.freedesktop.hal.power-management.reboot">
		<return result="yes" />
	</match>
	<match action="org.freedesktop.hal.power-management.hibernate">
		<return result="yes" />
	</match>
	<match action="org.freedesktop.hal.power-management.suspend">
		<return result="yes" />
	</match>
</config>



Some information here:

https://forums.freebsd.org/threads/shutdown-using-hal.2324/

https://forums.freebsd.org/threads/how-to-shutdown-and-reboot-in-xfce4.16916/


Also refer to the Gnome and HAL FAQ. I don't know why this stuff,
abandoned in Linux years ago, still seems to be neccessary...



-- 
Polytropon
Magdeburg, Germany
Happy FreeBSD user since 4.0
Andra moi ennepe, Mousa, ...


More information about the freebsd-questions mailing list