If you insist running as root, then set the environment variable RUN_AS_USER=root

来源:互联网 发布:广州万维软件 编辑:程序博客网 时间:2024/06/07 15:31

If you insist running as root, then set theenvironment variable RUN_AS_USER=root before running this script.


       在配置Nexus的时输入命令 ./nexus start后出现“ If you insist running as root, then set thee nvironment variable RUN_AS_USER=root before running this script. ”的警告信息。大概的意思是:如果你想使用root用户,那么在运行开始脚本之前应该设置环境变量”RUN_AS_USER=root"。

        

        解决方法

        关于这个问题共有两种解决方法,一种是临时解决,一种是永久的解决。


        1、临时方法

        

        输入:export RUN_AS_USER=root 后在执行 ./nexus start 运行结果如下图:

        

        2、永久方法


        在系统用配置即可,输入:vi /etc/profile向其中加入exportRUN_AS_USER=root,修改后保存退出,如下图

        

        修改完之后,先关闭nexus,再启动,如下图


        

        简简单单的几步就OK啦

阅读全文
0 0
原创粉丝点击