My lubuntu 18.04 desktop isn't responding. So I would like to restart it.
Only virtual consoles respond, so I ctrl alt f2 to switch to one.
I first kill lxpanel and openbox processes, so they are not running.
Then try to restart them by
DISPLAY=:0 lxpanelctl restart && DISPLAY=:0 openbox --restart
But ps -A shows they are still not running. How shall I restart them?
I found this at https://wiki.lxde.org/en/Main_Menu under the refreshing the menu section. This kills and restarts lxpanel.
Is it possible to hard reboot your computer (for a modern, ACPI-compliant system usually holding down the power button for multiple seconds cuts the power to the components, after which it can be booted up normally assuming no file writes were interrupted) I suggest you only use this if your computer really is not responding, it can occasionally cause filesystem corruption.
For lxpanel try: #!/bin/bash
If you want to copy/paste directly, then use my modified one-liner:
I don't know about openbox, though.