Run My APP Under a user other than root
I have a Java Application that I built. However I can't run this application except I run it as root. If I change the user to someone else , I can't run my application anymore. I am having this problem with my text editors as well I can only use KWrite when I am logged on as root. other wise I have to use VI . Can some please help me with this problem.
Searching for answers. :Pengy: |
i'll assume you wrote your java app as root initially, and then saved it.
do: 'ls -l <filename>' and you should see that it is owned by root. you change this by running 'chown user:group <filename>' as root. |
I have the owner and group set to the name of my new user and still this is not working.
I get an error saying connection to ":0.0" refused by the server. |
The connection to :0.0 refused by server is a result of the XSession being owned by a different user then the one trying to execute a program in X...
|
I figured that was the problem but each time I start up the system it automatically logs in as root without asking for a password or anything. Does anyone know how to change that? I temporary fixedthe problem by saying "xhost +" . But I will rather just log in as my newly created user.
Thanks |
Can you tell us more about the system that logs as root ?
O/S ? distro ? |
It's running the latest/most current version of Red hat.
|
So you should start another thread on the Red Hat forum asking why is your system automatically launching the graphic environment as root, without prompting for a password (both facts being major security hazards), and how to disable that and return to a more reasonable system, with a login menu and root account only used for maintenance tasks.
|
All times are GMT -5. The time now is 08:28 AM. |