GLPI + Fusion Inventory

実稼働ネットワークのコンピューターの構成についてOldを収集する必要がありました。 GLPIがベースとして選択されました。 なぜなら OCS Inventoryはすでにハブで説明されており、その記事へのコメントでFusion Inventroyについて言及されていたので、インストールします。

主なタスク:

  1. OCS Inventoryを使用せずにFusion InventoryをGLPIにねじ込みます
  2. 必要に応じて、情報収集スクリプトを手動で開始します(したがって、メモリに余計なものがハングアップしないようにします)。
  3. 産業用機器を制御するコンピューターの構成を収集します(それらはネットワークに接続されていません)。




サーバーには既にLAMPがインストールおよび構成されているはずです(私の場合、これはFAMPです)。



GLPIをインストールする



# cd /usr/ports/www/glpi; make install clean
      
      





データベースとユーザーを作成します(USERとPASSWORDを独自のものに置き換えます)。

 # mysqladmin -uroot -p create glpi # mysql -uroot -p -e"GRANT ALL ON glpi.* TO USERNAME@localhost IDENTIFIED BY 'PASSWORD'" glpi
      
      





Apache設定(httpd.confまたはhttpd-vhosts.conf)に追加します。

 Alias /glpi "/usr/local/www/glpi" <Directory /usr/local/www/glpi> AllowOverride Options FileInfo </Directory>
      
      





Apacheを再起動します。

 # apachectl restart
      
      





作成されたサイト(http:// {host.domain} / glpi /)に移動し、インストール言語としてロシア語を選択すると、すべてが明確になります。



FusionInventory(サーバー)をインストールします



FusionInventoryプラグインをダウンロードし、GLPIプラグインフォルダーに解凍します。

 # cd ~ # fetch http://forge.fusioninventory.org/attachments/download/120/fusioninventory-for-glpi-2.2.2-release.tar.gz # cd /usr/local/www/glpi/plugins/ # rm remove.txt # tar -xzvf /root/fusioninventory-for-glpi-2.2.2-release.tar.gz
      
      





フォルダ構造を確認します。次のようになります。

 |--- glpi |--- plugins |--- fusioninventory |--- fusioninventory | |--- index.php | |--- hook.php | |--- front | |--- inc | |--- fusininventory | |--- ... | |--- fusinvsnmp |--- ... etc...
      
      





管理者アカウントでGLPIに移動し、メニュー「設定」->「アドオン」->フィールド「FusionInventory」->「更新/インストール」->「有効」を選択します。 「インストール」し、プラグインのすべての部分を次の順序でオンにします。

  1. Fusioninventory
  2. FusionInventoryインベントリ
  3. FusionInventory SNMP




FusionInventoryのインストール(クライアント)



クライアントをダウンロードしてインストールします。

forge.fusioninventory.org/projects/fusioninventory-agent/wiki/Agent_supportedplateforms

インストール時に、サーバーへのパスを指定します(Winバージョンの場合、設定はインストール中に設定されます)。

 http://server_ip/glpi/plugins/fusioninventory/front/plugin_fusioninventory.communication.php
      
      





DNSが使用されている場合:

 http://glpi.mydomain/plugins/fusioninventory/front/plugin_fusioninventory.communication.php
      
      





Active Directoryの場合:

 http://AD_DOMAIN\user:password@serverip/glpi/plugins/fusioninventory/front/plugin_fusioninventory.communication.php
      
      





追加の設定(プロキシなど)を指定する必要がある場合があります-インストール中に「詳細」チェックボックス。

クライアントをインストールした後、GLPI Webインターフェース->「アドオン」->「FusionInventory」->「エージェント管理」に進み、コンピューターがリストに表示されるかどうかを確認します。

インストール後にエージェントが常にメモリにハングするのを防ぐには:





  1. インストールされているFusion-Inventoryのフォルダーをコピーします
  2. その中で、次の内容のsave_net.cmdファイルを作成します。


 set PATH=%CD%\perl\;%CD%\perl\bin;%PATH% perl.exe %CD%\perl\bin\fusioninventory-agent --debug -f --no-wakeonlan --scan-homedirs --logfile=%CD%agent-log.txt --share-dir=%CD%share —server=http://glpi.mydomain/plugins/fusioninventory/front/plugin_fusioninventory.communication.php
      
      





「glpi.mydomain」を自分の名前/ IPに変更することを忘れないでください。

インベントリ/更新するには、作成されたスクリプトを実行し、コンピューター構成(ネットワークがない)をファイルに保存するには、Fusion-Inventoryとsave_local.cmdを含むフォルダー内に「xml」ディレクトリを次の内容で作成します。

 set PATH=%CD%\perl\;%CD%\perl\bin;%PATH% perl.exe %CD%\perl\bin\fusioninventory-agent --debug -f --no-wakeonlan --scan-homedirs --local=%CD%\xml --logfile=%CD%\agent-log.txt --share-dir=%CD%\share
      
      





このスクリプトを実行した後、構成は「xml」ディレクトリに保存されます。 データベースに構成をインポートするには-glpi->「アドオン」->「FusionInventory」->「エージェントXMLファイルのインポート」に移動し、xmlフォルダーから目的のファイルを選択します。

結果として、フラッシュドライブから実行できるFusion Inventoryのポータブルバージョンを取得します。 主なことは、コンピューター上に生き物がいないことを確認することです。



FreeBSD / Linux






PS機器/コンピューター/などをリストから削除し、エージェント情報をサーバーに送信すると、対応するリストに表示されません-削除をキャンセルする必要があります(「削除されたオブジェクトを表示」->「復元」)



All Articles