- Community Home
- >
- Servers and Operating Systems
- >
- Legacy
- >
- Operating System - Tru64 Unix
- >
- Re: File descriptor leak when using with the getna...
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
Discussions
Discussions
Forums
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
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
тАО07-03-2009 01:53 AM
тАО07-03-2009 01:53 AM
File descriptor leak when using with the getnameinfo function
Problem:
Each time a program call getnameinfo(), the system open the files /etc/hosts and /etc/ipnodes, read them, return the expected result but _don't close_ these both files. Which drive a file descriptor leakage.
System:
$ uname -a
OSF1 juliette V5.1 2650 alpha
Compiler:
$ gcc -v
Thread model: single
gcc version 3.3.1
Steps to reproduce:
1. Compile the joined testcase
$ gcc -Wall getnameinfo.c -o getnameinfo
2. Launch
$ ./getnameinfo
3. Check with lsof the file descriptor leakage
$ ps aux |grep getnameinfo
comp 474152 0.0 0.1 2.38M 528K pts/0 S + 11:13:25 0:00.01
./getnameinfo
$ lsof -p 474152
COMMAND PID USER FD TYPE DEVICE SIZE/OFF NODE NAME
getnamein 474152 comp txt VREG 3296,411653 167536 962 /sbin/loader
getnamein 474152 comp txt VREG 3296,411653 2321952 1382 /shlib/libc.so
getnamein 474152 comp 0u VCHR 6,0 0t3962831 1821 /dev/pts/0
getnamein 474152 comp 1u VCHR 6,0 0t3962831 1821 /dev/pts/0
getnamein 474152 comp 2u VCHR 6,0 0t3962831 1821 /dev/pts/0
getnamein 474152 comp 3r VREG 3296,411653 1851 1994 /etc/hosts
getnamein 474152 comp 4r VREG 3296,411653 1717 2000 /etc/ipnodes
getnamein 474152 comp 5r VREG 3296,411653 1851 1994 /etc/hosts
getnamein 474152 comp 6r VREG 3296,411653 1717 2000 /etc/ipnodes
getnamein 474152 comp 7r VREG 3296,411653 1851 1994 /etc/hosts
getnamein 474152 comp 8r VREG 3296,411653 1717 2000 /etc/ipnodes
getnamein 474152 comp 9r VREG 3296,411653 1851 1994 /etc/hosts
getnamein 474152 comp 10r VREG 3296,411653 1717 2000 /etc/ipnodes
getnamein 474152 comp 11r VREG 3296,411653 1851 1994 /etc/hosts
getnamein 474152 comp 12r VREG 3296,411653 1717 2000 /etc/ipnodes
getnamein 474152 comp 13r VREG 3296,411653 1851 1994 /etc/hosts
getnamein 474152 comp 14r VREG 3296,411653 1717 2000 /etc/ipnodes
getnamein 474152 comp 15r VREG 3296,411653 1851 1994 /etc/hosts
getnamein 474152 comp 16r VREG 3296,411653 1717 2000 /etc/ipnodes
getnamein 474152 comp 17r VREG 3296,411653 1851 1994 /etc/hosts
getnamein 474152 comp 18r VREG 3296,411653 1717 2000 /etc/ipnodes
getnamein 474152 comp 19r VREG 3296,411653 1851 1994 /etc/hosts
....
This is a well-know issue on Tru64? Does a patch/a workaroung correct this issue?
Thanks.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО07-03-2009 12:35 PM
тАО07-03-2009 12:35 PM
Re: File descriptor leak when using with the getnameinfo function
> Does a patch/a workaround correct this issue?
Not sure as we've no idea exactly what version / patches you're running....
Please post the output of
# sizer -v
# dupatch -track -type kit
Cheers,
Rob
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО07-06-2009 12:25 AM
тАО07-06-2009 12:25 AM
Re: File descriptor leak when using with the getnameinfo function
here the result of commands:
# sizer -v
Compaq Tru64 UNIX V5.1B (Rev. 2650); Thu Jul 3 06:30:19 GMT 2003
# dupatch -track -type kit
* Previous session logs saved in session.log.[1-25]
- This dupatch session is logged in /var/adm/patch/log/session.log
Gathering details of relevant patches, this may take a bit of time
Patches installed on the system came from following patch kits:
--------------------------------------------------------------
- T64V51BB1AS0001-20021229 OSF540
- T64V51BB22AS0002-20030415 OSF540
NOTE
When a patch kit is listed, it does not necessarily mean
all patches on that kit are installed on your system.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО07-06-2009 10:56 AM
тАО07-06-2009 10:56 AM
Re: File descriptor leak when using with the getnameinfo function
This is a known bug that was fixed in patch kit 6 for V5.1B. Your dupatch output indicates that you're running patch kit 2, which is considerably out of date. To get around this leak, upgrade your system to kit 6 or kit 7 (the latest).
Regards,
Martin
A quick resolution to technical issues for your HPE products is just a click away HPE Support Center
See Self Help Post for more details
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО07-09-2009 05:59 AM
тАО07-09-2009 05:59 AM
Re: File descriptor leak when using with the getnameinfo function
Best regards.