VMWARE_CANNOT_RETRIEVE_VM_MOR_ID with EMC ScaleIO

If you are trying to run/evaluate EMC ScaleIO on “sub-par” servers, aka a homelab, and you get errormessages very early in the deployment, with the error being:
“VMWARE_CANNOT_RETRIEVE_VM_MOR_ID” or something similar.

It might just be because the cloned templates are set up with too many cores to what your hardware actually supports.

MDT LiteTouch WindowsPE x64 dnsmasq

Just a quick note, it works to boot an MDT LiteTouch WinPE x64-image with dnsmasq, using:

menu label ^Boot MDT-bootdisk
linux /memdisk
initrd /winmdtx64.iso
append iso raw

 

sources:

How to Install Windows 7 over a Network using Linux – PXE, DNSMasq, and Samba

http://www.syslinux.org/wiki/index.php?title=MEMDISK

Splunk systemd unit-file for debian Jessie

This one works with Debian Jessie.
Please note that after the first install, or after upgrades you have to start it manually to accept the license.

# editor /lib/systemd/system/splunk.service

[Unit]
Description=Splunk
Wants=network.target
After=network.target

[Service]
Type=forking
RemainAfterExit=yes
ExecStart=/opt/splunk/bin/splunk start
ExecStop=/opt/splunk/bin/splunk stop
ExecReload=/opt/splunk/bin/splunk restart
StandardOutput=syslog

[Install]
WantedBy=multi-user.target

# systemctl enable splunk.service

Vmware Perl SDK on Debian Jessie

The only thing I dislike more than RPM-based distros, is software thats only tested on RPM-based distros.
</fanboi>

Do the following to install VMWare Perl SDK:

# apt-get install libconvert-units-perl libmath-calc-units-perl libnagios-plugin-perl libxml-perl libclass-methodmaker-perl libnet-ssleay-perl libcrypt-ssleay-perl libarchive-zip-perl libdata-dump-perl libsoap-lite-perl libssl-dev –no-install-recommends

Enter “vmware-vsphere-cli-distrib” after extracting the tar-file from vmware, edit “vmware-install.pl” and search for:


if ( direct_command(“cat /etc/*-release | grep -i ubuntu”) || direct_command(“cat /proc/version | grep -i ubuntu”) ) {

Change it to:

if ( direct_command(“cat /etc/*-release | grep -i ubuntu”) || direct_command(“cat /proc/version | grep -i debian”) ) {

 

After running vmware-install.pl, watch as the installer will ruin your package-manager by downloading stuff via CPAN manually.

Thats just lovely. 🙂

Installing paperless on Debian Jessie

I wanted to test installation of https://github.com/danielquinn/paperless, but the instructions are “somewhat” unclear.
Here I am trying to document the process, so it might be usefull for someone later on.

First, having a requirements.txt is all great and dandy, but saying I need GNU Privacy Guard does not translate to which package, and a link to GPG’s homepage isnt very helpful.
Also, “apt-cache search gpg | wc -l” returns 72 packages.

Alright, enough said – lets do this. 🙂

Start slow, apt-get all the requirements (hope I got them all….) :

# apt-get install –no-install-recommends git libtiff-tools python3-pip python3-dev libtiff5-dev libjpeg62-turbo-dev zlib1g-dev libfreetype6-dev liblcms2-dev libwebp-dev tcl8.5-dev tk8.5-dev python-tk unpaper imagemagick tesseract-ocr tesseract-ocr-YOURLANGUAGE

Please note the YOURLANGUAGE there, to find your language do this:

$ apt-cache search tesseract-ocr-| sort

# git clone https://github.com/danielquinn/paperless /usr/src/paperless/
# cd /usr/src/paperless/

Copy the example-config, then edit it.
# cp /usr/src/paperless/paperless.conf.example /etc/paperless.conf
You have to change some stuff in the config-file, so do:
# editor /etc/paperless.conf
And edit:
PAPERLESS_PASSPHRASE, just set and forget – this should never ever be changed.
PAPERLESS_CONSUMPTION_DIR, somewhere your service user have access, I just used a subfolder in $HOME.

Then do

# pip3 install –requirement /usr/src/paperless/requirements.txt

(and poff, there goes management via apt. The packages dont exist with the correct versions in Jessie repos anyway, so well… This wouldnt have been pretty anyway.)

 

After that, do the following:

# /usr/src/paperless/src/manage.py migrate

and

# /usr/src/paperless/src/manage.py createsuperuser

 

Finally you run the software by starting the webserver, and the consumer.
First the webserver:
# /usr/src/paperless/src/manage.py runserver 0.0.0.0:8000 &
(Obviously, remember to open tcp/8000)
And the consumer:
# /usr/src/paperless/src/manage.py document_consumer

Then put pdf-files into the consumer-dir and watch some kind of magic happen.

To be honest, I wasn’t that impressed so I ditched the software at this point.
Therefore I doubt this guide will be updated in the future.

Configure Brother DCP-7055W under Debian Jessie

On a fresh machine, do the following:

# apt-get install cups sane sane-utils —no-install-recommends
(Theres two –no, in case wordpress touches the formating)

Surf to

http://support.brother.com/g/b/downloadend.aspx?c=gb&lang=en&prod=dcp7055w_us_eu_as&os=128&dlid=dlf006893_000&flang=4&type3=625

(In case link dont work, go to Brothers support-site, search up your printer, select Linux as OS, and pick the “deb-edition”, then select “Driver Install Tool”)

Right click on “If your download does not start automatically, please click here.”, copy link.

 

Go to server:

$ wget http://download.brother.com/welcome/dlf006893/linux-brprinter-installer-2.0.0-1.gz

(that link might be old when you are reading this)

Then, as root:

# mkdir brotherprint; mv linux*brprinter*.gz brotherprint; cd brotherprint

# gunzip linux-brprinter-installer-*.*.*-*.gz

# bash linux-brprinter-installer-*.*.*-*

Follow the on-screen installation, don’t panic if it can’t find ia32-libs, its going to work great.

When you are prompted for a device URI, choose yes, select 9 (thats input of IP)

When prompted, insert the IP. (DNS does not work…..)

 

When finished, test the scanner by issuing the following command:

# scanimage -T

You should hear your scanner working now. 🙂

MotionPie Cam in Domoticz with Motion detection

I wanted to try setting up my Raspberry Pi-camera, and I wanted to integrate it with Domoticz.

I did some manual labor for setting up a dedicated IP-cam from scratch, but after searching around I found MotionPie ( https://github.com/ccrisan/motionPie ).
No point re-inventing the wheel, so I loaded it up according to the installation manual, and got it up network-wise.

The following is needed to be configured in order for Domoticz to work:
IP Address: <ipaddress>
Port:<default-is-80>
Username:<blank>
Password:<blank>
ImageURL:picture/1/current/

If you create a dummy switch in Domoticz, you can have motionpie activate that switch using Motion Notifications:
Enable running of commands, and insert the following command:
curl ‘http://<IP-to-domoticz&gt;:8080/json.htm?type=command&param=switchlight&idx=<IDX>&switchcmd=On’
Where <IP-to-domoticz> is self-explanatory, and <IDX> is the ID-number for the switch.
Don’t forget to edit the switch so it’s a motion sensor, and set a custom off-delay.
MotionPie won’t trigger it “off” for you.

MotionPie and custom filenames

I wanted to setup a tiny timelapse-rig using raspberry pi and the official addon-camera.

A quick search returned MotionPie ( https://github.com/ccrisan/motionPie ), and after setting it up using the supplied wiki-pages and some initial configuration I had a feed to watch.

I plugged in a USB-drive (make sure it has a partition and a filesystem MotinoPie can read (ext4 f.ex.)) and under the admin-menu, and “File Storage” you should be able to select the external storage.

In order to create a timelapse you have to save snapshots at regular intervals, this is done under “Still Images”, select “Interval Snapshots” under “Capture Mode” and insert a interval.
Remember 30 pictures per second for a movie equalls 1800 pictures per minute of video.
Dont exagerate your interval, or you will have a very long (and boring?) timelapse.

15s interval over 3 days is 10 minutes of video and 18 000 pictures.

Now the tricky part was that I wanted to create the timelapse outside of MotionPie, and therefore I needed the pictures in sequence, and not using the default file naming.
There was no real legend with variables that I wanted (I wanted to use unix time) – so some quick googling led me to this handy site ( http://www.cyberciti.biz/faq/linux-unix-formatting-dates-for-display/ ) – and that site had this handy table:

%FORMAT String Description
%% a literal %
%a locale’s abbreviated weekday name (e.g., Sun)
%A locale’s full weekday name (e.g., Sunday)
%b locale’s abbreviated month name (e.g., Jan)
%B locale’s full month name (e.g., January)
%c locale’s date and time (e.g., Thu Mar 3 23:05:25 2005)
%C century; like %Y, except omit last two digits (e.g., 21)
%d day of month (e.g, 01)
%D date; same as %m/%d/%y
%e day of month, space padded; same as %_d
%F full date; same as %Y-%m-%d
%g last two digits of year of ISO week number (see %G)
%G year of ISO week number (see %V); normally useful only with %V
%h same as %b
%H hour (00..23)
%I hour (01..12)
%j day of year (001..366)
%k hour ( 0..23)
%l hour ( 1..12)
%m month (01..12)
%M minute (00..59)
%n a newline
%N nanoseconds (000000000..999999999)
%p locale’s equivalent of either AM or PM; blank if not known
%P like %p, but lower case
%r locale’s 12-hour clock time (e.g., 11:11:04 PM)
%R 24-hour hour and minute; same as %H:%M
%s seconds since 1970-01-01 00:00:00 UTC
%S second (00..60)
%t a tab
%T time; same as %H:%M:%S
%u day of week (1..7); 1 is Monday
%U week number of year, with Sunday as first day of week (00..53)
%V ISO week number, with Monday as first day of week (01..53)
%w day of week (0..6); 0 is Sunday
%W week number of year, with Monday as first day of week (00..53)
%x locale’s date representation (e.g., 12/31/99)
%X locale’s time representation (e.g., 23:13:48)
%y last two digits of year (00..99)
%Y year
%z +hhmm numeric timezone (e.g., -0400)
%:z +hh:mm numeric timezone (e.g., -04:00)
%::z +hh:mm:ss numeric time zone (e.g., -04:00:00)
%:::z numeric time zone with : to necessary precision (e.g., -04, +05:30)
%Z alphabetic time zone abbreviation (e.g., EDT)

So then it was just a matter of replacing anything under “Image File Name” with “pics/%s” – and everything will be jolly good.