Script to leak file handles


 
Thread Tools Search this Thread
# 1  
Script to leak file handles

This is a strange one.

We have an issue where our system is leaking SCTP file handles. There are people working on this and in the mean time we have a monitoring script that alarms when we need to perform actions to manually clear them. For testing purposes I want to write a script that purposfully leaks file handles and fast (leaks about 4000 in a few minutes). The problem is I have absolutely no idea how to do this or where to start and (surprisingly) it is not something people commonly want to do so the internet has not been helpful.

Does anyone know if it is possible to write a script (ksh Solaris) to leak file handles?
If so, would anyone be able to give me some pointers to get me started?

---------- Post updated at 06:07 PM ---------- Previous update was at 03:44 PM ----------

Just to let you know that I found it was easier to fake the output of netstat to make it look as if more file handles were in use than actually were, so I no longer need help with this. Thanks
 

Previous Thread | Next Thread
Thread Tools Search this Thread
Search this Thread:
Advanced Search

Test Your Knowledge in Science: Mathematics
Difficulty: Hard
If you could fold a piece of paper in half 50 times, its' thickness will be 3/4th the distance from the Earth to the Sun.
True or False?

10 More Discussions You Might Find Interesting

1. Linux

The Way Systemd Handles System Calls

Hi everyone, I have a question about the process management, and deep level system functionality of system calls between SystemD and SystemV? Does SystemD use the same system calls (fork(), exec(), bind() etc...) as SystemV? or Vice Versa? If they both use the same or very very similar sys... (2 Replies)
Discussion started by: Lost in Cyberia
2 Replies

2. Red Hat

Memory leak

Hi all I am using RED HAT 5.4, and i am getting memory uses problem. when i use "sync;echo 3 > /proc/sys/vm/drop_cache" command the memory will release after 2,3 hour memory show 95%. pls suggest right way. thanks (37 Replies)
Discussion started by: reply.ravi
37 Replies

3. UNIX for Advanced & Expert Users

sendmails works, but opens 43 file handles per email -> problem

I'm using Sendmail 8.13.8 on a CentOS 5.5 vServer (Virtuozzo). I'm using a loop in PHP to send a lot of HTML-mails via sendmail. Each mail is a mail with individual statistics for our users, so its not mass mailing, bcc is not an option. It all works fine, but when I take a closer look there... (2 Replies)
Discussion started by: ZX81
2 Replies

4. UNIX for Advanced & Expert Users

How UNIX/AIX handles a file deep down, say it's being read while another one tries to rename it?

Hi Thinkers, On AIX 5.3, we have a monitor program that reads the log file and searching for a certain string pattern that we define(say "transactionException"), if it sees it then it will raise an alert by sending an email. Because the log file XXX.log is rolling into XXX.log.0, XXX.log.1,... (2 Replies)
Discussion started by: TheGunMan
2 Replies

5. Shell Programming and Scripting

memory leak in igawk script

Hi, We are having igawk statement calling gawk function and processing a master file, each gawk function have rules and action. We are using associative array to keep the output of each rule and finally printing the associative array. We are seeing the memory is growing incrementally in TOP... (1 Reply)
Discussion started by: satvelucbe
1 Replies

6. Shell Programming and Scripting

Monitor open file handles used by a process

We have a process that is running out of file handles. Is there some command line way to determine this that we can include into a cron script? Please let me know JAK (3 Replies)
Discussion started by: jakSun8
3 Replies

7. Shell Programming and Scripting

How printf handles empty variables

See attached file that includes code, input and output. I am processing a colon delimited input file and building a ":" (colon) delimited output file. My printf statement prints contents of each of 20 variables and puts them into a record file. I am pushing out approximately 120 records. The... (2 Replies)
Discussion started by: Skyybugg
2 Replies

8. Shell Programming and Scripting

perl help with pipes and file handles (simple issue)

Hello, I have a program which opens a pipe for communication using file handle and forks 5 child processes. @waitlist = (1,2,3,4,5); foreach $item (@waitlist) { pipe *{$item},RETHAND; unless ($pid = fork()) { # Child process print RETHAND... (1 Reply)
Discussion started by: the_learner
1 Replies

9. Shell Programming and Scripting

SSH in batch mode and File-Handles in a loop

Hi all I try to execute SSH commands on several hosts in a while-loop. There seems to be a problem with file-handle, first cycle works correct but no other one will follow due to the while condition is false even that there are many more host entries (lines) in all_hosts.dat. ... (3 Replies)
Discussion started by: DaveCutler
3 Replies

10. UNIX for Advanced & Expert Users

File Handles

Hi, perhaps you can answer my question.....;) How can I check, how many file handles are used and how can i increase the value for maximum file handles??? (3 Replies)
Discussion started by: sjaeger
3 Replies
Pango::Script(3)					User Contributed Perl Documentation					  Pango::Script(3)

NAME
Pango::Script HIERARCHY
Glib::Enum +----Pango::Script METHODS
script = Pango::Script->for_unichar ($ch) o $ch (character) Since: pango 1.4 language or undef = Pango::Script->get_sample_language ($script) o $script (Pango::Script) Since: pango 1.4 ENUMS AND FLAGS
enum Pango::Script o 'invalid-code' / 'PANGO_SCRIPT_INVALID_CODE' o 'common' / 'PANGO_SCRIPT_COMMON' o 'inherited' / 'PANGO_SCRIPT_INHERITED' o 'arabic' / 'PANGO_SCRIPT_ARABIC' o 'armenian' / 'PANGO_SCRIPT_ARMENIAN' o 'bengali' / 'PANGO_SCRIPT_BENGALI' o 'bopomofo' / 'PANGO_SCRIPT_BOPOMOFO' o 'cherokee' / 'PANGO_SCRIPT_CHEROKEE' o 'coptic' / 'PANGO_SCRIPT_COPTIC' o 'cyrillic' / 'PANGO_SCRIPT_CYRILLIC' o 'deseret' / 'PANGO_SCRIPT_DESERET' o 'devanagari' / 'PANGO_SCRIPT_DEVANAGARI' o 'ethiopic' / 'PANGO_SCRIPT_ETHIOPIC' o 'georgian' / 'PANGO_SCRIPT_GEORGIAN' o 'gothic' / 'PANGO_SCRIPT_GOTHIC' o 'greek' / 'PANGO_SCRIPT_GREEK' o 'gujarati' / 'PANGO_SCRIPT_GUJARATI' o 'gurmukhi' / 'PANGO_SCRIPT_GURMUKHI' o 'han' / 'PANGO_SCRIPT_HAN' o 'hangul' / 'PANGO_SCRIPT_HANGUL' o 'hebrew' / 'PANGO_SCRIPT_HEBREW' o 'hiragana' / 'PANGO_SCRIPT_HIRAGANA' o 'kannada' / 'PANGO_SCRIPT_KANNADA' o 'katakana' / 'PANGO_SCRIPT_KATAKANA' o 'khmer' / 'PANGO_SCRIPT_KHMER' o 'lao' / 'PANGO_SCRIPT_LAO' o 'latin' / 'PANGO_SCRIPT_LATIN' o 'malayalam' / 'PANGO_SCRIPT_MALAYALAM' o 'mongolian' / 'PANGO_SCRIPT_MONGOLIAN' o 'myanmar' / 'PANGO_SCRIPT_MYANMAR' o 'ogham' / 'PANGO_SCRIPT_OGHAM' o 'old-italic' / 'PANGO_SCRIPT_OLD_ITALIC' o 'oriya' / 'PANGO_SCRIPT_ORIYA' o 'runic' / 'PANGO_SCRIPT_RUNIC' o 'sinhala' / 'PANGO_SCRIPT_SINHALA' o 'syriac' / 'PANGO_SCRIPT_SYRIAC' o 'tamil' / 'PANGO_SCRIPT_TAMIL' o 'telugu' / 'PANGO_SCRIPT_TELUGU' o 'thaana' / 'PANGO_SCRIPT_THAANA' o 'thai' / 'PANGO_SCRIPT_THAI' o 'tibetan' / 'PANGO_SCRIPT_TIBETAN' o 'canadian-aboriginal' / 'PANGO_SCRIPT_CANADIAN_ABORIGINAL' o 'yi' / 'PANGO_SCRIPT_YI' o 'tagalog' / 'PANGO_SCRIPT_TAGALOG' o 'hanunoo' / 'PANGO_SCRIPT_HANUNOO' o 'buhid' / 'PANGO_SCRIPT_BUHID' o 'tagbanwa' / 'PANGO_SCRIPT_TAGBANWA' o 'braille' / 'PANGO_SCRIPT_BRAILLE' o 'cypriot' / 'PANGO_SCRIPT_CYPRIOT' o 'limbu' / 'PANGO_SCRIPT_LIMBU' o 'osmanya' / 'PANGO_SCRIPT_OSMANYA' o 'shavian' / 'PANGO_SCRIPT_SHAVIAN' o 'linear-b' / 'PANGO_SCRIPT_LINEAR_B' o 'tai-le' / 'PANGO_SCRIPT_TAI_LE' o 'ugaritic' / 'PANGO_SCRIPT_UGARITIC' o 'new-tai-lue' / 'PANGO_SCRIPT_NEW_TAI_LUE' o 'buginese' / 'PANGO_SCRIPT_BUGINESE' o 'glagolitic' / 'PANGO_SCRIPT_GLAGOLITIC' o 'tifinagh' / 'PANGO_SCRIPT_TIFINAGH' o 'syloti-nagri' / 'PANGO_SCRIPT_SYLOTI_NAGRI' o 'old-persian' / 'PANGO_SCRIPT_OLD_PERSIAN' o 'kharoshthi' / 'PANGO_SCRIPT_KHAROSHTHI' o 'unknown' / 'PANGO_SCRIPT_UNKNOWN' o 'balinese' / 'PANGO_SCRIPT_BALINESE' o 'cuneiform' / 'PANGO_SCRIPT_CUNEIFORM' o 'phoenician' / 'PANGO_SCRIPT_PHOENICIAN' o 'phags-pa' / 'PANGO_SCRIPT_PHAGS_PA' o 'nko' / 'PANGO_SCRIPT_NKO' o 'kayah-li' / 'PANGO_SCRIPT_KAYAH_LI' o 'lepcha' / 'PANGO_SCRIPT_LEPCHA' o 'rejang' / 'PANGO_SCRIPT_REJANG' o 'sundanese' / 'PANGO_SCRIPT_SUNDANESE' o 'saurashtra' / 'PANGO_SCRIPT_SAURASHTRA' o 'cham' / 'PANGO_SCRIPT_CHAM' o 'ol-chiki' / 'PANGO_SCRIPT_OL_CHIKI' o 'vai' / 'PANGO_SCRIPT_VAI' o 'carian' / 'PANGO_SCRIPT_CARIAN' o 'lycian' / 'PANGO_SCRIPT_LYCIAN' o 'lydian' / 'PANGO_SCRIPT_LYDIAN' SEE ALSO
Pango, Glib::Enum COPYRIGHT
Copyright (C) 2003-2009 by the gtk2-perl team. This software is licensed under the LGPL. See Pango for a full notice. perl v5.12.1 2010-07-05 Pango::Script(3)

Featured Tech Videos