Reg: running rsgislib as non root user

12 views
Skip to first unread message

Girish Kumar

unread,
Jan 10, 2017, 1:54:46 AM1/10/17
to RSGISLib Support

Dear all,

          I am working on a project which requires some of the RSGISLIB functions to be executed as non root user. I have made python code which calls the rsgislib functions. But to run the code, we have to activate the osgeoenv. Hence a shellscript has been written which will activate the osgeoenv environment and call the python code. It is working fine as the root user. But we want to run the script as non root user. While trying to run as non root user, conda command not found error comes. Tried to export path also, but still problem exists. I am using RHEL 7 server and miniconda3. Is there any step to be followed while insalling miniconda or rsgislib to overcome this issue?
        Also after running a rsgislib function, is there any exit code or error code it returns after completion, which can be passed to a calling program.

Thanks and Regards
Girish

Daniel Clewley

unread,
Jan 10, 2017, 2:34:13 AM1/10/17
to Girish Kumar, RSGISLib Support
Hi Girish,

It shouldn’t ever be necessary to run RSGISLib as root. Did you install miniconda as root rather than a normal user? If it is installed centrally (rather than the root home directory) you might be able to chown it rather than having to reinstall.

Rather than creating a Python script to call all the Python code, you should be able to just add the activate step to your .bashrc, after the line where conda has been added to the path.

The RSGISLib functions will throw an exception if they don’t complete successfully so you can turn this into error codes in your Python script if you don’t want the full traceback.

Out of interest would you be able to provide some more details of the project you are using RSGISLib for - it is useful for us to know what people are using RSGISLib for.

Thanks,

Dan

--
You received this message because you are subscribed to the Google Groups "RSGISLib Support" group.
To unsubscribe from this group and stop receiving emails from it, send an email to rsgislib-suppo...@googlegroups.com.
To post to this group, send email to rsgislib...@googlegroups.com.
Visit this group at https://groups.google.com/group/rsgislib-support.
For more options, visit https://groups.google.com/d/optout.

Reply all
Reply to author
Forward
0 new messages