With our Nextcloud dashboard, you can easily track the number of files in your system, your user accounts, and your database size. Built with our infrastructure agent and Prometheus OpenMetrics integration, the Nextcloud integration gives you a set of default that let you view your most critical data all in one place.
After setting up the Nextcloud integration with New Relic, your data displays in dashboards like these right out of the box.
Install the infrastructure agent
To get data into New Relic, install our infrastructure agent. Our infrastructure agent collects and ingests data so you can keep track of your app’s performance.
You can install the infrastructure agent two different ways:
- Our guided install is a CLI tool that inspects your system and installs the infrastructure agent alongside the application monitoring agent that best works for your system. To learn more about how our guided install works, check out our Guided install overview.
- If you'd rather install our infrastructure agent manually, you can follow a tutorial for manual installation for Linux, Windows, or macOS.
Configure NRI-Flex for Nextcloud
Flex comes bundled with the New Relic infrastructure agent. To create a flex configuration file follow these steps:
Metrics for Nextcloud are available at the following URL: http://<YOUR_HOST_IP>/ocs/v2.php/apps/serverinfo/api/v1/info?format=json
Create a file named
nri-flex-nextcloud.yml
in/etc/newrelic-infra/integrations.d
Use our configuration template to update the fields
EVENT_TYPE
andYOUR_DOMAIN
in the file namednri-flex-nextcloud.yml
. The value on theevent_type
is used to store metrics on the NRDB. For example, you can updateEVENT_TYPE
toNextcloudFlexMetrics
Your nri-flex-nextcloud.yml
file should look like this:
integrations: - name: nri-flex config: name: nextcloudFlex global: base_url: http://<YOUR_HOST_IP>/ocs/v2.php/apps/serverinfo/api/v1/ user: <nextcloud_username> pass: <nextcloud_password> apis: - event_type: EVENT_TYPE url: info?format=json
Forward Nextcloud logs to New Relic
You can use log forwarding to forward Nextcloud logs to New Relic.
On Linux machines, your log file named logging.yml
should be placed in /etc/newrelic-infra/logging.d/
After creating the log file, add the following script to the logging.yml
file:
logs: - name: nextcloud.log file: /var/www/nextcloud/data/nextcloud.log attributes: logtype: nextcloud_log
Restart the New Relic infrastructure agent
Before you can start using your data, restart your infrastructure agent.
bash$sudo systemctl restart newrelic-infra.serviceInstall the Nextcloud quickstart to get our pre-built dashboards.
Find your data
You can choose our pre-built dashboard template named Nextcloud
to monitor your Nextcloud server metrics. Follow these steps to use our pre-built dashboard template:
- From one.newrelic.com, go to the + Add data page.
- Click on Dashboards.
- In the search bar, type
Nextcloud
. - The Nextcloud dashboard should appear. Click on it to install it.
Your Nextcloud dashboard is considered a custom dashboard and can be found in the Dashboards UI. For docs on using and editing dashboards, see our dashboard docs.
Use this sample query to view your Nextcloud metrics captured on one.newrelic.com:
Here's an example of NRQL query checking the number of active users for the last 5 minutes:
FROM NextcloudFlexMetrics SELECT latest(ocs.data.activeUsers.last5minutes)
Here's an example of NRQL query checking the number of active users in the last 24 hours:
FROM NextcloudFlexMetrics SELECT latest(ocs.data.activeUsers.last24hours)
What's next?
To learn more about building NRQL queries and generating dashboards:
- Read our introduction to the query builder to create basic and advanced queries.
- Read our introduction to dashboards to customize your dashboard and carry out different actions.
- See how to manage your dashboard to adjust your display mode, or to add more content to your dashboard.