- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- favorite sysadmin scripts you always keep around [...
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Forums
Discussions
Discussions
Discussions
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-02-2003 10:14 AM
02-02-2003 10:14 AM
Re: favorite sysadmin scripts you always keep around [2]
Hi,
type ls /dir/* and you'll get a listing of each directory and its sub-directories and files.
Example:
ls /usr/*
/usr/tmp:
OBAMHBAa01106 OBAMPAAa06934 envd.action5 ntp
OBAMIBAa03540 ems_inittab.old ign_configure swagent.log
OBAMNAAa01171 envd.action2 inetd.conf.old vol.tmp
/usr/tsm:
.tsm .tsmprint bin src term
.tsmkeys HPVERSION facetpcbin sys text
/usr/vue:
app-defaults bin
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-02-2003 09:21 PM
02-02-2003 09:21 PM
Re: favorite sysadmin scripts you always keep around [2]
see attached.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-03-2003 01:27 AM
02-03-2003 01:27 AM
Re: favorite sysadmin scripts you always keep around [2]
Has anybody a blondie-operators around your
work environment?
There are 2 of them here. :)
They are working with our system printers lp1_1 & lp2_1. So Difficult!!! And so many commands here about spooler and printers.
So here are an interface for using printers & control jobs for them. $LOCALDIR may be various.
Regards...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-03-2003 01:36 AM
02-03-2003 01:36 AM
Re: favorite sysadmin scripts you always keep around [2]
Another script ...
Script is part of /etc/profile - managing of user-sessions - it remove old sessions , allow only 1 user session,
assign priorities for each user /the user-priority is written beforehand in field 5 in every row of /etc/passwd /
Some users are the exceptions, indeed....
Regards.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-03-2003 04:02 AM
02-03-2003 04:02 AM
Re: favorite sysadmin scripts you always keep around [2]
Cleared from problems and tested version.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-03-2003 04:13 AM
02-03-2003 04:13 AM
Re: favorite sysadmin scripts you always keep around [2]
Hi,
Here follows a script that check the file systems. If the limit value is reached so a email is sent to the Administrator.
Regards,
Ricardo Bassoi
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-03-2003 04:16 AM
02-03-2003 04:16 AM
Re: favorite sysadmin scripts you always keep around [2]
Sorry All,
I sent a zip file in the attach.
Here follows the text.
Regards,
Ricardo
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-05-2003 04:47 AM
02-05-2003 04:47 AM
Re: favorite sysadmin scripts you always keep around [2]
stupid script, but useful if you're new to filesystem reduction or have a lot of filesystems to reduce, or hate doing KB to MB conversions.
PS: this script was thrown together real quick - it only does minimal testing.
Use at own risk.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-05-2003 05:28 AM
02-05-2003 05:28 AM
Re: favorite sysadmin scripts you always keep around [2]
same rules apply as the above..
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-05-2003 05:49 AM
02-05-2003 05:49 AM
Re: favorite sysadmin scripts you always keep around [2]
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-05-2003 06:12 AM
02-05-2003 06:12 AM
Re: favorite sysadmin scripts you always keep around [2]
Due to budget constraints, we have no XP512 Business Copy to use for refreshing environments. I have written a quick restore script that allows the User to define a 'rehosting' by using OmniBack Backups.
By providing the DBAs this script, they can perform their own restores without requiring OmniBack access, and the script allows a 'configure once-run many' philosophy.
The restore can be set to specify the logical volumes (or specific files within the logical volumes) to be specified, the source and destination servers and alterations to the path (changing the Oracle SID only).
The user then selects the specification to use, the session to restore from, and the tape drives to use.
This has saved heaps of time that was spent creating restores 1 mount point at a time, selecting versions, destination servers and 'restore as' directories.
Included are the script, the User instructions and SysAdmin customising instructions.
Any suggestions for improvement, my email address is at the end of the SysAdmin Notes.
Share and Enjoy! Ian
PS. HP - how about this functionality in OmniBack 5?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-05-2003 06:40 AM
02-05-2003 06:40 AM
Re: favorite sysadmin scripts you always keep around [2]
It gets the size of directories and the sub-directories and displays in kb. The usage is "dutree
Many thanks.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-09-2003 10:16 PM
02-09-2003 10:16 PM
Re: favorite sysadmin scripts you always keep around [2]
Here is a simple script which will give a snap shot of LVM informations like VG name PVs in a vg, LV name, size, mount point, fs type etc.
This script will give a warning if any lvol doesn't have an entry in /etc/fstab file.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-09-2003 11:18 PM
02-09-2003 11:18 PM
Re: favorite sysadmin scripts you always keep around [2]
A nice script to find out the total memory claimed by the system.
Regs David
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-09-2003 11:28 PM
02-09-2003 11:28 PM
Re: favorite sysadmin scripts you always keep around [2]
This is a script for the filesystem utilization check and the root mirror status check.
Incase the threshold is crossed. It sends and alert to me. Also if the root mirror fails it send an alert.
It has been scheduled to run once a day.
Name of the script: fs_check.txt
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-10-2003 11:45 AM
02-10-2003 11:45 AM
Re: favorite sysadmin scripts you always keep around [2]
Purpose:
Gather systems stats on cpu utilization and memory using glance.
Get the average cpu consuption for the reporting period.
Get the low point of memory for the reporting period.
Send a month to date recap in html format via email to interested parties every Friday.
Some of the scripts are a bit rough since they were written in the heat of need. But all are in production and have been running for months.
Regards,
dl
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-10-2003 12:21 PM
02-10-2003 12:21 PM
Re: favorite sysadmin scripts you always keep around [2]
serverlist is a list of all servers
path and attached_script_name refer to the script i attached
###
for i in `cat /serverlist`
do
banner $i
rcp /path/attached_script_name $i:/tmp
remsh $i /tmp/attached_script_name
remsh $i "/usr/bin/rm /tmp/attached_script_name"
done
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-10-2003 12:25 PM
02-10-2003 12:25 PM
Re: favorite sysadmin scripts you always keep around [2]
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-10-2003 01:18 PM
02-10-2003 01:18 PM
Re: favorite sysadmin scripts you always keep around [2]
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-10-2003 01:22 PM
02-10-2003 01:22 PM
Re: favorite sysadmin scripts you always keep around [2]
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-10-2003 01:30 PM
02-10-2003 01:30 PM
Re: favorite sysadmin scripts you always keep around [2]
Nevertheless, here's the next Netbackup script. This one is called tapeusage, and is one of the handi-dandier scripts I've written. It shows the number of tapes and the amount of data backed up for the last several days, the default is 7.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-10-2003 01:45 PM
02-10-2003 01:45 PM
Re: favorite sysadmin scripts you always keep around [2]
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-10-2003 02:07 PM
02-10-2003 02:07 PM
Re: favorite sysadmin scripts you always keep around [2]
When looking at /var/adm/syslog, disk errors are identified by a hex code number. This script, called "scsi_decoder" converts that hex number into a cXtXdX format, so you know which controller, target and disk is being referenced.
./scsi_decoder a12b3c44
This translates to c43t3d12
Here's the script:
#!/bin/ksh
Z=$1
I=`echo $Z|tr '[a-z]' '[A-Z]'`
LENGTH_I=`echo $I|wc -m`
if test "$LENGTH_I" -eq 9
then
A=`echo $I|sed s/..//`
B=`echo $A|sed s/....$//`
C=`echo "ibase=16;$B"|bc`
R=`echo $I|sed s/....//`
S=`echo $R|sed s/...$//`
T=`echo "ibase=16;$S"|bc`
F=`echo $I|sed s/.....//`
G=`echo $F|sed s/..$//`
D=`echo "ibase=16;$G"|bc`
echo "This translates to c"$C"t"$T"d"$D" "
echo
else
echo "The input string must be exactly 8 bytes. "
fi
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-10-2003 02:17 PM
02-10-2003 02:17 PM
Re: favorite sysadmin scripts you always keep around [2]
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-26-2003 09:31 AM
02-26-2003 09:31 AM
Re: favorite sysadmin scripts you always keep around [2]
A pretty robust script for killing users. It takes multiple arguments e.g. kiluser user1 user2 user3
It checks usernames, provides options for killing all or a single user processes, checks the processes are owned by the user in question, provides customisable exclusion list (includes root already) blah de blah de blah. I've also got a kiltty (takes the tty as an argument) and a kilgrep (takes any string you give it; VERY dangerous) but I'm working on giving these the all, one or none options before submitting.