Tag Archives: 2011

New year, new rules

Josefine

A retrospective

A lot of stuff happened in 2011. Some good stuff and some bad stuff. All very much connected to life itself. Such is the way of all good stories, unfortunately they all come to an end. It is with tears in my eyes that I remember the loved ones I’ve lost in the passed year. But my own story isn’t finished, and new chapters are added all the time. New life was created, to fill the gaps of the loved ones we have lost.

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

LVM filesystem integrity

LVM gives you flexibility at the cost of more complexity. When a system with LVM configured is shutdown uncleanly, there may be some trouble getting back on track again.

Some notes from the top of my head, for occasions when this happens.

  • If your LVM system stops booting and complains about the disks, or the disks are suspected being dirty, boot into maintenance/single mode.

 

  • Search for your volume group to see that it’s available:
sudo vgscan

 

  • Activate your volume group:
vgchange -ay

 

  • Check filesystem integrity, for each of your logical volumes:
Posted in Linux | Tagged , , , , , , , , , , , , , | Leave a comment

Installing lm-sensors

One of my boxes have had some spontaneous shutdowns lately. I thought I could take a look among the gathered data of munin, to see if I could get a hint on what was going on. Turns out I hadn’t installed and configured munin on the this machine on the last re-install. So…

After installing and configuring munin, I thought I’d install lm-sensors to get some more  mainboard temperature monitoring:

  • Installing:
sudo apt-get install lm-sensors

 

  • Configuring involves finding out suitable a driver for your mainboards chipset:
sudo sensors-detect

 

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

Truecrypt woes

Background

Solving disk problems is a little more complicated when devices are encrypted. You need to keep in mind that a filesystem on an encrypted device can’t be seen unless the device is decrypted. Here is a few problems I’ve come in touch with, together with solutions that have worked for me.

Error unmounting a volume

Error message which may occur when trying to unmount truecrypt volume:

device-mapper: create ioctl failed: Device or resource busy

 

Trying to remove the volume with cryptsetup gives a similar message:

sudo cryptsetup remove /dev/mapper/truecrypt1
Device /dev/mapper/truecrypt1 is busy.

 

As the error messages implies, something is keeping the volume open. If lsof doesn’t show anything, it might be an active NFS export keeping it busy.

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

Restore image timestamp

I’m taking lots of pictures with my digital camera. I often batch process them and I have noticed that some of my older images have gotten their timestamp updated at the time  when this happened. As luck has it, the original timestamp is stored in the EXIF data of the picture, and restoring it is simple.

 

Begin by installing the jhead package:

sudo apt-get install jhead

 

To show the EXIF data of an image:

jhead image.jpg

 

To reset the original timestamp stored in the EXIF data of an image:

jhead -ft image.jpg

 

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

Unknown media type

When issuing dpkg or apt-get some messages appear among the usual output;

[root@narcissus (18:32:36) vb4]# dpkg -i virtualbox-4.1_4.1.6-74713~Ubuntu~natty_i386.deb
(Reading database ... 119517 files and directories currently installed.)
Preparing to replace virtualbox-4.1 4.1.4-74291~Ubuntu~natty (using virtualbox-4.1_4.1.6-74713~Ubuntu~natty_i386.deb) ...
* Stopping VirtualBox kernel modules                                                      [ OK ]
Unpacking replacement virtualbox-4.1 ...
Setting up virtualbox-4.1 (4.1.6-74713~Ubuntu~natty) ...
addgroup: The group `vboxusers' already exists as a system group. Exiting.
* Stopping VirtualBox kernel modules                                                      [ OK ]
* Uninstalling old VirtualBox DKMS kernel modules                                         [ OK ]
* Trying to register the VirtualBox kernel modules using DKMS                             [ OK ]
* Starting VirtualBox kernel modules                                                      [ OK ]
Processing triggers for ureadahead ...
Processing triggers for shared-mime-info ...
Unknown media type in type 'virtual/bluedevil-input'
Unknown media type in type 'virtual/bluedevil-audio'
Unknown media type in type 'virtual/bluedevil-sendfile'
Unknown media type in type 'all/all'
Unknown media type in type 'all/allfiles'
Unknown media type in type 'uri/mms'
Unknown media type in type 'uri/mmst'
Unknown media type in type 'uri/mmsu'
Unknown media type in type 'uri/pnm'
Unknown media type in type 'uri/rtspt'
Unknown media type in type 'uri/rtspu'
Unknown media type in type 'interface/x-winamp-skin'
Processing triggers for desktop-file-utils ...
Processing triggers for hicolor-icon-theme ...
Processing triggers for python-central ...

Don’t worry about the messages regarding Unknown media type. They refer to file associations in KDE which don’t have recognizable definitions.

You can get directly to your file associations, without sifting through settings, with the following command:

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

SIOCADDRT: File exists

I’ve been getting output from cron mailed to me as:

/etc/cron.daily/mycron:
SIOCADDRT: File exists

This warning stems from the same route being set several times. I want to make sure eth0 is set to be the default device, should it have changed for some reason.

The message breaks down to this:

SIOC = Serial Input Output Controller

ADD = action is ADD

RT = RouTe

File exists = This means that the route is already configured (file exists in /proc)

In my case the solution is to simply suppress the message by redirecting it to /dev/null:

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

Syslogging in Natty Narwhal

Having recently moved up to Kubuntu 11.04 Natty Narwhal, I noticed early on that the log file /var/log/messages was missing in the new install. Seeing this a peculiar but not investigating further to why it was missing, I finally did caved in and did some quick googling on the matter.

It turns out the developers felt it was redundant to save the same data in both /var/log/syslog and /var/log/messages. I have previously felt that they are similar but they are not identical, as /var/log/messages holds more information than what is found in /var/log/syslog.

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

LVM: Growing a filesystem

Some quick notes on LVM:

  • Display information about physical volumes (PV)
pvdisplay
  • Display information about all locical volumes (LV)
lvdisplay -a
  • Growing a logical volume
lvextend -L +1G /dev/mapper/rootvg-home
  • Growing the filesystem (this works for JFS)
mount -o remount,resize /home && mount -o remount /home

That last remount is just to make the filesystem writable again, since the resize sets the filesystem to read-only.

See the LVM-HOWTO for more information.

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

Thrift store jackpot

Thrift store jackpot

Yesterday I went to a local thrift store to leave off some stuff from my basement clearance for charities sake. While I was there, I was also hoping to find some cheap plastic playsets in a usable scale, which could be used for conversions. I like to convert plastic buildings, because they often have some type of detailing, which saves me the time and effort to make it myself. Old and/or broken playsets are an excellent starting points for this task and they usually come very cheap too.

Posted in Tabletop | Tagged , , , , , | 2 Comments