Monthly Archives: April 2015

Telldus Tellstick Duo on CentOS 7

The Telldus Tellstick Duo is a tiny usb device to control rf devices such as lightbulbs, thermo meters and a lot of other stuff. The software to control the device is open source and works fine on Ubuntu/Debian, OS X and Windows. People have also documented how to get it to work with CentOS 6. But if you are like me and want to run the latest CentOS version then it is a little bit more complicated. In this guide I will show you how to compile and get it to run on the latest version of CentOS 7.

1. Begin by plugging in your tellstick duo in your machine, if you tail /var/log/messages you will see the following when you plug it in:

2. The next step is to install some repos and libraries so that we can compile the latest version of the software from telldus. Note, if this guide fails you can try to do “yum groupinstall Development Tools” instead.

3. Install the epel repo

4. Install all of the libftdi, libusb and libconfuse libraries

5. Download and unpack the telldus software. At the time of writing the latest package is 2.1.2

NOTE ! depending on your version of Tellstick Duo, version 2.1.2 of the software may not work. If you run in to issues such as error messages saying “TellStick not found” when you run tdtool. try 2.1.1 instead.

If you then run into issues when compiling 2.1.1 with make, you may need to edit the file “telldus-core-2.1.1/common/Socket_unix.cpp”. Make sure you include unistd.h so that it looks like this in the top of the file:

END OF NOTE

6. Now when you are supposed to run “cmake .” it will fail:

This is because of two things. It cannot find the Doxyfile.in and the FTDI_LIBRARY is not found, this can be fixed. First download the Doxyfile.in:

Run the following cmake command to point to the library:

This is how it looks like:

7. Almost done. Time to make it. Run this command:

All should be good and you can move on to installing it.

8. Install it:

9. Fix some symlinks and run ldconfig:

10. Done! Start the daemon with this command

Note. You have to restart the daemon each time you change the tellstick.conf file. You can use kill or whatever you like to do this.

11. Configure your devices in the file /etc/tellstick.conf . This is what it looks like by default:

12. Once you have set up your devices according to the documentation you can control them using “tdtool”

Other notes

For me as I have an old version of the Tellstick Duo I have to use version 2.1.1 of the software. I get error messages such as:

You can fix this by doing what is documented here:

http://developer.telldus.com/wiki/Dont%20wait%20for%20confirmation

exFAT on CentOS 7

I recently decided to swap out my Apple Mac Mini as a media center (I use Plex) and run Plex media server on Linux instead. Plex has come a long way and now works fine on CentOS 6 or later.

However, some of my media was on a exFAT (http://en.wikipedia.org/wiki/ExFAT) formatted USB drive and I wanted that to work on CentOS 7. A google search found a good solution and I wanted to share that with you in this small guide.

1. Start with adding some repos that you will need. As this guide is for CentOS 7 I have chosen the repos that fit that.

2. Download the latest epel release from this location (at the time of writing it is epel-release-7-5.noarch.rpm) http://mirror.nsc.liu.se/fedora-epel/7/x86_64/repoview/epel-release.html

3. Download and install

3. Download the latest nux repo from this location (at the time of writing it is nux-dextop-release-0-1.el7.nux.noarch.rpm): http://li.nux.ro/repos.html

4. Download and install:

5. Install the exFAT packages

6. Plugin your disk and get the partition that you want to mount. For instance:

Produces this output:

7. Mount it:

8. Done! it will now be mounted at /media/

Setup mail client on CentOS 7

Hi,

A lot of people often need to be able to send e-mail from a server at home. For instance, you may be running a Raspberry Pi that is monitoring something or doing something fun such as filming or taking pictures of your neighbor. I wrote this small guide as it is probably the easiest way of doing it for CentOS 7.

1. To start with, you probably have an ISP with an e-mail server, such as smtp.yourisp.com. This will be needed later in step 4 of the guide.

2. Make sure postfix is installed. Or else, yum install postfix. At the time of writing this is what I am running.

[root@serv1 ~]# yum list installed|grep postfix
postfix.x86_64 2:2.10.1-6.el7 @anaconda

3. Backup your /etc/postfix/main.cf file to /etc/postfix/main.cf.bk

4. Edit the file /etc/postfix/main.cf and change the following settings:

myorigin = server.yourdomain.com
mydestination = server.yourdomain.com, localhost
relayhost = smtp.yourisp.com

Where server.yourdomain.com can be something like serv1.mycooldomain.com or whatever the name is of your own domain.

5. Restart postfix, service postfix restart

6. Try it by doing something like this, if you want to monitor your RAID

/usr/sbin/mdadm --detail /dev/dm-1 > /root/RAID_STATUS.log
/bin/mail -s "RAID STATUS" "your-email@domain.com" < /root/RAID_STATUS.log