LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 04-05-2012, 02:33 PM   #1
Steviepower
Member
 
Registered: May 2010
Location: Eindhoven
Distribution: ubuntu/debian
Posts: 152

Rep: Reputation: 25
Unhappy Running cryptsetup returns error


Hello,

While I'm trying to encrypt an external harddrive on a debian6 server I'm having some troubles running cryptsetup. I tested this with a usb memory stick and it worked fine on ubuntu but now I have this server with an external harddrive connected to it, and it returns an error:
Code:
Cannot initialize device-mapper. Is dm_mod kernel module loaded?
Presumably this means the dm_mod kernel module isn't loaded. My question here is where do I get this from and how do I make sure it will be loaded?
quick google search returned:
Code:
steven@server:~$ sudo modprobe dm_mod
FATAL: Error inserting dm_mod (/lib/modules/2.6.32-5-amd64/kernel/drivers/md/dm-mod.ko): Unknown symbol in module, or unknown parameter (see dmesg)
What could this be and what am I not doing that I should do?

thanks,

btw, tried this on my ubuntu laptop: http://tipstrickshowtos.blogspot.com...into-your.html
worked fine.
 
Old 04-05-2012, 02:56 PM   #2
Steviepower
Member
 
Registered: May 2010
Location: Eindhoven
Distribution: ubuntu/debian
Posts: 152

Original Poster
Rep: Reputation: 25
Oh and I found out the module is called dm, not dm_mod apparently...
http://git.freebsd.your.org/gitweb/?...ded56651feb828
 
Old 04-05-2012, 03:17 PM   #3
Steviepower
Member
 
Registered: May 2010
Location: Eindhoven
Distribution: ubuntu/debian
Posts: 152

Original Poster
Rep: Reputation: 25
also found this:
Quote:
- Check that you have the device mapper and the crypt target in your kernel. The output of "dmsetup targets" should list a "crypt" target. If it is not there or the command fails, add device mapper and crypt-target to the kernel.
source: http://code.google.com/p/cryptsetup/...AskedQuestions

But how do I do this? Its a server distro... I don't feel like doing much things on there because it's a production system, I just want to be able to do secure backups from it.
 
Old 04-06-2012, 02:12 AM   #4
Steviepower
Member
 
Registered: May 2010
Location: Eindhoven
Distribution: ubuntu/debian
Posts: 152

Original Poster
Rep: Reputation: 25
I looked into modprobe and checked if the module was loaded by:
Code:
modproble -l|grep dm
and among other things it returned this:

Code:
kernel/drivers/hwmon/dme1737.ko
kernel/drivers/md/dm-mod.ko
kernel/drivers/md/dm-crypt.ko
kernel/drivers/md/dm-delay.ko
kernel/drivers/md/dm-multipath.ko
kernel/drivers/md/dm-round-robin.ko
kernel/drivers/md/dm-queue-length.ko
kernel/drivers/md/dm-service-time.ko
kernel/drivers/md/dm-snapshot.ko
kernel/drivers/md/dm-mirror.ko
kernel/drivers/md/dm-log.ko
kernel/drivers/md/dm-region-hash.ko
kernel/drivers/md/dm-log-userspace.ko
kernel/drivers/md/dm-zero.ko
So it does seem to be loaded!
 
Old 04-06-2012, 03:46 AM   #5
Steviepower
Member
 
Registered: May 2010
Location: Eindhoven
Distribution: ubuntu/debian
Posts: 152

Original Poster
Rep: Reputation: 25
on the other hand lsmod doesn't show an entry for dm-mod and when I try to load it by using modprobe dm-mod I get this:
Quote:
steven@server:~$ sudo modprobe dm-mod
FATAL: Error inserting dm_mod (/lib/modules/2.6.32-5-amd64/kernel/drivers/md/dm-mod.ko): Unknown symbol in module, or unknown parameter (see dmesg
 
Old 04-17-2012, 06:35 PM   #6
linuxStudent11
Member
 
Registered: Jun 2007
Posts: 164

Rep: Reputation: 18
What odes it say in dmesg? (try `less /var/log/dmesg` or just `dmesg | tail`)
 
Old 04-17-2012, 11:50 PM   #7
Steviepower
Member
 
Registered: May 2010
Location: Eindhoven
Distribution: ubuntu/debian
Posts: 152

Original Poster
Rep: Reputation: 25
all I get is:
Quote:
[22433716.203107] dm_mod: Unknown symbol scsi_verify_blk_ioctl
 
Old 04-18-2012, 02:27 AM   #8
H_TeXMeX_H
LQ Guru
 
Registered: Oct 2005
Location: $RANDOM
Distribution: slackware64
Posts: 12,928
Blog Entries: 2

Rep: Reputation: 1301Reputation: 1301Reputation: 1301Reputation: 1301Reputation: 1301Reputation: 1301Reputation: 1301Reputation: 1301Reputation: 1301Reputation: 1301
If you reply to your own thread, you take it off the zero reply list and you will get much less attention that other threads. I never saw this thread before.

I would say the problem may lie in how the kernel module was compiled. The module may have been compiled out-of-tree or for a different kernel config or maybe other modules are loaded that interfere with this one (like the SATA controller module, which may explain why it works with a USB stick).

You need the dm_mod and dm_crypt to use cryptsetup. Make sure the kernel and modules are installed properly and using the same config.

Can you post the output of 'lsmod' and 'lspci -k'.

Last edited by H_TeXMeX_H; 04-18-2012 at 02:29 AM.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
running process that sends email when returns 0 volumes Linux - Server 1 07-20-2010 11:13 AM
Running cryptsetup in initramfs with blackbox segmentation fault 3rdtreenz Linux - Kernel 1 01-03-2009 03:11 AM
cryptsetup error (Command failed: Invalid argument) SlackN00b Slackware 5 02-07-2007 12:59 PM
cryptsetup-luks error flying-tuxman Linux - Security 2 11-20-2006 11:08 AM
running an executable from a bourne shell which returns a value anekkan Programming 6 09-19-2005 07:59 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 12:10 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration