Commit Graph

67 Commits

Author SHA1 Message Date
Tony Murray
f3fc6f2906 Use Exceptions
Use exceptions for addHost()
Gets rid of silly mixed return and only returns the device_id.  Throwing an exception if we run into any issues.
Slightly modifies api add host output again to include device_id
2016-08-07 12:16:40 -05:00
Tony Murray
52d31369f0 addHost.php output improvements/fixes 2016-08-03 15:16:30 -05:00
Tony Murray
66bed276c2 Reconstruct addHost() so it is easier to understand
Update addHost() to return either device_id or a string
modify print_error(), print_message() to allow for $quiet variable
Only call addHost() once in addhost.php, if the snmp version isn't set, addHost will cope
Fix up snmp-scan.php and discovery-protocols.inc.php to detect when a device already exists
change in ip_exists() to make it more readable
2016-08-02 00:31:27 -05:00
laf
8a46c7611d Add support for stopping devices being added with duplicate sysNames 2016-05-02 20:20:29 +00:00
Maximilian Wilhelm
2ae99e50f5 Add support for setting port association mode when adding a host.
This adds a '-p' switch to addhost.php and a select box to the WebUI to
  set the port association mode for newly added devices.

Signed-off-by: Maximilian Wilhelm <max@rfc2324.org>
2016-01-26 13:49:57 +01:00
Richard Hartmann
604620cb1c addhost.php: Fix indented prompt when erroring out 2015-11-03 13:58:12 +01:00
Job Snijders
d8693f05ae Fix coding style part 2 2015-07-15 11:04:22 +02:00
laf
c4572c206a Added debugging output of invalid snmpv3 args 2015-06-24 16:32:42 +01:00
Louis Rossouw
7f3f942e83 Adding the ability to use multiple poller groups for a poller. 2015-06-22 12:37:00 +02:00
laf
8391a39f8f Updated addhost.php to use distributed_poller_group if set 2015-05-09 10:34:55 +01:00
laf
88775be882 Removed old debug line! 2015-03-25 19:48:55 +00:00
laf
ab82effa3b Updated adding devices for distributed poller 2015-03-19 22:06:13 +00:00
laf
c1ef9b6808 Resolved a large number index issues and update Console_Color to V2 2015-03-01 18:04:57 +00:00
Paul Gear
aa9dded019 Remove user-facing references to Observium
This eliminates nearly all of the user-facing references to Observium,
including in the names of temporary files and in the metadata of PDFs.  Many
of these may not be used any more, but I've adjusted them anyway.  These
changes should also make it easier to change the branding later if it is
needed.  There are a few references of which I still don't understand the
significance, so I've left them as-is for now.  The Unix agent in particular
is rather untidy.
2013-11-05 09:33:32 +10:00
Tyler Christiansen
63d428c0e1 Revert "update copyright notice" after discussion with Paul
This reverts commit 774233327e.
2013-10-28 12:01:36 -07:00
Tyler Christiansen
774233327e update copyright notice 2013-10-28 01:46:59 -07:00
Adam Amstrong
73cbb710a0 replace "sha1" with "sha", as required by net-snmp
git-svn-id: http://www.observium.org/svn/observer/trunk@3189 61d68cd4-352d-0410-923a-c4978735b2b8
2012-05-15 17:03:35 +00:00
Tom Laermans
4985943822 syntaxer run
git-svn-id: http://www.observium.org/svn/observer/trunk@3185 61d68cd4-352d-0410-923a-c4978735b2b8
2012-05-15 15:18:57 +00:00
Adam Amstrong
790480769b snmpv3 support. for hipsters.
git-svn-id: http://www.observium.org/svn/observer/trunk@3156 61d68cd4-352d-0410-923a-c4978735b2b8
2012-05-09 16:18:23 +00:00
Adam Amstrong
dbf212f652 phpDocumentator headers. retire static-config. IF YOU ARE READING THIS, REMOVE IT FROM THE BOTTOM YOUR CONFIG.PHP. YES. YOU.
git-svn-id: http://www.observium.org/svn/observer/trunk@3150 61d68cd4-352d-0410-923a-c4978735b2b8
2012-05-09 10:01:42 +00:00
Tom Laermans
a10d3f75ea syntaxer run
git-svn-id: http://www.observium.org/svn/observer/trunk@3008 61d68cd4-352d-0410-923a-c4978735b2b8
2012-04-09 15:30:45 +00:00
Tom Laermans
015695e724 when no snmp version is given on commandline, try v2c first, then v1
git-svn-id: http://www.observium.org/svn/observer/trunk@2991 61d68cd4-352d-0410-923a-c4978735b2b8
2012-04-08 11:04:43 +00:00
Tom Laermans
6b210ea056 change directory to observium root, now also for other commandline tools
git-svn-id: http://www.observium.org/svn/observer/trunk@2990 61d68cd4-352d-0410-923a-c4978735b2b8
2012-04-08 10:44:41 +00:00
Tom Laermans
83f335785b make addhost from the webinterface work correctly
git-svn-id: http://www.observium.org/svn/observer/trunk@2646 61d68cd4-352d-0410-923a-c4978735b2b8
2011-10-05 09:32:34 +00:00
Tom Laermans
86c65da8aa fix addhost? oops?
git-svn-id: http://www.observium.org/svn/observer/trunk@2645 61d68cd4-352d-0410-923a-c4978735b2b8
2011-10-05 08:53:44 +00:00
Tom Laermans
5aaa8b970d small addhost cleanup
git-svn-id: http://www.observium.org/svn/observer/trunk@2644 61d68cd4-352d-0410-923a-c4978735b2b8
2011-10-04 15:05:27 +00:00
Tom Laermans
43f3c547b7 typo fix in addhost
git-svn-id: http://www.observium.org/svn/observer/trunk@2524 61d68cd4-352d-0410-923a-c4978735b2b8
2011-09-20 15:48:12 +00:00
Tom Laermans
f87ed09e1b more code cleanup
git-svn-id: http://www.observium.org/svn/observer/trunk@2519 61d68cd4-352d-0410-923a-c4978735b2b8
2011-09-20 14:34:27 +00:00
Tom Laermans
d864ce234f kill a whole bunch of trailing spaces
git-svn-id: http://www.observium.org/svn/observer/trunk@2516 61d68cd4-352d-0410-923a-c4978735b2b8
2011-09-20 09:55:11 +00:00
Adam Amstrong
fb5d8b398f new funky discovery stuff (autodiscovery works now for discovery protocols)
git-svn-id: http://www.observium.org/svn/observer/trunk@2460 61d68cd4-352d-0410-923a-c4978735b2b8
2011-09-14 17:26:59 +00:00
Adam Amstrong
52ebbeab79 add symbol ap support (thanks to David Magniez)
git-svn-id: http://www.observium.org/svn/observer/trunk@2431 61d68cd4-352d-0410-923a-c4978735b2b8
2011-09-08 13:36:32 +00:00
Adam Amstrong
9fc744aac3 updates to addhost and cleanups. add ability to do colour on console :D :D :D
git-svn-id: http://www.observium.org/svn/observer/trunk@2430 61d68cd4-352d-0410-923a-c4978735b2b8
2011-09-08 12:24:18 +00:00
Adam Amstrong
bc0cdd2415 move poller.php (inc os/system) to db* (and others, but poller is biggest change)
git-svn-id: http://www.observium.org/svn/observer/trunk@2298 61d68cd4-352d-0410-923a-c4978735b2b8
2011-05-13 11:42:26 +00:00
Tom Laermans
340c71b2e7 more code cleanups, modify renamehost to also take a source parameter so we can build a renamehost function into the web gui some day
git-svn-id: http://www.observium.org/svn/observer/trunk@1980 61d68cd4-352d-0410-923a-c4978735b2b8
2011-03-27 10:21:19 +00:00
Tom Laermans
de7ff537cc revert r1957 patch
git-svn-id: http://www.observium.org/svn/observer/trunk@1960 61d68cd4-352d-0410-923a-c4978735b2b8
2011-03-23 09:54:56 +00:00
Geert Hauwaerts
6501cd29b5 - Code cleanup by Bastian Widmer.
git-svn-id: http://www.observium.org/svn/observer/trunk@1957 61d68cd4-352d-0410-923a-c4978735b2b8
2011-03-22 20:27:39 +00:00
Tom Laermans
9cef58a8b3 correctly let the user know if the host could not be added
git-svn-id: http://www.observium.org/svn/observer/trunk@1934 61d68cd4-352d-0410-923a-c4978735b2b8
2011-03-19 10:24:44 +00:00
Tom Laermans
afb40ceac9 cycle all configured communities on addhost, remove dead code, minor optimisation on isdomainresolves
git-svn-id: http://www.observium.org/svn/observer/trunk@1933 61d68cd4-352d-0410-923a-c4978735b2b8
2011-03-19 10:18:45 +00:00
Tom Laermans
350b57bb79 fix to actually make community parameter optional again
git-svn-id: http://www.observium.org/svn/observer/trunk@1874 61d68cd4-352d-0410-923a-c4978735b2b8
2011-03-16 14:23:38 +00:00
Tom Laermans
50f873bffc the trailing spaces hunt continues...
git-svn-id: http://www.observium.org/svn/observer/trunk@1867 61d68cd4-352d-0410-923a-c4978735b2b8
2011-03-16 09:29:46 +00:00
Tom Laermans
0b55624ba0 Make addhost work correctly again after transport patch, found by jwh
git-svn-id: http://www.observium.org/svn/observer/trunk@1864 61d68cd4-352d-0410-923a-c4978735b2b8
2011-03-16 01:05:02 +00:00
Tom Laermans
b07db6b09f addhost: make transport list dynamic
git-svn-id: http://www.observium.org/svn/observer/trunk@1863 61d68cd4-352d-0410-923a-c4978735b2b8
2011-03-16 00:50:17 +00:00
Adam Amstrong
ba2e142c09 ipv4/ipv6 udp/tcp transport support patch
git-svn-id: http://www.observium.org/svn/observer/trunk@1860 61d68cd4-352d-0410-923a-c4978735b2b8
2011-03-15 16:12:44 +00:00
Tom Laermans
8c2422d671 more addhost reindent
git-svn-id: http://www.observium.org/svn/observer/trunk@1832 61d68cd4-352d-0410-923a-c4978735b2b8
2011-03-14 18:56:26 +00:00
Tom Laermans
7cae27970e reindent/reformat addhost and adduser
git-svn-id: http://www.observium.org/svn/observer/trunk@1831 61d68cd4-352d-0410-923a-c4978735b2b8
2011-03-14 18:53:48 +00:00
Adam Amstrong
cd76567edb ginger patch
git-svn-id: http://www.observium.org/svn/observer/trunk@1699 61d68cd4-352d-0410-923a-c4978735b2b8
2010-09-03 18:26:59 +00:00
Tom Laermans
b34cb35a46 fix addhost that got borked a few commits back
git-svn-id: http://www.observium.org/svn/observer/trunk@1549 61d68cd4-352d-0410-923a-c4978735b2b8
2010-07-30 16:24:01 +00:00
Tom Laermans
ee3fbf8a5f fix lldp discovery code, small fix, addhost fix
git-svn-id: http://www.observium.org/svn/observer/trunk@1547 61d68cd4-352d-0410-923a-c4978735b2b8
2010-07-30 15:04:44 +00:00
Adam Amstrong
73f8e3c7a8 display total traffic for mikrotik until cpu/memory graphing
git-svn-id: http://www.observium.org/svn/observer/trunk@1446 61d68cd4-352d-0410-923a-c4978735b2b8
2010-07-20 18:28:15 +00:00
Tom Laermans
3f3b6c1c86 actually commit powervault detection + minor polling
git-svn-id: http://www.observium.org/svn/observer/trunk@1357 61d68cd4-352d-0410-923a-c4978735b2b8
2010-07-15 17:21:02 +00:00