Author Archives: apeekaboo

Choosing default editor

For some reason my editor ofchoice (vim) reverted back to the default editor of nano on my server. The command for setting the default editor is:

sudo update-alternatives --config editor

Hopefully the setting will stick this time.

 

Posted in Linux | Tagged , , , , , | Leave a comment

Duplicate sources.list entry (apt-get)

It’s been bugging me for some time now. Whenever I do an apt-get update I get a warning:

# apt-get update
Hit http://www.ksplice.com quantal InRelease
Hit http://www.ksplice.com quantal/ksplice Sources
Get:1 http://www.ksplice.com quantal/ksplice amd64 Packages [1,566 B]
Get:2 http://www.ksplice.com quantal/ksplice i386 Packages [1,566 B]
Ign http://www.ksplice.com quantal/ksplice Translation-en_US
Ign http://www.ksplice.com quantal/ksplice Translation-en
Ign http://repo.steampowered.com precise/steam Translation-en_US
Ign http://repo.steampowered.com precise/steam Translation-en
Fetched 3,132 B in 3s (850 B/s)
Reading package lists... Done
W: Duplicate sources.list entry http://www.ksplice.com/apt/ quantal/ksplice amd64 Packages (/var/lib/apt/lists/www.ksplice.com_apt_dists_quantal_ksplice_binary-amd64_Packages)
W: Duplicate sources.list entry http://www.ksplice.com/apt/ quantal/ksplice i386 Packages (/var/lib/apt/lists/www.ksplice.com_apt_dists_quantal_ksplice_binary-i386_Packages)
W: You may want to run apt-get update to correct these problems

Obviously /etc/apt/sources.list doesn’t have any duplicate entries for the repository, so where does the warning stem from? Checking in /etc/apt/sources.list.d reveals a file called ksplice.list. The information in this file is the same as my entry in /etc/apt/sources.list so one entry has to be removed. I choose to move the file /etc/apt/sources.list.d/ksplice.list out of the way. I prefer keeping my sources in /etc/apt/sources.list as this makes it easier to maintain between both upgrades and other machines.

Posted in Linux | Tagged , , , , , | Leave a comment

Creating PDF files from images

Creating PDF files from images is really easy to do with the ImageMagick suite installed. This software suite can handle over 100 different image formats and is essential to have if you manipulate large batches of images. It has all sorts of useful functions; translate, flip, mirror, rotate, scale,  shear and transform images, adjust image colors, apply various special  effects, or draw text, lines, polygons, ellipses and Bézier curves.

 

  • Install imagemagick if it’s not present:
sudo apt-get install imagemagick

 

  • Convert some files into a PDF file:
convert file1.jpg file2.jpg document.pdf

or

convert *.jpg document.pdf

 

Posted in Linux | Tagged , , , , , , | Leave a comment

House moving update

If you’ve tried accessing this site for the last week, you already know that it has been offline. The reason for this is that I have been busy house moving, and setting up the server in my new apartment haven’t really been a priority. There is still loads of stuff to do, like unpacking boxes, buying new furniture, etc. We still have lots of stuff in storage, but we’re slowly getting all the pieces together. My painting/hobby station will be located inside the apartment this time, but some furniture is still missing.

Posted in Tabletop | Tagged | Leave a comment

Rebuilding a RAID1 mirror with Truecrypt container

Background

Rebuilding a RAID1 mirror with a Truecrypt container on it may require some additional steps. I guess that since no filesystem is visible on the disk, the RAID array is having trouble determining which disk to rebuild from. If your neighbourhood have had a blackout, the filesystem in the container is probably dirty anyway. This is how I take care of the matter on my external ICY Box IB-RD4320 USB chassi.

The manual for ICY Box IB-RD4320 USB chassi have this table regarding the meaning of the LED lamps on the unit:

Posted in Linux | Tagged , , , , , , , , , , , , , , , , , | Leave a comment

Opera: Blocking Flash

I think most people on Linux are aware of what a resource hog Adobe Flash is. Having recently upgraded to Opera-12.11 and at the same time purged almost all my preferences that I’ve had since for Opera version 6, I noticed stability and performance issues.

I run a horrific amount of open tabs and many sites run some sort of Flash for either ads or for your plain enjoyment/annoyance… This hogs the system and makes Opera unstable. Flash is rarely used for navigation, unless the site is lacking in content (my own cynical observation…), which is a reason to not visit it in the first place. Fortunately it’s easy to activate Opera’s On Demand Plugin and On Demand Plugin Placeholder, which blocks Flash until you click on the placeholder to activate it.

Posted in Linux | Tagged , , , , | Leave a comment

Logrotate: duplicate log entry

Cron is mailing me reports like these:

/etc/cron.daily/logrotate:
error: squeezeboxserver:1 duplicate log entry for /var/log/squeezeboxserver/server.log
error: found error in /var/log/squeezeboxserver/server.log , skipping
error: squeezeboxserver:14 duplicate log entry for /var/log/squeezeboxserver/scanner.log
error: found error in /var/log/squeezeboxserver/scanner.log , skipping

As the report tells you, logrotate tries to rotate some logs twice. Not a severe error but annoying enough to be fixed.

Begin by changing directory:

cd /etc/logrotate.d

Search for the filenames mentioned in the error report:

grep "/var/log/squeezeboxserver/scanner.log" *
logitechmediaserver:/var/log/squeezeboxserver/scanner.log {
squeezeboxserver:/var/log/squeezeboxserver/scanner.log {

It seems that squeezeboxserver changed name (this has happened before…) to logitechmediaserver with the latest software upgrade. An old entry still exists in logrotate for squeezeboxserver. Move this file out of the way:

mv squeezeboxserver /tmp/

There, problem fixed!

Posted in Linux | Tagged , , , , , , , , | Leave a comment

Mounting Linux NFS shares in AIX

I found a scribbled note regarding the matter and just had to post this as a reminder:

Mounting an NFS export from a Linux server in AIX will surely fail, unless you run this command before mounting:

nfso -o nfs_use_reserved_ports=1

After this you can proceed with regular mounting.

The explanations I’ve seen to why AIX doesn’t use reserved ports to begin with, vary from AIX follows NFS standard to It’s more secure this way. Whatever the reason behind this, it’s annoying when mounting fails without an abvious and reasonable explanation.

 

 

 

Posted in Linux | Tagged , , , , , , | Leave a comment

Converting files to mp3

I have previously used Lame to convert different file formats to mp3. Having stumbled on some mp4 videos that refused to being converted to mp3 I thought I’d try my luck with FFmpeg instead.

Using FFmpeg was quite easy:

ffmpeg -i infile outffile.mp3

Controlling the bit-rate of the created file:

ffmpeg -b 192 -i infile outffile.mp3

 

The mp4 file was converted to mp3 without problems. Mission accomplished!

Posted in Linux | Tagged , , , , | Leave a comment

WIP: the Crane

At my last visit to Toys ‘R’ Us, I bought two interesting terrain pieces for €6 each. Both are kids toys related to the brand Elias. This post is about the second one, a crane (Elias – Krana i Lunvik).

The crane, still untouched

The problem with both the Elias stuff and Thomas and Friends, is that most (all?) vehicles and many buildings have a face. This is of course a kids toy, so they want to add some character and persona to the stuff so they also can sell movies, cartoons and what not. For me this presents a problem, since I want terrain that looks a bit less like… a kids toy.

Posted in Tabletop | Tagged , , , , , , | Leave a comment