Menu ▾ ▴

#317 Auto scan

Next_Release
closed
nobody
None
1
2016-02-02
2015-07-31
No

Hi,

A good Function is that we could enable per subnet auto scan...

Every 12/24hr + automated report..

Thanks,
David

Discussion

  • Benoit Lambert

    Benoit Lambert - 2015-07-31

    Already a thing.

    Put these in cron:

    /var/www/html/phpipam/functions/scripts/discoveryCheck.php
    /var/www/html/phpipam/functions/scripts/pingCheck.php

     
  • David Micallef

    David Micallef - 2015-09-07

    Hi,

    Sorry for the late reply.

    Am having the below error:

    [root@ipmgmt scripts]# ./pingCheck.php
    No such file or directoryhp
    command not foundne 2:
    ./pingCheck.php: line 3: //: is a directory
    ./pingCheck.php: line 4: syntax error near unexpected token `dirname'
    '/pingCheck.php: line 4: `require_once( dirname(FILE) . '/../functions.php' );
    [root@ipmgmt scripts]# ./discoveryCheck.php
    No such file or directory1: ?php
    command not foundp: line 2:
    ./discoveryCheck.php: line 3: //: is a directory
    ./discoveryCheck.php: line 4: syntax error near unexpected token dirname' '/discoveryCheck.php: line 4:require_once( dirname(FILE) . '/../functions.php' );
    [root@ipmgmt scripts]#
     
  • David Micallef

    David Micallef - 2015-09-07

    Hi,

    Added php path before the command and worked..

    /usr/bin/php ./pingCheck.php < Worked perfect :)

    Issue am having now is the below:

    [root@ipmgmt scripts]# /usr/bin/php ./discoveryCheck.php
    PHP Warning: exec(): Unable to fork [/bin/ping -c 1 -w 1 10.70.26.85 1>/dev/null 2>&1] in /var/www/phpipam/functions/functions-network.php on line 3288
    PHP Warning: exec(): Unable to fork [/bin/ping -c 1 -w 1 10.70.26.86 1>/dev/null 2>&1] in /var/www/phpipam/functions/functions-network.php on line 3288

    Warning: exec(): Unable to fork [/bin/ping -c 1 -w 1 10.70.26.85 1>/dev/null 2>&1] in /var/www/phpipam/functions/functions-network.php on line 3288
    PHP Fatal error: Uncaught exception 'Exception' with message 'pcntl_fork() returned a status of -1. No new process was created' in /var/www/phpipam/functions/scripts/Thread.php:160
    Stack trace:

    0 /var/www/phpipam/functions/scripts/discoveryCheck.php(63): Thread->start('10.70.26.87', 1, 1, true)

    1 {main}

    thrown in /var/www/phpipam/functions/scripts/Thread.php on line 160

    Fatal error: Uncaught exception 'Exception' with message 'pcntl_fork() returned a status of -1. No new process was created' in /var/www/phpipam/functions/scripts/Thread.php:160
    Stack trace:

    0 /var/www/phpipam/functions/scripts/discoveryCheck.php(63): Thread->start('10.70.26.87', 1, 1, true)

    1 {main}

    thrown in /var/www/phpipam/functions/scripts/Thread.php on line 160

    Warning: exec(): Unable to fork [/bin/ping -c 1 -w 1 10.70.26.86 1>/dev/null 2>&1] in /var/www/phpipam/functions/functions-network.php on line 3288
    [root@ipmgmt scripts]#

    Pizu

     

    Last edit: David Micallef 2015-09-07
  • Miha Petkovsek

    Miha Petkovsek - 2016-02-02
    • status: open --> closed
     

Anonymous
Anonymous

Add attachments
Cancel