LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 04-21-2014, 09:33 AM   #1
Madhusudan801
LQ Newbie
 
Registered: Apr 2014
Posts: 2

Rep: Reputation: Disabled
Question issues with cryptsetup on CentOS 5.3 (kernel 2.6.18-128)


Hi,
Let me at the outset apologise for posting about cryptsetup about which i found some threads existing but the workarounds suggested in those dint quite help me...so here goes:

The following are the details of my set up
Linux flavour - Cent OS version 5.3
Kernel Version - 2.6.18-128.el5

Issue -
I am trying to encrypt a partition (i created a partition at the time of installation itself) on my hardisk using LUKS. I use the following command to achieve the same:
Code:
cryptsetup c aes-cbc-essiv:sha256 y s 256 luksFormat /dev/sda3
initially i kept getting the following error message:
Code:
      Failed to set up dm-crypt key mapping
      Check kernel support for the aes-cbc-essiv:sha256 cipher spec and verify that /dev/sda3 contains at least 258 sectors.
      Failed to write key storage
(i tried the cryptsetup with the other ciphers as well like aes-xts-plain64 but that dint work as well)

but then that changed today..the error message i get today is
Code:
Command failed
I have no idea what made this change happen...

The cryptsetup version is 1.0.3

Some of the diagnostics i performed
i did the following before using the cryptsetup
Code:
modprobe dm_crypt
modprobe dm_mod
modprobe aes
modprobe cbc
modprobe sha256
I did the last three steps because i cudnt find the aes-cbc-essiv:sha256 cipher in my /proc/crypto file

The following changes have also been made on /etc/lvm/lvm.conf
Code:
types = [ "device-mapper", 16 ] 
filter = [ "a|^/dev/mapper/[A-Z].*|", "r|^/dev/mapper/.*|", "a/.*/" ]
The dmsetup targets command gives the following output:
crypt v1.3.0
multipath v1.0.5
raid45 v1.0.0
snapshot-origin v1.6.0
zero v1.0.0
mirror v1.2.0
striped v1.1.0
linear v1.0.2
error v1.0.1

Please let me know where i am going wrong....

Thanks in Advance...
Madhusudan
 
Old 04-21-2014, 01:23 PM   #2
John VV
LQ Muse
 
Registered: Aug 2005
Location: A2 area Mi.
Posts: 16,990

Rep: Reputation: 2448Reputation: 2448Reputation: 2448Reputation: 2448Reputation: 2448Reputation: 2448Reputation: 2448Reputation: 2448Reputation: 2448Reputation: 2448Reputation: 2448
I take it you are not aware that CentOS 5.3 is 7 minor versions OUT of Date
and has been UNSUPPORTED since it went End of Life in October of 2009

5.3 is 4.5 YEARS OUT OF DATE
DO NOT USE IT !!!!!

upgrade to the current 5,10 in the older legacy 5 series ( if you MUST use 5 for old legacy hardware )
or
install the Current CentOS 6.5
 
Old 04-22-2014, 08:02 AM   #3
Madhusudan801
LQ Newbie
 
Registered: Apr 2014
Posts: 2

Original Poster
Rep: Reputation: Disabled
Thanks for the suggestion John VV. I would not be able to upgrade the OS easily....thats another story for another day.....

Anyways....i managed to complete the encrytption successfully. I had not unmounted the partition before trying to encrypt it..so before we
Code:
cryptsetup luksFormat /dev/sda3
we need to
Code:
umount /dev/sda3
Thanks!!
 
Old 04-22-2014, 01:19 PM   #4
John VV
LQ Muse
 
Registered: Aug 2005
Location: A2 area Mi.
Posts: 16,990

Rep: Reputation: 2448Reputation: 2448Reputation: 2448Reputation: 2448Reputation: 2448Reputation: 2448Reputation: 2448Reputation: 2448Reputation: 2448Reputation: 2448Reputation: 2448
mind you if you are using that encrypted partition for SECURITY reasons
a lot of bug and random number bugs have been fixed in the last 4.5 YEARS

this might leave that encryption almost USELESS
extreme caution should be used until you can use up to date software
 
1 members found this post helpful.
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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
Kernel version 2.6.18-128, what does it mean 18-128 ? bala.linuxtech Linux - Newbie 3 12-12-2012 06:13 AM
Centos 6.3 Kernel 3.5 and above usb sound card issues kosta20071 Linux - Kernel 1 09-30-2012 04:36 PM
Compiling cryptsetup issues HarryLong Linux - Software 2 02-14-2012 10:33 AM
issues updating to vmlinuz-2.6.18-128.1.6.el5xen mek Linux - Software 1 12-22-2009 09:21 PM
centos with 2.6.18-128 kernel behzadfu Linux - Server 1 07-02-2009 08:22 AM


All times are GMT -5. The time now is 01:56 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
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration