zoukankan      html  css  js  c++  java
  • nexus私服linux搭建问题

    一、这几天服务器挂了,nexus私服没有备份出来,只能手动再安装一个新的在新的服务器上。

    前提是该服务器已经配置好了JDK,当前服务器版本是jdk1.6.0_29-64    。

    nexus安装包下载:http://www.sonatype.org/nexus/archived

    先是下载目前最新的版本

    Nexus 2.6.3              2013-09-16

    有提供zip和tar.gz格式,随便下哪种都可以。解压后安装到/opt/nexus目录。


    二、解压之后会有两个文件夹,nexus-2.6.0-05和sonatype-work,我们进入第一个文件夹的bin目录来启动nexus 。

    1、进入启动目录,启动

    cd nexus-2.6.0-05/bin/
    ./nexus start


    2、这时候提示:

    ****************************************
    WARNING – NOT RECOMMENDED TO RUN AS ROOT
    ****************************************
    If you insist running as root, then set the environment variable RUN_AS_USER=root before running this script.


    大概意思就是要在环境配置export RUN_AS_USER=root,临时配置

    在命令行下输入:

    export RUN_AS_USER=root

    然后执行,就不会再提示了
    ./nexus start


    3、也可以在系统里面永久配置

    vi /etc/profile  加入export RUN_AS_USER=root


    三、启动之后查看日志(日志路径:nexus/logs)

    报:

    wrapper  | Reloading Wrapper configuration...
    wrapper  | Launching a JVM...
    wrapper  | JVM exited while loading the application.
    jvm 5    | Exception in thread "main" java.lang.UnsupportedClassVersionError: org/sonatype/nexus/bootstrap/jsw/JswLauncher : Unsupported major.minor version 51.0
    jvm 5    |     at java.lang.ClassLoader.defineClass1(Native Method)
    jvm 5    |     at java.lang.ClassLoader.defineClassCond(ClassLoader.java:631)
    jvm 5    |     at java.lang.ClassLoader.defineClass(ClassLoader.java:615)
    jvm 5    |     at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:141)
    jvm 5    |     at java.net.URLClassLoader.defineClass(URLClassLoader.java:283)
    jvm 5    |     at java.net.URLClassLoader.access$000(URLClassLoader.java:58)
    jvm 5    |     at java.net.URLClassLoader$1.run(URLClassLoader.java:197)
    jvm 5    |     at java.security.AccessController.doPrivileged(Native Method)
    jvm 5    |     at java.net.URLClassLoader.findClass(URLClassLoader.java:190)
    jvm 5    |     at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
    jvm 5    |     at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301)
    jvm 5    |     at java.lang.ClassLoader.loadClass(ClassLoader.java:247)
    jvm 5    | Could not find the main class: org.sonatype.nexus.bootstrap.jsw.JswLauncher.  Program will exit.
    wrapper  | There were 5 failed launches in a row, each lasting less than 300 seconds.  Giving up.
    wrapper  |   There may be a configuration problem: please check the logs.
    wrapper  | <-- Wrapper Stopped


    网上解释是要JAVA7才行。唉只能下个低版本了。


    四、重新下了个nexus-oss-webapp-1.9.2.4-bundle.zip 版本。

    解压/opt/nexus1924/bin/jsw/linux-x86-64  目录下启动就可以访问了。

    http://192.168.13.31:8081/nexus

    默认管理员用户名/密码: admin/admin123


    五、参考

    http://blog.youxey.com/archives/293.html   Linux/CentOS安装maven私有仓库nexus

    http://blog.csdn.net/shandian534/article/details/8987349    Nexus 安装与配

    http://snowolf.iteye.com/blog/1605811  Maven零散笔记——配置Nexus

    http://www.blogjava.net/javalinjx/archive/2013/08/21/403110.html  linux系统之上搭建maven 之nexus服务篇

    http://wenku.baidu.com/view/a9a0618acc22bcd126ff0c4a.html    Nexus入门指南(图文)





    版权声明:本文为博主原创文章,未经博主允许不得转载。

  • 相关阅读:
    MyEclipse2014中SVN的使用方法
    使用Navicat V8.0创建数据库,外键出现错误ERROR 1005: Can’t create table (errno: 121)
    个人简历
    Android Studio集成SVN报错:can't use subversion command line client : svn
    面向对象原型的七种方法详解(前)
    js中return的用法
    面试题总结
    Ajax 是什么?Ajax 的交互模型?同步和异步的区别?如何解决跨域问题?以及 HTTP状态码
    css3实现的3中loading动画效果
    CSS3绘制弹球动画效果
  • 原文地址:https://www.cnblogs.com/cuker919/p/4878524.html
Copyright © 2011-2022 走看看