Hello, I am creating a custom graphic interface with Java (Swing) and trying to start it on boot.
Machine: Raspberry Pi 4
OS: Raspbian OS Lite
Xserver has been installed, as well the Java environment.
All run smooth when, after the user login (automatic), I type the following commands:
> startx
after X server start
> java mygui.java
No issues.
If I add the commands inside the .bashrc file, to run on boot (after boot), the java gui start anyway, but I get some errors:
/usr/lib/xorg/Xorg.wrap: Only console users are allowed to run the X server
xinit giving up
xinit unable to connect to X server: Connection refused
xinit server error
Couldn't get a file descriptor referring to console
I do not understand.
Is the java program that try to run before the xserver is loaded?
I am beginner with linux.
Machine: Raspberry Pi 4
OS: Raspbian OS Lite
Xserver has been installed, as well the Java environment.
All run smooth when, after the user login (automatic), I type the following commands:
> startx
after X server start
> java mygui.java
No issues.
If I add the commands inside the .bashrc file, to run on boot (after boot), the java gui start anyway, but I get some errors:
/usr/lib/xorg/Xorg.wrap: Only console users are allowed to run the X server
xinit giving up
xinit unable to connect to X server: Connection refused
xinit server error
Couldn't get a file descriptor referring to console
I do not understand.
Is the java program that try to run before the xserver is loaded?
I am beginner with linux.