Comments (11)
Sure thing -- so, that should be OK. Just make sure you update the inventory file to match the IP addresses for the hosts to match the DHCP assigned addresses, in the clone it's high-availability/ansible/inventory/coreos
e.g. this file:
https://github.com/dougbtv/docker-asterisk/blob/master/high-availability/ansible/inventory/coreos
And then... Also update the variables to reflect that subnet, in this file high-availability/ansible/vars/coreos.yml
-- which already uses a 192.168.122.0/24
subnet (I developed it in Fedora using libvirt, so, I believe that's default), it's this file:
https://github.com/dougbtv/docker-asterisk/blob/master/high-availability/ansible/vars/coreos.yml
But if you're using the cluster_creator.yml
playbook, it should be templating the cloud configs for you, using this file: high-availability/ansible/roles/libvirt-coreos/templates/libvirt-cloud-config.j2
e.g.
Which should set a static IP address in the subnet you set the in the variables, so it's setup to create 5 boxes, and for boxes numbered 1-5 it should assign them IPs like 192.168.122.101
- 192.168.122.105
Are you using the cluster_creator.yml
playbook?
from docker-asterisk.
Yes, I'm using the cluster_creator.yml
playbook with the laptop_coreos
inventory file.
I dug myself into the configs, and I can see the libvirt-cloud-config.j2 template, and it should configure a static IP, but for some reason it get a dynamic IP.
I get few SELINUX AVC Denial messages while running the cluster creator, but I'm not sure what is the reason for it, so I uploaded a log for you.
cat /var/log/audit/audit.log | grep deni
Thanks
from docker-asterisk.
Hrmmm, yeah I definitely have developed it with SELinux disabled. I wonder if the two are related? It's possible.
Unfortunately, I'm not too interested in debugging it with SELinux compatibility at the moment. If you are however -- I'd be more than happy to accept a PR that makes it SELinux friendly.
Any chance you'd want to try it again with SELinux disabled? I wondering if it might be an issue with the VM not having privileges enough to set it's IP statically? I'm unsure, tbh.
from docker-asterisk.
As it is a VM it should not be affected by any host networking settings, because this 192.168.122 range only exists in the VM itself.
I turned off selinux for qemu with this
SVirt can be disabled for the libvirt QEMU driver by editting /etc/libvirt/qemu.conf
, uncommenting and setting
security_driver='none'
Then restart libvirtd
with
service libvirtd restart
Now I can't see SELinux errors, but my core boxes still receiving static IPs...
I don't need selinux, as I just want to try it out.
from docker-asterisk.
OK, cool, that takes selinux out of the equation. Interesting, I wonder
what is causing it to not assign the static IP...
For kicks, can you log into one of the CoreOS machines and cat the
cloud-init file and see that it looks ok?
Good chance I can try it on Fedora 23 this weekend and see but on two
machines with F21, I get static ips.
On Fri, Jan 8, 2016, 10:21 AM Zoltan Burgermeiszter <
[email protected]> wrote:
As it is a VM it should not be affected by any host networking settings,
because this 192.168.122 range only exists in the VM itself.I turned off selinux for qemu with this
https://fedoraproject.org/wiki/How_to_debug_Virtualization_problemsSVirt can be disabled for the libvirt QEMU driver by editting
/etc/libvirt/qemu.conf, uncommenting and setting
security_driver='none'
Then restart libvirtd with
service libvirtd restartNow I can't see SELinux errors, but my core boxes still receiving static
IPs...—
Reply to this email directly or view it on GitHub
#35 (comment)
.
from docker-asterisk.
I can connect to the dynamic ips of the boxes with ssh, but can not log in as it is asking for a password which does not exists as it should authenticate with the SSH key.
I configured my ssh key in the coreos.yml.
If it works for you on F21, then I'll try it with that.
The Fedora runs in a VMWare environment, but I don't think that effects this IP issue.
Thanks,
Zoltan
from docker-asterisk.
Should be totally OK within vmware, I think. Hrmmm, with sshing in, you
should be able to do.... "ssh [email protected]" and it should use your
local keys, otherwise, specify the key with "ssh -i .ssh/path/to/ssh/key
[email protected]"
On Fri, Jan 8, 2016 at 11:02 AM Zoltan Burgermeiszter <
[email protected]> wrote:
I can connect to the dynamic ips of the boxes with ssh, but can not log in
as it is asking for a password which does not exists as it should
authenticate with the SSH key.
I configured my ssh key in the coreos.yml.If it works for you on F21, then I'll try it with that.
The Fedora runs in a VMWare environment, but I don't think that effects
this IP issue.Thanks,
Zoltan—
Reply to this email directly or view it on GitHub
#35 (comment)
.
from docker-asterisk.
OK, I think I have found something.
I managed to SSH in to the boxes with [email protected]
I was a bit confused, because when I opened the bow from the QEMU manager it showed the dynamic IP above the login prompt. I think the core guest first boot up with a dynamic IP and the configure the static IP for itself.
So in the following file:
docker-asterisk/high-availability/ansible/roles/libvirt-coreos/tasks/libvirt_loaduserdata.yml:13
libvirt_userdatadir: "/var/lib/libvirt/images/coreos/coreos{{ boxnumber }}/openstack/latest"
On the Fedora host:
cat /var/lib/libvirt/images/coreos/coreos0/openstack/latest/user_data
The correct 192.168.122.200
is configured everywhere.
And now I can SSH to the correct IPs.
Aaaaand, the original dynamic IP also works.
So I done some more investigation.
On Fedora host:
nmap -sP 192.168.122.1/24
This shows the random IPs and the correct static IPs from the range of 200-205.
So now I can SSH in to for example to the core0 box with both the 192.168.122.106
and 192.168.122.200
But even if I SSH into the .200
IP, when I run the ifconfig
command, it says the following:
eth0: inet 192.168.122.106 netmask 255.255.255.0 broadcast 192.168.122.255
Weird.
So maybe I was misinformed, because initially, when I got the SELinux errors, I was unable to SSH into the boxes via the 200-205 range, and when I opened the box from the QEMU Manager it showed the dynamic IP above the login prompt, and then after I disabled SELinux, it still showed a dynamic IP.
But now the 200-205 seems to be fine. :)
Now the bootstrap_ansible_coreos.yml ran without any issues :)
(However it would be good to remove the core boxes from the known_hosts file on cluster destroy)
Thanks for your help so far.
The source of the issues was the enabled SELinux.
(or the known_hosts file.)
Thanks anyway.
from docker-asterisk.
Nice find!! Cool, happy to help, getting CoreOS up and running and etcd
synchronized are the hardest parts to me.... I am hopeful the next plays
will be smoother.
On Fri, Jan 8, 2016, 5:48 PM Zoltan Burgermeiszter [email protected]
wrote:
OK, I think I have found something.
I managed to SSH in to the boxes with [email protected]
I was a bit confused, because when I opened the bow from the QEMU manager
it showed the dynamic IP above the login prompt. I think the core guest
first boot up with a dynamic IP and the configure the static IP for itself.So in the following file:
docker-asterisk/high-availability/ansible/roles/libvirt-coreos/tasks/libvirt_loaduserdata.yml:13
https://github.com/dougbtv/docker-asterisk/blob/master/high-availability/ansible/roles/libvirt-coreos/tasks/libvirt_loaduserdata.yml#L13libvirt_userdatadir: "/var/lib/libvirt/images/coreos/coreos{{ boxnumber
}}/openstack/latest"On the Fedora host:
cat /var/lib/libvirt/images/coreos/coreos0/openstack/latest/user_data
https://github.com/dougbtv/docker-asterisk/files/83216/coreos0-user_data.txtThe correct 192.168.122.200 is configured everywhere.
And now I can SSH to the correct IPs.
Aaaaand, the original dynamic IP also works.So I done some more investigation.
On Fedora host:
nmap -sP 192.168.122.1/24
https://github.com/dougbtv/docker-asterisk/files/83230/fedora-nmap.txtThis shows the random IPs and the correct static IPs from the range of
200-205.So now I can SSH in to for example to the core0 box with both the
192.168.122.106 and 192.168.122.200
But even if I SSH into the .200 IP, when I run the ifconfig command, it
says the following:
eth0: inet 192.168.122.106 netmask 255.255.255.0 broadcast 192.168.122.255Weird.
So maybe I was misinformed, because initially, when I got the SELinux
errors, I was unable to SSH into the boxes via the 200-205 range, and when
I opened the box from the QEMU Manager it showed the dynamic IP above the
login prompt, and then after I disabled SELinux, it still showed a dynamic
IP.But now the 200-205 seems to be fine. :)
Now the bootstrap_ansible_coreos.yml ran without any issues :)
(However it would be good to remove the core boxes from the known_hosts
file on cluster destroy)Thanks for your help so far.
The source of the issues was the enabled SELinux.
(or the known_hosts file.)
Thanks anyway.—
Reply to this email directly or view it on GitHub
#35 (comment)
.
from docker-asterisk.
Thanks for all your help.
from docker-asterisk.
No prob zoltan, thanks for closing er out.
On Wed, Jan 13, 2016, 7:15 AM Zoltan Burgermeiszter <
[email protected]> wrote:
Thanks for all your help.
—
Reply to this email directly or view it on GitHub
#35 (comment)
.
from docker-asterisk.
Related Issues (20)
- capt-agent HOT 2
- Problem with keepalived on CoreOS HOT 2
- Error: image library/docker_images not found HOT 3
- Synology NAS Run Asterisk HOT 1
- Access to the directories. HOT 1
- Are there any way to expose SIP ports HOT 8
- Add gettext package? HOT 2
- Error When Building - asterisk-core-sounds-en-gsm-1.4.24 HOT 2
- How to connect from X-lite? HOT 7
- Question: make menuselect HOT 2
- asterisk 15 please HOT 2
- RTCP Transmission errors HOT 2
- Docker image too big HOT 7
- HA no dropped calls HOT 1
- Asterisk with kubernetes please
- No web interface ? HOT 1
- Enable voicemail to email delivery HOT 5
- mount volume for log files HOT 1
- speeding up docker image building HOT 1
- Create SECURITY.md HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from docker-asterisk.