Setting committed in r3812. Please do understand page layout MAY be incorrect if you're extending the host name to longer than what we're expecting, although since we got rid of the small notification boxes on the front page I don't really know of any such occasions.

Set $config['shorthost']['length'] to whatever you wanted to modify the function as; I highly recommend undoing the source change modification presented earlier in this thread.

Tom

On 16/03/2013 14:48, Tom Laermans wrote:
Andreas,

Adam will shoot us for "not having a sensible naming scheme" but I'm also a device.pop person, and I actually have the same issue somewhat - I'll roll it into a not-recommended semi-undocumented config option in the next few days (if I don't forget) so you don't have to patch the source to get what you want.

Tom

On 15/03/2013 14:21, Andreas Rüdel wrote:
thanks so much!

works 


Andreas



On 15 March 2013 12:29, Michiel Klaver <michiel@klaver.it> wrote:
At 15-03-2013 09:59, Andreas Rüdel wrote:
> Hi, Observium
>
> 2) I need some hint where I can change the behaviour of observium to cut
> avay domains after the first dot - we used subdomains to segment our
> hardware so now all devices are called the same on the overview screen.
> (alarms / events)
>
> Example:
> switch1.site1.country1
> switch1.site2.country1
> switch1.site1.country2
> and so on..
> (I know it's boring but we ran out of elven names at one point...) ;)
>
> on the overview page they would all be called "switch1"
> when I go to "devices" everything is just fine
>
> can this be changed somewhere? could not find in config.php and don't dare
> editing the other files
>


It's not changeable as config option, but located here:
/opt/observium/includes/common.php

Search for line 149:
function shorthost($hostname, $len=12)

And change 12 to 30, or something that fit's your needs...


THIS IS A QUICK HACK, COULD BREAK SVN, NO SUPPORT.



_______________________________________________
observium mailing list
observium@observium.org
http://postman.memetic.org/cgi-bin/mailman/listinfo/observium



_______________________________________________
observium mailing list
observium@observium.org
http://postman.memetic.org/cgi-bin/mailman/listinfo/observium