Posts tagged ‘Linux’

Confluence 5.4.2 x64 installation error

I was attempting an installation of Confluence 5.4.2 x64 from the binary file that can be executed and it failed like below;

root@hostname:/home/username# ./atlassian-confluence-5.4.2-x64.bin
Unpacking JRE …
Starting Installer …
./atlassian-confluence-5.4.2-x64.bin: 466: /home/username/atlassian-confluence-5.4.2-x64.bin.17671.dir/jre/bin/java: not found

I’ve seen this problem before with another product, so I knew immediately what the problem is. It’s due to executing the x64 version on a 32bit Linux.

Go download the 32bit version of the file and execute it. It will work.

Wifidog and Authpuppy

I’ve been trying to get Wifidog and Authpuppy going, however failed to get the end to end solution working.

I was able to get Wifidog installed and compiled. In addition to getting Authpuppy going, but getting them to work together is not working  for me.

I want to use a small pc with dual nics to connect to the local network (which gets out to internet) and the other nic connected to 1 or more Access Points.

The network with the Access Point doesn’t appear to have its traffic intercepted by Wifidog at all, and that’s the bit that I am stuck with currently.

Exigent VPS

I signed up for a Exigent VPS several weeks back and have been using it on and off. I loaded mine up with a configuration that would allow vhost mail hosting and webhosting. It ran fine, the bandwidth to the VPS itself seemed fine.

To be honest I have been very happy with the VPS service, so much so I recommended it to others. Since we signed up during an introduction of new hardware/services, we actually got a good sign up cost.

I don’t use mine currently, as I moved my services back to shared web hosting, but tempted to hang onto it for a bit longer as its good to have. Besides, if I get rid of it, I wont get another for the price I am paying at the moment.

If you need a VPS, check out Exigent.

Realtek RTL2838 DVB-T tuner on Raspberry Pi with TvHeadEnd success

I decided to give my DVB-T usb dongle (Realtek RTL2838) another go with the Raspberry Pi and TvHeadEnd. As I thought the newer version of Raspbian if available might address the condition I had previously where I had no dvb device after plugging it in. Older post found here.

It would appear it was a good to check this out again.

I downloaded the latest Raspbian available from the Raspberry Pi site. The version available at the time of this post is the one below;

2013-12-20-wheezy-raspbian.zip

I installed to an SD card and booted my Raspberry Pi.

I plugged in my Realtek RTL2838 tuner and it detected fine and when I checked for the dvb device structure, it was populated all correctly, which never happened previously at all.

[26848.628778] usb 1-1.3: new high-speed USB device number 6 using dwc_otg
[26848.741110] usb 1-1.3: New USB device found, idVendor=0bda, idProduct=2838
[26848.741147] usb 1-1.3: New USB device strings: Mfr=1, Product=2, SerialNumber=3
[26848.741166] usb 1-1.3: Product: RTL2838UHIDIR
[26848.741183] usb 1-1.3: Manufacturer: Realtek
[26848.741199] usb 1-1.3: SerialNumber: 00000001
[26848.851456] usb 1-1.3: dvb_usb_v2: found a 'Realtek RTL2832U reference design' in warm state
[26848.857238] usbcore: registered new interface driver dvb_usb_rtl28xxu
[26848.921368] usb 1-1.3: dvb_usb_v2: will pass the complete MPEG2 transport stream to the software demuxer
[26848.921447] DVB: registering new adapter (Realtek RTL2832U reference design)
[26848.965698] usb 1-1.3: DVB: registering adapter 0 frontend 0 (Realtek RTL2832 (DVB-T))...
[26849.001551] r820t 0-001a: creating new instance
[26849.014447] r820t 0-001a: Rafael Micro r820t successfully identified
[26849.021655] Registered IR keymap rc-empty
[26849.022183] input: Realtek RTL2832U reference design as /devices/platform/bcm2708_usb/usb1/1-1/1-1.3/rc/rc0/input0
[26849.022231] rc0: Realtek RTL2832U reference design as /devices/platform/bcm2708_usb/usb1/1-1/1-1.3/rc/rc0
[26849.022262] usb 1-1.3: dvb_usb_v2: schedule remote query interval to 400 msecs
[26849.035148] usb 1-1.3: dvb_usb_v2: 'Realtek RTL2832U reference design' successfully initialized and connected

And device files

root@raspberrypi:~# ls -la /dev/dvb
total 0
drwxr-xr-x  3 root root   60 Jan  1 14:51 .
drwxr-xr-x 13 root root 3080 Jan  1 14:51 ..
drwxr-xr-x  2 root root  120 Jan  1 14:51 adapter0
root@raspberrypi:~# ls -la /dev/dvb/adapter0/
total 0
drwxr-xr-x 2 root root     120 Jan  1 14:51 .
drwxr-xr-x 3 root root      60 Jan  1 14:51 ..
crw-rw---T 1 root video 212, 4 Jan  1 14:51 demux0
crw-rw---T 1 root video 212, 5 Jan  1 14:51 dvr0
crw-rw---T 1 root video 212, 3 Jan  1 14:51 frontend0
crw-rw---T 1 root video 212, 7 Jan  1 14:51 net0

Next I configured other tools before compiling and installing the TvHeadEnd per the steps below;

sudo apt-get install unzip libcurl4-openssl-dev pkg-config git build-essential dvb-apps

cd ~
git clone https://github.com/tvheadend/tvheadend
cd tvheadend
./configure
make
sudo make install

At which point I executed the binary via “tvheadend -C” and I could now access the web interface for the TvHeadEnd software via http://raspberrypi_ip:9981/ where I could now see my dvb tuner was detected.

At this point you now have to configure the network and channels according to your region. Can be a bit tricky, but I followed the info available at the post here (step 14). This helped me make sense of the sequence of actions.

Below is a screen grab showing VideoLan Client from my Windows 7 desktop and a web browser in the background attached to the TvHeadEnd which is running on the Raspberry Pi with the RTL2838 tuner.

tvheadend_rtl2838_rpi_vlc

 

EDIT: And to get my TvHeadEnd to auto start with boot I performed the following additional steps.

Created /etc/init.d/tvheadend file with the contents below;

#!/bin/bash
### BEGIN INIT INFO
# Provides: tvheadend
# Required-Start: $local_fs $remote_fs $network
# Required-Stop: $local_fs $remote_fs $network
# Should-Start: $syslog
# Should-Stop: $syslog
# Default-Start: 2 3 4 5
# Default-Stop: 0 1
# Short-Description: start/stop tvheadend Server
### END INIT INFO

TVHNAME="tvheadend"
TVHBIN="/usr/local/bin/tvheadend"
TVHUSER="tvheadend"
TVHGROUP="tvheadend"
PIDFILE=/var/run/$TVHNAME.pid

start() {
if [ -e $PIDFILE ]; then
PID=$(ps ax | grep -v grep | grep -w $(cat $PIDFILE) | awk '{print $1}')
if [ -n "$PID" ]; then
echo "$TVHNAME already running (pid $PID)."
exit 1
fi
fi
echo -n "Starting tvheadend: "
start-stop-daemon --start --background --pidfile $PIDFILE --make-pidfile --user ${TVHUSER} --exec ${TVHBIN} -- \
-u ${TVHUSER} -g ${TVHGROUP} -f -C
echo "Done."
}

stop() {
if [ -e $PIDFILE ]; then
PID=$(ps ax | grep -v grep | grep -w $(cat $PIDFILE) | awk '{print $1}')
if [ -n "$PID" ]; then
echo -n "Stopping $TVHNAME: "
start-stop-daemon --stop --quiet --pidfile $PIDFILE --name ${TVHNAME}
echo "Done."
else
echo "$TVHNAME is not running."
fi
else
echo "$TVHNAME is not running."
fi
}

status() {
if [ -e $PIDFILE ]; then
PID=$(ps ax | grep -v grep | grep -w $(cat $PIDFILE) | awk '{print $1}')
if [ -n "$PID" ]; then
echo "$TVHNAME is running (pid $PID)."
else
echo "$TVHNAME is not running."
[ -e $PIDFILE ] && exit 1 || exit 3
fi
fi
}

case "$1" in
start) start ;;
stop) stop ;;
restart) stop && sleep 2 && start ;;
*) echo "Usage: $0 [start|stop|restart|status]" && exit 1 ;;
esac

exit 0

Now set the script as executable using below;

sudo chmod 755 /etc/init.d/tvheadend

Create a tvheadend group

sudo groupadd tvheadend

Create a tvheadend user that is part of the video group and tvheadend group.

sudo useradd -g tvheadend -G video -m tvheadend

And now set the initscript tvheadend to startup and shutdown as system does

sudo update-rc.d tvheadend defaults

Raspberry Pi and Xbox 360 camera as a Webcam

Have wanted to configure an Xbox 360 camera as a Webcam on a Raspberry Pi. I’ve simple followed the post here.

I wasn’t interested in having the camera capture images with motion, as I want to act more like a traditional webcam that captures an image every set interval. To perform that task you just need to enable the option below in the motion.conf (/etc/motion/motion.conf) and you can test it by running “motion -n” as root (or via sudo).

# Make automated snapshot every N seconds (default: 0 = disabled)
snapshot_interval 120

With the interval set below it will create a file every 120 seconds. You’ll also get a lastsnap.jpg symlink which links to the last/latest capture.

I modified the configuration to also append some text to the webcam capture and overlay it on the picture. A demo of what I captured is below and how it looks.

01-20140101005600-snapshot

Raspberry Pi with RTL8188CUS 802.11n wifi adapter – Update

I’ve actually been playing around with my Realtek RTL8188CUS wifi adapter and found that the configuration of the wifi adapter without wpa_supplicant seems to be a better way to go.

The information I found below was taken directly from the source Far Robotics Website. Thanks to those folks for posting the 3 methods below;

Installing rtl8188cus and rtl8188eu based wifi adaptors for raspbian without using wpa_supplicant.

Edit the file /etc/network/interfaces using the following format for networks with WPA/WPA2 security. Use the command sudo nano /etc/network/interfaces to open and edit the file. Exit the editor and save the file using keys cntl-X, Y, Enter.  Enclose Your-Network-Name and Your-Network-Password within quotation marks as in the example below.

auto lo

iface lo inet loopback
iface eth0 inet dhcp

allow-hotplug wlan0
iface wlan0 inet dhcp
wpa-ssid "Your-Network-Name"
wpa-psk "Your-Network-Password"

Edit the file /etc/network/interfaces using the following format for networks using WEP security. Use the command sudo nano /etc/network/interfaces to open and edit the file. Exit the editor and save the file using keys cntl-X, Y, Enter. Do not use quotation marks around Your-Network-Name and Your-Network-Password.

auto lo

iface lo inet loopback
iface eth0 inet dhcp

allow-hotplug wlan0
iface wlan0 inet dhcp
wireless-essid Your-Network-Name
wireless-key Your-Network-Password

Edit the file /etc/network/interfaces using the following format for networks using no security. Use the  command sudo nano /etc/network/interfaces to open and edit the file. Exit the editor and save the file using keys cntl-X, Y, Enter. Do not use quotation marks around Your-Network-Name.

auto lo

iface lo inet loopback
iface eth0 inet dhcp

allow-hotplug wlan0
iface wlan0 inet dhcp
wireless-essid Your-Network-Name

If you have success and/or failure, be sure to post a comment. Feedback is always most welcome.

XPEnology DSM 4.2 on HP N40L Microserver Follow up

I’ve noticed that my earlier post (here) on running XPEnology DSM 4.2 on a HP N40L Microserver gets a large number of hits on a weekly basis. Thought it might be a good time to post a follow up.

The software appeared to install fine and appeared to be operational much like a Synology NAS.

However despite everything seeming okay it was still a hack to get this working on a HP N40L Microserver no matter which way you look at it. I couldn’t get over that thought and as such wasn’t about to trust my data on the system.

So I opted to not use XPEnology DSM 4.2 on my HP N40L Microserver in the end. However I am sure plenty of people do use it and have no problem doing so. If you find any of my posts on this subject, and go on to use it. By all means post a comment so others can see that it’s being used by people with no problem.

Simpana 10 – Clearing simpana lock file on Unix clients

Just wanted to put together a clip that covers this condition which can be seen on Unix clients for Simpana 9 and Simpana 10. The steps to resolve it on both versions are exactly the same.

This condition is typically seen when Simpana services do not get shutdown cleanly. Maybe the system never ran all the init scripts during shutdown including ours, or the system wasn’t shutdown cleanly.

What will happen in that condition is that on the next simpana services start you will get an error as shown below;

**** There is already another simpana running.

However if you run a “simpana list” you’ll notice that no simpana services are running despite the failure to start up and the error indicating simpana is already running.

Our software during start up will create a lock file, which is referenced and checked at start up. If it exists you will get the message. During shutdown its removed.

Best way to find out the name of the lock file is to take part of the error message and grep for it in the simpana script. Make sure your in the correct path when you grep for it. i.e. default install location is /opt/simpana/Base

cat simpana | grep "There is already another simpana running"

From the output shown you will see the full path to the file and the filename we test exists. Please watch the video clip below for a complete walk through.

Simpana 9 – Manual rollback of SP on Unix

Another video clip from a demo/information series I put together. This one talks about how to manually rollback a Service Pack on a Unix client.

Hope you enjoy, always remember to provide feedback.

Simpana 9 – Unix – Manual Install of ServicePack

Another video clip from a demo/information series I put together. This one talks about how to manually install a Simpana 9 Service Pack onto a Unix client.

Hope you enjoy. Feedback, hit the comments of the post.