[ixpmanager] New install step by step

Nick Hilliard nick at inex.ie
Mon Aug 13 10:17:17 IST 2018


If you're running mrtg in daemon mode, in theory it should pick up 
changes to the mrtg.conf file automatically without needing to reload.

In practice, i can be a good idea to restart mrtg if there's been a 
change because signal handling in perl is not 100% reliable, which can 
cause mrtg to fail to reload properly from time to time.  I.e. put 
something like this at the end of your script:

/usr/local/bin/mrtg --check ${mrtgdir}/mrtg.cfg.$$                 \
     && /bin/mv /${mrtgdir}/mrtg.cfg.$$ ${mrtgdir}/mrtg.cfg \
     && service mrtg_daemon restart > /dev/null 2>&1

Nick

> Vladislav Bidikov <mailto:vladislav.bidikov at finki.ukim.mk>
> 11 August 2018 at 09:28
>
> Hi all,
>
>
> The previous problem was resolved by a bad template file (which got 
> corrupted on the FS by a person editing it and changing the 
> permissions)...
>
> IXP manager works fine now for a week...
>
>
> The only last and not so clear thing is that which is the best way to 
> run the mrtg config script - which cron entry as root maybe ?
>
> And any experience if after you regenerate the mrtg.cfg - do we need a 
> mrtg restart since the script from the IXP manager runs MRTG as daemon ??
>
>
> for example our cron file looks like this:
>
>
> /etc/cron.d/ixpmanager
> 0 2   * * *   www-data        /srv/ixpmanager/artisan 
> grapher:upload-stats-to-db
> */15  * * * * /srv/ixpmanager/gen-mrtg-conf
>
>
> Thanks...
>
> Regards,
>
> -- 
> V.B
> FCC
>
>
>
> ------------------------------------------------------------------------
> *From:* ixpmanager <ixpmanager-bounces at inex.ie> on behalf of Vladislav 
> Bidikov <vladislav.bidikov at finki.ukim.mk>
> *Sent:* Monday, August 6, 2018 6:02:46 PM
> *To:* INEX IXP Manager Users Mailing List
> *Subject:* Re: [ixpmanager] New install step by step
>
> Hi,
>
> Just to further update on the matter - on ~ 20.07 the API 
> configuration was working perfectly fine...
>
>
> The result was a good Bird config file... nothing was done in the 
> period between then and today (vacation time)
>
>
> Here is the config of RS1:
>
> http://prntscr.com/kfddq8
>
>
> The Laravel error says something about api missing in the router and 
> creates this:
>
> HTTP_USER_AGENT: curl/7.38.0
> REMOTE_PORT: 40402
> REQUEST_METHOD: GET
> REQUEST_URI: /api/v4/router/gen-config/rs1-v4-ixpmk
>
>
> 2018-08-06T15:40:48+00:00 DEBUG (7) [194.149.136.160]: Logger instantiated
> 2018-08-06T15:40:48+00:00 DEBUG (7) [194.149.136.160]:
>
> 2018-08-06T15:40:48+00:00 DEBUG (7) [194.149.136.160]: 
> ErrorController::errorAction()
> 2018-08-06T15:40:48+00:00 DEBUG (7) [194.149.136.160]:
>
> ************************************************************************
> ****************************** EXCEPTIONS *******************************
> ************************************************************************
>
> --------------------------- EXCEPTION --------------------------
>
> Message: Invalid controller specified (api)
> Line: 248
> File: 
> /srv/ixpmanager/vendor/zendframework/zendframework1/library/Zend/Controller/Dispatcher/Standard.php
>
> Trace:
>
> #0 
> /srv/ixpmanager/vendor/zendframework/zendframework1/library/Zend/Controller/Front.php(954): 
> Zend_Controller_Dispatcher_Standard->dispatch(Object(Zend_Controller_Request_Http), 
> Object(Zend_Controller_Response_Http))
> #1 
> /srv/ixpmanager/vendor/zendframework/zendframework1/library/Zend/Application/Bootstrap/Bootstrap.php(105): 
> Zend_Controller_Front->dispatch()
> #2 
> /srv/ixpmanager/vendor/zendframework/zendframework1/library/Zend/Application.php(384): 
> Zend_Application_Bootstrap_Bootstrap->run()
> #3 /srv/ixpmanager/app/Exceptions/Handler.php(62): Zend_Application->run()
> #4 
> /srv/ixpmanager/vendor/laravel/framework/src/Illuminate/Routing/Pipeline.php(83): 
> IXP\Exceptions\Handler->render(Object(Illuminate\Http\Request), 
> Object(Symfony\Component\HttpKernel\Exception\NotFoundHttpException))
> #5 
> /srv/ixpmanager/vendor/laravel/framework/src/Illuminate/Routing/Pipeline.php(32): 
> Illuminate\Routing\Pipeline->handleException(Object(Illuminate\Http\Request), 
> Object(Symfony\Component\HttpKernel\Exception\NotFoundHttpException))
> #6 /srv/ixpmanager/vendor/fideloper/proxy/src/TrustProxies.php(56): 
> Illuminate\Routing\Pipeline->Illuminate\Routing\{closure}(Object(Illuminate\Http\Request))
> #7 
> /srv/ixpmanager/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php(149): 
> Fideloper\Proxy\TrustProxies->handle(Object(Illuminate\Http\Request), 
> Object(Closure))
> #8 
> /srv/ixpmanager/vendor/laravel/framework/src/Illuminate/Routing/Pipeline.php(53): 
> Illuminate\Pipeline\Pipeline->Illuminate\Pipeline\{closure}(Object(Illuminate\Http\Request))
> #9 
> /srv/ixpmanager/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/TransformsRequest.php(30): 
> Illuminate\Routing\Pipeline->Illuminate\Routing\{closure}(Object(Illuminate\Http\Request))
> #10 
> /srv/ixpmanager/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php(149): 
> Illuminate\Foundation\Http\Middleware\TransformsRequest->handle(Object(Illuminate\Http\Request), 
> Object(Closure))
> #11 
> /srv/ixpmanager/vendor/laravel/framework/src/Illuminate/Routing/Pipeline.php(53): 
> Illuminate\Pipeline\Pipeline->Illuminate\Pipeline\{closure}(Object(Illuminate\Http\Request))
> #12 
> /srv/ixpmanager/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/TransformsRequest.php(30): 
> Illuminate\Routing\Pipeline->Illuminate\Routing\{closure}(Object(Illuminate\Http\Request))
> #13 
> /srv/ixpmanager/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php(149): 
> Illuminate\Foundation\Http\Middleware\TransformsRequest->handle(Object(Illuminate\Http\Request), 
> Object(Closure))
> #14 
> /srv/ixpmanager/vendor/laravel/framework/src/Illuminate/Routing/Pipeline.php(53): 
> Illuminate\Pipeline\Pipeline->Illuminate\Pipeline\{closure}(Object(Illuminate\Http\Request))
> #15 
> /srv/ixpmanager/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/ValidatePostSize.php(27): 
> Illuminate\Routing\Pipeline->Illuminate\Routing\{closure}(Object(Illuminate\Http\Request))
> #16 
> /srv/ixpmanager/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php(149): 
> Illuminate\Foundation\Http\Middleware\ValidatePostSize->handle(Object(Illuminate\Http\Request), 
> Object(Closure))
> #17 
> /srv/ixpmanager/vendor/laravel/framework/src/Illuminate/Routing/Pipeline.php(53): 
> Illuminate\Pipeline\Pipeline->Illuminate\Pipeline\{closure}(Object(Illuminate\Http\Request))
> #18 
> /srv/ixpmanager/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/CheckForMaintenanceMode.php(46): 
> Illuminate\Routing\Pipeline->Illuminate\Routing\{closure}(Object(Illuminate\Http\Request))
> #19 
> /srv/ixpmanager/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php(149): 
> Illuminate\Foundation\Http\Middleware\CheckForMaintenanceMode->handle(Object(Illuminate\Http\Request), 
> Object(Closure))
> #20 
> /srv/ixpmanager/vendor/laravel/framework/src/Illuminate/Routing/Pipeline.php(53): 
> Illuminate\Pipeline\Pipeline->Illuminate\Pipeline\{closure}(Object(Illuminate\Http\Request))
> #21 
> /srv/ixpmanager/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php(102): 
> Illuminate\Routing\Pipeline->Illuminate\Routing\{closure}(Object(Illuminate\Http\Request))
> #22 
> /srv/ixpmanager/vendor/laravel/framework/src/Illuminate/Foundation/Http/Kernel.php(151): 
> Illuminate\Pipeline\Pipeline->then(Object(Closure))
> #23 
> /srv/ixpmanager/vendor/laravel/framework/src/Illuminate/Foundation/Http/Kernel.php(116): 
> Illuminate\Foundation\Http\Kernel->sendRequestThroughRouter(Object(Illuminate\Http\Request))
> #24 /srv/ixpmanager/public/index.php(85): 
> Illuminate\Foundation\Http\Kernel->handle(Object(Illuminate\Http\Request))
> #25 {main}
>
>
> If needed i can provide more detailed logs - but i'm still completely 
> clueless...
>
>
>
> Please advice....
>
>
>
> Best regards,
>
> -- 
>
> V.B
>
> FCC
>
>
>
>
> ------------------------------------------------------------------------
> *From:* ixpmanager <ixpmanager-bounces at inex.ie> on behalf of Vladislav 
> Bidikov <vladislav.bidikov at finki.ukim.mk>
> *Sent:* Monday, August 6, 2018 3:05:39 PM
> *To:* Barry O'Donovan
> *Cc:* INEX IXP Manager Users Mailing List
> *Subject:* Re: [ixpmanager] New install step by step
>
> Hi team,
>
>
> Today we where going to connect the first "customer" and something 
> strange is happening with the automatic script for generation of the 
> config:
>
>
> In the script we have the url:
>
> URL="http://194.149.136.158/api/v4/router/gen-config"
>
>
> And today we see a 404 error...
>
>
> Runing:
>
> URL="http://194.149.136.158/api/v4/test"
>
> Says we are ok (API test fine, authenticated OK)
>
>
> We did not any change on the IXP manager instance... any idea where to 
> look into this ?
>
>
>
> Best regards,
>
>
> -- 
>
> V.B
>
> FCC
>
>
>
>
> ------------------------------------------------------------------------
> *From:* Barry O'Donovan <barry.odonovan at inex.ie>
> *Sent:* Friday, July 27, 2018 10:44:30 AM
> *To:* Vladislav Bidikov
> *Cc:* INEX IXP Manager Users Mailing List
> *Subject:* Re: [ixpmanager] New install step by step
>
>
> Vladislav Bidikov wrote on 25/07/2018 21:38:
> > Sorry - i mixed 2 different slide decks (someone needs to grab a coffee
> > ) - and this old one (which is not the one i thought on the IXP manager
> > site) is definitely one that can help
>
> Cool.
>
> > That slide deck - solved the Cisco people...
> > 
> > I have solved the Mikrotik ones... and i have a BIRD to try for the bird
> > one 😊
>
> Bird have some examples here:
>
> https://gitlab.labs.nic.cz/labs/bird/wikis/Examples
>
> While the slide deck I provided has Cisco examples, a network engineer
> familiar with Juniper should be able to use the examples to program a
> JunOS BGP config / any other device.
>
> > At the end of the day - what is the worse that could happen if we 
> > miss-configure a router - we will not brake the internet just the ISP we
> > experiment with .... :)
>
> Any possibly any bilateral peers and possibly their upstreams. Big
> internet outages are usually caused by human's fat-fingering a BGP
> configuration.
>
> If you're using the IXP Manager generated route server configuration,
> then that'll ensure nothing bad happens with those sessions.
>
>   - Barry
>
>
>
>
> _______________________________________________
> INEX IXP Manager mailing list
> ixpmanager at inex.ie
> Unsubscribe or change options here: 
> https://www.inex.ie/mailman/listinfo/ixpmanager
> Vladislav Bidikov <mailto:vladislav.bidikov at finki.ukim.mk>
> 23 July 2018 at 17:36
> Hi Nick,
> I will try to comment inline 😃
> Bare with me as my email client seems a bit with his own mind most of 
> the time ...
>
> Thanks for the super fast response...
>
> -- 
> V.B
> FCC
>
>
> ------------------------------------------------------------------------
> *From:* Nick Hilliard <nick at inex.ie>
> *Sent:* Monday, July 23, 2018 6:19 PM
> *To:* INEX IXP Manager Users Mailing List; Vladislav Bidikov
> *Subject:* Re: [ixpmanager] New install step by step
> Vladislav Bidikov wrote on 23/07/2018 16:51:
> >> I chose Customer type as Route Server (although examples show pro-bono
> >> as option) is this ok?
>
> >yep, that's correct.
>
> >> Now several questions emerge:
> >>
> >> 1.
> >>
> >> I would like to add the second Route Server (separate VM)  - can i 
> just
> >> add it under routes the same as i did for RS1 ?
>
> >yes.
>
> Ok. this is settled...
>
>
>
> >> 2.
> >>
> >> Can i add another customer (with private AS number) for Route 
> Colector -
> >> and than go from there ?
>
> >You should set the Route Collector up as being owned by the IXP itself.
> >It would be a good idea for the IXP to have its own ASN.
>
> See this screen shot:
> http://prntscr.com/k9ztzm
>
> Since i only got one AS number (for the peering/RS) maybe we made a 
> mistake ...
> Can i use the same As also for Route collector - wince the services of 
> the IXP are not in this ip/AS space ?
>
>
> >> 3.
> >>
> >> Since all these VMs (2 x RS, 1 x Rc, 1 x AS112) will be connected 
> on the
> >> same Port (the Eth-Trunk) how will IXP manager handle this since there
> >> will be 3 customers ?
>
> >The VM acts as a virtual switch.  In fact, this usually causes
> >monitoring problems because most (all?) VM snmp implementations don't
> >support per-interface monitoring.
> >
> >The physical switch port configuration can be done manually.
>
>
> This trunk to the VM based on Debian (which run on VmWare) will be 
> working fine since the port itself is as Eth-Trunk and MRTG is 
> monitoring it that way...
> Also, after we resolve (4) with a separate port for FCSE, the only 
> traffic there will be for RS/RC/AS112 and the 2x1G trunk is more for 
> redundancy purposes...
>
> Config of switches will be done completely manually...
>
>
>
>
> >> 4.
> >>
> >> Since i expect one real customer (ourselves as FCSE - with AS 52188)
> >> also will come connected on the same trunk (to save few ETH ports) how
> >> to handle this?
>
> >um, you don't really want to do this.  Each real customer should have
> >their own physical port with appropriate port security mechanisms. FCSE
> >might run the IXP but it's not the IXP, and each should have their 
> own port.
>
> Ok, new 1G (copper/optic) combo port for this ...
>
>
> >> 5.
> >>
> >> Also, i enabled MRTG grapher which i see all files are 
> generated/updated
> >> in /srv/mrtg but the web page shows imaged not found:
> >>
> >> http://prntscr.com/k9zd66
> >>
> >> and, view source does not help since i cannot debug where does the img
> >> is loaded from...
>
> >These files should come straight from /srv/mrtg.  Have you configured
> >the following variables in .env:
> >
> >GRAPHER_BACKEND_MRTG_WORKDIR="/srv/mrtg"
> >GRAPHER_BACKEND_MRTG_LOGDIR="/srv/mrtg"
>
> These where there, after i got your reply and hit refresh graphs 
> started showing without intervention ....
> So this is resolved...
>
>
> Best regards,
>
>
>
>
>
>
> Nick Hilliard <mailto:nick at inex.ie>
> 23 July 2018 at 17:19
> Vladislav Bidikov wrote on 23/07/2018 16:51:
>> I chose Customer type as Route Server (although examples show 
>> pro-bono as option) is this ok?
>
> yep, that's correct.
>
>> Now several questions emerge:
>>
>> 1.
>>
>> I would like to add the second Route Server (separate VM)  - can i 
>> just add it under routes the same as i did for RS1 ?
>
> yes.
>
>> 2.
>>
>> Can i add another customer (with private AS number) for Route 
>> Colector - and than go from there ?
>
> You should set the Route Collector up as being owned by the IXP 
> itself. It would be a good idea for the IXP to have its own ASN.
>
>> 3.
>>
>> Since all these VMs (2 x RS, 1 x Rc, 1 x AS112) will be connected on 
>> the same Port (the Eth-Trunk) how will IXP manager handle this since 
>> there will be 3 customers ?
>
> The VM acts as a virtual switch.  In fact, this usually causes 
> monitoring problems because most (all?) VM snmp implementations don't 
> support per-interface monitoring.
>
> The physical switch port configuration can be done manually.
>
>> 4.
>>
>> Since i expect one real customer (ourselves as FCSE - with AS 52188) 
>> also will come connected on the same trunk (to save few ETH ports) 
>> how to handle this?
>
> um, you don't really want to do this.  Each real customer should have 
> their own physical port with appropriate port security mechanisms.  
> FCSE might run the IXP but it's not the IXP, and each should have 
> their own port.
>
>> 5.
>>
>> Also, i enabled MRTG grapher which i see all files are 
>> generated/updated in /srv/mrtg but the web page shows imaged not found:
>>
>> http://prntscr.com/k9zd66
>>
>> and, view source does not help since i cannot debug where does the 
>> img is loaded from...
>
> These files should come straight from /srv/mrtg.  Have you configured 
> the following variables in .env:
>
> GRAPHER_BACKEND_MRTG_WORKDIR="/srv/mrtg"
> GRAPHER_BACKEND_MRTG_LOGDIR="/srv/mrtg"
>
> Nick
>
> Vladislav Bidikov <mailto:vladislav.bidikov at finki.ukim.mk>
> 23 July 2018 at 16:51
>
> Hi all,
>
>
> Things are progressing ...
>
>
> I installer the first Route Server and did a config as shown here:
>
> http://prntscr.com/k9z8vx
>
>
> the customer is defined here:
>
> http://prntscr.com/k9z8ny
>
> I chose Customer type as Route Server (although examples show pro-bono 
> as option) is this ok?
>
>
> The script for generating the BIRD config works fine and bird works 
> (well it starts not sure how to debug correctly with only one RS) 😊
>
>
> Now several questions emerge:
>
> 1.
>
> I would like to add the second Route Server (separate VM)  - can i 
> just add it under routes the same as i did for RS1 ?
>
>
> 2.
>
> Can i add another customer (with private AS number) for Route Colector 
> - and than go from there ?
>
>
> 3.
>
> Since all these VMs (2 x RS, 1 x Rc, 1 x AS112) will be connected on 
> the same Port (the Eth-Trunk) how will IXP manager handle this since 
> there will be 3 customers ?
>
>
> 4.
>
> Since i expect one real customer (ourselves as FCSE - with AS 52188) 
> also will come connected on the same trunk (to save few ETH ports) how 
> to handle this?
>
>
> 5.
>
> Also, i enabled MRTG grapher which i see all files are 
> generated/updated in /srv/mrtg but the web page shows imaged not found:
>
> http://prntscr.com/k9zd66
>
> and, view source does not help since i cannot debug where does the img 
> is loaded from...
>
>
>
>
> Looks like after our whole experience - i can probably write a 
> detailed "DO&DONT for new IXPs"...
>
>
>
> Thanks in advance,
>
>
> -- 
>
> V.B
>
> FCC
>
>
>
> ------------------------------------------------------------------------
> *From:* Vladislav Bidikov
> *Sent:* Thursday, July 19, 2018 10:11:29 AM
> *To:* Barry O'Donovan; INEX IXP Manager Users Mailing List
> *Subject:* Re: [ixpmanager] New install step by step
>
> Hi,
>
> I will try to do a pull request next week 😊
>
>
> Since changed the Vendor params of "Huawei" with bundle "Eth-Trunk" - 
> should i do a "re-scan" to have these settings updated - or i need to 
> remove and add the switches again ?
>
>
> For getting the vendor "Huawei" in the IXP-Manager by default what 
> needs to be done ?
>
>
> Hope today i will have the grapher "mrtg" ready and install the two RS ...
>
> One last bit, if i like to have a route collector server, can i use a 
> private ASN number for this ??
>
>
>
> Cheers,
>
>
> -- 
>
> V.B
>
> FCC
>
>
> ------------------------------------------------------------------------
> *From:* Barry O'Donovan <barry.odonovan at inex.ie>
> *Sent:* Wednesday, July 18, 2018 12:02:37 PM
> *To:* INEX IXP Manager Users Mailing List; Vladislav Bidikov
> *Subject:* Re: [ixpmanager] New install step by step
>
>
> Vladislav Bidikov wrote on 18/07/2018 08:52:
> > I have fixed the detection code in platform_huawei.php - should i add a
> > ticket on GitHub with the code so i can be included into the next 
> > version (and that way not to change that file every time).. - also i saw
> > that some tickets on GitHub are in the SNMP detection project, and some
> > in the ixpmanager - so where is the ideal part his to be done fast for
> > next version)
>
> That's discussed here:
>
> https://github.com/opensolutions/OSS_SNMP/wiki/Device-Discovery
>
> It's a separate project to IXP Manager but, as will all open source
> projects on GitHub, a good pull request is the quickest and easiest way.
> Especially one that comes with a unit test.
>
>   - Barry
>
>
>
> _______________________________________________
> INEX IXP Manager mailing list
> ixpmanager at inex.ie
> Unsubscribe or change options here: 
> https://www.inex.ie/mailman/listinfo/ixpmanager

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://www.inex.ie/pipermail/ixpmanager/attachments/20180813/f7455ac5/attachment-0001.html>


More information about the ixpmanager mailing list