You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cloudstack.apache.org by Stephan Seitz <s....@secretresearchfacility.com> on 2015/06/16 17:31:23 UTC

best way to patch or modify systemvm (routervm)

Hi there,

we'ld like to connect to virtualrouters[1] via l2tp/ipsec vpn. In
general, this works as expected, except vpn-clients are unable to
use the virtualrouter as DNS-Server (which is correctly propagated to
the vpn-clients).

Inside the VR, /etc/dnsmasq.conf shows
interface=eth0
except-interface=eth1
except-interface=eth2
except-interface=lo
listen-address=10.254.254.1

ppp0 is never covered by that configuration.

As a quick fix, I removed the interface= and listen-address= line.
To get rid of those lines, I also removed them in /etc/dnsmasq.conf.tmpl
and commented one dnsmasq.conf-related sed
in /etc/init.d/cloud-early-config.


I did the very same changes inside the 4.5 systevm-template. I used
blktap to get access to the vhd.

All I did shows no effect to the VRs. Every deployment seems completely
unaltered, so I'ld like to ask how (and where) I'm able to patch ( or
personalize ) my router-VMs.


Thank's for any suggestions!

cheers,
- Stephan



[1] root@r-55-VM:~# cat /etc/cloudstack-release 
Cloudstack Release 4.5.1 Tue May  5 00:33:58 UTC 2015




Re: best way to patch or modify systemvm (routervm)

Posted by Stephan Seitz <s....@secretresearchfacility.com>.
Thanks anyway. I'll post my results if it works :)

Am Mittwoch, den 17.06.2015, 12:00 +0200 schrieb Erik Weber: 
> There's multiple parts involved.
> You have the actual system vm template, the systemvm.iso, and remote ssh
> functions.
> 
> I am a bit into deep water right now, but I *think* some of the scripts
> used is located in the systemvm.iso, and it might be enough to change those.
> Note that the systemvm.iso is copied to the hypervisors and have to be
> updated there as well as on the mgmt server if you do any changes to it.
> 
> I haven't really done what you're trying to do before, so besides pointing
> at the locations I can't really be of much assistance.
> 



Re: best way to patch or modify systemvm (routervm)

Posted by Erik Weber <te...@gmail.com>.
There's multiple parts involved.
You have the actual system vm template, the systemvm.iso, and remote ssh
functions.

I am a bit into deep water right now, but I *think* some of the scripts
used is located in the systemvm.iso, and it might be enough to change those.
Note that the systemvm.iso is copied to the hypervisors and have to be
updated there as well as on the mgmt server if you do any changes to it.

I haven't really done what you're trying to do before, so besides pointing
at the locations I can't really be of much assistance.

-- 
Erik

On Wed, Jun 17, 2015 at 11:55 AM, Stephan Seitz <
s.seitz@secretresearchfacility.com> wrote:

> Thanks for your help, Erik.
> I'm able to deploy my own version of virtualrouters now :)
> Anyway, I'm trying to modify the dnsmasq.conf / dnsmasq.conf.tmpl, which
> seems to be impossible since some weird cloud* / init* / somewhat*
> script cleans it up during the deployment process.
>
> Could someone please shed some light, where / how the dnsmasq setup is
> written?
>
> I grep -r'ed inside my vhd template and think that conf must be pushed
> somehow from the outside.
>
> Cheers,
>
> Stephan
>
> Am Dienstag, den 16.06.2015, 19:55 +0200 schrieb Erik Weber:
> > You could upload the vhd as a new template, mark it as 'routing' and set
> > the global config option for routers to the new template.
> >
> > Erik
> >
> > Den tirsdag 16. juni 2015 skrev Stephan Seitz <
> > s.seitz@secretresearchfacility.com> følgende:
> >
> > > Hi there,
> > >
> > > we'ld like to connect to virtualrouters[1] via l2tp/ipsec vpn. In
> > > general, this works as expected, except vpn-clients are unable to
> > > use the virtualrouter as DNS-Server (which is correctly propagated to
> > > the vpn-clients).
> > >
> > > Inside the VR, /etc/dnsmasq.conf shows
> > > interface=eth0
> > > except-interface=eth1
> > > except-interface=eth2
> > > except-interface=lo
> > > listen-address=10.254.254.1
> > >
> > > ppp0 is never covered by that configuration.
> > >
> > > As a quick fix, I removed the interface= and listen-address= line.
> > > To get rid of those lines, I also removed them in
> /etc/dnsmasq.conf.tmpl
> > > and commented one dnsmasq.conf-related sed
> > > in /etc/init.d/cloud-early-config.
> > >
> > >
> > > I did the very same changes inside the 4.5 systevm-template. I used
> > > blktap to get access to the vhd.
> > >
> > > All I did shows no effect to the VRs. Every deployment seems completely
> > > unaltered, so I'ld like to ask how (and where) I'm able to patch ( or
> > > personalize ) my router-VMs.
> > >
> > >
> > > Thank's for any suggestions!
> > >
> > > cheers,
> > > - Stephan
> > >
> > >
> > >
> > > [1] root@r-55-VM:~# cat /etc/cloudstack-release
> > > Cloudstack Release 4.5.1 Tue May  5 00:33:58 UTC 2015
> > >
> > >
> > >
> > >
>
>
>

Re: best way to patch or modify systemvm (routervm)

Posted by Stephan Seitz <s....@secretresearchfacility.com>.
Thanks for your help, Erik.
I'm able to deploy my own version of virtualrouters now :)
Anyway, I'm trying to modify the dnsmasq.conf / dnsmasq.conf.tmpl, which
seems to be impossible since some weird cloud* / init* / somewhat*
script cleans it up during the deployment process.

Could someone please shed some light, where / how the dnsmasq setup is
written?

I grep -r'ed inside my vhd template and think that conf must be pushed
somehow from the outside.

Cheers,

Stephan

Am Dienstag, den 16.06.2015, 19:55 +0200 schrieb Erik Weber: 
> You could upload the vhd as a new template, mark it as 'routing' and set
> the global config option for routers to the new template.
> 
> Erik
> 
> Den tirsdag 16. juni 2015 skrev Stephan Seitz <
> s.seitz@secretresearchfacility.com> følgende:
> 
> > Hi there,
> >
> > we'ld like to connect to virtualrouters[1] via l2tp/ipsec vpn. In
> > general, this works as expected, except vpn-clients are unable to
> > use the virtualrouter as DNS-Server (which is correctly propagated to
> > the vpn-clients).
> >
> > Inside the VR, /etc/dnsmasq.conf shows
> > interface=eth0
> > except-interface=eth1
> > except-interface=eth2
> > except-interface=lo
> > listen-address=10.254.254.1
> >
> > ppp0 is never covered by that configuration.
> >
> > As a quick fix, I removed the interface= and listen-address= line.
> > To get rid of those lines, I also removed them in /etc/dnsmasq.conf.tmpl
> > and commented one dnsmasq.conf-related sed
> > in /etc/init.d/cloud-early-config.
> >
> >
> > I did the very same changes inside the 4.5 systevm-template. I used
> > blktap to get access to the vhd.
> >
> > All I did shows no effect to the VRs. Every deployment seems completely
> > unaltered, so I'ld like to ask how (and where) I'm able to patch ( or
> > personalize ) my router-VMs.
> >
> >
> > Thank's for any suggestions!
> >
> > cheers,
> > - Stephan
> >
> >
> >
> > [1] root@r-55-VM:~# cat /etc/cloudstack-release
> > Cloudstack Release 4.5.1 Tue May  5 00:33:58 UTC 2015
> >
> >
> >
> >



Re: best way to patch or modify systemvm (routervm)

Posted by Dean Kamali <de...@gmail.com>.
I will give it a try when I get a chance, and let you guys know, thanks

On Tue, Jun 16, 2015 at 2:12 PM, Erik Weber <te...@gmail.com> wrote:

> I haven't really tried it this way, but in theory it should work.
>
> Note that you might have to clear udev rules first, if such things exists
> in debian.
>
> Erik
>
> Den tirsdag 16. juni 2015 skrev Dean Kamali <de...@gmail.com>
> følgende:
>
> > ​Erilk,
> >
> > So make new changes to ssvm, shutdown, export and import it again? this
> way
> > the template will preserve the changes you made to the VM?​
> >
> > Dean
> >
> > On Tue, Jun 16, 2015 at 1:55 PM, Erik Weber <terbolous@gmail.com
> > <javascript:;>> wrote:
> >
> > > You could upload the vhd as a new template, mark it as 'routing' and
> set
> > > the global config option for routers to the new template.
> > >
> > > Erik
> > >
> > > Den tirsdag 16. juni 2015 skrev Stephan Seitz <
> > > s.seitz@secretresearchfacility.com <javascript:;>> følgende:
> > >
> > > > Hi there,
> > > >
> > > > we'ld like to connect to virtualrouters[1] via l2tp/ipsec vpn. In
> > > > general, this works as expected, except vpn-clients are unable to
> > > > use the virtualrouter as DNS-Server (which is correctly propagated to
> > > > the vpn-clients).
> > > >
> > > > Inside the VR, /etc/dnsmasq.conf shows
> > > > interface=eth0
> > > > except-interface=eth1
> > > > except-interface=eth2
> > > > except-interface=lo
> > > > listen-address=10.254.254.1
> > > >
> > > > ppp0 is never covered by that configuration.
> > > >
> > > > As a quick fix, I removed the interface= and listen-address= line.
> > > > To get rid of those lines, I also removed them in
> > /etc/dnsmasq.conf.tmpl
> > > > and commented one dnsmasq.conf-related sed
> > > > in /etc/init.d/cloud-early-config.
> > > >
> > > >
> > > > I did the very same changes inside the 4.5 systevm-template. I used
> > > > blktap to get access to the vhd.
> > > >
> > > > All I did shows no effect to the VRs. Every deployment seems
> completely
> > > > unaltered, so I'ld like to ask how (and where) I'm able to patch ( or
> > > > personalize ) my router-VMs.
> > > >
> > > >
> > > > Thank's for any suggestions!
> > > >
> > > > cheers,
> > > > - Stephan
> > > >
> > > >
> > > >
> > > > [1] root@r-55-VM:~# cat /etc/cloudstack-release
> > > > Cloudstack Release 4.5.1 Tue May  5 00:33:58 UTC 2015
> > > >
> > > >
> > > >
> > > >
> > >
> >
>

Re: best way to patch or modify systemvm (routervm)

Posted by Erik Weber <te...@gmail.com>.
I haven't really tried it this way, but in theory it should work.

Note that you might have to clear udev rules first, if such things exists
in debian.

Erik

Den tirsdag 16. juni 2015 skrev Dean Kamali <de...@gmail.com>
følgende:

> ​Erilk,
>
> So make new changes to ssvm, shutdown, export and import it again? this way
> the template will preserve the changes you made to the VM?​
>
> Dean
>
> On Tue, Jun 16, 2015 at 1:55 PM, Erik Weber <terbolous@gmail.com
> <javascript:;>> wrote:
>
> > You could upload the vhd as a new template, mark it as 'routing' and set
> > the global config option for routers to the new template.
> >
> > Erik
> >
> > Den tirsdag 16. juni 2015 skrev Stephan Seitz <
> > s.seitz@secretresearchfacility.com <javascript:;>> følgende:
> >
> > > Hi there,
> > >
> > > we'ld like to connect to virtualrouters[1] via l2tp/ipsec vpn. In
> > > general, this works as expected, except vpn-clients are unable to
> > > use the virtualrouter as DNS-Server (which is correctly propagated to
> > > the vpn-clients).
> > >
> > > Inside the VR, /etc/dnsmasq.conf shows
> > > interface=eth0
> > > except-interface=eth1
> > > except-interface=eth2
> > > except-interface=lo
> > > listen-address=10.254.254.1
> > >
> > > ppp0 is never covered by that configuration.
> > >
> > > As a quick fix, I removed the interface= and listen-address= line.
> > > To get rid of those lines, I also removed them in
> /etc/dnsmasq.conf.tmpl
> > > and commented one dnsmasq.conf-related sed
> > > in /etc/init.d/cloud-early-config.
> > >
> > >
> > > I did the very same changes inside the 4.5 systevm-template. I used
> > > blktap to get access to the vhd.
> > >
> > > All I did shows no effect to the VRs. Every deployment seems completely
> > > unaltered, so I'ld like to ask how (and where) I'm able to patch ( or
> > > personalize ) my router-VMs.
> > >
> > >
> > > Thank's for any suggestions!
> > >
> > > cheers,
> > > - Stephan
> > >
> > >
> > >
> > > [1] root@r-55-VM:~# cat /etc/cloudstack-release
> > > Cloudstack Release 4.5.1 Tue May  5 00:33:58 UTC 2015
> > >
> > >
> > >
> > >
> >
>

Re: best way to patch or modify systemvm (routervm)

Posted by Dean Kamali <de...@gmail.com>.
​Erilk,

So make new changes to ssvm, shutdown, export and import it again? this way
the template will preserve the changes you made to the VM?​

Dean

On Tue, Jun 16, 2015 at 1:55 PM, Erik Weber <te...@gmail.com> wrote:

> You could upload the vhd as a new template, mark it as 'routing' and set
> the global config option for routers to the new template.
>
> Erik
>
> Den tirsdag 16. juni 2015 skrev Stephan Seitz <
> s.seitz@secretresearchfacility.com> følgende:
>
> > Hi there,
> >
> > we'ld like to connect to virtualrouters[1] via l2tp/ipsec vpn. In
> > general, this works as expected, except vpn-clients are unable to
> > use the virtualrouter as DNS-Server (which is correctly propagated to
> > the vpn-clients).
> >
> > Inside the VR, /etc/dnsmasq.conf shows
> > interface=eth0
> > except-interface=eth1
> > except-interface=eth2
> > except-interface=lo
> > listen-address=10.254.254.1
> >
> > ppp0 is never covered by that configuration.
> >
> > As a quick fix, I removed the interface= and listen-address= line.
> > To get rid of those lines, I also removed them in /etc/dnsmasq.conf.tmpl
> > and commented one dnsmasq.conf-related sed
> > in /etc/init.d/cloud-early-config.
> >
> >
> > I did the very same changes inside the 4.5 systevm-template. I used
> > blktap to get access to the vhd.
> >
> > All I did shows no effect to the VRs. Every deployment seems completely
> > unaltered, so I'ld like to ask how (and where) I'm able to patch ( or
> > personalize ) my router-VMs.
> >
> >
> > Thank's for any suggestions!
> >
> > cheers,
> > - Stephan
> >
> >
> >
> > [1] root@r-55-VM:~# cat /etc/cloudstack-release
> > Cloudstack Release 4.5.1 Tue May  5 00:33:58 UTC 2015
> >
> >
> >
> >
>

Re: best way to patch or modify systemvm (routervm)

Posted by Erik Weber <te...@gmail.com>.
You could upload the vhd as a new template, mark it as 'routing' and set
the global config option for routers to the new template.

Erik

Den tirsdag 16. juni 2015 skrev Stephan Seitz <
s.seitz@secretresearchfacility.com> følgende:

> Hi there,
>
> we'ld like to connect to virtualrouters[1] via l2tp/ipsec vpn. In
> general, this works as expected, except vpn-clients are unable to
> use the virtualrouter as DNS-Server (which is correctly propagated to
> the vpn-clients).
>
> Inside the VR, /etc/dnsmasq.conf shows
> interface=eth0
> except-interface=eth1
> except-interface=eth2
> except-interface=lo
> listen-address=10.254.254.1
>
> ppp0 is never covered by that configuration.
>
> As a quick fix, I removed the interface= and listen-address= line.
> To get rid of those lines, I also removed them in /etc/dnsmasq.conf.tmpl
> and commented one dnsmasq.conf-related sed
> in /etc/init.d/cloud-early-config.
>
>
> I did the very same changes inside the 4.5 systevm-template. I used
> blktap to get access to the vhd.
>
> All I did shows no effect to the VRs. Every deployment seems completely
> unaltered, so I'ld like to ask how (and where) I'm able to patch ( or
> personalize ) my router-VMs.
>
>
> Thank's for any suggestions!
>
> cheers,
> - Stephan
>
>
>
> [1] root@r-55-VM:~# cat /etc/cloudstack-release
> Cloudstack Release 4.5.1 Tue May  5 00:33:58 UTC 2015
>
>
>
>