"getgrent" call in kernel 2.6.x /perl 5.8.3 ?

Discussion in 'Perl Misc' started by Michael Faltmann, Sep 17, 2004.

  1. Can somebody help?Hello NG,

    I have a problem here with a perl script which make use of the "getgrent"
    system call.
    This script has been working perfectly under various kernel revisions,
    starting with 2.2.x. After upgrading to 2.6.4 in conjunction with system
    update suse9.0 -->suse9.1, however, it fails.

    It have the idea I has to with the length of the longest line in "group"
    which is some 5000 Bytes long (1500 users approx.) . When I shorten this
    line to around 3000 Bytes, the script seems to work.

    System: suse9.1
    kernel: 2.6.4 / 2.6.5
    perl : 5.8.3



    The script lines of interest:
    -------------------
    setgrent;
    while (@groups=getgrent) {
    $grname{$groups[2]}=$groups[0];
    $grmitglieder{$groups[0]}=$groups[3];
    $grgid{$groups[0]} = $groups[2];
    }

    the errormessage simply reads "Out of memory!"


    Can somebody help?
    MF
     
    Michael Faltmann, Sep 17, 2004
    #1
    1. Advertisements

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. gooch

    linux kernel system call

    gooch, Oct 6, 2003, in forum: C Programming
    Replies:
    3
    Views:
    530
  2. fran
    Replies:
    2
    Views:
    767
  3. yogesh
    Replies:
    3
    Views:
    788
    Kenny McCormack
    Feb 12, 2006
  4. Replies:
    3
    Views:
    360
  5. Charles Oliver Nutter

    Bug in Kernel#method objects that call super?

    Charles Oliver Nutter, Jul 9, 2007, in forum: Ruby
    Replies:
    4
    Views:
    298
    Tim Pease
    Jul 10, 2007
  6. Ball, Donald A Jr (Library)

    How to debug failing Kernel.system call

    Ball, Donald A Jr (Library), Nov 12, 2007, in forum: Ruby
    Replies:
    3
    Views:
    209
    Alex Shulgin
    Nov 14, 2007
  7. Wes Gamble
    Replies:
    2
    Views:
    216
    Robert Klemme
    Jun 19, 2009
  8. Lars Gierth
    Replies:
    6
    Views:
    481
    David Masover
    Mar 20, 2010
Loading...