1.下载Nexus

地址:     https://pan.baidu.com/s/1D5AI6zmuRBSMK0k7j41VuQ

提取码: q50j

选择02-nexus

2.新建nexus账号

useradd nexus

重置密码

passwd nexus

123456

3.更改文件属性

chown -R nexus:nexus /opt/nexus/nexus-2.14.15-01/

chown -R nexus:nexus /opt/nexus/sonatype-work/

4.修改端口

cd /opt/nexus/nexus-2.14.15-01/conf

vi nexus.properties

#
# Sonatype Nexus (TM) Open Source Version
# Copyright (c) -present Sonatype, Inc.
# All rights reserved. Includes the third-party code listed at http://links.sonatype.com/products/nexus/oss/attributions.
#
# This program and the accompanying materials are made available under the terms of the Eclipse Public License Version 1.0,
# which accompanies this distribution and is available at http://www.eclipse.org/legal/epl-v10.html.
#
# Sonatype Nexus (TM) Professional Version is available from Sonatype, Inc. "Sonatype" and "Sonatype Nexus" are trademarks
# of Sonatype, Inc. Apache Maven is a trademark of the Apache Software Foundation. M2eclipse is a trademark of the
# Eclipse Foundation. All other trademarks are the property of their respective owners.
# # Sonatype Nexus
# ==============
# This is the most basic configuration of Nexus. # Jetty section
application-port=
application-host=192.168.125.139
nexus-webapp=${bundleBasedir}/nexus
nexus-webapp-context-path=/nexus # Nexus section
nexus-work=${bundleBasedir}/../sonatype-work/nexus
runtime=${bundleBasedir}/nexus/WEB-INF # orientdb buffer size in megabytes
storage.diskCache.bufferSize=

5.修改环境变量

vi /etc/profile

新增如下配置

#set nexus enviroment
NEXUS_HOME=/opt/nexus/nexus-2.14.-
PATH=$PATH:$NEXUS_HOME/bin
export NEXUS_HOME

刷新生效

source  /etc/profile

6.开机启动

# vi /etc/rc.d/rc.local

# set nexus auto-run when open system
su - nexus -c '/opt/nexus/nexus-2.14.15-01/bin/nexus start'

#复制脚本cp /opt/nexus/nexus-2.14.15-01/bin/nexus /etc/init.d/nexus

#添加系统服务:chkconfig --add nexus

#设置启动级别为345:chkconfig --levels 345 nexus on

#查看是否添加成功:chkconfig --list|grep nexus

#vi /etc/init.d/nexus

#第一行 设置启动账号

#RUN_AS_USER="root"

#将NEXUS_HOME=".."修改为NEXUS_HOME="/opt/nexus/nexus-2.14.15-01/"

#重启 reboot查看nexus是否启动,ps –ef|grep nexus

 

7.系统访问验证

http://192.168.125.139:8081/nexus

9.修改账号

默认账号 admin/admin123

请修改登录密码

10.重启再次验证

居然启动失败了,切换nexus账号输入 nexus console 执行一半失败了

经过日志分析2个原因:

a./opt/nexus/目录下面的有文件的所有这发生了变化,既文件的所属和权限发生了变化

b./opt/nexus/sonatype-work/nexus/conf/nexus.xml 删除该文件,运行时会自动生成

c.vi /etc/hosts 添加 127.0.0.1 机器名

经过以上分析修正后,执行正常了。

Centos610安装Nexus的更多相关文章

  1. CentOS安装Nexus(Maven私有库)详细配置及上传本地jar到私服

    Nexus原理 Maven的原理就是将jar从远程中央仓库下载到PC磁盘的本地仓库,当本地仓库没有发现需要的jar就会去Maven默认的远程中央仓库Maven Central(由Apache维护)中寻 ...

  2. 在Windows上安装Nexus 3.2.0-01

      在Windows上安装Nexus 环境: Windows 7 apache-maven-3.3.9 JDK 1.8 下载Nexus: https://sonatype-download.globa ...

  3. 在CMD命令下安装nexus报错和启动的问题

    安装问题问题描述: 在控制台(cmd)下执行nexus install命令安装nexus服务的时候报错: wrapper | OpenSCManager failed - 拒绝访问. (0x5) 同时 ...

  4. CentOS 7下安装nexus 3

    安装nexus 3的几个注意事项: 1.nexus 3和nexus 2不一样,nexus 2可以搜索Maven主仓库的包,但在nexus 3不能,只能搜索缓存过的包. 2.安装时关心的点在于运行环境, ...

  5. Linux环境安装Nexus

    Linux环境安装Nexus Nexus可以做Maven私服,私服不是Maven的核心概念,它仅仅是一种衍生出来的特殊的Maven仓库.有三种专门的Maven仓库管理软件可以用来帮助大家建立私服: N ...

  6. Maven nexus 安装nexus私服出现的两个问题

    1. 在win10中安装nexus时提示:wrapper | OpenSCManager failed - 拒绝访问. (0x5) 主要是没有权限.需要以管理员的身份运行 如果你是直接点击 start ...

  7. (十一)maven之安装nexus私服

    安装nexus私服 前面的文章中对项目引入jar依赖包的时候,maven一般先是在本地仓库找对应版本的jar依赖包,如果在本地仓库中找不到,就上中央仓库中下载到本地仓库. 然而maven默认提供的中央 ...

  8. 在Windows上安装Nexus

    在Windows上安装Nexus 学习了:https://www.cnblogs.com/yucongblog/p/6696736.html 下载地址:https://sonatype-downloa ...

  9. Maven nexus 安装nexus : wrapper | OpenSCManager failed - 拒绝访问。 (0x5)

    在win7中安装nexus时提示:wrapper | OpenSCManager failed - 拒绝访问. (0x5) 主要是没有权限.需要以管理员的身份运行 如果你是直接点击 start-nex ...

随机推荐

  1. 53最大子序和.py

    题目:给定一个整数数组 nums ,找到一个具有最大和的连续子数组(子数组最少包含一个元素),返回其最大和. 来源:https://leetcode-cn.com/problems/maximum-s ...

  2. JS 获取随机颜色值

    获取随机颜色值 function fn1(){ return '#' + Math.floor( Math.random() * 0xffffff ).toString(16); } function ...

  3. Python - python3.7新增的contextvars vs Thread local(threading.local)

    总结 和threading.local()类似.Python3.7新增. thread.local(): 不同线程,同一个变量保存不同的值. contextvars: 不同上下文,同一个变量保存不同的 ...

  4. crowdfunding项目01——感人的错误

    四十搭环境,半个小时下载jar包,网速感人,一个半小时找bug真是感动 首先SSM项目,主要功能进行增删改查 建立父工程和子工程,产生依赖关系 父工程:pom 子工程:jar.war(web工程) 错 ...

  5. Docker+JMeter单机版+Nginx

    基于JMeter5.1.1+Nginx1.12.2JMeter发起压测  Nginx作为文件服务器 一.目录结构: Dockerfile文件: FROM ubuntu:18.04# 基础镜像 MAIN ...

  6. Java之字符串输入next()与nextLine()

            next():一定要读取到有效字符后才可以结束输入,对输入有效字符之前遇到的空格键.Tab键或Enter键等结束符,next()方法会自动将其去掉: 只有在输入有效字符之后,next( ...

  7. AcWing 842. 排列数字

    深搜的一道水题 https://www.acwing.com/problem/content/844/   正确输入输出 #include<bits/stdc++.h> using nam ...

  8. javaFx中Image的路径问题

    网络图像文件前面加“http://”,而本地文件则要加“file:”.将源代码改为: Image image = new Image("file:image/qq.jpg"); I ...

  9. mac VirtualBox虚拟机装CentOS,并配置网络,使其发布的静态网站能访问

    1.下载VirtualBox(macOS版本) 下载地址:https://download.virtualbox.org/virtualbox/6.0.8/VirtualBox-6.0.8-13052 ...

  10. schroeder reverb matlab实现

    原理参考:Natural sounding artificial reverberation combFilter.m: function output = combFilter(delay, gai ...