11-26-2005
Quote:
Originally Posted by Neo
Which operating system are you using?
Red Hat 9.0(Shrike)
9 More Discussions You Might Find Interesting
1. UNIX for Dummies Questions & Answers
How can I find out what software is installed on the machine, other than ls? Is there a registry program like in Windows? The os is Sun 2.5.
Thanks (1 Reply)
Discussion started by: ViperD
1 Replies
2. UNIX for Dummies Questions & Answers
Hi All,
I am looking for a way to inventory the hardware and software components of many Solaris 8 servers/workstations. I would like to script this to run against a list of IP's in a text file.
For Windows there are many such programs available (like Belarc)
Is there anything similar for... (4 Replies)
Discussion started by: limey
4 Replies
3. Shell Programming and Scripting
Is there such a script out there that will Analyze a folder and subfolders, getting file type utilization and file aging. A CSV file will be created with file information File,Size,Date Created,Last Modified,Last Accessed,Extension,File Type,Owner
A Summary report text file will also be created... (4 Replies)
Discussion started by: seacros
4 Replies
4. Shell Programming and Scripting
Hi guys, im currently doing a library database program, and i need help for the following commands
my library.txt is
Google:Harry:45.00:50:100
This is my code
echo "Please enter Title"
read BookTitle
echo "Please enter Author"
read Author
echo "Price"
read Price
... (2 Replies)
Discussion started by: ichar
2 Replies
5. Shell Programming and Scripting
Hi,
I am getting all the scripts in my unix box through ls and pasting them in a xls for the Inventory Purpose.
Right now I am doing it manually I am going manually in each directory and doing a ls > temp.txt and pasting this out put in xls manually.
Is there any way to automate this ..if... (1 Reply)
Discussion started by: gaur.deepti
1 Replies
6. UNIX for Dummies Questions & Answers
Hi ,
We are migrating our scripts from one unix server to another unix server in aix. Is there any way we can export the permissions, owner, group of the folders and files inside the folders.
If I am copying xyz folder from old server, I need to generate a report with permissions ,owner and... (5 Replies)
Discussion started by: shruthidwh
5 Replies
7. UNIX for Advanced & Expert Users
we create a HP-UX software depot with a new perl-modul. after installation of the software depot, the perl module
i can't find with instmodsh in the inventory for installed Perl modules.
- i have learned of using instmodsh command : i find out what modules are already installed on my system.
... (0 Replies)
Discussion started by: bora99
0 Replies
8. Solaris
i need to extract following information through command line on solaris machine :
1.manufacturer name (hardware as well as OS)
2.Model number
3.Serial number - Serial Number of the device or the Physical device serial number for Virtual Servers
4.whether the server is physical or virtual -... (3 Replies)
Discussion started by: omkar.jadhav
3 Replies
9. UNIX for Advanced & Expert Users
Hi,
do you know any good server inventory open source products?
I want information like, server hostnames, ram, cpu, os, filesystems, volume groups, disks, adapters, installed software versions, firmware levels and so on
os: aix, solaris, linux, hpux
data should be kept in a database, web... (7 Replies)
Discussion started by: funksen
7 Replies
LEARN ABOUT DEBIAN
arch::inventory
Arch::Inventory(3pm) User Contributed Perl Documentation Arch::Inventory(3pm)
NAME
Arch::Inventory - class representing a tree inventory
SYNOPSIS
use Arch::Inventory qw(:category :type);
my $inv = Arch::Inventory->new; # use cwd
print Arch::Inventory->to_string($inv->get_root_entry), "
";
print $inv->get_listing;
or (most commonly):
use Arch::Tree;
my $tree = Arch::Tree->new;
my $inv = $tree->get_inventory;
print $inv->get_listing;
DESCRIPTION
Arch::Inventory generates a tree inventory.
An inventory is a tree structure of elements, each representing a single directory entry of the source tree. Each inventory entry is
described by an hash with the following fields:
category
The classification of the tree element. category can be one of TREE, SOURCE, PRECIOUS, BACKUP or JUNK.
untagged
A boolean value indicating whether the element was first classified as SOURCE but lacked an inventory id.
type
The tree element type. type can be one of FILE, DIRECTORY or SYMLINK.
path
The complete path to the tree element relative to the inventory base directory.
id The elements inventory id. May be "undef".
children
A hash of the elements direct children, idexed by their last path element.
This field exists for elements of type DIRECTORY only.
The category and type constants can be conveniently imported using the tags ":category" and ":type".
use Arch::Inventory qw(:category :type);
METHODS
The following methods are available:
new, directory, get_root_entry, get_entry, get_listing, annotate_fs, foreach, dump, to_string.
new [$dir]
Create an inventory for $dir or the current directory if $dir is not specified.
directory
Returns the inventories base directory as passed to new.
get_root_entry
Returns the inventory element for the base directory.
The root entry always has the following properties:
$root = {
category => TREE, # if {arch} exists, SOURCE otherwise
untagged => 1,
type => DIRECTORY,
path => '',
id => undef,
children => { ... },
}
get_entry $path
get_entry @path_elements
Returns the inventory element for the specified path. The path may either be given as a single string or as a list of path elements.
If the element does not exist "undef" is returned.
Using an empty or no path is equivalent to calling get_root_entry.
get_listing
Generates a textual inventory listing equivalent to the output of
tla inventory -tspbju -B --kind --ids --untagged
Note: The output order is not equivalent to tla. Instead of strict ASCII order of path names, a directory entry is always directly
followed by its child entries. Entries with the same parent entry are ASCII ordered.
annotate_fs
annotate_fs $entry
Add filesystem information to $entry or every inventory entry if none is provided. This adds the fields stat and symlink to the
annotated entries which contain the output of lstat and readlink respectively.
foreach $coderef
Execute $coderef for every inventory entry, passing the entry as $_[0].
dump
Generates a dump of the inventory structure using Data::Dumper.
to_string $inventory_element
Generates an inventory line for the inventory element as produced by tla.
BUGS
Awaiting for your reports.
AUTHORS
Mikhael Goikhman (migo@homemail.com--Perl-GPL/arch-perl--devel).
Enno Cramer (uebergeek@web.de--2003/arch-perl--devel).
SEE ALSO
For more information, see tla, Arch::Util.
perl v5.10.1 2005-10-23 Arch::Inventory(3pm)