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. Python之路【第三十二篇】:django 分页器

    Django的分页器paginator 文件为pageDemo models.py from django.db import models # Create your models here. cl ...

  2. 本地cmd连接远程mysql数据库

    一.登录远程mysql 输入mysql -h要远程的IP地址 -u设置的MySQL用户名 -p登录用户密码 例如:mysql -h 192.168.1.139 -u root -p dorlocald ...

  3. vue引用fastClick后,ios输入框聚焦不灵敏问题

    fastClick.prototype.focus = function (targetElement) {       targetElement.focus() }

  4. 题解【Codeforces886B】Vlad and Cafes

    本题是模拟题. 我们可以用b数组记录每个数字在a数组中出现的最后位置,然后从0到2·10^5依次寻找最后一次出现最早的数(注意是0!),最后统计输出即可. AC代码: #include <bit ...

  5. ffmpeg-- audio decoder

    测试代码来源于:http://ffmpeg.org/doxygen/trunk/decode_audio_8c-example.html /* * Copyright (c) 2001 Fabrice ...

  6. 程序设计实验:一个Python游戏,体验软件开发。

    小组在GitHub上找了一个Pygame实现的超级马里奥游戏.所以我的学习过程大致如下: 1.快速学习Python基础语法. 2.学习pygame并着手理解这个项目. 3.完成作业以及各种文档报告. ...

  7. 安装k8s出现 Failed to list *api.Node: Get http://192.168.144.131:8080...: dial tcp 192.168.144.131:8080: getsockopt: no route to

    原因是master主机的防火墙没关,导致无法访问主机的8080端口,解决方法暂时关闭主机上的防火墙. * centos6 : service iptables stop * centos7 : sys ...

  8. EntityFramework 根据时间筛选数据

    需求:根据当前时间,获取条件合适的数据,其中截止时间只比较日期. 1. 运行会报错的版本: var lifeWorkEventBatch = clientRepositoryContainer.Lif ...

  9. SQL更新语句的执行

    联系上文SQL查询语句的执行 查询语句的那一套流程,更新语句也是同样会走一遍. 更新流程还涉及两个重要的日志模块: ​ redo log(重做日志)和 binlog(归档日志) redo log:重做 ...

  10. Java - 集合 - Map

    Map 1.Map实现类:HashMap.Hashtable.LinkedHashMap.TreeMap HashMap 新增元素/获取元素 1 void contextLoads() { 2 //声 ...