[Fusioninventory-user] Agent xml with LLVM part
    Guillaume Rousse 
    guillomovitch at gmail.com
       
    Sun Dec 23 16:47:08 UTC 2012
    
    
  
Le 23/12/2012 14:41, David DURIEUX a écrit :
> If other people have LVM volumes a little complex (many hard disks,
> many volume groups...) send me the XLM please.
Help yourself, generate samples directly with whetever complexity needed...
my @logical_volumes = (
     {
         LV_UUID   => '2ByrwP-byIK-8twm-qyHd-Bjm9-EwFd-CzPaAd',
         SIZE      => 5901,
         ATTR      => '-wi-ao',
         VG_UUID   => 'Eubwcw-UFh2-P3Kn-aI6y-qcLT-VCzU-ls49ha',
         LV_NAME   => 'home',
         SEG_COUNT => '1'
     },
     {
     ...
     }
);
my $inventory = FusionInventory::Agent::Task::Inventory::Inventory->new();
for each my $volume (@logical_volumes) {
     $inventory->addEntry(
         section => 'LOGICAL_VOLUMES',
         entry => $volume
     );
}
...
my $tpp = XML::TreePP->new(indent => 2);
print $tpp->write({
     REQUEST => {
         CONTENT  => $inventory}>{content},
         DEVICEID => 'whatever',
         QUERY    => "INVENTORY",
     }
});
    
    
More information about the Fusioninventory-user
mailing list