Skip to content

openhab2: check if alive

As mentioned in my previous openHAB blog post: it seems to be too much to ask to have a reliable and working display in the kitchen.

Another problem I found is that the weather data occasionally does not update. Everything seems to work, no errors in the log, just no updated data. Of course this results in outdated weather info in the kitchen, and the threat that "someone" will buy a regular weather station and render my 7" Raspberry display useless.

After fighting with logs and debugging and not finding any real clue, I decided to tackle this problem from another angle, and regularly check if the weather data is up to date.

 

Continue reading "openhab2: check if alive"
  • Twitter
  • Bookmark openhab2: check if alive at del.icio.us
  • Facebook
  • Google Bookmarks
  • FriendFeed
  • Digg openhab2: check if alive
  • Bloglines openhab2: check if alive
  • Technorati openhab2: check if alive
  • Fark this: openhab2: check if alive
  • Bookmark openhab2: check if alive at YahooMyWeb
  • Bookmark openhab2: check if alive at Furl.net
  • Bookmark openhab2: check if alive at reddit.com
  • Bookmark openhab2: check if alive at blinklist.com
  • Bookmark openhab2: check if alive at Spurl.net
  • Bookmark openhab2: check if alive at Simpy.com
  • Bookmark openhab2: check if alive at blogmarks
  • Bookmark openhab2: check if alive with wists
  • wong it!
  • Bookmark using any bookmark manager!
  • Stumble It!
  • Identi.ca

Ansible, delegate_to and set_fact

Another Ansible upgrade, another Playbook failing.

I have a number Playbooks which run on virtual machines. Some tasks are "outsourced" to the physical machine where the VM is running on, using "delegate_to". One of the tasks (which I haven't used in a while, because I rarely touch this machine) stopped working, and instead throws a "variable undefined" error. But from the beginning, here is the VM Playbook:

- block:
  - include: server-part.yml
  delegate_to: "{{ ansible_host }}"
  delegate_facts: True

That's the short form of it, and the $ansible_host variable holds the physical server address. That part is working. In "server-part.yml" I have the following:

# re-do the gather_facts task for the host
- action: setup

- name: Determine network interface name
  set_fact:
    main_interface: "{{ item }}"
  with_items:
    "{{ hostvars[physicalhost]['ansible_interfaces'] }}"
  when: item is match("^e[tn]")
  changed_when: false

- name: Verify interface name is set
  fail:
    msg: "Could not determine network interface name!"
  when: main_interface is not defined

The only physical network interface in this server is "eth0", that's still the case. There are a couple reasons why I still scan the list of interfaces, instead of just depending on "eth0". The main reason however is that this part also works with the enumeration systemd is doing with network interfaces (they have "en" names, instead of "eth"). But suddenly $main_interface in the next step is no longer defined.

Digging deeper (aka: -vvvv) it shows that Ansible is setting the correct interface name in the "set_fact" task, but then the variable is no longer defined immediately after that. What? I'm not sure I had to use this Playbook since my host was upgraded to Ansible 2.8.3, but I couldn't find any issues matching this problem either.

 

Continue reading "Ansible, delegate_to and set_fact"
  • Twitter
  • Bookmark Ansible, delegate_to and set_fact at del.icio.us
  • Facebook
  • Google Bookmarks
  • FriendFeed
  • Digg Ansible, delegate_to and set_fact
  • Bloglines Ansible, delegate_to and set_fact
  • Technorati Ansible, delegate_to and set_fact
  • Fark this: Ansible, delegate_to and set_fact
  • Bookmark Ansible, delegate_to and set_fact at YahooMyWeb
  • Bookmark Ansible, delegate_to and set_fact at Furl.net
  • Bookmark Ansible, delegate_to and set_fact at reddit.com
  • Bookmark Ansible, delegate_to and set_fact at blinklist.com
  • Bookmark Ansible, delegate_to and set_fact at Spurl.net
  • Bookmark Ansible, delegate_to and set_fact at Simpy.com
  • Bookmark Ansible, delegate_to and set_fact at blogmarks
  • Bookmark Ansible, delegate_to and set_fact with wists
  • wong it!
  • Bookmark using any bookmark manager!
  • Stumble It!
  • Identi.ca

Apache Karaf client in openHAB, and the "Session has been closed" error

Don't you love it when things suddenly stop working?

In my openHAB installation I have a check which verifies that the weather data is up to date. Otherwise it restarts the openhab2 service. And this check stopped working ... Leaving the kitchen display not updated for a longer time. The same display where I expect the entire installation to "just work", and don't create so many different problems. Seems to be a hard problem to have an openHAB installation without any trouble ...

 

Continue reading "Apache Karaf client in openHAB, and the "Session has been closed" error"
  • Twitter
  • Bookmark Apache Karaf client in openHAB, and the "Session has been closed" error at del.icio.us
  • Facebook
  • Google Bookmarks
  • FriendFeed
  • Digg Apache Karaf client in openHAB, and the "Session has been closed" error
  • Bloglines Apache Karaf client in openHAB, and the "Session has been closed" error
  • Technorati Apache Karaf client in openHAB, and the "Session has been closed" error
  • Fark this: Apache Karaf client in openHAB, and the "Session has been closed" error
  • Bookmark Apache Karaf client in openHAB, and the "Session has been closed" error at YahooMyWeb
  • Bookmark Apache Karaf client in openHAB, and the "Session has been closed" error at Furl.net
  • Bookmark Apache Karaf client in openHAB, and the "Session has been closed" error at reddit.com
  • Bookmark Apache Karaf client in openHAB, and the "Session has been closed" error at blinklist.com
  • Bookmark Apache Karaf client in openHAB, and the "Session has been closed" error at Spurl.net
  • Bookmark Apache Karaf client in openHAB, and the "Session has been closed" error at Simpy.com
  • Bookmark Apache Karaf client in openHAB, and the "Session has been closed" error at blogmarks
  • Bookmark Apache Karaf client in openHAB, and the "Session has been closed" error with wists
  • wong it!
  • Bookmark using any bookmark manager!
  • Stumble It!
  • Identi.ca

Related Projects

The PostgreSQL main website has a new page: "Related Projects".

This page lists the projects which help running and maintaining the PostgreSQL project, the infrastructure, and other things like the translations for press releases. For each project it lists links to the source, as well as information where to send updates, patches, or input.

If you want to get involved in one of the projects, that's your starting point. If a project is missing, please send a note or a patch to pgsql-www.

Many thanks to Jonathan S. Katz for polishing the patch, and making it look nice!

  • Twitter
  • Bookmark Related Projects at del.icio.us
  • Facebook
  • Google Bookmarks
  • FriendFeed
  • Digg Related Projects
  • Bloglines Related Projects
  • Technorati Related Projects
  • Fark this: Related Projects
  • Bookmark Related Projects at YahooMyWeb
  • Bookmark Related Projects at Furl.net
  • Bookmark Related Projects at reddit.com
  • Bookmark Related Projects at blinklist.com
  • Bookmark Related Projects at Spurl.net
  • Bookmark Related Projects at Simpy.com
  • Bookmark Related Projects at blogmarks
  • Bookmark Related Projects with wists
  • wong it!
  • Bookmark using any bookmark manager!
  • Stumble It!
  • Identi.ca

openHAB HABpanel configuration gets destroyed, HABpanel stays blank

openHAB is a stream of pure joy when it comes to debugging. Especially when all I want is a small display in the kitchen, working autonomous and without the need to restart it all the time or login to fix issues.

The latest installment of that endeavor was a black screen in the browser, with no way to even get to the usual HABpanel controls. After some debugging, it turns out that the file "habpanel.config" (/var/lib/openhab2/config/org/openhab/habpanel.config) on the openHAB server was destroyed, or more accurate: shortened to 4829 bytes. Lucky me I have this file in my Ansible playbooks, and whenever there is a change, a copy of this file is fetched to my Ansible host. From there it goes into my backups, and I can restore a couple dozen versions back, if needed. So not all is bad, but still something is not working as expected. First I installed a copy of this file from my backups - but turns out shortly later the file is shortened again. Later I figured that the file is always shortened when the openHAB service restarts. This particular instance was still running openHAB 2.4, and I used this opportunity to upgrade to 2.5, test my Playbooks (and exclude the one config file from everything) and see if the problem persists. It does. Except that after upgrading to 2.5 the file is no longer shortened to 4829 bytes, but to 4875 bytes.

Every time that happens, the file ends somewhere in the middle of the HABpanel panel configuration - and naturally the HABpanel service can no longer read that file and shows a blank screen. I would wish that it rather shows an error message, or does something useful here, but oh well.

For a while (and mostly because I was busy with other tasks) I helped myself by changing the owner of "habpanel.config" and the directory this files lives in to "root:root". This threw a couple other errors into the logfile, but helped somewhat because the config file got no longer destroyed when the service restarted.

 

Continue reading "openHAB HABpanel configuration gets destroyed, HABpanel stays blank"
  • Twitter
  • Bookmark openHAB HABpanel configuration gets destroyed, HABpanel stays blank at del.icio.us
  • Facebook
  • Google Bookmarks
  • FriendFeed
  • Digg openHAB HABpanel configuration gets destroyed, HABpanel stays blank
  • Bloglines openHAB HABpanel configuration gets destroyed, HABpanel stays blank
  • Technorati openHAB HABpanel configuration gets destroyed, HABpanel stays blank
  • Fark this: openHAB HABpanel configuration gets destroyed, HABpanel stays blank
  • Bookmark openHAB HABpanel configuration gets destroyed, HABpanel stays blank at YahooMyWeb
  • Bookmark openHAB HABpanel configuration gets destroyed, HABpanel stays blank at Furl.net
  • Bookmark openHAB HABpanel configuration gets destroyed, HABpanel stays blank at reddit.com
  • Bookmark openHAB HABpanel configuration gets destroyed, HABpanel stays blank at blinklist.com
  • Bookmark openHAB HABpanel configuration gets destroyed, HABpanel stays blank at Spurl.net
  • Bookmark openHAB HABpanel configuration gets destroyed, HABpanel stays blank at Simpy.com
  • Bookmark openHAB HABpanel configuration gets destroyed, HABpanel stays blank at blogmarks
  • Bookmark openHAB HABpanel configuration gets destroyed, HABpanel stays blank with wists
  • wong it!
  • Bookmark using any bookmark manager!
  • Stumble It!
  • Identi.ca

Internet access in Cuba

Cuba is still a developing country in terms of Internet access. For a few years tinternet was only available via satellite, and that was slow. There are now a few submarine cables, which has improved the speed, reliability and accessibility. Internet access in Cuba is basically offered by the state provider ETECSA. The internet available in hotels is just passed through to the provider as well.

 

Continue reading "Internet access in Cuba"
  • Twitter
  • Bookmark Internet access in Cuba at del.icio.us
  • Facebook
  • Google Bookmarks
  • FriendFeed
  • Digg Internet access in Cuba
  • Bloglines Internet access in Cuba
  • Technorati Internet access in Cuba
  • Fark this: Internet access in Cuba
  • Bookmark Internet access in Cuba at YahooMyWeb
  • Bookmark Internet access in Cuba at Furl.net
  • Bookmark Internet access in Cuba at reddit.com
  • Bookmark Internet access in Cuba at blinklist.com
  • Bookmark Internet access in Cuba at Spurl.net
  • Bookmark Internet access in Cuba at Simpy.com
  • Bookmark Internet access in Cuba at blogmarks
  • Bookmark Internet access in Cuba with wists
  • wong it!
  • Bookmark using any bookmark manager!
  • Stumble It!
  • Identi.ca