mirror of
https://github.com/Cacti/documentation.git
synced 2026-12-06 15:13:53 +09:00
docs: [1.2.x] refresh the front page, correct grammar and Markdown, and align plugin pages with their READMEs (#273)
* docs: [1.2.x] refresh the manual front page The front page opened with version notes before saying what Cacti is, used headings as sentences in the credits, and its table of contents listed seven sections while the page has ten. Open with a short description and a getting-started sequence, link the website and forums, give the credits real headings, and list every section in the table of contents in page order. Record Jeff Pasnak under In Memoriam with a link to the 1.2.31 release announcement. Correct label typos and wrap long entries with reference links. Existing section anchors are unchanged, and every page is still linked. Signed-off-by: Thomas Vincent <thomasvincent@gmail.com> * docs: [1.2.x] fix typos, unrendered headings and forum links A check of every page linked from the front page found misspellings in eleven pages, three Mactrack headings written without a space after the hashes, which render as plain text, and two forum links still using http. Correct the spellings, add the missing space so the headings render, and point the forum links at https, where they already redirect. Signed-off-by: Thomas Vincent <thomasvincent@gmail.com> * docs: [1.2.x] align the plugin pages with the plugin READMEs The supported plugins list and the Syslog and Mactrack pages had drifted from the README and INFO files in the plugin repositories. Update the descriptions that the READMEs contradict: Monitor's Thold requirement, the Router Configs transfer methods, the ReportIt release and Cacti versions, the WMI collection methods and its development status, and NUT support in Apcupsd. Add the Syslog requirements, the upgrade procedure, the dedicated database settings and the remote collector settings, and correct the database grant and a misplaced code fence. Add the Mactrack requirements and a short section on history partitioning and ignored ports that links to the README. Signed-off-by: Thomas Vincent <thomasvincent@gmail.com> * docs: [1.2.x] correct grammar, spelling and broken Markdown A read of every page linked from the front page found grammar and spelling errors throughout, and Markdown that does not render as intended. Correct grammar, spelling, punctuation and product-name capitalization in 95 pages without changing headings, code blocks, link targets or the meaning of the text. Repair the Markdown defects: a code fence in the SSH tunnel how-to that never closed, malformed bold markers in the user management and device defaults pages, a release notes table with no blank line before it, split rows in the tree sorting table, and LDAP list items missing their markers. Correct three interface labels quoted with typos. Signed-off-by: Thomas Vincent <thomasvincent@gmail.com> * docs: [1.2.x] correct statements that differ from the 1.2.x source Reviewers of the linked pages flagged statements that looked wrong. Each was compared with the Cacti 1.2.x source at 1523aa04b, and only those the source or the page itself settles are changed. Correct interface labels and option names (Index Count Changed, Permissive, Not Selected, Utilities, the BCC description, the gear icon for plugin install), the default Maximum Value of U for a new data source item, the sysDescr object name, the PHP floor wording in the requirements table, the Mactrack wildcard character and the snmptrapd -On option. Repair cross-references, example values that disagree with their commands, two table captions, a split list and several sentences with missing words. Statements the source does not settle are left as written. Signed-off-by: Thomas Vincent <thomasvincent@gmail.com> --------- Signed-off-by: Thomas Vincent <thomasvincent@gmail.com>
This commit is contained in:
1 parent
c53d1ac3a2
commit
741ad51355
100 files changed
+1574
-1467
No files matched your search
+78
-76
@@ -1,7 +1,7 @@
|
||||
# Command Line Scripts (CLI)
|
||||
|
||||
Cacti supports a number of command line scripts. You will find them in the
|
||||
`./cli` directory. The CLI scripts fall into multiple categories, they include:
|
||||
`./cli` directory. The CLI scripts fall into multiple categories; they include:
|
||||
|
||||
- **Automation** - Utilities to help automate adding objects to Cacti
|
||||
- **Maintenance** - Utilities to help keep Cacti healthy
|
||||
@@ -10,7 +10,7 @@ Cacti supports a number of command line scripts. You will find them in the
|
||||
components
|
||||
- **Install/Upgrade** - Utilities to help with installing and upgrading Cacti
|
||||
|
||||
In the table below, each of the CLI scripts are categories and explained
|
||||
In the table below, each of the CLI scripts is categorized and explained
|
||||
briefly.
|
||||
|
||||
## Automation Scripts
|
||||
@@ -23,17 +23,17 @@ briefly.
|
||||
| add_graph_template.php | Automation | Allows adding a Graph Template to Cacti. |
|
||||
| add_graphs.php | Automation | Allows adding a Graph to Cacti. |
|
||||
| add_perms.php | Automation | Allows adding permissions to Cacti. |
|
||||
| add_tree.php | Automation | Allows adding tree's tree branches and objects to Cacti Trees. |
|
||||
| add_tree.php | Automation | Allows adding trees, tree branches and objects to Cacti Trees. |
|
||||
| apply_automation_rules.php | Automation | Executes Cacti automation rules for devices selected by id, hostname or description. |
|
||||
| remove_device.php | Automation | Allows removing Devices selected by id, IP address or description. |
|
||||
| plugin_manage.php | Automation | Allows installing, enabling, disabling and uninstalling plugins. |
|
||||
| copy_user.php | Maintenance | Allows creating new users from Templates |
|
||||
| copy_user.php | Automation | Allows creating new users from Templates |
|
||||
|
||||
## Maintenance Scripts
|
||||
|
||||
| Script | Category | Description |
|
||||
| ------------------------------------- | ----------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
|
||||
| input_whitelist.php | Maintenance | To to onboard new Data Input Methods when using Cacti in a high security environment where new Data Input Methods must always be vetted before enabling for general use. |
|
||||
| input_whitelist.php | Maintenance | To onboard new Data Input Methods when using Cacti in a high security environment where new Data Input Methods must always be vetted before enabling for general use. |
|
||||
| poller_graphs_reapply_names.php | Maintenance | Allows selecting re-running of Cacti's suggested values engine for Graphs |
|
||||
| poller_reindex_hosts.php | Maintenance | Batch method to re-index Cacti Devices |
|
||||
| analyze_database.php | Maintenance | Analyzes all Cacti tables rebuilding their index cardinality. Important to run after having added large numbers of Devices and Graphs to Cacti. |
|
||||
@@ -57,7 +57,7 @@ briefly.
|
||||
| audit_graph_template_inputs.php | Repair | Reports Graph Template input integrity findings without changing the database. |
|
||||
| push_out_hosts.php | Repair | Deprecated. Use `rebuild_poller_cache.php`. |
|
||||
| rebuild_poller_cache.php | Repair | Batch process to re-populate Cacti's poller cache. NOTE: This script can run for a very long time on large systems. |
|
||||
| repair_database.php | Repair | Utility to look for common problems with old Cacti databases where objects were removed while still in use. Also rapairs all tables after a system crash. |
|
||||
| repair_database.php | Repair | Utility to look for common problems with old Cacti databases where objects were removed while still in use. Also repairs all tables after a system crash. |
|
||||
| repair_graphs.php | Repair | Utility to repair Cacti Graphs whose structure is damaged due to legacy Cacti behavior. |
|
||||
| repair_templates.php | Repair | Utility to repair Cacti Templates whose structure was damaged due to legacy Cacti behavior. |
|
||||
|
||||
@@ -65,10 +65,10 @@ briefly.
|
||||
|
||||
| Script | Category | Description |
|
||||
| ------------------ | ---------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
||||
| audit_database.php | Repair/Migration | Script to audit your Cacti schema, and repair any tables that don't match the stock Cacti schema. It will also upgrade the Cacti schema and run plugin upgrade functions. This is a good migration tool to move database from old versions of Cacti. |
|
||||
| audit_database.php | Repair/Migration | Script to audit your Cacti schema, and repair any tables that don't match the stock Cacti schema. It will also upgrade the Cacti schema and run plugin upgrade functions. This is a good migration tool to move databases from old versions of Cacti. |
|
||||
| convert_tables.php | Repair/Migration | Convert all tables from their current form to the Cacti preferred table type, collation and charset |
|
||||
| fix_mediumint.php | Repair/Migration | Increases the size of key Cacti columns for systems with over a million Graphs that have been in service for years. |
|
||||
| splice_rrd.php | Migration | Utility that allows two RRDfiles to be merged, and also assists with resampling an old RRDfile to a new RRA configuration, for example moving a Cacti system from 5 minute polling to 1 minute polling. |
|
||||
| splice_rrd.php | Repair/Migration | Utility that allows two RRDfiles to be merged, and also assists with resampling an old RRDfile to a new RRA configuration, for example moving a Cacti system from 5 minute polling to 1 minute polling. |
|
||||
|
||||
## Install/Upgrade Scripts
|
||||
|
||||
@@ -79,11 +79,11 @@ briefly.
|
||||
| install_cacti.php | Install/Upgrade | Script to install Cacti from a raw schema. Used primarily by distribution maintainers. |
|
||||
| md5sum.php | Install/Upgrade | Utility to verify the MD5SUM of a file. |
|
||||
| sqltable_to_php.php | Install/Upgrade | Utility for Plugin Developers to create an object for creating tables in plugins. |
|
||||
| structure_rra_paths.php | Install/Upgrade | Utility to convert a system from a flat directory path to a heirarchial one. Important for certain file systems that don't perform well when there are tens or hundreds of thousands of files in a single directory. |
|
||||
| structure_rra_paths.php | Install/Upgrade | Utility to convert a system from a flat directory path to a hierarchical one. Important for certain file systems that don't perform well when there are tens or hundreds of thousands of files in a single directory. |
|
||||
| upgrade_database.php | Install/Upgrade | Utility to upgrade a Cacti database from a point in time to the current release. Or even rerun the database upgrade from a point in the past to catch up with changes. This script should be used in conjunction with the `audit_database.php --repair --upgrade` option. |
|
||||
|
||||
> **NOTE**: Package maintainers may wish to utilize the CLI methods of
|
||||
> install_cacti.php and upgrade_database.php to perform in place installations
|
||||
> install_cacti.php and upgrade_database.php to perform in-place installations
|
||||
> and upgrades.
|
||||
|
||||
In the sub-sections below, we will demonstrate the use of a few of these CLI
|
||||
@@ -91,12 +91,12 @@ scripts.
|
||||
|
||||
> **Caution**: In the following examples, several numbers are shown as output
|
||||
> from various scripts. They will vary between different installations. So don't
|
||||
> bother, if your numbers will vary.
|
||||
> bother if your numbers will vary.
|
||||
|
||||
## Rebuild Poller Cache
|
||||
|
||||
The poller cache holds all commands that cacti will issue during the polling
|
||||
process in an internal format. It is possible, to review the current contents of
|
||||
The poller cache holds all commands that Cacti will issue during the polling
|
||||
process in an internal format. It is possible to review the current contents of
|
||||
the poller cache by visiting `System Utilities`, `View Poller Cache`. It is
|
||||
possible to apply filters to this view; it will show up like
|
||||
|
||||
@@ -117,10 +117,10 @@ Localhost - mtaReceivedVolume SNMP Version: 1, Community: somesecret, OID: .1.
|
||||
RRD: /var/www/html/cacti/rra/localhost_mtareceivedvolume_49.rrd
|
||||
```
|
||||
|
||||
There are several circumstances, that may result in the poller cache being out
|
||||
There are several circumstances that may result in the poller cache being out
|
||||
of sync. An example would be a change of the name of a script used in a
|
||||
`Data Input Method`. This change is _not_ automatically propagated to the poller
|
||||
cache. It is required, to run `php -q rebuild_poller_cache.php` manually.
|
||||
cache. It is required to run `php -q rebuild_poller_cache.php` manually.
|
||||
|
||||
Calling the script with the parameter `--help` yields
|
||||
|
||||
@@ -147,7 +147,7 @@ System Controlled:
|
||||
|
||||
```
|
||||
|
||||
Debug mode lists the data sources items that are worked upon.
|
||||
Debug mode lists the data source items that are worked upon.
|
||||
|
||||
```console
|
||||
shell>php -q rebuild_poller_cache.php -d
|
||||
@@ -172,11 +172,11 @@ shell>
|
||||
> **Caution**
|
||||
>
|
||||
> Rebuilding the poller cache interferes with the poller operation. Make sure
|
||||
> that the poller is not running and will not start during a rebuild operation
|
||||
> that the poller is not running and will not start during a rebuild operation.
|
||||
|
||||
## Re-Index Hosts
|
||||
|
||||
Re-Indexing is required only for SNMP/Script Data Queries. Remember, that when
|
||||
Re-Indexing is required only for SNMP/Script Data Queries. Remember that when
|
||||
applying a Data Query to a Host, a `Re-Index Method` has to be chosen. This
|
||||
reindex method governs the automatic re-indexing based on specific events.
|
||||
|
||||
@@ -186,22 +186,23 @@ reindex method governs the automatic re-indexing based on specific events.
|
||||
| --------------------- | ------------------------------------------------------------------ |
|
||||
| Uptime Goes Backwards | Refers to a system reboot |
|
||||
| Index Count Changed | Refers to a change of the number of indexed items |
|
||||
| Verify All Fields | All index fields of the according XML file are checked for changes |
|
||||
| Verify All Fields | All index fields of the corresponding XML file are checked for changes |
|
||||
|
||||
If the method is set to `Uptime Goes Backwards`, Cacti will detect if the target
|
||||
has been rebooted by querying sysUptime (.1.3.6.1.2.1.1.3.0). If the current
|
||||
value for the uptime is lower than the previous one (uptime goes backwards), a
|
||||
reboot is assumed and a re-index is performed
|
||||
reboot is assumed and a re-index is performed.
|
||||
|
||||
If the method is set to `Index Count Change`, e.g. the number of interfaces,
|
||||
without checking sysUptime. It is of particular interest in cases, where indexed
|
||||
If the method is set to `Index Count Changed`, Cacti checks the number of
|
||||
indexed items, e.g. the number of interfaces, without checking sysUptime. It
|
||||
is of particular interest in cases where indexed
|
||||
entries may change without the need of a reboot. As modern operating systems
|
||||
seldom require reboots for system configuration changes, you may want to
|
||||
consider this setting for many cases (e.g. creating of a new filesystem without
|
||||
a reboot). The index to be considered is defined by the according XML file.
|
||||
consider this setting for many cases (e.g. creating a new filesystem without
|
||||
a reboot). The index to be considered is defined by the corresponding XML file.
|
||||
|
||||
If the method is set to `Verify All Fields`, all indexes of the data source are
|
||||
checked for changes. This is of particular interest e.g. in cases, where the
|
||||
checked for changes. This is of particular interest e.g. in cases where the
|
||||
index is non-numeric (e.g. a MAC address). It should be noted that in the 1.0
|
||||
and 1.1 releases, this method was found to be broken and has been corrected
|
||||
since 1.2.
|
||||
@@ -255,7 +256,7 @@ DEBUG: Data query number '3' host: '15' SNMP Query Id: '1' starting
|
||||
DEBUG: Data query number '3' host: '15' SNMP Query Id: '1' ending
|
||||
```
|
||||
|
||||
It is possible, to select a host based on its host description using
|
||||
It is possible to select a host based on its host description using
|
||||
`--host-descr=[host description]`. It is allowed to apply an SQL filter
|
||||
expression for the description like `--host-descr=some%descr`. Use this parameter in
|
||||
conjunction with either `--id=[host id]` or `--qid=[data query id]` or both:
|
||||
@@ -271,18 +272,18 @@ DEBUG: Data query number '1' host: '2' SNMP Query Id: '1' ending
|
||||
> **Caution**
|
||||
>
|
||||
> Re-Indexing interferes with the poller operation. Make sure that the poller is
|
||||
> not running and will not start during a reindex operation
|
||||
> not running and will not start during a reindex operation.
|
||||
|
||||
## Empty Poller Output Table
|
||||
|
||||
During normal poller operation, all retrieved results are intermediately stored
|
||||
in the table named poller_output After execution of cmd.php or Spine, this table
|
||||
holds all results. The poller.php finally issues all rrdtool update operations.
|
||||
Thus, after polling has completed, the table should be empty.
|
||||
in the table named poller_output. After execution of cmd.php or Spine, this
|
||||
table holds all results. The poller.php finally issues all rrdtool update
|
||||
operations. Thus, after polling has completed, the table should be empty.
|
||||
|
||||
Conditions may arise, where the table is not (completely) emptied. The most
|
||||
often known issue is lack of php memory. In those cases, the table is bigger
|
||||
than the php memory size, thus not all items are handled correctly. If that
|
||||
Conditions may arise where the table is not (completely) emptied. The most
|
||||
often known issue is lack of PHP memory. In those cases, the table is bigger
|
||||
than the PHP memory size, thus not all items are handled correctly. If that
|
||||
issue occurs, you may save all pending updates _after increasing PHP memory
|
||||
appropriately_ by running this very script. Calling the script with the
|
||||
parameter `--help` yields
|
||||
@@ -306,7 +307,7 @@ There were 0, RRD updates made this pass
|
||||
shell>
|
||||
```
|
||||
|
||||
In case, you hit the poller process or if the table was really not fully
|
||||
In case you hit the poller process or if the table was really not fully
|
||||
processed, you may find
|
||||
|
||||
```console
|
||||
@@ -336,14 +337,15 @@ There were 21, RRD updates made this pass
|
||||
shell>
|
||||
```
|
||||
|
||||
If logging level verbosity was switched to `DEBUG` you may find additional debug
|
||||
messages that usually show up in `cacti.log`
|
||||
If logging level verbosity was switched to `DEBUG`, you may find additional
|
||||
debug messages that usually show up in `cacti.log`.
|
||||
|
||||
## Reapply Suggested Names to Graphs
|
||||
|
||||
For a general understanding of suggested names used with data queries, please
|
||||
see ?. Be aware, that changes to the `Suggested Names` section of a data query
|
||||
will not automatically be propagated to all existing graphs. This is, where
|
||||
see [Data Queries](Data-Queries.md#associated-graph-templates). Be aware that
|
||||
changes to the `Suggested Names` section of a data query
|
||||
will not automatically be propagated to all existing graphs. This is where
|
||||
poller_graphs_reapply_names.php drops in. Calling the script with the parameter
|
||||
`--help` yields
|
||||
|
||||
@@ -365,7 +367,7 @@ Optional:
|
||||
|
||||
```
|
||||
|
||||
Assume a situation, where the suggested names where changed for the standard
|
||||
Assume a situation where the suggested names were changed for the standard
|
||||
data query named `SNMP - Get Mounted Partitions`. In this case, you will want to
|
||||
rework all graphs for this data query only. A verbose run will yield
|
||||
|
||||
@@ -387,13 +389,13 @@ DEBUG: Graph Name 'Localhost - Used Space - /boot' starting
|
||||
DEBUG: Graph Rename Done for Graph 'Localhost - Used Space - /boot'
|
||||
```
|
||||
|
||||
Notice the miss-spelling of the word “Space”. The `--filter` option (also
|
||||
Notice the misspelling of the word “Space”. The `--filter` option (also
|
||||
accepted as `-s`) is not case sensitive.
|
||||
|
||||
## Copy Local Cacti Users
|
||||
|
||||
For use and understanding the limitation of this script, it is of importance to
|
||||
read [User Management](User-Management.md)
|
||||
read [User Management](User-Management.md).
|
||||
|
||||
Calling the script with the parameter `--help` yields
|
||||
|
||||
@@ -419,7 +421,7 @@ Copying User...
|
||||
User copied...
|
||||
```
|
||||
|
||||
Find the results of this program call at User Management
|
||||
Find the results of this program call at User Management.
|
||||
|
||||
| User Name\*\* | Full Name | Enabled | Realm | Default Graph Policy | Last Login |
|
||||
| ------------- | ------------- | ------- | ----- | -------------------- | --------------------------------- |
|
||||
@@ -430,7 +432,7 @@ Find the results of this program call at User Management
|
||||
## Add a New Device
|
||||
|
||||
While it is an easy task to add a new device from the panels, this would be a
|
||||
tedious task for creating dozens of hundreds of devices in one turn. This is,
|
||||
tedious task for creating dozens or hundreds of devices in one turn. This is
|
||||
where the script `add_device.php` comes in. First, let's have a look at the
|
||||
whole list of features it provides. Calling the script with the parameter
|
||||
`--help` yields
|
||||
@@ -486,8 +488,8 @@ List Options:
|
||||
--quiet - batch mode value return
|
||||
```
|
||||
|
||||
Wow, that's quite a lot of options. To better understand it's use, let's first
|
||||
stick to the listing options
|
||||
Wow, that's quite a lot of options. To better understand its use, let's first
|
||||
stick to the listing options.
|
||||
|
||||
### List all Host Templates
|
||||
|
||||
@@ -521,13 +523,13 @@ Known communities are: (community)
|
||||
snmp-get
|
||||
```
|
||||
|
||||
Of course, your list will vary
|
||||
Of course, your list will vary.
|
||||
|
||||
### Create a New Device
|
||||
|
||||
Now, let's set up the most basic command to add a new device. The description
|
||||
shall be `"Device Add Test"`, the ip will be given as a FQDN,
|
||||
`router.mydomain.com`. As a SNMP enabled device, surely a community string has
|
||||
`router.mydomain.com`. As an SNMP-enabled device, surely a community string has
|
||||
to be provided; in this case given as `public`. In total, this makes the
|
||||
following command
|
||||
|
||||
@@ -551,13 +553,13 @@ next steps.
|
||||
## Associate a Data Query to an existing Host
|
||||
|
||||
It is recommended to maintain data query associations by maintaining host
|
||||
templates. Each time, a data query is added to a host template, it will
|
||||
templates. Each time a data query is added to a host template, it will be
|
||||
automatically associated with all hosts related to that very host template. The
|
||||
data query will be executed as well; this way the snmp cache will be filled with
|
||||
all values related to that query.
|
||||
|
||||
Nevertheless, it is sometimes suitable to manually associate a certain data
|
||||
query with a single host only without changing any host template. This is, where
|
||||
query with a single host only without changing any host template. This is where
|
||||
the script `add_data_query.php` comes in. First, let's have a look at the whole
|
||||
list of features it provides. Calling the script with the parameter `--help`
|
||||
yields
|
||||
@@ -630,11 +632,11 @@ find non-zero values for the data query status column, e.g. _Success [41 Items,
|
||||
## Associate a Graph Template to an existing Host
|
||||
|
||||
It is recommended to maintain graph template associations by maintaining host
|
||||
templates. Each time, a graph template is added to a host template, it will
|
||||
templates. Each time a graph template is added to a host template, it will be
|
||||
automatically associated with all hosts related to that very host template.
|
||||
|
||||
Nevertheless, it is sometimes suitable to manually associate a certain graph
|
||||
template with a single host only without changing any host template. This is,
|
||||
template with a single host only without changing any host template. This is
|
||||
where the script `add_graph_template.php` comes in. First, let's have a look at
|
||||
the whole list of features it provides. Calling the script with the parameter
|
||||
`--help` yields
|
||||
@@ -698,9 +700,9 @@ Success: Graph Template associated for host: (11: router) - graph-template: (7:
|
||||
|
||||
## Add a New Graph
|
||||
|
||||
You won't stop now as you've just created a device from cli. Surely, the task of
|
||||
setting up graphs is the next step. This is done using `add_graphs.php`. Calling
|
||||
the script with the parameter `--help` yields
|
||||
You won't stop now as you've just created a device from the CLI. Surely, the
|
||||
task of setting up graphs is the next step. This is done using `add_graphs.php`.
|
||||
Calling the script with the parameter `--help` yields
|
||||
|
||||
```console
|
||||
shell>php -q add_graphs.php
|
||||
@@ -757,7 +759,7 @@ ones:
|
||||
|
||||
> **Caution**
|
||||
>
|
||||
> When running this cli script, caution must be taken to avoid typos. Sometimes,
|
||||
> When running this CLI script, caution must be taken to avoid typos. Sometimes,
|
||||
> list options take an ending “s”, where the option for graph creation comes
|
||||
> without “s”. Error messages are not issued to indicate this typo; instead you
|
||||
> will see the general help screen.
|
||||
@@ -814,7 +816,7 @@ Known Graph Templates:(id, name)
|
||||
|
||||
### List Options for Associated Data Queries
|
||||
|
||||
First task is to find all id's for available data queries.
|
||||
First task is to find all ids for available data queries.
|
||||
|
||||
```console
|
||||
shell>php -q add_graphs.php --host-id=2 --list-snmp-queries
|
||||
@@ -891,7 +893,7 @@ graph are determined.
|
||||
### Add Non-Indexed Graphs
|
||||
|
||||
We will create a graph for `ucd/net - CPU Usage`. Above, we've identified the
|
||||
graph template it to be `4`. In total, that makes up for the following command
|
||||
graph template id to be `4`. In total, that makes up for the following command
|
||||
|
||||
```console
|
||||
shell>php -q add_graphs.php --host-id=11 --graph-type=cg --graph-template-id=4
|
||||
@@ -910,7 +912,7 @@ to the list of Associated Graph Templates.
|
||||
|
||||
### Add Indexed Graphs
|
||||
|
||||
First, let's sum up the id's of all resources required for this task:
|
||||
First, let's sum up the ids of all resources required for this task:
|
||||
|
||||
###### Table 20-2. Parameters required for an Interface Traffic Graph
|
||||
|
||||
@@ -944,11 +946,11 @@ different Re-Index Method by entering the optional parameter `--reindex-method`.
|
||||
|
||||
## Add Items to a Tree
|
||||
|
||||
Now, that we've created some nice graphs, they should be put the graph trees.
|
||||
This is done using `add_tree.php`. As you will notice soon, it is possible to
|
||||
even add header items, hosts and graphs to a tree as well as adding a new tree
|
||||
itself. But let us first see the help output. Calling the script with the
|
||||
parameter `--help` yields
|
||||
Now that we've created some nice graphs, they should be put into the graph
|
||||
trees. This is done using `add_tree.php`. As you will notice soon, it is
|
||||
possible to even add header items, hosts and graphs to a tree as well as adding
|
||||
a new tree itself. But let us first see the help output. Calling the script with
|
||||
the parameter `--help` yields
|
||||
|
||||
```console
|
||||
shell>php -q add_tree.php --help
|
||||
@@ -1017,7 +1019,7 @@ id sort method name
|
||||
|
||||
### List Nodes
|
||||
|
||||
Listing all existed node of a given tree is done by
|
||||
Listing all existing nodes of a given tree is done by
|
||||
|
||||
```console
|
||||
shell>php -q add_tree.php --list-nodes --tree-id=1
|
||||
@@ -1074,7 +1076,7 @@ as expected.
|
||||
|
||||
### Add a new Header Node to a Tree
|
||||
|
||||
Now, that a new tree has been created, you may want to add a new header to that
|
||||
Now that a new tree has been created, you may want to add a new header to that
|
||||
very tree. Use
|
||||
|
||||
```console
|
||||
@@ -1119,9 +1121,9 @@ shell>php -q add_tree.php --type=node --node-type=host --tree-id=6 --parent-node
|
||||
Added Node node-id: (24)
|
||||
```
|
||||
|
||||
Both example come without a `--host-group-style` option. For those cases,
|
||||
`Graph Template` host group style is default. Here's an example for providing a
|
||||
host group option of `Data Query Index` instead
|
||||
Both examples come without a `--host-group-style` option. For those cases,
|
||||
`Graph Template` host group style is the default. Here's an example for
|
||||
providing a host group option of `Data Query Index` instead
|
||||
|
||||
```console
|
||||
shell>php -q add_tree.php --type=node --node-type=host --tree-id=6 --parent-node=22 --host-id=1 --host-group-style=2
|
||||
@@ -1223,7 +1225,7 @@ Known Graph Templates:(id, name)
|
||||
|
||||
### List Graphs for given Hosts where permissions can be set
|
||||
|
||||
To be able to add a permissions to a specific Graph, the id of that very graph
|
||||
To be able to add permissions to a specific Graph, the id of that very graph
|
||||
is required. Thus, a `--list-graphs --host-id=[id]` option was implemented
|
||||
|
||||
```console
|
||||
@@ -1253,7 +1255,7 @@ will add graph permissions for a given host. This is done using the parameter
|
||||
shell>php -q add_perms.php --user-id=4 --item-type=host --item-id=1
|
||||
```
|
||||
|
||||
`--user-id=4` must specify an existing users. Else, an error message will be
|
||||
`--user-id=4` must specify an existing user. Else, an error message will be
|
||||
printed. As `--item-type=host` is given, `--item-id=1` must specify a valid
|
||||
host. Again, if no host with this specific id exists, an error message will be
|
||||
printed. No output is produced on successful operations.
|
||||
@@ -1265,7 +1267,7 @@ parameter `--item-type=tree` as follows
|
||||
shell>php -q add_perms.php --user-id=4 --item-type=tree --item-id=1
|
||||
```
|
||||
|
||||
`--user-id=4` must specify an existing users. Else, an error message will be
|
||||
`--user-id=4` must specify an existing user. Else, an error message will be
|
||||
printed. As `--item-type=tree` is given, `--item-id=1` must specify a valid tree
|
||||
(the Default Tree in this case). Again, if no tree with this specific id exists,
|
||||
an error message will be printed. No output is produced on successful
|
||||
@@ -1278,8 +1280,8 @@ Adding graph permissions for a given graph template is done using the parameter
|
||||
shell>php -q add_perms.php --user-id=4 --item-type=graph_template --item-id=25
|
||||
```
|
||||
|
||||
`--user-id=4` must specify an existing users. Else, an error message will be
|
||||
printed. As `--item-type=graph_template` is given, `--item-id=1` must specify a
|
||||
`--user-id=4` must specify an existing user. Else, an error message will be
|
||||
printed. As `--item-type=graph_template` is given, `--item-id=25` must specify a
|
||||
valid graph_template (the Interface - Traffic (bytes/sec) in this case). Again,
|
||||
if no graph template with this specific id exists, an error message will be
|
||||
printed. No output is produced on successful operations.
|
||||
@@ -1291,9 +1293,9 @@ parameter `--item-type=graph` as follows
|
||||
shell>php -q add_perms.php --user-id=4 --item-type=graph --item-id=8
|
||||
```
|
||||
|
||||
`--user-id=4` must specify an existing users. Else, an error message will be
|
||||
printed. As `--item-type=graph` is given, `--item-id=1` must specify a valid
|
||||
graph. Again, if no graph template with this specific id exists, an error
|
||||
`--user-id=4` must specify an existing user. Else, an error message will be
|
||||
printed. As `--item-type=graph` is given, `--item-id=8` must specify a valid
|
||||
graph. Again, if no graph with this specific id exists, an error
|
||||
message will be printed. No output is produced on successful operations.
|
||||
|
||||
---
|
||||
|
||||
Reference in new issue
Block a user