The Nexus 3 server log

8,590 views
Skip to first unread message

Sverre Moe

unread,
Sep 26, 2016, 5:29:28 AM9/26/16
to Nexus Users
Where can I find the Nexus 3 server log? I have installed Nexus 3 alongside Nexus 2 under /opt/nexus.
I logged in as the same user that was running Nexus 2, executed /opt/nexus/bin/nexus start.
However the Nexus 3 did not start, and I cannot find the log to investigate what went wrong.

With Nexus 2 the log was located under NEXUS_HOME/logs/wrapper.log

Peter Lynch

unread,
Sep 26, 2016, 9:10:51 AM9/26/16
to Sverre Moe, Nexus Users
Hi Sverre,

I have installed Nexus 3 alongside Nexus 2 under /opt/nexus

To be clear, the two instances cannot and should not attempt to share files. I am not sure what you mean "alongside". Next to, but independent of each other would be OK.

The Nexus 3 data directory contains a log directory. 

In that directory there should be the following files:

nexus.log - main application log to look for errors
karaf.log - the Apache Karaf container log file - should contain very minimal messages related to booting Nexus via the container
requet.log - http request log for http requests into a running Nexus

I noticed we could do a better job documenting this in the book, so I filed this:


-Peter

--
You received this message because you are subscribed to the Google Groups "Nexus Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to nexus-users+unsubscribe@glists.sonatype.com.
To post to this group, send email to nexus...@glists.sonatype.com.
To view this discussion on the web visit https://groups.google.com/a/glists.sonatype.com/d/msgid/nexus-users/c26949c6-2dcf-47ac-91e8-e9db9618bbed%40glists.sonatype.com.
For more options, visit https://groups.google.com/a/glists.sonatype.com/d/optout.

Sverre Moe

unread,
Sep 26, 2016, 9:48:11 AM9/26/16
to Peter Lynch, Nexus Users
Thanks for that information. What I meant with alongside was installed
on the same server. They do not share any files, since Nexus 3 does
not have a sonatype-work directory that Nexus 2 does. The Nexus 2
installation is located on /home/build/nexus-2.14.0-1. while I
unpacked Nexus 3 under /opt/nexus as recommended in the documentation.
>> email to nexus-users...@glists.sonatype.com.

Sverre Moe

unread,
Sep 27, 2016, 3:44:23 AM9/27/16
to Nexus Users, sverr...@gmail.com
mandag 26. september 2016 15.10.51 UTC+2 skrev Peter Lynch følgende:
Hi Sverre,

The Nexus 3 data directory contains a log directory. 

In that directory there should be the following files:

nexus.log - main application log to look for errors
karaf.log - the Apache Karaf container log file - should contain very minimal messages related to booting Nexus via the container
requet.log - http request log for http requests into a running Nexus
 
I have no log files within /opt/nexus/data directory. 

Matthew Barker

unread,
Sep 27, 2016, 9:09:01 AM9/27/16
to Sverre Moe, Nexus Users
Sverre,

Click on the link in Peter's e-mail labeled "data directory" to go to an article to determine where your data directory resides, here is the URL again:


Under that data directory will be a log directory.

Best,
Matthew

Matthew Barker | Sr Principle Solutions Architect

--
You received this message because you are subscribed to the Google Groups "Nexus Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to nexus-users+unsubscribe@glists.sonatype.com.
To post to this group, send email to nexus...@glists.sonatype.com.



--

Matthew Barker | Sr Principle Solutions Architect

Sverre Moe

unread,
Sep 27, 2016, 9:16:52 AM9/27/16
to Nexus Users, sverr...@gmail.com
I already have determined where my data directory resides. There are no log files under this directory, nor is there a log directory.

build@nexus:/opt/nexus> ./bin/nexus start
Starting nexus
build@nexus:/opt/nexus> ./bin/nexus status
nexus is stopped.
build@nexus:/opt/nexus> find data/
data/
data/clean_cache
data/tmp
data/tmp/.placeholder
To unsubscribe from this group and stop receiving emails from it, send an email to nexus-users...@glists.sonatype.com.

To post to this group, send email to nexus...@glists.sonatype.com.

Rich Seddon

unread,
Sep 27, 2016, 10:06:55 AM9/27/16
to Sverre Moe, Nexus Users
That does not look like an active data directory, that data directory listing only has the files we ship with.  Once you start Nexus you should see the following in the data directory:

blobs/
cache/
db/
downloads/
elasticsearch/
etc/
generated-bundles/
health-check/
instances/
keystores/
lock
log/
logback/
orient/
port
tmp/

Go to "support/system information" in the administration UI, and see what the "workingDirectory" is set to.

Rich


To unsubscribe from this group and stop receiving emails from it, send an email to nexus-users+unsubscribe@glists.sonatype.com.

To post to this group, send email to nexus...@glists.sonatype.com.

Rich Seddon

unread,
Sep 27, 2016, 10:15:18 AM9/27/16
to Sverre Moe, Nexus Users
Sorry about that, I missed the fact that it wouldn't startup.

Can you try running Nexus in console mode?

./bin/nexus run

That will print startup messages to console.

Sverre Moe

unread,
Sep 28, 2016, 1:46:09 AM9/28/16
to Nexus Users, sverr...@gmail.com
Running with ./bin/nexus run I was able to find out why it would start.
The user build I am using to run Nexus did not have access to /opt/nexus

build@nexus:/opt/nexus> ./bin/nexus run
Unable to update instance pid: Unable to create directory /opt/nexus/data/instances
/opt/nexus/data/log/karaf.log (No such file or directory)
Unable to update instance pid: Unable to create directory /opt/nexus/data/instances

I changed ownership of /opt/nexus from root to build and thus was able to start up Nexus 3.
Reply all
Reply to author
Forward
0 new messages