ncftpput and high load server :(

Discussion in 'Server Operation' started by XLucky, Nov 12, 2009.

  1. XLucky

    XLucky New Member

    Hi,

    Help please solve the problem with ncftpput

    I try to execute command:

    <? php
    ...
    shell_exec ( 'umask 0000; TERM = vt100; export TERM; nice-n 19 /usr/local/ bin/ncftpput-u user-p pass-P 21 ftp.host.com / /patch/to/file/to/upload.gz 1>> /log/ncftpput.log 2>> /log/ncftpput.log ');
    ...
    ?>

    Everything works fine, but after completion, is the load on the server.

    $> Uptime
    $> Load average: 10.11, 15.15, 19.15
    And it continues to grow.

    How can I solve this problem?
     
  2. falko

    falko Super Moderator Howtoforge Staff

    Please run
    Code:
    top
    to see what processes eat up most of your server resources.
     
  3. XLucky

    XLucky New Member

    After completion of the work(ncftpput) remains httpd process and the load is not reduced, but increased ...
     
  4. falko

    falko Super Moderator Howtoforge Staff

    Any errors in your Apache error log?
     
  5. XLucky

    XLucky New Member

    lol :)
    fixed as

    <? php
    ...
    shell_exec ( 'umask 0000; TERM = vt100; export TERM; nice-n 19 /usr/local/ bin/ncftpput-u user-p pass-P 21 ftp.host.com / /patch/to/file/to/upload.gz 1>> /log/ncftpput.log 2>> /log/ncftpput.log & > /dev/null');
    ...
    ?>

    Worked fine with & > /dev/null :D
     

Share This Page