You cannot "destroy" a partition. What you can do is to remove it. You can also put its start (where there is a bit of structure information) within other data that then gets overwritten. I assume you have somthing in there that is smaller than the actual partition and starts at the beginning, correct? To resize the partition, I would say the best way is to use GNU parted and just move the end forward and keep the start. As long as you do not put anything after the end of the new partition, nothing there gets overwritten. Only the geometry information in the first sector of the partition will be updated. Since you are not too familiar with doing this, I would advise a complete backup of anything valuable on the affected disk, before you start. Mistakes are easy to make. As a second precaution, before you chenge anything, print out the current geometry information thet parted reports. Arno On Sun, Mar 09, 2008 at 10:20:59PM +0100, K?vin REDON wrote: > how should I resize the partiton, since it's an unformatted partition. > setting the end cylinder of the partition will not destroy it ? > > Kevin > > Arno Wagner wrote: > > Plain cryptsetup encrypts the whole device. ''resize'' is > > only for when you do not want that. What you need to do > > is to conventionally resize the partition. Cryptsetup > > will follow. If you need to resize something within the > > encrypted device, do this conventionally on the decrypted > > device (/dev/mapper/<something>). > > > > Arno > > > > On Sun, Mar 09, 2008 at 12:10:59PM +0100, K??vin REDON wrote: > >> Hi, > >> > >> I wish to shrink the encrypted partition. > >> I did : > >> > >> cryptsetup --size 189563200 resize sda5_crypt > >> (was 233936411 before) > >> the status show this size, but the partition itself (/dev/sda5) did not > >> shrink, and after a reboot the size of sda5_crypt is again 233936411. > >> > >> for more details of what sda5_crypt, just tell me (basically LVM that I > >> shrinked successfully) > >> > >> Thanks, > >> Kevin REDON > >> > >> --------------------------------------------------------------------- > >> dm-crypt mailing list - http://www.saout.de/misc/dm-crypt/ > >> To unsubscribe, e-mail: dm-crypt-unsubscribe@xxxxxxxx > >> For additional commands, e-mail: dm-crypt-help@xxxxxxxx > >> > > > > --------------------------------------------------------------------- > dm-crypt mailing list - http://www.saout.de/misc/dm-crypt/ > To unsubscribe, e-mail: dm-crypt-unsubscribe@xxxxxxxx > For additional commands, e-mail: dm-crypt-help@xxxxxxxx > -- Arno Wagner, Dipl. Inform., CISSP --- Email: arno@xxxxxxxxxxx GnuPG: ID: 1E25338F FP: 0C30 5782 9D93 F785 E79C 0296 797F 6B50 1E25 338F ---- Cuddly UI's are the manifestation of wishful thinking. -- Dylan Evans If it's in the news, don't worry about it. The very definition of "news" is "something that hardly ever happens." -- Bruce Schneier --------------------------------------------------------------------- dm-crypt mailing list - http://www.saout.de/misc/dm-crypt/ To unsubscribe, e-mail: dm-crypt-unsubscribe@xxxxxxxx For additional commands, e-mail: dm-crypt-help@xxxxxxxx