Open File Manager as Root in Ubuntu UserLAnd - Fosslicious

Wednesday, April 3, 2019

Open File Manager as Root in Ubuntu UserLAnd

UserLAnd is an application developed to run Linux distributions on Android devices. This application is easy to use. In addition, we can also run just one application provided by UserLAnd, for example Firefox, GIMP, and others.

In this article, I want to discuss one of the problems when using UserLAnd, which is that it cannot call the application GUI through a terminal, except applications that can be run in terminals such as Vim and Nano.

The following is a screenshot of the problem that I found:
UserLAnd Ubuntu Cannot Open File Manager on Root Mode
When calling the application via the terminal, there is a notification that "Client is not authorized to connect to server Cannot open display" on terminal. The Solution is to add the code below to the .bashrc file in the Home directory.
xhost +
to allow X11 graphics to be run from root. You can write the code at the top in the .bashrc file as shown below:
bashrc file on home directory ubuntu
Let's try calling File Manager on root mode that we run in Ubuntu UserLAnd, and the results are like this:
Open File Manager as Root in UserLAnd!
What do you think? Hopefully useful for those of you who are experiencing the same problem. ENJOY !!!