New Relic One Top Nerdpack

@gjajka this Nerdpack doesn’t present itself as a launcher on the New Relic One homepage. You need to navigate to the Entity Explorer > Select an Infrastructure Host. Then you’ll see the Top Nerdlet on the left nav of your screen.

The reason is that this piece of functionality needs a context of an Entity in order to know what processes, etc. it’s reporting.

I hope that helps.

1 Like

@joelworrall thanks for the information…I am up and running now.

Cheers,

1 Like

Great! Thanks for confirming @gjajka :smiley:

@joelworrall @RyanVeitch…I am not sure if this is the proper site to report bugs…but Top will crash if you select a custom time from the Custom pull down menu.

You can also reproduce this issue if you use the zoom in functionality.

Let me know if you need more details.

Good luck.

thanks

Hey @gjajka - Interesting - we’re working on the ability to remove the custom timepicker in Nerdpacks, because it’s not always useful in custom nerdpacks. Top may be one of those where the timepicker has not been set up in the nerdpack code, so shouldn’t have an effect. I’ll pass on to the team that these problems should show intuitive errors though, rather than crashing the nerdpack.

Thanks for reporting this. It’ll be logged as an issue in the repo and we’ll seek to address in the open source project.

FYI @gjajka, this is resolved in v. 0.1.7 https://github.com/newrelic/nr1-top/releases/tag/v0.1.7

2 Likes

When I launch Top, I get this: “No entity found - This Nerdpack must be run on a monitored host with the New Relic Infrastructure agent deployed on it. Please select a host that meets that criteria.” although I def have the infra agent installed on the host. Any ideas?

The issue is that the Nerdlet wasn’t enabled for the account under which that entity exists. Enable it for the account, and the problem is solved.

1 Like

I deployed the nr1-top using the following commands.
Please note, that I had to update the version for that (which solved issues mentioned in the previous post - I deleted it as not relevant). But in spite of the successful build, and running server ( nr1 nerdpack:serve) I cannot see anything on https://one.newrelic.com/?nerdpacks=local
Infrastructure agent is running on the node and produces output
How can I troubleshoot this issue?

(Installation log is in the first answer to this post. I put it there to avoid the pollution of the main thread. I tried to upload it as an attachment, but as new user I’m not authorised to add attachments to my posts. My apologies)

upgrade node

sudo npm cache clean -f
sudo npm install -g n
sudo n stable

install nerd package

curl -s https://cli.nr-ext.net/installer.sh | sudo bash
nr1 --version
nr1 profiles:add --name company --api-key API KEY REDACTED --region us
git clone https://github.com/newrelic/nr1-top.git
cd cd nr1-top
cd nr1-top/
nr1 nerdpack:uuid -gf
npm install
npm start

Installation log

I’m terrible sorry for putting it here, but as the new user I cannot attach files to my posts :frowning:

Connection to 127.0.0.1 closed.
DeepThoughtDesk01:~ DeepThoughtDesk$ ssh seva@127.0.0.1 -p 2201
seva@127.0.0.1's password:
Welcome to Ubuntu 18.04.4 LTS (GNU/Linux 5.3.0-51-generic x86_64)

 * Documentation:  https://help.ubuntu.com
 * Management:     https://landscape.canonical.com
 * Support:        https://ubuntu.com/advantage

 * Ubuntu 20.04 LTS is out, raising the bar on performance, security,
   and optimisation for Intel, AMD, Nvidia, ARM64 and Z15 as well as
   AWS, Azure and Google Cloud.

     https://ubuntu.com/blog/ubuntu-20-04-lts-arrives


 * Canonical Livepatch is enabled.
   - All available patches applied.

0 packages can be updated.
0 updates are security updates.

Your Hardware Enablement Stack (HWE) is supported until April 2023.
Last login: Wed May  6 05:04:50 2020 from 10.0.2.2
seva@NewRelic-Lab01:~$ curl -s https://cli.nr-ext.net/installer.sh | sudo bash
[sudo] password for seva:
Installing from DEB repository

Setting up repository
OK
Hit:1 https://download.newrelic.com/infrastructure_agent/linux/apt bionic InRelease
Hit:2 http://de.archive.ubuntu.com/ubuntu bionic InRelease
Hit:3 https://download.docker.com/linux/ubuntu bionic InRelease
Hit:4 http://de.archive.ubuntu.com/ubuntu bionic-updates InRelease
Hit:5 http://de.archive.ubuntu.com/ubuntu bionic-backports InRelease
Get:6 http://security.ubuntu.com/ubuntu bionic-security InRelease [88,7 kB]
Hit:7 https://packages.cloud.google.com/apt kubernetes-xenial InRelease
Get:8 https://cli.nr-ext.net/deb  InRelease [2.917 B]
Get:9 http://security.ubuntu.com/ubuntu bionic-security/main amd64 DEP-11 Metadata [38,7 kB]
Get:10 http://security.ubuntu.com/ubuntu bionic-security/universe amd64 DEP-11 Metadata [42,0 kB]
Get:11 http://security.ubuntu.com/ubuntu bionic-security/multiverse amd64 DEP-11 Metadata [2.464 B]
Get:12 https://cli.nr-ext.net/deb  Packages [452 B]
Fetched 175 kB in 1s (123 kB/s)
Reading package lists... Done

Installing nr1 package
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following packages were automatically installed and are no longer required:
  efibootmgr libfwup1 libwayland-egl1-mesa
Use 'apt autoremove' to remove them.
The following NEW packages will be installed:
  nr1
0 upgraded, 1 newly installed, 0 to remove and 0 not upgraded.
Need to get 20,8 MB of archives.
After this operation, 0 B of additional disk space will be used.
Get:1 https://cli.nr-ext.net/deb  nr1 1.22.2-1 [20,8 MB]
Fetched 20,8 MB in 5s (4.420 kB/s)
Selecting previously unselected package nr1.
(Reading database ... 177250 files and directories currently installed.)
Preparing to unpack .../nr1_1.22.2-1_amd64.deb ...
Unpacking nr1 (1.22.2-1) ...
Setting up nr1 (1.22.2-1) ...

All done!
seva@NewRelic-Lab01:~$
seva@NewRelic-Lab01:~$
seva@NewRelic-Lab01:~$ nr1 --version
@datanerd/nr1/1.22.2 linux-x64 node-v10.16.3
seva@NewRelic-Lab01:~$ nr1 profiles:add --name wandisco --api-key _API KEY REDACTED_ --region us

Customer agrees that by answering yes that New Relic and its affiliates have the
right to collect Usage Data from Customer through the NR1 CLI and use Usage Data
to support, operate and improve New Relic products and services and for other
lawful business purposes.

"Usage Data" means diagnostics data related to the use of the NR1 CLI with New
Relic Products, including, without limitation, errors, machine operating system
(i.e. Windows/Linux and version), the command that triggered the error (word by
word, what the user typed in the NR1 CLI), trace of the error (which may include
user name), error message, and usage tracking.

For clarity, Usage Data is not considered "Customer Data", "Performance Data" or
any other similar term as used in any applicable subscription or license
agreement for New Relic Products. At Customer's election, Customer may disable
the collection of Usage Data as described in the NR1 CLI documentation.

✔ Do you want to help improve the NR1 CLI by sending usage statistics? … yes
 ✔  Added profile wandisco.
This is the first profile created, so it will be used by default from now on. Run nr1 profiles:default to choose a default profile.
seva@NewRelic-Lab01:~$ sudo npm cache clean -f
npm WARN using --force I sure hope you know what you are doing.
seva@NewRelic-Lab01:~$ sudo npm install -g n

/usr/local/bin/n -> /usr/local/lib/node_modules/n/bin/n
/usr/local/lib
└── n@6.5.1

seva@NewRelic-Lab01:~$
seva@NewRelic-Lab01:~$ sudo n stable

  installing : node-v12.16.3
       mkdir : /usr/local/n/versions/node/12.16.3
       fetch : https://nodejs.org/dist/v12.16.3/node-v12.16.3-linux-x64.tar.xz
   installed : v12.16.3 (with npm 6.14.4)

Note: the node command changed location and the old location may be remembered in your current shell.
         old : /usr/bin/node
         new : /usr/local/bin/node
To reset the command location hash either start a new shell, or execute PATH="$PATH"

seva@NewRelic-Lab01:~$ git clone https://github.com/newrelic/nr1-top.git
Cloning into 'nr1-top'...
remote: Enumerating objects: 161, done.
remote: Counting objects: 100% (161/161), done.
remote: Compressing objects: 100% (113/113), done.
remote: Total 427 (delta 84), reused 104 (delta 38), pack-reused 266
Receiving objects: 100% (427/427), 2.24 MiB | 3.21 MiB/s, done.
Resolving deltas: 100% (219/219), done.
seva@NewRelic-Lab01:~$ cd cd nr1-top
-bash: cd: too many arguments
seva@NewRelic-Lab01:~$ cd nr1-top/
seva@NewRelic-Lab01:~/nr1-top$ nr1 nerdpack:uuid -gf
The new generated id is f018cf66-9d18-4002-a739-44235264efc7
seva@NewRelic-Lab01:~/nr1-top$ npm install

> core-js-pure@3.6.4 postinstall /home/seva/nr1-top/node_modules/core-js-pure
> node -e "try{require('./postinstall')}catch(e){}"

Thank you for using core-js ( https://github.com/zloirock/core-js ) for polyfilling JavaScript standard library!

The project needs your help! Please consider supporting of core-js on Open Collective or Patreon:
> https://opencollective.com/core-js
> https://www.patreon.com/zloirock

Also, the author of core-js ( https://github.com/zloirock ) is looking for a good job -)

added 330 packages from 252 contributors and audited 1164 packages in 11.273s

32 packages are looking for funding
  run `npm fund` for details

found 0 vulnerabilities

seva@NewRelic-Lab01:~/nr1-top$ npm start

> nr1-top@0.5.2 start /home/seva/nr1-top
> nr1 nerdpack:serve

Found and loaded 1 nr1.json files on Top (f018cf66-9d18-4002-a739-44235264efc7) Nerdpack.

Nerdpack:
 ✔  Top (f018cf66-9d18-4002-a739-44235264efc7) nr1.json

Nerdlets:
 ✔  top-nerdlet nerdlets/top-nerdlet/nr1.json

There is no certificate created yet.
 ✔  New certificate created.


🛠  Built artifact files for:
 ⁎  f018cf66-9d18-4002-a739-44235264efc7--top-nerdlet built ✔

 ✔  Nerdpack built successfully!
 ★  Starting as orchestrator...

 ✔  Server ready! Test it at: https://one.newrelic.com/?nerdpacks=local
 ↩  Server will reload automatically if you modify any file!

Hi @v.semouchin your latest reply implies that you do indeed have the nerdpack running and it should appear as a launcher here: https://one.newrelic.com/?nerdpacks=local

I’m curious if you see any browser console errors?

If there is nothing there that appears related, can you also ensure that you are logged into the New Relic account from which the API key was generated from?


Alternatively, you can try to install the Top Nerdpack to your accounts from the New Relic One Catalog:
https://docs.newrelic.com/docs/new-relic-one/use-new-relic-one/build-new-relic-one/discover-manage-applications-new-relic-one-catalog

Hi, Ryan,
as mentioned I logged in my only NewRelic account. I can see infrastructure agents running. With APM and browser I have another issue - I use the shopper application + selenium browser (from NewRelic candidate assignment) to generate the web traffic on the. But unfortunately 1) Shopper fails to load test data into mySql database (I contacted shopper community they promise to send me sql script which will do the job. Still waiting) and 2) the chrome driver from selenium browser crashes too which cause the browser contains to take about 50-60% or CPU time. I have two VMs with same application deployed on them the same issue on both after clean rebuild as well. So do not see anything it the browser console. I see only that 2 applications are there.
Anyway it is a different issue. But the message is - yes, everything is OK with account. If you mean the application browser - I cannot use it yet.
I will try to download the application from the NewRelic catalog this evening

Hi @v.semouchin - Are you using New Relic Synthetics? Or are you running Selenium tests locally?

Were you able to get the nerdpack from the Application Catalog?

Hi, @RyanVeitch,

  1. I do not use Newrelic Synthetics, just a containerized Selenium Browser + python script
  2. When I go to the NewRelic one catalog I see that only three apps have a “Add this app” button - browser analyzer, cloud optimizer, and status pages. All other including top don’t. Ann all three buttons are greyed out. I created in my trial account another user with base role “User” and all add-on roles, including the “Nerdpack Manager”, but this does not change anything.
    Yes, I’m using this new user to post this message, this is maybe the reason, why my name is “df98483b7b83e612aa81”

Looks like that the reason why the application is not visile in locals is the following:

seva@NewRelic-Lab01:~/nr1-top$ nr1 nerdpack:uuid --generate --force --verbose
init version: @oclif/command@1.5.19 argv: [ ‘–generate’, ‘–force’, ‘–verbose’, [length]: 3 ]
Using profile V.Semouchin
Request: POST https://artifact-registry.service.eu.newrelic.com/graphql
Data: mutation {
generatePackageUuid
}
Headers: {
‘API-Key’: ‘NRAK-XXXXXXXXXXXXXXXXXQUY’,
‘Content-Type’: ‘application/graphql’
}

Sending usage event cliError
:heavy_multiplication_x: Error: Please accept the New Relic Developer Terms and Conditions prior to executing this operation.

{ locations: [ { line: 3, column: 17 } ],
path: [ ‘generatePackageUuid’ ],
extensions: { type: ‘TERMS_AND_CONDITIONS_NOT_ACCEPTED’ },
code: ‘TERMS_AND_CONDITIONS_NOT_ACCEPTED’,
origin: ‘graphql-service’ }
seva@NewRelic-Lab01:~/nr1-top$

Please follow the discussion on it in New Relic One terms and conditions

For folks looking at this thread for a resolution to the issues faced by @AAASeva, Please check out this thread:

Hi,

I’m following the New Relic Candidate Assessment and I bump into the fact that it seems that my API key is missing or invalid when applying

nr1 profiles:add --name setisbew --api-key NRAA-xxxxxxxxxxxxxxxxxxxxxxxe05b --region us
nr1 nerdpack:uuid -gf`

I tried to regenerate the REST API and the API. Nothing helps.
Where does it go wrong?

Nevermind!

I found out that my region is the ‘eu’, and not the ‘us’. The API-key is off course not applicable for the wrong region. :slight_smile:

1 Like

Thanks for following up with that @martin.de.bes - glad you got it figured out.