Backtrack 5 – Bootable USB Thumb Drive with “Full” Disk Encryption

UPDATE (8/14/2012): I have reports that the howto works fine with Backtrack 5 R3. Please let me know if this turns out to not be the case.

UPDATE (3/3/2012): The how-to has been updated to reflect changes for Backtrack R2. They were very minor and using the previous method still works. The only real change is:

  • lvm2 is now part of the ISO. That means we no longer have to use apt-get to install it. However, we still need to install hashalot, so it doesn't save us a step.
  • Added a note at the end about using dd to backup your install per a very good suggestion by Richard in comment 241.

UPDATE: This update has been tested with BT5R1 and works as is. Before we get started, here are a few housekeeping items:

  • There is a PDF version of this article available here.
  • Finally, if you want to be notified of updates to this page, subscribe to my RSS feed here.

I put quotes around full in the title because technically the whole disk isn't encrypted. We use LVM and the native encryption routines included in Ubuntu  to encrypt all partitions except for a small boot partition that never contains any data.

This is a fairly involved process, but I have done my best to document each detail. Please let me know if I missed anything or you have any questions. I can be reached via the contact form on the 'About' page of this website or via the comments below.

I strongly recommend you read through this guide at least once before starting.

I will be making a PDF available in the near future.

As in all my how-tos, user entered text is bold and comments are preceded by a # sign and generally not part of the output of a command. Finally, a couple of posts from the Ubuntu Community Documentation site were instrumental in getting this working.

https://help.ubuntu.com/community/EncryptedFilesystemOnIntrepid https://help.ubuntu.com/community/EncryptedFilesystemLVMHowto

WARNING: Before you start, please be aware that you can cause the system you are using to build this with to not boot correctly. During the install process below there is a warning about indicating where you want the boot loader to be installed. Be very careful at this point. First we are going to need some stuff.

Tools and Supplies

  1. A USB thumbdrive for the install - minimum capacity 16GB. Actually, you can squeeze this onto an 8GB drive, but you are out of room at that point.
  2. A Backtrack 5 DVD or an additional USB thumbdrive  (minimum 2GB, must be Backtrack 5)
  3. Optional: UNetbootin - A tool to transfer an iso image to a USB drive.
  4. Working internet connection once Backtrack 5 is booted.

Let's get started!

First, we need to grab a copy of the Backtrack 5 ISO.

Backtrack 5 Download Page

For my tests, I used the 64-bit Gnome build. I have not tested this how-to with all versions of Backtrack 5, but they should all behave similarly with the possible exception of the ARM build. I have no experience with Backtrack on that platform.

Now that we have the goods in hand, we can get to cooking.

This tutorial is based on booting Backtrack 5 first. That means that you need some form of bootable Backtrack media. It can be a virtual machine, DVD, or USB drive. Use your favorite method of creating a DVD or USB drive or you can use UNetBootin to create the thumb drive.  Below is a screenshot of using UnetBootin to install Backtrack, version 4 in this case, on a USB drive. Again, you will need version 5. I'm just lazy right now 🙂

It is as simple as selecting the image we want to write to the USB drive, the drive to write it to, and then clicking the 'OK' button. Warning: Make sure you pick the correct destination drive. You don't want to shoot yourself in the foot. 🙂

Partitioning

The first step is the physical partitioning of the drive. Boot up Backtrack from your DVD or USB drive. If you boot with the default menu item "Backtrack Text", you will not need to start networking as it will have started automatically. You can verify that networking is up and running by executing:

ifconfig 

and checking that your interface is up and has an IP address assigned. If networking isn't configured, the following commands will start it.

/etc/init.d/networking start

We do need to start the graphical interface.

startx

We will also need to figure out which drive is our target drive.  The following command will show the drives available and you can determine from that which is the new USB drive. Open a terminal windows and execute the following.

dmesg | egrep hd.\|sd.

We need to physically partition the target drive as follows:

  1. The first partition needs to be a primary partition, 500 MB in size, set to type ext4. Also remember to make this partition active when you are creating it. Otherwise you might have some boot problems.
  2. The rest of the drive should be configured as an extended partition and then a logical partition created on top of it.

Below are the steps to take to get the drive partitioned.  A '# blah blah' indicates a comment and is not part of the command and user typed commands are bolded. One note, we will need to delete any existing partitions on the drive. Also, the cylinder numbers below are specific to my test machines/thumb drives, yours may be different. Finally, if you are using this how-to to install to a internal hard drive, you probably want to add a swap partition.

fdisk /dev/sdb # use the appropriate drive letter for your system

# delete existing partitions. There may be more than one.

Command (m for help): d

Partition number (1-4): 1

# create the first partition

Command (m for help): n

Command action e   extended p   primary partition (1-4) p

Partition number (1-4): 1

First cylinder (1-2022, default 1): <enter>

Using default value 1 Last cylinder, +cylinders or +size{K,M,G} (1-2022, default 2022): +500M

# create the extended partition

Command (m for help): n

Command action e   extended p   primary partition (1-4) e

Partition number (1-4): 2

First cylinder (66-2022, default 66): <enter>

Using default value 66 Last cylinder, +cylinders or +size{K,M,G} (66-2022, default 2022): <enter>

Using default value 2022

# Create the logical partition.

Command (m for help): n

Command action l    logical (5 or over) p   primary partition (1-4) l

First cylinder (66-2022, default 66): <enter>

Using default value 66 Last cylinder, +cylinders or +size{K,M,G} (66-2022, default 2022): <enter>

Using default value 2022

# Setting the partition type for the first partition to ext3 Command (m for help): t

Partition number (1-4): 1

Hex code (type L to list codes): 83

# Setting the first partition active

Command (m for help): a

Partition number (1-4): 1

Command (m for help): w

If you happen to get an error that mentions something like "..the partition table failed with error 16:...", you need to reboot before continuing with the how-to. You might be able to get away with continuing, but there is a good chance you will experience some problems. After rebooting, you will need to re-execute the startx command and the cryptsetup luksOpen commands.

If you happen to get an error with mentions something like "..the partition table failed with error 22:..." you can run partprobe to re-read things. At least, this worked in my case.

It is now time to get a couple additional packages installed that we need for LVM and encryption. First we need to update the local repositories and then install lvm2 and hashalot. Output has been ommitted.

# For Backtrack 5 R1 type the following.
apt-get update
apt-get install hashalot lvm2

# For Backtrack 5 R2 we only need hashalot. Type the following.
apt-get update
apt-get install hashalot

Our next step is to enable encryption on the logical partition we created above and make it available for use. Before we do that though, there is an optional step we can take if we want to make sure no one can tell where our data is on the drive. It isn't really necessary since anything written will be encrypted, but if we want to be thorough and make sure no one can see where our data even sits on the drive, we can fill the logical partition with random data before enabling encryption on it. This will take some time, as much as a couple hours or more. Execute the following command:

dd if=/dev/urandom of=/dev/sdb5

The following commands will setup encryption services for the partition and open it for use. There are several ciphers that can be used, but the one indicated in the command is supposed to be the most secure and quickest for Ubuntu 8.10. Please note that the case of the command luksFormat is required.

cryptsetup -y --cipher aes-xts-plain --key-size 512 luksFormat /dev/sdb5

WARNING! ======== This will overwrite data on /dev/sdb5 irrevocably. Are you sure? (Type uppercase yes): YES

Enter LUKS passphrase: (enter passphrase) [type passphrase]

Verify passphrase: (repeat passphrase) [type passphase]

Command successful.

cryptsetup  luksOpen /dev/sdb5 pvcrypt

Enter LUKS passphrase: [type passphrase]

key slot 0 unlocked. Command successful.

If you should happen to get a "cannot access device" error when trying to perform the cryptsetup setup commands above, make sure the USB drive has not been mounted. That can happen sometimes. Now that that's all done, we can create our root and swap partitions using LVM. Again, the commands below will do so. 7.3 GB was the largest I could make my root partition. Play around with it a little and you may be able to make it a bit larger or you may have to make it a bit smaller.

pvcreate /dev/mapper/pvcrypt

Physical "volume /dev/mapper/pvcrypt" successfully created

vgcreate vg /dev/mapper/pvcrypt

Volume group "vg" successfully created

lvcreate -n root -l 100%FREE vg Logical volume "root" created.

The final step is to format the logical volumes we just created. I have not included the output below for brevity's sake.

mkfs.ext4 /dev/mapper/vg-root

If you want to try and eek out every last bit of performance and help your flash drive last longer, you can alternatively use the following command to disable journaling on the root partition. I have not tested this yet, but it should work just fine. Remember that this will open you to a greater possibility of unrecoverable drive corruption. Notice that the first letter o is small case and the second is a capitol letter O.

tune2fs -o journal_data_writeback /dev/mapper/vg-root

tune2fs -O ^has_journal /dev/mapper/vg-root

e2fsck -f /dev/mapper/vg-root

Believe it or not, we are finally ready to start installing Backtrack. To do, double-click on the install.sh icon on the desktop. This will start the graphical installer. Select you language of choice and click the 'Forward' button.

Next, select you timezone and click the 'Forward' button.

The next step is to select our keyboard layout. Pick yours and click the 'Forward' button. I can not vouch for any keyboard layout other than English.

Click on 'Specify partitions manually' and click the 'Forward' button.

We are not going to indicate the mount points for our partitions. First let's setup our root partition. Click on the row with vg-root in it and click the 'Change' button.

Select ext4 from the dropdown menu for 'Use as:', click 'Format the partition:', enter '/' without the quotes for the mount point and click the 'OK' button. The system will re-read the partition table and redisplay it.

Now for the boot partition. Click the row with you boot parition in it, /dev/sdb1 in my case, and click the 'Change' button.

Again, select ext4 and click the format checkbox. Enter '/boot' without the quotes for the mount point and click the 'OK' button. The disk partition will be re-read and the display updated.

Click the 'Forward' button.

You will get this message if you are installing to a USB drive and not using a swap partition. Click the 'Continue' button.

WARNING: You must click on the advanced tab on the next page and select your USB drive as the target for installing the bootloader. You will break your system if you do not.

Don't forget! Make sure you select the target disk for your install as the device for the boot loader to be installed on or you run the risk of making the system you are doing this on non-bootable. Then click on the 'OK' button.

Click the 'Install' button to start the install.

This will take some time. Go get a coke or beverage or your choice and relax for a bit.

More waiting.

and...more waiting. If it seems like the system is stuck at 99% forever, that's normal, at least in every case where I have done the install.

Finally! Important! Click on the 'Continue Testing' button. DO NOT click on the 'Restart Now' button or you have to redo a bunch of stuff.

We have now installed the main distribution to our thumb drive. The next step is to configure the newly installed system to use LVM and open the encrypted partition. However, before we do that we need to figure out the UUID of our encrypted volume. We want to do this so that we don't run into problems if the device name of the drive changes from machine to machine. The command we used to use to do this was vol_id. This has changed with Backtrack 5. We now use blkid. So execute blkidas below.

blkid /dev/sdb5

/dev/sdb5: UUID="2c133ec5-2eb2-4261-b8ee-5f6924b24ee4" TYPE="crypto-LUKS"

Make a note of the ID_FS_UUID value which is in italics above. We will need it later. Note: your output will be different than mine. Now time to configure our newly installed system. The first thing we have to do is make the newly installed system active so we can make changes to it. We do that by mounting the partitions and chrooting to it.

mkdir /mnt/backtrack5

mount /dev/mapper/vg-root /mnt/backtrack5

mount /dev/sdb1 /mnt/backtrack5/boot

chroot /mnt/backtrack5

mount -t proc proc /proc

mount -t sysfs sys /sys

To make everything truly operational, we can mount /dev/pts, but every time I try I have problems unless I reboot first. That is a real pain, so I just don't mount /dev/pts. We will get a couple warnings/errors as we go along, but they do not affect our install. The magic to making all this work is to rebuild the initrd image that is used to boot our system. We need to include some things, load some modules, and tell it to open the encrypted volume, but first we have to go through the whole process of installing software again. We have to do this because we are essentially right back where we started when we booted the live cd. Do the following again.

apt-get update

apt-get install hashalot lvm2

The next step is to configure how initramfs-tools will create our initrd file. This involves editing one files, the /etc/crypttab file. We used to have to edit /etc/fstab, but it appears we don't need to do that any longer. Mine was correct with /dev/mapper/vg-root as the root entry. If my change it isn't correct in your installation, follow the directions below to correct it. I use the vi editor, but you can use  your favorite editor.

vi /etc/crypttab

We need to add the following line to the file. If you are new to vi, hit the o key and the type the following:

pvcrypt      /dev/disk/by-uuid/<uuid from above>         none         luks

When you are done typing that line, hit the esc key and then type ':wq' without the quotes to save and exit vi. The file should look like this. The uuid is unique to my case. Make sure yours matches your system.

# <target device>   <source device>   <key file>   <options>
pvcrypt      /dev/disk/by-uuid/09330b5a-5659-4efd-8e9d-0abc404c5162    none         luks

Fixing the /etc/fstab file if necessary If we need to edit the /etc/fstab file, do the following. Again, use your favorite editor or vi.

vi /etc/fstab

The file will look something like below. The UUIDs will be different though.

# /etc/fstab: static file system information.
#
# <file system> <mount point>   <type>  <options>       <dump>  <pass>
proc            /proc           proc    defaults        0       0
# /dev/mapper/vg-root
UUID=c8d9b9a0-2198-4966-bc3a-39259df6a2c2 / ext4 relatime,errors=remount-ro 0 1
# /dev/sdb1
UUID=6af425ad-99b8-44a5-9ee1-0349141f9b1f /boot   ext4    relatime 0       2

We need to delete the first line that starts with UUID right after the line which contains 'vg-root.' It is bolded and in red above. We also need to remove the comment symbol from the start of the line with 'vg-root' in it. That line is just bolded above. For those new to vi, position the cursor on first 'U' of the line using your arrow keys and type 'dd', then move the cursor to the '#' in the line above and type the letter o, then type the line below, hit the esc key and type ':wq' without the quotes to save the file.  The line needs to look like below when done:

/dev/mapper/vg-root / ext4  defaults 0 1

Once that is done, there is one final thing we need to do before we can rebuild the initrd image and reboot. There is a bug in the cryptroot script that produces an odd situation.

Fixing the Passphrase Entry Bug

When we boot our USB drive, it will appear to be stuck on the splash screen. What is actually happening is that the system is waiting on us to enter our luks password. We have two choices for doing so.

The first is to just type it in when we see the splash screen. This works as long as we have waited long enough for the system to be ready for us. However, it's kind of hard to tell what's going on.

The second option is to press the F8 key which takes us to the console. There we will see the system waiting for us to enter our passphrase and this is where this odd bug shows up.

Initially, it will look like 4 characters have already been entered. They haven't been, but that's what it looks like. Then, every type we press a key, it will reprint the line asking us to enter our passphrase. It is actually taking the input correctly, but, man, it's annoying 🙂

We can fix that. Greg M and James had a conversation in the comments about this topic and found the resources needed to fix it. James was kind enough to send me the changes that need to be made.

As mentioned, the problem is with the cryptroot script. This script is the script that requests our passphrase and mounts the encrypted volume. Kind of important stuff.

Greg and James used a patch file found in this post in the Backtrack Linux forums. Below I have included the actual changes to be made. Alternatively, you can use a patch file. The commands to perform the patch are as follows. BTW - that's a zero in the patch command.

Warning: You can make your system unbootable if the cryptroot script gets corrupted.

cd ~

wget http://www.infosecramblings.com/cryptroot.patch

patch -u /usr/share/initramfs-tools/scripts/local-top/cryptroot ./cryptroot.patch

If you prefer to do it the manual way, open the file /usr/share/initramfs-tools/scripts/local-top/cryptroot in your favorite editor. Go to line 275. You should see the following:

# Try to get a satisfactory password $crypttries times
 	count=0
 	while [ $crypttries -le 0 ] || [ $count -lt $crypttries ]; do

Add the following line right after 'count=0'

echo "Unlocking the disk $cryptsource ($crypttarget)"

The section should now look like this:

count=0
echo "Unlocking the disk $cryptsource ($crypttarget)"
while [ $crypttries -le 0 ] || [ $count -lt $crypttries ]; do

Next, skip down to line 291 and you'll see a the following:

if [ -z "$cryptkeyscript" ]; then
cryptkey="Unlocking the disk $cryptsource ($crypttarget)\nEnter passphrase: "
    if [ -x /bin/plymouth ] && plymouth --ping; then

Replace the middle line, the one that starts with cryptkey, with:

cryptkey="Enter passphrase: "

so that it now looks like this:

if [ -z "$cryptkeyscript" ]; then
cryptkey="Enter passphrase: "
if [ -x /bin/plymouth ] && plymouth --ping; then

That's it. Save the file and we are ready to rebuild initrd. To do that, execute the following command.

update-initramfs -u

Now, if having to press the F8 key at boot bugs you, you can change the boot sequence to go directly to the console.

Warning: You can make your system unbootable playing around in here 🙂

To make the system boot to the console, edit the /boot/grub/grub.cfg file, search for the word 'splash', without the quotes, and delete the word  splash and only that word. The line will end up looking like this:

linux /vmliunx-3.2.6 root=/dev/mapper/vg-root ro text vga=791

If all goes well, you are now ready to cross your fingers and reboot.

SUPER IMPORTANT

Do not run aptitude safe-upgrade! It will remove some vital tools. Run apt-get upgrade instead which appears to leave things installed that need to be installed. If  you should happen to run aptitude safe-upgrade, ignore the warning about removing packages, type 'Y' and let it do its thing, you will need to run the following command before you reboot or your install will be broken.

apt-get install cryptsetup ecryptfs-utils keyutils

If you have problems, you can use the troubleshooting directions below to get back to the state where you can try to figure out how what went wrong.

System All Booted

Once you have a booting system, you are ready to login. The default userid is root and the default password is toor. You are now ready to login and being playing. Don't forget to change the root password as soon as you login the first time.

That's it.

You can make some final tweaks if you want like starting GNOME at boot, but for all intents and purposes you have successfully installed Backtrack 5 to a USB drive and don't have to worry about sensitive information being intercepted if it gets lost of stolen.

Backing It Up

Richard, in comment 241, mentioned backing up his completed install periodically just in case something goes wrong with his USB drive.

This is a fantastic idea.

There are several ways you can accomplish this.

First, on a Linux or other UNIX variant, like OpenBSD or Mac OS X, you can use the dd command.

Note: You will use the device identifier of the DRIVE, not a partition, unless you want to dd each partition separately. That seems a bit silly though. For instance, /dev/sdb is the whole drive, while /dev/sdb1 is just the first partition.

# Do not boot to the USB drive for this. Execute the following to create a binary copy of your drive.

dd if=/dev/[your device] of=/[destination]/backtrack5USB.img

You will need to have free space available on the target drive equivalent to the size of the USB drive. You can compres the image after the dd is complete using gzip or bzip2.

On a Windows machine, you will need to use a utility that will create a binary copy of the USB device. There are several products out there that will do this. Once such free product that will do this is USB Image Tool. This is freeware tool which creates an exact duplicate image of a USB drive. It does require .NET. There are many other options.

Troubleshooting

If you run into any problems, you don't have to start over. As long as your encrypted volume is built correctly and you have the correct LUKS passphrase, you can get back to the place you were with the Live CD. Simply boot with the original Live CD/USB drive and enter the following.

/etc/init.d/networking start

apt-get update

apt-get instal hashalot lvm2 # lvm2 not needed for R2

cryptsetup luksOpen /dev/[your logical partition] pvcrypt

mkdir /mnt/backtrack5

mount /dev/mapper/vg-root /mnt/backtrack5

mount /dev/[boot partition] /mnt/backtrack5/boot

chroot /mnt/backtrack5

mount -t proc proc /proc

mount -t sysfs sys /sys

mount -t devpts devpts /dev/pts

You can now do any trouble shooting you need to do and try to reboot again. One note, if you want to check the UUID of your partition, do it before you chroot.

-Kevin

Creative Commons License

Backtrack 5 – Bootable USB Thumb Drive with “Full” Disk Encryption by Kevin Riggins is licensed under a Creative Commons Attribution-Noncommercial-Share Alike 3.0 United States License. Permissions beyond the scope of this license may be available at http://www.infosecramblings.com/about/. Reblog this post [with Zemanta]

http://www.infosecramblings.com/backtrack/backtrack-5-bootable-usb-thumb-drive-with-full-disk-encryption/#comment-32660

{ 441 comments… read them below or add one }

thewire May 14, 2011 at 5:05 pm

hey kevin thanks for the update. also one thing to note is that after i booted into the system, i did a system update ‘apt-get update’ and ‘aptitude safe-upgrade’ without realizing until hours of trial and error that it is set to auto remove cryptsetup as well as some other necessary tools and updated the initramfs so when i rebooted i could not log back in. so after doing a clean install i do ‘apt-get update’ and ‘aptitude safe-upgrade’ to find out what is being removed and copy that and do ‘apt-get install’ for those programs and that seems to fix my problems and i am able to do an upgrade normally. sorry i am not on my computer to give u which specific files are needed. just thought id give my 2 cents.

Reply

kriggins May 15, 2011 at 7:26 am

@thewire,

Very interesting. I will have to play with this. I have done upgrades before on my Backtrack installations, but not using the safe-upgrade option. I will put a note in the how-to to be careful with apt-get safe-upgrade.

Kevin

Reply

kriggins May 15, 2011 at 7:57 am

@thewire,

You can also avoid this problem by using apt-get upgrade instead of aptitude safe-upgrade. Apt-get doesn’t break things. I have updated the how-to with a warning about this issue.

Kevin

Reply

HomeSen August 9, 2011 at 11:31 am

You should also be able to avoid that issue by not mixing apt-get and aptitude.

Instead of:
$ apt-get install
you should use:
$ aptitude install

Thus all packages get marked correctly (as dependency of an installed package) and thus wont get removed the next time you perform a safe-upgrade 😉

Reply

pete January 3, 2012 at 7:59 pm

…also do not run ‘apt-get autoremove’. It will remove encryptfs-utils and cryptsetup also.

Reply

K73SK December 18, 2012 at 2:19 pm

Thanks pete for saying what it removed, I did the following:

Anyone else who did “apt-get autoremove” , I did the same thing by accident. I went into the troubleshooting (as stated above) on my boot disk first, and then did the following (AFTER CHROOT):

apt-get install cryptsetup
apt-get install hashalot
apt-get update

then I did the entire section labeled “Fixing the Passphrase Entry Bug” again and it works again.

Reply

billdebill May 14, 2011 at 5:17 pm

Hi,

Thanks for an updated version of the guide!
I think that there’s a typo in “Troubleshooting” section. Following line:

“mount /dev/[boot partition] /mnt/backtrack4/boot”

has “backtrack4” instead of “backtrack5”

Reply

kriggins May 15, 2011 at 7:27 am

@billdebill,

Thanks for the comment. Fixed now.

Kevin

Reply

Marc Handelman May 14, 2011 at 9:33 pm

Outstanding tutorial, well written, and with a keen attention to detail. Much appreciated.

Reply

kriggins May 15, 2011 at 7:27 am

@Marc,

Thanks.

Kevin

Reply

Edoha May 15, 2011 at 8:30 am

я ставлю бактрак5 лайф сиди, но он выдает ошибку, не загружается графическая оболочка, у меня видео карта н видио 310м, скачивал драйвера на версию кде х64, но они не ставяться, как мне его запустить?

Reply

Abhisek August 12, 2011 at 1:57 pm

What language have you written?

Reply

Dahgoth August 28, 2011 at 3:16 pm

Попробуй почитать Вики и ФАЙ для начала, друг =)
Эта ссылка поможет тебе:
http://www.backtrack-linux.org/wiki/index.php/Basic_Usage#X_wont_start.21

Try to read Wiki and FAQ for begining mate =)
This link will help you:
http://www.backtrack-linux.org/wiki/index.php/Basic_Usage#X_wont_start.21

Reply

Mr.H May 15, 2011 at 4:11 pm

Hello, this new tutorial for BT5 is simply excellent !
I’ve just done it and it works flawlessly. About the potential error 16 when partitioning with fdisk, I found out that it did not happen when you save (with ‘w’) a first time after deleting all partitions and then go on with fdisk again.

Dunno if it’s a mere coincidence but it worked for me !

Thanks a lot for updating your work so fast !

Reply

kriggins May 15, 2011 at 7:26 pm

@Mr. H,

Thanks and I’m glad it worked for you.

Kevin

Reply

pete January 3, 2012 at 7:35 pm

I found this to be true as well.

Reply

Freakin May 15, 2011 at 5:20 pm

Any tips for getting this live USB to work on a macbook? Works great on various PCs but macbook won’t even find it when i try to boot…

thanks for the updated guide!!

Reply

kriggins May 15, 2011 at 7:26 pm

@freakin,

The only Mac in the house is my wife’s and I am not going near it. If I even breathe around it and something goes wrong, life will not be worth living for me 🙂

Maybe somebody else who has some experience with live CDs and Macs can chime in.

Kevin

Reply

Nasrudiin May 16, 2011 at 10:20 pm

Try to make virtual side by side with win OS then use live CD or USB. That is the easiest way you can do.

Reply

vdm August 4, 2011 at 11:21 am

I just finished installing BT5 on a 64G USB stick for my normal Macbook (one of the first unibody models) and his is what i did, as far as memory serves.

– Created a HFS+ partition of about 25M or so and format it. I used a GNU/Linux OS on another PC for this. The reason was that the OSX disk tool didn’t let me make a partition of fewer then a few gigs. Way too much overkill for a partition that will only hold a few files and on a medium where resources are low.

– Put the stick in OSX and download rEFit from http://refit.sourceforge.net. You do NOT have to install it on the macbook, just copy the files and run the script as explained at http://refit.sourceforge.net/doc/c1s1_install.html (The other medium part at the bottom). You’re done with the booting part.

– Insert the BT5 DVD and Reboot and hold down the Alt/Option button in the loading screen. When you have the USB stick in the macbook, an rEFit option should appear along side with a “windows” DVD boot icon (Apple, wtf?!) to start BT5. You can now boot the DVD and follow this guide normally.

– At the part where you need to specify where to place the boot loader, select the boot partition and NOT the drive itself. In my case, /dev/sdb2.

That’s it, and no special config on your Macbook required!

Reply

Joe May 12, 2012 at 9:48 pm

Im a little confused, being a newbie and all, but should we instal the boot loader to the HFS+ partition? And for the partition steps in the guide, should we change partition number? eg, partition 1 in the guide should be partition 2 for us?

Reply

Pointer May 15, 2011 at 7:33 pm

Great guide! I had some trouble partitioning it from the command line on my first attempt so I opted for GParted. After doing the guide and rebooting for the first time it wouldn’t boot. I used the troubleshooting section and determined that the problem was I mounted sdb5 as the boot when it should have been sdb2. After that all works! Only other question… how do you change the backtrack splash that shows after the grub but before pressing F8 to enter passphrase?

Thanks!

Reply

lel October 23, 2013 at 2:42 am
Juggl3r May 16, 2011 at 10:39 am

Hi, I have some problemes….

i does everything like in the tutorial, but when I try to boot from the USB stick, it don’t finds the boot partition? (I use truecrypt on my host-machine and when I hit ESC in the bootsection, it don’t displays the possible partitions…) When I try to boot my BT4 from USB, I also hit ESC and then I can say, I want to boot from paritition 1… but with my BT5 USB Stick it don’t work.
What I have done wrong? Can I repair that or do I have to make all new?

But Thanks for that Tutorial!

Reply

Nasrudiin May 16, 2011 at 6:17 pm

Great stuff. I just reminding if you just need to use persistent USB then you can use same as like the BT4 or BT3.

Reply

kriggins May 18, 2011 at 7:08 am

@nasrudiin,

True, but there are some issues with Backtrack 5 and persistence. The Backtrack 4 how-to method does not yet work.

Kevin

Reply

Cheno May 16, 2011 at 6:21 pm

Could you perhaps make a video of this tutorial? It would help me greatly. Also, when you want us to reboot after the mounting and chrooting stage, do you want us to reboot from the live CD or from the usb flash drive we just made?
Thanks.

Reply

Nasrudiin May 16, 2011 at 10:16 pm

Yes the USB you just made it because you were troubleshooting for any trouble you get it. Now you trying to to see if you are successful.Good luck

Reply

kriggins May 18, 2011 at 7:08 am

@cheno,

I plan to make a video, but it will be a bit. Have to carve out the time to do it. BY the time I tell you to reboot, you are done. You will be booting from the new USB drive.

Kevin

Reply

Anonymous May 17, 2011 at 8:42 pm

I am new to installing backtrack at all and followed the guide all the way to the end and then I get an error when I boot up from the USB drive:

ALERT! /dev/mapper/vg-root does not exist. Dropping to shell!

Please tell me what I am doing wrong and thank you for your time and help.

Reply

Anonymous May 18, 2011 at 11:04 am

The boot after my initial install also had:
ALERT! /dev/mapper/vg-root does not exist. Dropping to shell!

I went back into the chrooted environment and cleaned up the fstab file (replaced options (error=remount-ro) with defaults), reran “update-initramfs -u” and rebooted successfully.

Also, the 3rd command under troubleshooting has a missing “l” in install. Just cosmetic if one is coying and pasting.

Reply

Anonymous May 18, 2011 at 2:44 pm

When I run “update-initramfs -u” I get the following messages

update-initramfs: Generating /boot/initrd.img-2.6.38
cryptsetup: WARNING: invalid line in /etc/crypttab –
cp: cannot stat ‘/etc/console-setup/boottime.kmap.gz’: No such file or directory

When I execute “vi /etc/crypttab” and I type what is said in the guide the text is in white. Could that be the problem?

Again thank you for your time and help.

Reply

jheitz1117 July 30, 2011 at 5:37 pm

If you have leading spaces in the /etc/crypttab file, you might try removing them. This may be worth noting in the walkthrough itself for the following reasons.

I had both of those problems, where /dev/mapper/vg-root did not exist upon booting to my persistent drive, and also the warning indicating an invalid line in /etc/crypttab. I resolved both problems at once on a hail-mary guess that the program doesn’t like lines that start with spaces. In order to line up the fields with the comment in the file (because I’m completely anal about that kind of thing, lol), I had typed two spaces before ‘pvcreate’. When I removed the spaces, I no longer received the warning when I updated the initrd image, and I also was able to boot to my persistent drive afterward.

Reply

Nasrudiin May 20, 2011 at 9:29 am

It exist my friend. I tried and it works for me. I do not know what you have done but try to use the guidelines step by step. Are you sure you did not jump anything? Let me know. Thank you

Reply

Anonymous May 20, 2011 at 5:21 pm

No I didn’t skip any steps at all. I did everything step by step.

Reply

Silva May 20, 2011 at 10:14 pm

Same here I have that problem and still did not find solutions. Also I have tried this guidelines http://www.backtrack-linux.org/wiki/index.php/Persistent_USB and have the problem coping the iso to the USB.

Reply

aj May 19, 2011 at 10:46 pm

Send me your email and I will email you a pdf of this article. I printed it with Acrobat anyway.

Reply

Anonymous May 19, 2011 at 11:08 pm

I just need help with the last part of the file editing and then I will be fine. As I stated above the error I am getting is:

When I run “update-initramfs -u” I get the following messages

update-initramfs: Generating /boot/initrd.img-2.6.38
cryptsetup: WARNING: invalid line in /etc/crypttab –
cp: cannot stat ‘/etc/console-setup/boottime.kmap.gz’: No such file or directory

When I execute “vi /etc/crypttab” and I type what is said in the guide the text is in white. Could that be the problem?

Again thank you for your time and help.

Reply

Silva May 20, 2011 at 9:52 am

Sorry I did not understand the process for this. Could you please help me sorted it of this. Thank you

vi /etc/fstab

The file will look something like below. The UUIDs will be different though.

# /etc/fstab: static file system information.
#
#
proc /proc proc defaults 0 0
# /dev/mapper/vg-root
UUID=c8d9b9a0-2198-4966-bc3a-39259df6a2c2 / ext4 relatime,errors=remount-ro 0 1
# /dev/sdb1
UUID=6af425ad-99b8-44a5-9ee1-0349141f9b1f /boot ext4 relatime 0 2
The only line we need to change is the line for vg-root which is bolded above. For those new to vi, position the cursor on first ‘U’ of the line using your arrow keys and type ‘dd’, then move the cursor to the ‘#’ in the line above and type the letter o, then type the line below, hit the esc key and type ‘:wq’ without the quotes to save the file. The line needs to look like below when done:

/dev/mapper/vg-root / ext4 defaults 0 1

Reply

Jake May 20, 2011 at 8:18 pm

Thanks again for the article! I was able to get this with 4, but now, on BT5 I get the following when I run ‘startx’:

Fatal Server Error:
Could not create lock file in /tmp/.tX0-lock

I tried to delete it, but I’m told the rile is ‘read only’. Do you know why this is?

Reply

HarrisonFord May 23, 2011 at 11:26 pm

Users who are getting this error: “ALERT! /dev/mapper/vg-root does not exist. Dropping to shell!” Followed by a drop to ‘(intramfs)’ prompt

Did you use gEdit to edit /etc/crypttab and /etc/fstab? This will not work because in the command prompt, you re-mapped the root to /mnt/backtrack5, therefore “vi /etc/crypttab” in that shell edits a completely different file than opening /etc/crypttab via gEdit with X.

Hope that helps.

Reply

HolyDeadMonkey May 25, 2011 at 6:03 am

Good job! thx

Reply

Nicholas Farshidmehr May 26, 2011 at 12:13 am

If you do the partitioning in text mode (without startx) then you can get past the errors after you reboot.

Reply

Nicholas Farshidmehr May 26, 2011 at 12:44 am

I don’t want encryption. I’m confused on how to avoid this in the howto.

Reply

DJB May 27, 2011 at 7:36 am

Great tutorial, thanks!

I spent over an hour troubleshooting initramfs+grub after running aptitude safe-upgrade before finding this; I never thought of checking for packages which had been purged >_>.

As an unrelated note for some Intel HD/GMA users, you may need to change “nomodeset” to “i915.modeset=1” in the kernel arguments in /boot/grub/grub.cfg (edit the entries in /etc/grub.d || /etc/default/grub then run grub-mkconfig to make permanent) if the kernel panics on starting X.

Reply

cikasole May 29, 2011 at 3:36 am

I managed to do everything without encryption, using BT5 64bit KDE and 16GiB USB stick.

Here are the steps:

1.I followed the fdisk part (partitioning) of the tutorial. but I guess it could be skipped if we don’t want encryption — it can be done later during installation as well

2. I skipped next crypto parts and went directly to installation. Installation went as in the tutorial. Just take care to set mount point for /dev/sdb5 to “/” and format it to ext4.

3. I did the blkid part for both /dev/sdb1 and /dev/sdb5, but found later that it was not necessary., at least in my case.

4. I followed the “mkdir, mount, chroot” part, without references to crypto stuff:

mkdir /mnt/BT5
mount /dev/sdb5 /mnt/BT5
mount /dev/sdb1 /mnt/BT5/boot
chroot /mnt/BT5
mount -t proc proc /proc
mount -t sysfs sys /sys

5. I opened my /etc/fstab in editor and found that I don’t need UUIDs from the step 3. In my case, all was already there. The only thing I did here is to comment out one line that was referring to swap partition, although I am not sure whether that was necessary at all.

I also foud out that “realtime” in “/” and “/boot” lines, does not work for me, since later during boot my system complained something about unknown option. When I left it untouched it worked. That means in “/boot” line I have word “defaults” instead of “realtime” and in “/” line I have “errors=remount-ro” only. The rest is like in tutorial.

6. I skipped everything and went directly to “update-initframes -u”

Reboot.
First time, startx refuses to work, same as with DVD. To resolve this, as mentioned somewhere else, the following has to be done (only first time):

rm .kde/cache-root/*.kcache
rm .kde/cache-bt/*.kcache

That’s it.

Now there is an issue. While the USB boots and works perfectly on the same computer where it has been produced, it seems that it has problems when booted on different hardware. On my netbook for example it fails to detect wireless adapter. When I boot the same netbook from DVD, the adapter gets detected correctly.

I hope that this can be resolved. I’ll investigate further, but if anyone can help, I’d appreciate it.

HTH

Reply

cikasole May 30, 2011 at 9:12 am

Here are the news regarding the wireless detection issue mentioned in my previous post.

I was wrong. The wireless adapter *is* detected correctly and the right drivers are in place.

The problem is different — somehow during boot, my wireless card gets renamed from wlan0 to wlan1. Later, during KDE session, wicd looks for wlan0 and can not find it. When directed to wlan1, wicd scans the networks correctly and everything works fine.

Anyway. it is clear that this issue has nothing to do with the above USB installation procedure. After some testing I can confirm that my BT5 USB works fine on a number of quite different machines.

HTH

Reply

Slim June 2, 2011 at 11:30 am

not sure if its a typo but instead of “realtime” try “relatime”

Reply

cikasole June 7, 2011 at 2:51 am

You are right — it is relatime…

Reply

Rob June 5, 2011 at 8:34 am

Hi there…

On some computers when I boot from the USB, I get to the Backtrack background, press F8 to enter the password and it shows:

Begin: Loading essential drivers… …
Done.
Begin: Running /scripts/init-premount …
Done.
Begin: Mounting root file system… …
Begin: Running /scripts/local-top …
Begin: waiting for encrypted source device… …

I then wait for a few min’s and then it shows:

-r ALERT! /dev/disk/by-uuid/2875495c-f54f-4130-9ed4-be8f7192812d does not exist. Dropping to a shell!

BusyBox V1.13.3 (Ubuntu 1:1.13.3-1ubuntu11) built-in shell (ash)
Enter ‘help’ for a list of built in commands.

(initramfs)

Does anyone know how I can get this sorted to boot off any machine?

Reply

Joe June 11, 2011 at 8:20 am

Are you probably using an USB 3.0 stick on an USB 3.0 port?
This was the problem on my side…

After plugging the stick to a USB 2.0 port, it worked.
I’m still trying to figure out what went wrong.

Reply

sp June 13, 2011 at 9:40 pm

This was the issue for me. I’d really like to be able to boot a FDE’d BT5 USB 3.0 stick, but haven’t had much luck yet.

Reply

saintpatrick June 13, 2011 at 10:44 pm

I think I got this issue sorted.

Alright, so this doesn’t make it pretty (that is to say, I still receive a “Device doesn’t begin with /dev/mapper” error message), but it will allow you to boot a USB 3.0 device from a USB 3.0 port.

After you chroot to your /mnt/backtrack5 use vi /etc/initramfs-tools/modules to add the module ‘xhci-hcd’ (no quotes) and :wq

Now update your image again via update-initramfs -u and reboot. You should now get a luks passphrase prompt!

Reply

Dave June 23, 2012 at 10:09 am

I tried your solution, but it isn’t working here.

I get the password prompt, but after I enter the password I get a long series of errors, and BT refuses to boot.

Works fine in the USB 2.0 port though. Still looking for a solution to this.

Bobby June 8, 2011 at 9:26 am

Hi all,
i have some trouble, i cant create a extended partition.
i can do this : Command (m for help): d
Partition number (1-4): 1

# create the first partition

Command (m for help): n
Command action
e extended
p primary partition (1-4)
p
Partition number (1-4): 1
First cylinder (1-2022, default 1):
Using default value 1
Last cylinder, +cylinders or +size{K,M,G} (1-2022, default 2022): +500M

so the nex step is:
Command action
e extended
p primary partition (1-4)
but i have only l and p

can someone help me?

Reply

phr33k August 6, 2011 at 12:42 pm

looks like there is already a extended partition, so you can only create a logical partition,
therefore you’ll get only the l and the p in fdisk

press p in fdisk to make sure and delete existing extended partition

Reply

Craig June 8, 2011 at 8:04 pm

Above it says to add a swap for a hard dive install. I can do the how to instructions but need instructions for “hard drive install with “full” disk encryption”. Help is much appreciated! Thank you.

Reply

Newbie June 12, 2011 at 12:11 am

hey im really newbie here, trying to learn about linux , i think i broke my usb in the process lol…. i cant access it from linux neither from windows with /dev/sdb says dont exist and a 4gb usb is now a 200mb usb….. need help for fixing it …
root@root:~# fdisk /dev/sdb
bash: /dev/sdb1: No such file or directory…i cant even format it .. HELP >P

Reply

proofer June 12, 2011 at 7:54 pm

Try Easus Partition free; choose delete, Apply .
Do a basic format with FAT32.
good luck

Reply

Newbie June 12, 2011 at 12:28 am

root@root:~# dd if=/dev/urandom of=/dev/sdb5
dd: writing to `/dev/sdb5′: No space left on device
1763329+0 records in
1763328+0 records out
902823936 bytes (903 MB) copied, 183.437 s, 4.9 MB/s
root@root:~# cryptsetup -y –cipher aes-xts-plain –key-size 512 luksFormat /dev/sdb5

WARNING!
========
This will overwrite data on /dev/sdb5 irrevocably.

Are you sure? (Type uppercase yes): YES
Cannot open device /dev/sdb5 for read-only access.

THIS WAS THE LAST STEP I DID :S AND I DONT KNOW HOW TO FIX MY USB HEHE

Reply

proofer June 12, 2011 at 7:56 pm

proofer June 12, 2011 at 7:54 pm
Try Easus Partition free; choose delete, Apply .
Do a basic format with FAT32.
good luck

Reply

proofer June 12, 2011 at 8:02 pm

Hint! Do create a Primary Partition, don’t use the defaults.

good luck

Reply

Newbie June 13, 2011 at 9:58 am

thanks 4 the help . did it and all fixed 🙂 TY!

Reply

arka July 4, 2012 at 11:23 am

help me pls! i still can’t fix, how to creat a partition and then not use for default

Reply

George June 12, 2011 at 5:51 pm

Looks great! The boldface lines in your code blocks don’t show up as boldface in Google Chrome, so you might want to put a little + by the front of them or something for Chrome users. The system I didn’t see them on was running Chrome 12.0.742 on Windows XP

Reply

George June 12, 2011 at 6:02 pm

Oh right, when I do this, I don’t get a graphical prompt for my luks passphrase, I have to F2 into a console to punch that in, and if you delay too long it just drops you into a shell.

Anything I can do to fix this?

Reply

proofer June 12, 2011 at 7:59 pm

Everything works fine with a WeTab and Cruzer Micro 16G.

Deleted U3 before and did a format with Easus Part. Free!

thx for the tutorial !!!

Reply

J June 12, 2011 at 8:40 pm

Hi, great guide, was wondering about the part wheere you have to press f8 to get into the console to input the luks passphrase, is there a way to fix that so the prompt for luks passphrase pops up itself without pressing f8?

Thanks

J

Reply

sprawlxy June 12, 2011 at 8:51 pm

Gave this a shot, ran into problems with video on an Acer AO522. It boots up. I select the default mode, or text mode. I let it run through the initial setup and then it freezes with garbled graphics on the monitor. Same thing if I boot in safe mode. I’m attempting the Gnome 32-bit version. I’m going to play around a bit, try the 64-bit version, a different laptop, and a different USB stick. Will post if I can make it work with the simple stuff first.

Reply

sprawlxy June 12, 2011 at 8:53 pm

Failure on different USB stick. That’s not it.

Reply

sprawlxy June 13, 2011 at 3:43 pm

It was the Acer AO522 netbook. Seems to be working on Toshiba Tecra M5. Onward!

Don’t know what it is about that Acer, but it knows there’s a graphics problem because it asks me to choose a graphics setting when I boot up (all the graphics settings fail the same way). That option to choose a graphics setting doesn’t happen on the Tecra nor is it anywhere in the notes, so there’s something with that Acer netbook. It has an ATI 6250 GPU integrated into the CPU. Maybe it has something to do with that.

64-bit version made no difference. Same video problem.

Reply

proofer June 13, 2011 at 2:14 pm

Fixing for USB stick:
1. delete all partitions with Windows diskmanagment. Format a new partition with FAT32.
( Can perhaps be skipped )
2. use ” Hard Disk Low Level Format Tool 2.36 from http://hddguru.com

3. It is free! Works well with Windows 7 as admin

4. Do at least 2 runs, make sure that no error messages come up.

5. Now you have a real fresh one, helped me with 2 sticks.

Good luck!

Btw.: I try to have BT5 with persistent, did just a low level format! LOL

Reply

Shockrates June 16, 2011 at 9:27 am

Great work mate, once again!

I wanted to ask thought, will following this guide also make my usb persistent with changes?
I am looking forward to a complete guide that will show, how to install Backtrack5 making a persistent-usb which ALSO has “full” disk encryption.

Also, i would like to inform you that backtrack persistent-usb guide just got updated and it now works with backtrack5:
http://www.backtrack-linux.org/wiki/index.php/Persistent_USB

Keep up the good work!

Reply

Gibbon June 18, 2011 at 9:48 am

I tried adding a third partition in the fdisk phase, for FAT32 files to be run when I am on a Windows OS (PuTTY, portable Firefox, etc). Everything seemed normal until the manual partition settings in the BT5 installer. There were no /dev/mapper* partitions, just /dev/sdb* were listed. Everything from then on was weird, such as my /etc/fstab listing the /dev/sdb* instead of any UUID=’s. And then finally at the end, I rebooted, and it was not even listed as a bootable medium. Is there anything in the steps I need to change to allow access to an extra FAT32 partition?

Reply

James June 18, 2011 at 2:13 pm

Really nice guide Kevin, very easy to follow!

Got my 16 GB SanDisk Cruzer Memory Stick with BackTrack 5 installed complete with encryption! For anyone that’s wondering, following this guide will also give you a persistent install, so any changes you make stick! (See what I did there?!)

Install went without a hitch. (Though I was on the 99% screen for the best part of an hour!). One thing I failed to do in my eagerness was check my fstab file. Luckily my /dev/mapper/vg-root entry was OK however my /boot partition was listed as /dev/sdc1 which is a big no no as with removable devices the dev naming is 99.9% bound to change. Upon booting into BackTrack 5 for the first time I got errors with mounting /boot saying it could find a superblock. This was because /dev/sdc1 actually got assigned to my Windows partition on my laptop. The lesson here is make sure your boot partition is written in with it’s UUID to ensure the boot partition will always boot correctly, regardless of what it’s dev name is.

Reply

Greg M June 18, 2011 at 2:20 pm

Greetings:

A few comments and a question. Apologize for the length, but any feedback appreciated!! I have been using Kevin’s method for USB (no swap) and HDD installs (with swap) with great results, however with the release of BT5 Kevin has changed his writeup to recommend the editing of /etc/crypttab while chrooted instead of using the local-top scripts for creating the initrd he used for BT4.

I am using “pvcrypt_usb” for the PV and “vg_usb” for the VG because if I plug in the drive to a system which already has an encrypted install with “pvcrypt” and “vg” there will be problems, per the manpage for “vgrename”: “All the Volume Groups visible to a system need to have different names. Otherwise many LVM2 commands will refuse to run or give warning messages”.

Using the “new” procedure, testing with the x32 KDE and the x64 KDE produces the same “error”. I have remastered my BT 5 DVD’s to include the lvm2, hashalot, latest dmraid and other modules so I don’t have to re-install the packages after a chroot when installing my system. When booting, after pressing F8 to remove the wallpaper screen to reveal the passphrase screen, I get: (my actual luks crypt partition UUID is omitted for less clutter, the real output shows my actial ID.

Unlocking the disk /dev/by-uuid/UUID (pvcrypt_usb)
Unlocking the disk /dev/by-uuid/UUID (pvcrypt_usb)
Unlocking the disk /dev/by-uuid/UUID (pvcrypt_usb)
Unlocking the disk /dev/by-uuid/UUID (pvcrypt_usb)
Unlocking the disk /dev/by-uuid/UUID (pvcrypt_usb)
Enter passphrase: ****

Yes I get 5 lines of this and the first 4 characters of a password is “filled in”, pressing backspace four times to erase whatever password is there repeats the line “Unlocking the disk /dev/by-uuid/UUID (pvcrypt_usb)” line once for every press of the backspace key. Every press of a key to enter my password also repeats the line until I press enter. Afterwards, my luks partition is unlocked and the system does boot OK.

While my system does work, I really would like to clean up the password entry. Attempting to use the older way with the initramfs-tools scripts does not work, “initramfs-update -u” returns an error, “cannot stat (path) boottime.kmap.gz. This file is hard-coded in the script “hooks-pcvrypt” (for BT4): cp /etc/console-setup/boottime.kmap.gz ${DESTDIR}/etc/console but the file is not present in BT5, there is a bug noted here:

http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=565416

However the workaround of copying /etc/console-setup/cached.kmap.gz to /etc/console/boottime.kmap.gz and updating the initramfs still has issues. The file “cached.kmap.gz” is present in BT5. Booting (after a delay) fails to an initramfs shell, maybe I will try and mod the script itself.

The reason why I would like to use the script method for my install is that for BT4 I previously modded the /local-top/pvcrypt script to include dmraid -ay to activate my software fakeraid before decrypting the luks volume. The script method produced a cleaner password entry screen (on BT4), don’t know if this is coincidence or not.

So if you read my ramblings this far:

Has anyone else had the multiple lines described here on password entry?
Has anyone gotten the initramfs scripts method for generating a new initramfs to work on BT5?

Thanks!!!

Reply

phr33k August 7, 2011 at 8:55 am

i have the multiple lines on password entry too, but seems only to happen when switching from splash to textmode via f8, but entering the password on the splash screen works for me with no problems.

Reply

Vicky April 21, 2012 at 1:56 am

For windows this is the most easiest way to make a backtrack 5 r2 bootable usb. Follow the link http://2021hacker.blogspot.in/2012/04/make-backtrack-5-bootable-usb-using.html

Reply

James June 18, 2011 at 4:40 pm

Hi Greg M,

I also have the same problem you described. I installed BackTrack 5 KDE 32-bit. When I get to the BackTrack 5 red splashcreen pressing F8 reveals multiple entries of Unlocking the disk /dev/by-uuid/UUID (pvcrypt_usb) with the passphrase already filled in with 4 characters.

I too would like to know if there is anyway to fix it.

Reply

phr33k August 7, 2011 at 8:56 am

try entering your password on the splash screen without switching to text mode, works for me

Reply

Greg M June 18, 2011 at 11:13 pm
James June 19, 2011 at 2:57 am

Hi Glen,

I tried the patch and it works great. No more Unlocking the disk /dev/by-uuid/UUID (pvcrypt_usb) lines are generated on each key press! However the passphrase line still has four characters already in there when you come to type in the password.

But apart from that works fine.

Reply

James June 19, 2011 at 2:58 am

Apologies for calling you “Glen” Greg!

Reply

Greg M June 19, 2011 at 2:48 pm

John (;-)

James:

Yes I was going to mention that, I get the four characters pre-filled in also after applying the patch. But it is 95 % better. I am curious, if you type in an incorrect password, the script will note the failure and bring up another password prompt, this time without the four **** ‘s.

Would be nice to fix that, I am going to see if I can get someone interested in helping to mod the script, if you have any luck please post back here, OK?

Greg

Reply

James June 20, 2011 at 10:30 am

Hi Greg,

I certainly will. I haven’t had much time to actually look at the code inside the cryptroot script, but hopefully in the next few days I’ll get chance to play around with it a bit to see if we can fix the cryptroot lines once and for all.

Reply

Greg M June 20, 2011 at 12:29 pm

James, a thought. I think the script is OK. The reason for the four characters is, I am suggesting, the results of the keyboard mapping for the F8 key you have to press to reveal the password entry which is hidden by the splash. If we can disable the splash (grub kernel parameter line edit, I will try and remove any reference to “quiet” and “splash”), and see what happens.

gm

Reply

James June 20, 2011 at 3:07 pm

That is interesting as I temporarily took out the BackTrack 5 splash and made my system revert to the Plymouth boot splash (The one Ubuntu uses) in it’s very basic form and the line to enter your passphrase did not have any characters already entered. So this would indicate the BackTrack 5 splash has something to do with it.

The fact you have to press the F8 key to get to the enter passphrase line would certainly explain the rogue four characters.

Reply

pointer June 24, 2011 at 9:38 am

how were you able to change/remove the bt5 splash? I’ve tried everything and I cannot figure out how to change it.

George June 23, 2011 at 12:04 am

In my experience you can simply type your passphrase at the blank GUI screen (the red BT5 wallpaper before you press F8) and press return. You’re welcome to press F8 at some point if you think something is amiss during startup

Reply

T. June 26, 2011 at 3:02 pm

This whole pvcrypt stuff is driving me mad:

I have the volume set up. When accessing the encrypted volume manually (e.g. as in the Troubleshooting section) i can open it. However when I try unlock it at boot time pvcrypt keeps telling me that “No key available with this passphrase”

Any clues?

Reply

Demitri July 8, 2011 at 10:32 pm

Why is 16GB flash drive the minimum for this tutorial? And why is an 8GB drive not enough room. Is it because of the encryption? If so, how could i install this without encryption.

Reply

kriggins July 18, 2011 at 9:22 am

@demitri,

You can use ann 8GB drive, but you will only have a couple hunder MB of space left after the install. This install decompresses all the files on the DVD/ISO and needs more space.

Kevin

Reply

Raistlin July 10, 2011 at 7:17 pm

Thanks a lot for the tutorial !

Reply

bart July 11, 2011 at 2:33 am

Hi all,
After the commands :
root@root:~# vi /etc/crypttab
root@root:~# vi /etc/crypttab
root@root:~# vi /etc/fstab
root@root:~# update-initramfs -u

I Get the following message:
update-initramfs is disabled since running on read-only media

what now ?

regards

Reply

bart July 11, 2011 at 8:30 am

I did

as root
mv /usr/sbin/{update-initramfs.distrib,update-initramfs}

Reply

kriggins July 18, 2011 at 9:20 am

@bart,

You appear to have skipped the chroot step.

Kevin

Reply

Surfer dude July 14, 2011 at 5:35 am

so i followed the guide using BT5Gnome DVD all looks fine but when i reboot i get a GRUB error 15

The reason for grub error 15 is very simple and so is the solution. The error gives you a message “Error 15: File not found!” simply because the file grub wants is not there. why? because grub is looking into a wrong device. You need to make changes to your /boot/grub/menu.lst file to fix the problem so that grub looks into the correct device but first find out where is your root partition

however there is no menu.lst on the DVD or the USB anyone got a clue were / how i might get the needed file or what the correct setting should be if there should indeed be a menu.lst file used in this type of config.

Reply

Dan July 17, 2011 at 2:04 pm

Hi Kevin, thanks for all of the hard work you put into that howto. Everything went perfectly, except for one small thing. I’m experiencing the blank screen on startx problem (see http://www.backtrack-linux.org/forums/backtrack-5-bugs/42193-black-screen-after-startx.html for problem and usual fix). By performing the temporary fix (editing the code from the grub menu) I can get into the BT5 GUI, but I can’t perform the persistent fix because apparently grub.cfg isn’t in any of the usual spots. I think it’s on /dev/sdc or /dev/sdc1, while my Linux partition is /dev/sdc5, but I can’t figure out how to mount that partition so I can edit the real grub.cfg file. There are grub.cfg files at /boot/grub and /etc/default, but they only point to Win7, which isn’t even on my grub menu. Update-grub also only pushes the Win7 option and doesn’t mention BT5 (luckily I tested it first instead of pushing it out to /sdc). Anyway, can you help?

Reply

kriggins July 18, 2011 at 9:19 am

@dan,

I haven’t fought with this issue yet and haven’t messed around with the boot menu either. I actually experienced some of the same problems with the persistent install in getting the correct grub/syslinux configuration setup and couldn’t get it resolved.

That being said, any menu configuration files will reside on the unencrypted boot partition which is mounted under /boot once you have booted the thumbdrive. Any changes here should be reflected in the boot menu. If I have a chance to test in the near future and figure something out, I will let you know.

Kevin

Reply

Ruxpin July 19, 2011 at 4:38 am

Thanks, I used this information to install BT5 on my laptop (with the added swap drive.)

I have a similar issue with the loading of BT5 and entering the password. I need to switch screens CTRL-ALT-F1 so I can see LUKS prompting me for my password.

I have looked at the following link
http://www.backtrack-linux.org/forums/backtrack-5-bugs/40541-problem-initrds-cryptroot-when-unlocking-luks-root-during-boot.html

How do I apply this patch?

I think I seen a Gentoo setup with full disk encryption, and the spash image had a field for you to enter in your passphrase. Ill have to search to build this into my BT5 install.

Reply

Rob July 19, 2011 at 12:41 pm

This is a great howto, thanks for putting it together. I successfully installed everything and it works great, but it’s realllly slow. I’m experiencing delays of 3 seconds or so when clicking desktop icons, etc. Even command line has a noticeable delay.

Is this just do to the encryption running off a thumbdrive? I have it installed on a 16GB USB 3.0 thumbdrive. I’ve tried it on a few different machines and am getting consistently slow performance, even on new, fast machines.

Have you experienced this or do you have any tips?

Reply

Koper July 21, 2011 at 1:32 pm

Same thing here. I’ve put it on 64GB Corsair GTR. Everything seems OK except it’s REALLY slow. I’m starting to think its because of the size of the encrypted partition.

I’m gona give it a try with something like 14GB and get back with the results…

Reply

Koper July 21, 2011 at 7:10 pm

The size did not affect overall performance.

I would appreciate some info of your encrypted USB partitions.
For instance I got:

root@bt:~# dd if=/dev/zero of=/tmp/x.del bs=8k count=128k; rm /tmp/x.del
131072+0 records in
131072+0 records out
1073741824 bytes (1.1 GB) copied, 115.668 s, 9.3 MB/s

Reply

Rob July 22, 2011 at 8:03 pm

Similar results on my end. I’m averaging 10.8 MB/s…less than I had hoped.

Reply

truckers July 20, 2011 at 12:48 pm

Hi mate,

thanks for this excellent guide. Unfortunately I ran apt-get autoremove after a few days of use and now my system is unbootable in the same way as running aptitude safe-upgrade I imagine.

The error I receive is a missing “/sbin/cryptsetup/libgcrypt.so.11” and it returns “cryptsetup error: options or bad password?”

I’ve mounted and decrypted the drive in my native ubuntu and copied libgcrypt.so.11 from my native files to “/tmp/sbin, /tmp/usr, /tmp/lib, /tmp/lib/cryptsetup, /tmp/usr/lib” on the boot partition of the external hdd. Still no change.

Anyway to fix this without a clean install?

Reply

Eric July 26, 2011 at 5:55 pm

Hi, I am really enjoying this guide so far, it is really good. Thanks for making it. I have a question though.

When I get to the part of running the “apt-get install hashalot lvm2” I get a weird error, I can’t figure out what is causing it. It will start accessing the repositories for hashalot and lvm2 and whatnot, but then it says:

Selecting previously deselected package hashalot.
(Reading database … 40%E: Sub-process /usr/bin/dpkg exited unexpectedly

Because of this I can’t go on to do the
pvcreate /dev/mapper/pvcrypt
Physical “volume /dev/mapper/pvcrypt” successfully created
vgcreate vg /dev/mapper/pvcrypt
Volume group “vg” successfully created
lvcreate -n root -l 100%FREE vg
Logical volume “root” created.
Set of commands.

Any help as to what might be going wrong here would be great. Thanks!

Reply

Eric July 26, 2011 at 6:39 pm

Got it. I just created a new VM instance of backtrack and was able to install everything fine. Wish I would have held off on posting that long thing until I had tried a little harder. Oh well, maybe it will help someone else with the same problem.

Reply

Dan July 30, 2011 at 12:40 am

@kriggins,

actually you helped a lot. I just created a temp directory in /mnt, then mounted /dev/sdc1 (boot) there. Once I did that I was able to edit the real grub.cfg file directly. Haven’t tested yet because I’m running a script right now that I’m already committed to finishing. Once it’s done I’ll reboot and let you know whether the changes took, but this is the only grub.cfg that I’ve had to override read-only permissions on so I think its the right one.

Thanks!
Dan

Reply

christian July 31, 2011 at 12:57 pm

would you be making a how-to video of this tutorial(step-by-step) any time soon?

Reply

Sid August 5, 2011 at 4:29 pm

i made a backtrack 5 bootable flashdrive when i use with my laptop with window vista it works fine when i use on ibm desktop with xp on it it dont i also check my bios setting
i dont know wht i am doing worng and idea
using backtrck5 32 bit iso

Reply

PatrickHimebaugh May 9, 2012 at 10:15 pm

@ sid almost been a year since this post..

Did you find a solution to this issue…

Samsung np-rv711 i3 4gb ram
Asus eepc Intel Atom
PNY 16g M1 Attache
Backtrack 5r2 94bit Gnome

I am experiencing this problem too when moving from computer to computer(Laptop to Netbook. My Aim and Goal is to have a “backtrack to go”/mobile where I am on the move and need to access a computer i can boot into my Flash drive and do what I do best.

I have also stripped this down to just install on the flash drive with no encryption because its a little to time consuming. Ill do the encryption later once i figure this part out. I follow the steps to create 2 partitions and set them up during install with /boot and /…. and I am operational with my samsung laptop

Here is what I noticed. when I plugged in the drive to the Asus netbook.. the grub boot loader comes up like it should in the boot partition(104mb) However it lists my tailored Samsung bootloaders.

ubuntu x.x.x
ubuntu x.x.x (recovery)
memory diog.
Win 7
OSX

when choosing the first one Ubuntu the netbook attempts to load but just sits on a black screen no errors. just blank.

So I don’t have a solution yet. however I am thinking and looking around for help and an answer

it could be something with the following:
The grub has to be modified for
uuid’s
Missing loaded hardware like the Live Cd does before going live e.g Graphics card.

So a question… when we are installing backtrack ubuntu is it only installing just the necessary hardware that was loaded during the Live CD/USB to the USB drive?

There is another install method I am looking into called usb persistent taking the Live Iso files and copying them over.. this will look for and install the necessary hardware for that computer like in a live cd version but will allow you to save and I hope Modify files and not give problems being read-only.

im too new to linux, but finding this a fun learning experience. I just want it to load to the USBgrub and load.

Reply

PatrickHimebaugh May 10, 2012 at 2:14 am

Ok well I was Mislead and my issue looks like the 64bit gnome OS is not compatible with the 64bit i686 Atom cpu.. so I am attempting to use 32bit Gnome LiveUSB to test…

Reply

hector August 5, 2011 at 5:29 pm

thank u for ur version of this download

Reply

hector August 5, 2011 at 5:31 pm

i dont know what else u want me to say

Reply

hector August 5, 2011 at 5:32 pm

what am i doing wrong

Reply

hector August 5, 2011 at 5:33 pm

Error: please type

Reply

Kromag August 9, 2011 at 10:41 am

I am having trouble with this instruction set. I will admit I am new to BT and only slightly familiar with Linux.

When I go through the steps I get all the way to:

“mount /dev/mapper/vg-root/mnt/backtrack5”

I then get the following output error:

“mount: can’t find /dev/mapper/vg-root/mnt/backtrack5 in /etc/fstab or /etc/mtab”

I even get this when I reboot and go through the troubleshooting steps. Did I miss something or is there a step missing?

Reply

phr33k August 9, 2011 at 12:48 pm

you simply missed a space

try mount /dev/mapper/vg-root /mnt/backtrack5

and make sure /mnt/backtrack5 exists

Reply

Kromag August 10, 2011 at 7:22 am

phr33k,

Thanks for that. I was missing the space.

Now I get the following error:
“mount: special device /dev/mapper/vg-root does not exist”

This is the second time I have gone through the guide and keep getting caught in the same spot. I have got to be missing something else somewhere but I did not get any other errors along the way other than the ‘…the partition table failed with error 16…” but the guide addressed that error and I was able to move past that.

Sorry for being such a noob but I am trying to correct that by gong through all of this.

Reply

phr33k August 10, 2011 at 11:54 am

no need for excuse, it’s all a learning process 😉

in which part exactly you have this prob? i think u’re trying to mount & chrooting to your fresh install? if so then first make sure if /dev/mapper/vg-root exists
using “ls /dev/mapper” command. if there is no volumegroup then you probably missed some steps before. regarding to this howto you should found /dev/mapper/pvcrypt which is the physical encrypted volume on your chosen partition, also you should have your logical volume /dev/mapper/vg-root on your volumegroup

let me know if everything is in place

Reply

Kromag August 10, 2011 at 12:50 pm

When I typed in the “ls /dev/mapper” I got the below output:
“control udisks-luks-uuid……..-uid0”

I keep feeling like maybe I was supposed to cd somewhere and missed it?

Reply

phr33k August 11, 2011 at 12:15 pm

weird..
the output should look something like this

root@bt:~# ls /dev/mapper/
total 0
drwxr-xr-x 2 root root 100 2011-08-11 20:58 .
drwxr-xr-x 19 root root 4.0K 2011-08-11 18:59 ..
crw-rw—- 1 root root 10, 236 2011-08-11 18:58 control
brw-rw—- 1 root disk 252, 0 2011-08-11 18:59 pvcrypt
brw-rw—- 1 root disk 252, 1 2011-08-11 18:59 vg-root

what’s the output of lvscan and pvscan?
the partition was encrypted and you opened it with luksOpen?
the physical volume was created with no errors?
the volumegroup and the locical volume were created as well?
did you reboot the system directly after install?

a lot of questions but i’m not sure where it hangs

Reply

Necrologist August 11, 2011 at 2:09 pm

Hello,

For all those who get
“/dev/mapper/vg-root does not exist. Dropping to shell!”
try typing your password with different keymaps,
NO don’t try to change it in boottime,
just try to type it like you would have a different keyboard before you,

BT set the default for me for a completely different one that I expected (not US and not the one I choose in the installer but a subtype of it…)

Hope it helps some of you too, it helped me at least

Reply

Abhisek August 12, 2011 at 1:58 pm

You’re a perfectionist!!! This tutorial on Partial disk encryption of BT5 is a real help for h4x0rs!!!

Reply

Julian August 17, 2011 at 10:24 am

Hi!

Many thanks for your how-to.

I created two primary partitions (sdb1 for /boot and sdb2 for NTFS to use with windows). I also created the extended and the Luks partition.

System starts perfectly, but when I tried to use the sdb2 partition in windows, it didn’t works, it only detects sdb1 (/Boot) and it asked to format it…

Is anyway to use my sdb2 NTFS partition into windows? (Is a 30Gb partition, alf of my USB Stick)

Thanks!

Reply

phr33k August 17, 2011 at 12:55 pm

@kevin: in the troubleshooting part, did you missed the activation of the volumegroup?

i tried to mount the crypted partition on another machine, but after opening the partition
there is no /dev/mapper/vg-root available

after issuing a “vgchange -ay vg” command, the volumegroup was activated and avail. as mapper device /dev/mapper/vg-root

@Kromag: this could have been your issue to. try to activate the volume group before mounting it

Reply

Francisco August 18, 2011 at 10:32 pm

ok i get very confused with anything sorry.
let me get this straight do we need a 2nd usb drive apart from the 16g??
if we use UNetbootin do i write the .iso to the 16g or the aditional?
im really sorry i easily get confused.

Reply

Francisco August 18, 2011 at 11:20 pm

nvm i understand now after a few hours of researching (my head hurts)

Reply

aron July 15, 2012 at 8:25 pm

want to explain it to me? I am really confused on that matter!

Reply

noName August 21, 2011 at 11:48 am

Regarding BT5R1 – you have to run “apt-get install cryptsetup ecryptfs-utils keyutils” before first restart. Otherwise you will be stuck with a shiny ALERT!

Reply

kriggins August 21, 2011 at 1:19 pm

Thanks for the info! Put an update at the top of the how-to and am adding that step right now. Will also test the rest as soon as my download finishes.

Kevin

Reply

kriggins August 21, 2011 at 8:50 pm

@noName

Not sure what you did, but it is unnecessary to reinstall those packages in my testing. If you did any sort of apt-get activity with autoremove, that might explain what happened.

Kevin

Reply

Jay February 1, 2012 at 12:48 pm

THANK YOU!!! after my installation, booting worked just fine. Did apt-get update, apt-get upgrade and it didn’t boot afterwards. THIS post saved me 😉

Reply

negativezerosquared August 22, 2011 at 2:07 pm

hello all,

how long does the line
dd if=/dev/urandom of=/dev/sdb5
normally take?

i’m doing it to a 8gb sandisk u3 cruzer micro through VirtalBox, and it’s almost been a day and it’s not done…

Reply

phr33k August 23, 2011 at 12:17 pm

don’t know what’s going wrong, although the cruzer is extremely slow at write speed, a day+ is definitely too long for writing random data to your stick. if youre using windows somewhere try to check it with chkflsh from http://mikelab.kiev.ua/index_en.php?page=PROGRAMS/chkflsh_en

Reply

phr33k August 23, 2011 at 12:19 pm

or you are maybe using the usb1.1 driver in virtualbox. make sure to check ehci inside vbox

Reply

Mike August 23, 2011 at 5:15 pm

After following the guide and rebooting and selecting my sd card, I get:
error: cannot read the Linux header
error: you need to load the kernel first

Any ideas? Tried it twice and got this error both times.

Reply

iarathron August 25, 2011 at 6:09 am

Hello guys,

I have used the guide and everything works perfectly, thanks!

Just one question: I have installed and regularly use truecrypt on my backtrack 5 usb. The problem is that everytime i shutdown, when i reboot into backtrack, truecrypt seems to be uninstalled and i need to install it again every time. Am i doing something wrong?

Thanks very much

Iam

Reply

Gen August 25, 2011 at 8:42 pm

Kevin,

thanks a lot for your tutorial. Everyone, thanks for sharing your experiences.

I got a laptop to play with and my aim is to have a Windows 7/Backtrack 5r1 dualboot where both systems are encrypted (with Truecrypt and luks respectively) – not a USB stick. In combination with other tutorials I used this one as a guidance in order to install BT 5r1 to an already existing Windows 7 – I had to exchange GRUB2 for GRUB and to manually add the Windows 7 entry in the menu.lst but so far it worked (Truecrypt encryption still pending, fingers crossed).

I of course added a Linux swap partition on my harddisk. Question is: is the swap partition now encrypted as well?

My guess is not. How would I go about encrypting it as well? Where in the tutorial’s process would I incorporate this step, and with which commands? I’m a Windows person (used to command line from the DOS days though) and I feel like things are bit over my head at the moment.

Thanks in advance,
Gen

Reply

kris weston August 29, 2011 at 3:54 am

hey there, ==i /bin hacking a script that does this and a few other things, its designed to customise linux, think it only works on debian based distros at the moment though, the reader is welcome to edit it to work on other distros and mail it back meh tho 😉

http://www.krisweston.com/2011/ubuntu-remaster-script/

will do this page for you with a few key presses

Reply

Jonathan August 29, 2011 at 5:31 pm

Almost finished copying files…
Strange concept of “almost”… 🙂
It’ s been “almost” 2.30 hours I’m waiting “almost” 🙂

BTW Excellent work, thank you for this great tutorial,

Jonathan.

Reply

Martin September 3, 2011 at 9:39 am

I installed BT5 R1 with your very nice tutorial on my USB drive but its sooooo slow.. i often notice some “lags” and they are about 2 sec … 🙁

(usb drive 30mbs read/14mbs write)

My question: Is it because of the encryption ?

Reply

Darren September 5, 2011 at 8:41 pm

I had the same issue with a Sandisk Cruiser Contour Extreme 16GB drive. I thought there was something wrong with the drive, but formatting it back to fat32 and copying files under windows was fine and at the rated speed. Which is a shame because I bought the drive specifically for BT and I expected instant response – since running it on an 8GB Maxell previously was blisteringly fast!

It also looked ok (avg 22mb/s) when testing with “hdparm /tT /dev/sdb”

I am not sure if it was related to encryption but every time there was an attempt to access the drive it would “lag” then be ok. For me, it was more like the initialisation of the drive that caused it, like it kept going to “sleep”.

Reply

abbie September 8, 2011 at 9:49 am

when I type in this command “cryptsetup -y –cipher aes-xts-plain –key-size 512 luksFormat /dev/sdb5” I get the message “Cannot open device /dev/sdb5 for read-only access”. I have tried the chmod command but does not seem to work. Please help.
Thank you very much.

Reply

Bartosz September 21, 2011 at 9:07 am
GdubG September 28, 2011 at 6:16 pm

I too had the ‘ALERT! /dev/mapper/vg-root does not exist. Dropping to shell!’ problem. After multiple repair attempts to fstab and checking most everything else for mistakes, I reverted to my original fstab and had to very carefully remove ONLY “errors=remount-ro” and change to “defaults” for the “/dev/mapper/vg-root /” line while using vi. Only then would the text remain green and acceptable resulting in a booting system. You cannot alter the spaces in between or anything and vi is very good at letting you know correct configuration with displayed text colors. On my system in vi, “/dev/mapper/vg-root /” remained white, “ext4” and “defaults” were green, and “0 1” were red. If any mount options turned white it indicated problem.

Good thing I made a backup of fstab before editing, eh? Might want to add ‘cp /etc/fstab /etc/fstab.bak to your excellent instructions prior to editing that file. Then add cp /etc/fstab.bak /etc/fstab in your troubleshooting section, or something like that.

Thanks for the write up…. I love this setup. I’m using Plop Boot Manager ISO to boot USB from a virtual machine, but can also boot direct to USB from my laptop. To set it up like I did in a VM, download the latest Plop zip file and extract the ISO from it, then set up a VM to boot to the ISO file while your BT5 USB drive is connected to the virtual machine. A menu will come up where you can select USB as a boot option and WHALAA… BT5 in a VM from an external USB drive. Shwiiiing!

http://www.plop.at/en/bootmanager.html

Reply

Phil-the-Frog September 30, 2011 at 10:16 am

Hello !

Thanks Kevin, for the good work !

I just want to give my feedback :

I’ve installed BT5 without problem on USB key with encryption.
First time, I thought that install had failed, because the screen remained black, so I re-install all the stuff.
Bu it seems that the first install was good, and when I decided to wait and see, during the black screen after second install, It finally boot after 2 or 3 minutes…
That’s why it’s important to choose carefuly the USB key, specially for the amount of time needed to access to it.
And It’s better to choose a USB key with a LED showing the activity. Mine have no LED…

But it worked just fine.

My USB key is 32 G, and it takes about 8 hours to feed it with random data.

At splash screen, I hit instead of in order to get to first screen. When I type my password, it gives a newline at each character (??), so when I hit at splash screen, it consider this is the firs character of the password, and the first attempt to identify myself fails.
This behaviour doesn’t occurs if I hit .
Hope this helps.

I’ve made a PDF file from the html page found on the site, because I saw that no PDF was available, interested ? Have a look here :

http://www.megaupload.com/?d=TLBQQDS7

Would you like to have the “.odt” file (Open Office) in order to modify it ? It’s here :

http://www.megaupload.com/?d=ZHIGQILJ

Hope this helps too.

Regards,

Phil

Reply

Phil-the-Frog September 30, 2011 at 10:19 am

Message re-send because some character dissapeared… ESC and F8 were written between brackets… Sorry… Erase the sentences before Hello, please.

Hello !

Thanks Kevin, for the good work !

I just want to give my feedback :

I’ve installed BT5 without problem on USB key with encryption.
First time, I thought that install had failed, because the screen remained black, so I re-install all the stuff.
Bu it seems that the first install was good, and when I decided to wait and see, during the black screen after second install, It finally boot after 2 or 3 minutes…
That’s why it’s important to choose carefuly the USB key, specially for the amount of time needed to access to it.
And It’s better to choose a USB key with a LED showing the activity. Mine have no LED…

But it worked just fine.

My USB key is 32 G, and it takes about 8 hours to feed it with random data.

At splash screen, I hit ESC instead of F8 in order to get to first screen. When I type my password, it gives a newline at each character (??), so when I hit F8 at splash screen, it consider this is the firs character of the password, and the first attempt to identify myself fails.
This behaviour doesn’t occurs if I hit ESC.
Hope this helps.

I’ve made a PDF file from the html page found on the site, because I saw that no PDF was available, interested ? Have a look here :

http://www.megaupload.com/?d=TLBQQDS7

Would you like to have the “.odt” file (Open Office) in order to modify it ? It’s here :

http://www.megaupload.com/?d=ZHIGQILJ

Hope this helps too.

Regards,

Phil

Reply

rtype October 6, 2011 at 1:22 am

Hi everyone. I need your help. I’ve successfully followed this guide for a regular disk installation. I’ve customized the OS to my liking and have used remastersys to create an iso which I’ve loaded onto my USB drive with UNetBootIN. The USB boots to the UNetBootIN/GRUB screen, however I’m unable to go any further.

I imagine that the beginning of this problem has to do with the fact that the UUID referenced is my laptop’s hard drive and not my USB drive’s UUID.

I’m creating a number of customized live USB drives… Would someone be incredibly kind and guide me through the remaining steps necessary to remaster the customized system I created using this guide, and bouncing it to an iso which will also work on my various USB drives?

I can’t thank you enough. 🙂

rtype

Reply

rtype October 6, 2011 at 1:25 am

By the way Kevin, you’ve created such a flawless guide! Thank you so much for your help.

Reply

rtype October 6, 2011 at 2:56 am

I’m unable to get the ID_FS_UUID of the USB drive when running the blkid command on /dev/sdb or /deb/sdb1…

Any thoughts?

Reply

Dan October 7, 2011 at 4:16 pm

Check (with fdisk) to make sure that /dev/sdb1 is the partition you want to run the blkid command on to find the UUID. In my case, when I try to run blkid of the actual USB drive I’m booted off of it doesn’t give me any information back. You have to run blkid against the drive that you’re installing to and then it should give you the UUID.

Reply

Dan October 7, 2011 at 4:23 pm

Errr. I’m super confused now. You’d probably do better to ignore my comment. 🙂

Reply

Traheaerne October 7, 2011 at 1:16 pm

Just wanted to drop a line or two to say thank you! I got it to work first time through on a 16GB Super Talent drive. I am not experiencing the lag times that others have mentioned; quick access times all around. Thanks again!

Reply

Dan October 7, 2011 at 4:07 pm

To, those of you that were able to perform this process to install on a computers HDD… how did you successfully mount the /dev/sdb1 partition to the /mnt/backtrack5/boot directory? Every attempt says that the device is busy or already mounted (to cdrom). Thoughts?! Thanks!

Reply

Dan October 7, 2011 at 4:23 pm

I’m not very smart. Please disregard.

Reply

Dustom October 9, 2012 at 9:26 am

I am new to linux, and I got that same error last night. I have searched all over the web trying to resolve it with no luck. When I tried to unmount the cdrom it wouldn’t work. It sounds like you figured it out. Can you help me shed some light on the problem?

Reply

ttof October 25, 2011 at 2:04 am

I’m feeling better by learning this. But i still get confused about that “How to install Backtrack with Xp on same PC without hampering other partation and data. Plz. Suggest me as soon as possible .

Reply

kriggins October 25, 2011 at 6:33 am

What you want to do is called dual booting. Search for “backtrac 5 dual boot windows” and you will find a number of resources including videos.

Here is one resource:

http://www.backtrack-linux.org/wiki/index.php/Dual_Boot_BackTrack_And_Windows7

Kevin

Reply

Aija October 25, 2011 at 5:16 am

Hello,
I have a little problem. I im stuck at “partitioning” section of your “Backtrack 5 – Bootable USB Thumb Drive with “Full” Disk Encryption”.

I cant get partprobe working. Is there any other way to do this?

Reply

kriggins October 25, 2011 at 6:35 am

@Aiija,

Can you be more specific with the problem you are experiencing?

Kevin

Reply

Andrew November 2, 2011 at 12:16 am

Everything worked like a charm for me until right after I entered the password for luks. It gave me an error saying /dev/mapper/vg-root does not exist, dropping to a built in shell, then it gives me a busybox shell prompt. Any ideas?

Reply

kriggins November 6, 2011 at 6:07 am

@Andrew,

Have you tried the troubleshooting steps to make sure everything works manually? This is usually an indication that some modules didn’t get installed correctly. It happens some times.

Kevin

Reply

Alberto Vassena November 5, 2011 at 11:56 am

This tute is exactly what I have been looking for for a few days.
I have followed it step by step and everything went as expected: I have successfully installed BT5R1 as my 3rd OS on my netbook (with /dev/mapper/vg-swap too).
Thanks a lot, Kevin! Great work!

Reply

kriggins November 6, 2011 at 6:06 am

Thanks Alberto! Glad it worked for you.

Reply

Ignacio Agulló Sousa November 6, 2011 at 11:12 pm

Well, I must say the procedure is exquisitely detailed, with images of every step.
Out of curiosity, I tried to install BackTrack 5 with “full” disk encryption (more like full partition encryption, I’m afraid) on a 4 GB pendrive. This is what happened:
a) I tried to do it on a computer that already had Ubuntu on its hard drive. Running the installer, at “Ready to install”, I made the proper choices to mount / and /boot, then clicked on “Forward”. Guess what? The installer told me it was going to format /dev/mapper/vg-root, /dev/sdb1 AND the swap partition from my hard drive, even tough I had not selected it! It wants a swap partition and is not taking a no for an answer! There was no way at all to make the installer refrain from formatting the swap, and I definitely didn’t want the installer to touch my hard drive at all, so I aborted installation.
b) I tried again on a desktop computer which offered easy access to the hard drive so I could disconnect it during the installation. I got as far as installing system and copying the files. It got to the 99%, got stuck a lot of time there, and then it told me there wasn’t enough disk space. Seems that a 4 GB pendrive was almost enough, so I expect 8 GB would be more than enough.

Reply

Mary December 7, 2012 at 10:08 am

Having exactly the same problem:
when getting to “Ready to Install” the summary states that it will change the partition table on the usb key, and format the swap partition of an existing linux system on the PC’s own hard drive, and the partition #1 of sdc

A part from the swap problem (indeed is not nice that goes messing up on the PC’s hard driver), shouldn’t it list 2 partitions to format on the usb key (/boot and /) ?
/ is actually on the encrypted volume, but it is not listed at all in the summary

Reply

Joffy November 9, 2011 at 3:47 pm

when i do:
lvcreate -n root -l 100%FREE vg
it comes back with :
Volume group “vg” not found

this is the second time iv been through it and i dont think i had the problem the first time… any ideas?

Reply

kriggins November 9, 2011 at 8:45 pm

@joffy

Have you verified that your volume group was created? This really seems like either the volume group didn’t get created, didn’t get activated or there is a typo in the name.

Kevin

Reply

Joffy November 10, 2011 at 7:31 am

Yeah maybe.. went through it again and worked fine 🙂 only thing i did find is that in the installer i had to double click which partition it was, clicking forward only brought up an error message (confused a noob like me :p)

Reply

crr November 11, 2011 at 3:14 am

I have 8gb, can i make drive on usb?

Reply

Duke November 12, 2011 at 8:56 pm

So i Finished everything and it all works well! ty for all the info!

now the only thing i noticed that i would like to do is the usb keyboard doesnt seem to work before you enter the key…. my guess is usb keyboard driver is on partition 5 and the driver cant be accessed without the key what would be a work around for this? any ideas? i want to b able to use usb keyboard for login =[

Reply

A November 19, 2011 at 12:54 pm

Hi all,

I encountered an minor error which I solved but which I found no help with on the internet, so thought I’d post about it.

During the prepare partitions step, this tutorial has us select the appropriate partitions and click “Forward.” I received an error when this occured, along the lines of, “No root partition exists. Please specify” (not exact quote, cannot recall exact terminology).

I solved this by right-clicking on the two paritions we are intereste in and selecting “change,” this brings us to the screen that the tutorial says occurs when you would press forward. I set the options as directed and it works great. One thing to note is that you don’t want to continue forward until you change the options for both/all of the partitions that you need to change the settings for.

Thanks, and great tutorial!

Reply

niswarth November 21, 2011 at 12:33 pm

i think i made some mistake. now one of my partitions has been completely removed and my windows gui is not starting. it automatically starts drmk kernel. plz help. plz

Reply

mike November 23, 2011 at 7:00 pm

I have run through the tutorial to the point of cryptsetup the following is what is happening
cryptsetup -y –cipher aes-xts-plain –key-size 512 luksFormat /dev/sdd1
Warning!
======
This will overwrite data on /dev/sdd1 irrevocably.
Are you sure? (Type uppercase yes) : YES
Enter LUKS passphrase:xxxxxxxx
Verify passphrase:xxxxxxxx
device-mapper: reload ioctl failed: Invalid argument
Failed to setup dm-crypt key mapping for device /dev/sdd1.
Check that kernel supports aes-xts-plain cipher (check syslog for more info)
root@root~#

I am a newbie and could use some help to get beyond this error. What do I need to do?

Reply

kriggins November 29, 2011 at 6:30 am

@mike,

First I have to ask if /dev/sdd1 is correct. ioctl errors usually mean there is a problem getting to the device.

Kevin

Reply

Dave November 26, 2011 at 3:12 pm

I have struggled with this all day. I have managed to get to the part….

“The magic to making all this work is to rebuild the initrd image that is used to boot our system. We need to include some things, load some modules, and tell it to open the encrypted volume, but first we have to go through the whole process of installing software again. We have to do this because we are essentially right back where we started when we booted the live cd. Do the following again.

apt-get update
apt-get install hashalot lvm2”

My problem is that this computer has no internet connection and I am trying to install these 2 programs from a USB drive. After CHROOT I can no longer install these as it says “no such file or directory ! ” I assume it is something to do with chroot not seeing the temporary DVD run desktop but I cannot understand why I can’t load them from UBB drive ?

If I “open terminal here” it works but I won’t be installing into the real newly created encrypted drive.

Please help it is driving me crazy !

Reply

kriggins November 29, 2011 at 6:27 am

@Dave,

I think @Rob’s question was for me and not in response to your problem. If you have the packages downloaded to a USB drive all you need to do is copy them to the newly installed USB drive before you chroot. After theses steps:

mkdir /mnt/backtrack5
mount /dev/mapper/vg-root /mnt/backtrack5
mount /dev/sdb1 /mnt/backtrack5/boot

copy the files to /mnt/backtrack5/tmp or /mnt/backtrack5/root then do the chroot. They should be available to you from within the chrooted environment then.

Hope this helps.

Kevin

Reply

rob November 28, 2011 at 3:20 pm

why didnt you setup a swap space

Reply

Dave November 28, 2011 at 5:33 pm

“why didnt you setup a swap space”

Hi and thanks for your help :o)

I am not sure how that would help. I think the problem is that I cannot copy from a separate attached USB flash drive to the inside of the newly encrypted install. Is there really no way to copy or install those files without having to connect to the internet and download them ?

I am sure this is a simple thing to do but searching Google relating to a question like this is very difficult, I get a lot of unrelated answers.

I just need to do this bit after getting to the stage I mentioned above. Everything else seems to work.

apt-get update
apt-get install hashalot lvm2″

But from a file stored on a flash drive and not connecting to the internet. I am sorry but this is proving very difficult for me. It probably isn’t for anyone else !

Reply

kriggins November 29, 2011 at 6:28 am

@Rob,

We don’t use a swap space on the USB install in order to save on writes. It helps us prolong the life of our device.

Kevin

Reply

Dave November 29, 2011 at 8:57 am

Thanks for the tutorial!!

It worked great except BT5R1 seems very buggy (install disk only booting 1/3 times). Obviously not your fault. I have gotten on the stick twice on my home machine, but most of my machines I’m getting a black screen after selecting the boot OS in GRUB loader. Any hints or suggestions?

Also do you have any experience using this guide with the Ubuntu install disk? If this continues to be an issue I’m thinking I may try backing up & doing a straight Ubuntu install. Was their a reason you picked the BT flavor?
Thanks!!!!

Reply

kriggins November 29, 2011 at 9:05 am

@dave,

This was all about having a Backtrack install on a USB drive for penetration testing, not about having an encrypted Linux distro for general use. It started way back with version 3, when this process was significantly more complex 🙂

As far as working with a regular ubuntu install, that is where some of the original steps came from. If you look at the beginning of the tutorial, there are a couple of references that you can potentially draw on.

On the blank screen thing, I have had that happen when it is waiting for me to type my Luks phrase, but that is the only time. Have you tried pressing the F8 key to get to the console screen to see what errors might be displayed?

Kevin

Reply

Dave November 29, 2011 at 10:44 am

Thanks, yes there are two Davids on here.

I have tried pressing f8 but this lockup is prior to the splash screen and pressing it doesn’t do anything. In the few instances that I have booted to the disk it’s gone through the text boot at the splash I have hit f8 and logged in.
Seems like there is some issue with the boot loader starting the process.

I’ll think about if I want to to a re-install and see if that solves the problem, or giveup & just do a crypt container.

Reply

Dave November 29, 2011 at 10:31 am

Err…

there seems to be 2 of us on here called “Dave”.

My last message seems to have gone missing. I hope this doesn’t confuse you Kevin !

Reply

Dave November 29, 2011 at 10:33 am

Hi Kevin ! Just re-posting this in case it went missing.

Thank you so much, I was working into the night with this and it is starting to get me down. I am going to try your suggestion now !! Thanks very much.

Is there any way I can start from the position I mentioned above without having to re-do everything ? When I re-boot and I get the error “dropping to a built in shell” ? Can I boot back to my live DVD and start from where I left off if I mount the Luks ?

A small suggestion for your tutorial, can you mention at the start that some users need to change which keyboard layout they use as this will affect their password later.

Can I ask a general question ? I use truecrypt in windows and I understand it very well. What I don’t understand with this new (to me) Luks is that when mounted I don’t see a new drive letter in root and I can’t seem to see within the container.

Thanks again and I will report back with either good or bad news !!

Reply

kriggins November 29, 2011 at 10:40 am

@dave,

Heh. Didn’t catch that there were two of you commenting at the samish time 🙂

You should be able to boot the DVD, install hashalot and lvm, and then open the encrypted volume and go from there. This would be very similar to the troubleshooting guidance at the end of the how-to. Just remember to copy your hashalot and lvm packages in before chrooting 🙂

Thanks for the tip on the keyboard language.

Kevin

Reply

Dave November 29, 2011 at 12:08 pm

Thanks again for your help Kevin, I’m sorry it must be a bit annoying for you.
I am trying to use my USB install from where I left off. I am getting to this bit.

cryptsetup luksOpen /dev/[your logical partition] pvcrypt
mkdir /mnt/backtrack5

Which is working fine. Then I do this…
mount /dev/mapper/vg-root /mnt/backtrack5

I get the error “mount /dev/mapper/vg-root /mnt/backtrack5 does not exist.”

I can see “pvcrypt” in my mapper folder.

I am starting to think I will have to redo this whole process again 🙁

Reply

kriggins November 29, 2011 at 12:14 pm

First the obvious question, did you install the lvm package before doing the cryptsetup command? If so, it is likely that the volume group did not get activated. I think there is a comment above that this happens sometimes and directions on how to activate it. If you can’t find it, let me know and I’ll try and find the command to activate the volume group.

Reply

Test November 29, 2011 at 12:44 pm

Hi

This is Dave again, my posts are not getting though and I am just testing with this.

Reply

Test November 29, 2011 at 12:48 pm

I’m not sure what is happening with the posts here ,I made a test post above and it got through, but previous attempts as “Dave” didn’t.

Here is a copy of what I sent before.

Not sure if you are getting my replies

“did you install the lvm package before doing the cryptsetup command?”

Yes.

I think I found it above…

vgchange -ay vg

Thanks to someone called “phr33k” I think.

Thanks Kevin

I’ll report back ! 🙂

(A later post)

It worked !!!

I have got one line further on !! I get to this..
mount /dev/sdb1 /mnt/backtrack5/boot

I get this error message.. unknown file system type “crypto_LUKS”.

I have LVM and Hashalot installed.

Thanks for your patience.

Reply

kriggins November 29, 2011 at 2:13 pm

I’m not familiar with that error. You may be best served at this point to start over.

Reply

Test November 29, 2011 at 4:32 pm

Hi this is Dave again !!

I have no idea what is wrong. I have followed this tutorial many, many times and been exceptionally careful at all stages. Everything seems to go well and I don’t get any error messages when going through the entire procedure. I always remember to use my actual path sda and not the one in the tutorial.

I have started a fresh since my last post, again…totally wiped my USB drive and still it does not work for me. I am getting quite frustrated with it. I have managed to copy my hashalot and lvm folders to a temp directory in my mounted container. I have even (so I thought) managed to install them there by chroot.

I tried to boot the USB drive and I get the following…

Freezes on boot screen. So I press F8 and input my correct password.

cryptsetup lvm is not available

waits 15 seconds then

Alert! /dev/mapper/vg-root does not exsist. Dropping to a shell.

(initramfs)

Questions.

How can I triple check that lvm is installed in my USB version of Backtrack5 before I dismount it and close the live DVD ? I need to see that it is there and installed correctly as booting back up, installing hashalot, lvm, changing keyboard region, mounting the volume etc, etc just to start again takes so long.

I should perhaps point out that I need to use this…vgchange -ay vg….Every time I need to get back in to fix it. Could this be an indication of another problem and should this be run when booting in my install ?

I desperately would like this to work and I will stick with it but I must admit it is starting to get to me. Any help would be very much appreciated.

Thank you.

Reply

Test November 30, 2011 at 8:09 am

The “Fixing the /etc/fstab file if necessary” is not very clear to me.

“The only line we need to change is the line for vg-root which is bolded above.”

This doesn’t show up on the HTML page. However I was able to see it bolded in word. It turns out you mean this line.

UUID=c8d9b9a0-2198-4966-bc3a-39259df6a2c2 / ext4 relatime,errors=remount-ro 0 1

You say the finished line needs to look like this.

“/dev/mapper/vg-root / ext4 defaults 0 1”

There is no example shown of the full page when finished. I presume it should look exactly like…

# /etc/fstab: static file system information.
#
#
proc /proc proc defaults 0 0
# /dev/mapper/vg-root
/dev/mapper/vg-root / ext4 defaults 0 1”# /dev/sdb1
UUID=6af425ad-99b8-44a5-9ee1-0349141f9b1f /boot ext4 relatime 0 2

This whole thing is still not working for me and I have tried a few more times since I last posted. I have never failed at something like this before and I cannot understand what is going wrong for me.

I have even tried different flash drives and even a hard drive to try to get it going.

I can follow your logic and everything seems to go ok its just when I reboot it always fails. My last error message when trying to boot was …

“waiting for encrypted source device”

The only thing I am considering is that I am using Backtrack 5R1, were you using 5 ?

Are there any tests I can do to check things are ok as I move along the procedure ?

When I have copied the hashalot folder and lvm folder to my newly installed backtrack do I install the hashalot and lvm whilst in the temp folder of my encrypted install using “tools/open terminal” or do I chroot and remove everything before the /temp ?

Thank you.

Reply

kriggins November 30, 2011 at 8:25 am

I honestly don’t know why you are having the difficulties you are having. Per the first line of the how-to, this method has been verified with R1. I will offer that I have never tried to do it without an Internet connection to the box I was working on.

The only other thought I had was that there may be some other packages that get updated when the ‘apt-get install hashalot lvm’ command is executed with a live Internet connection. I honestly don’t remember if any are.

I also don’t have any other tips for checking progress. Generally, if the command execute successfully, then everything is going well.

Kevin

Reply

Test November 30, 2011 at 8:37 am

Hi thanks for your reply.
can I please check that the following should be what I am left with ? Obviously UUID numbers will be different.

# /etc/fstab: static file system information.
#
#
proc /proc proc defaults 0 0
# /dev/mapper/vg-root
/dev/mapper/vg-root / ext4 defaults 0 1”# /dev/sdb1
UUID=6af425ad-99b8-44a5-9ee1-0349141f9b1f /boot ext4 relatime 0 2

Also it would be very helpful if you would please confirm the following.

When I have copied the hashalot folder and lvm folder to my newly installed backtrack do I install the hashalot and lvm whilst in the temp folder of my encrypted install using “tools/open terminal” or do I chroot and remove everything before the /temp ?

I am running the “configure” script within each of those folders, make and then make install.

Thank you.

Reply

kriggins November 30, 2011 at 9:47 am

The /etc/fstab should look like this:

# /etc/fstab: static file system information.
#
#
proc /proc proc defaults 0 0
# /dev/mapper/vg-root
/dev/mapper/vg-root / ext4 defaults 0 1
# /dev/sdb1
UUID=6af425ad-99b8-44a5-9ee1-0349141f9b1f /boot ext4 relatime 0 2

You appear to be missing a line break and have an extra single quote mark.

I have never installed hashalot and lvm from source for this project. I strongly suggest downloading the ubuntu packages and using the built-in package management tools to install them. That very well may be the problem.

Again, there may be dependencies that need to be met in order to install these packages and that may be why things are failing. I don’t remember and don’t have time right now to do another install to check.

Kevin

Reply

Test November 30, 2011 at 9:59 am

Thank you.

Those errors were due to clumsy posting and not what I was actually typing in, sorry about that rather embarrassing.

I will struggle on trying to get this to work for me. If you get bored and get chance to try this without internet connection then I would be very interested in hearing how you got on.

Thanks anyway.

Reply

dev/null December 2, 2011 at 3:22 pm

Hey Kevin,

First off, very impressive how-to. I’ve gotten my encrypted root fs booting, and all appears well… except:

I’m using your directions to set up a ssd disk instead of a thumb drive. I clumsily attempted to encrypt the swap partition I allocated by duplicating the same steps as for the root partition (e.g. I have a pvcrypt-root and a pvcrypt-swap, a vg-root and a vg-swap, etc). When the system boots, I don’t get a chance to enter a passphrase for the swap partition.

I suspect that isn’t the right way to set this up. Can you give me any pointers?

Reply

dev/null December 2, 2011 at 4:12 pm

So, problem solved. In case anyone else is (like me) unfamiliar with using LVM, the correct solution is to do the following:

1) Create a single logical partition, and encrypt it.
2) Create a single volume group.
3) Create two logical volumes, one for root and one for swap.
4) Continue with installation.

Note that this is only slightly different from the directions above.

A good summary of these steps is here: http://laffers.net/howtos/backtrack-4-with-full-disk-encryption-dual-boot-kubuntu-10-04-lucid/.

Reply

Patrick December 3, 2011 at 9:02 pm

Hi there, the only typo I found was when you are going to indicate the mount points, you said:
We are not going to indicate the mount points for our partitions. First let’s setup our root partition. Click on the row with vg-root in it and click the ‘Forward’ button.

It should indicate to hit the ‘Change…’ button.

Other than that though, thank you very much for this amazing tutorial!

Reply

kriggins December 7, 2011 at 2:23 pm

@Patrick,

Thanks! Fixed it.

Kevin

Reply

Sam December 5, 2011 at 5:32 pm

Could you tell me what steps I need to follow without encryption?
it’s a pain in the ass using a passphrase and pressing f8 fucks things up

Reply

kriggins December 7, 2011 at 2:21 pm

@Sam,

There are instructions/tutorial on the Backtrack website that show you how to do this, but essentially all you do is boot, startx and double click the install.sh icon on the desktop. Be careful to install it to correct partition though.

Kevin

Reply

James December 6, 2011 at 5:21 am

Is there a bug with cryptsetup or something? I did this several months ago with BackTrack 5 and it worked a treat.

Now doing it with BackTrack 5 RC1 everytime I run update-initramfs -u I get:

“cryptsetup: WARNING invalid line in /etc/crypttab -”

Attempting to boot the USB drive gives me ALERT /dev/mapper/vg-root does not exist and drops to a BusyBox shell. I checked the crypttab file and everything is fine, no leading white spaces etc, fstab is also correct.

Any ideas?

Reply

James December 6, 2011 at 5:24 am

Additional note. crypttab displayed that error from the first time hashalot and lvm2 were installed and the intrid image was first built when the crypttab file was blank.

Reply

James December 6, 2011 at 9:55 am

Looks like crypttab is buggy in BT5 RC1. I just tried it all over again this time using a BT5 image from release date and its working fine. On the first run of update-initramfs, the error appeared, however after editing /etc/crypttab and re-running the second time the error disappeared. I did everything exactly the same when attempting to use BT5 RC1 and yet it failed here.

Don’t know if anyone has experienced this, but hopefully someone finds this useful.

Reply

kriggins December 7, 2011 at 2:20 pm

@james,

Have you tried it with R1 instead of RC1? I have tested it with the official R1 release and it worked fine at the time.

Kevin

Reply

James December 9, 2011 at 9:01 am

Sorry I meant R1. I don’t know what was up but it didn’t like it with R1 at all. However its nothing major. All I did was use a BT5 Image set up the USB stick and then upgrade.

JB December 7, 2011 at 7:54 pm

Has there been any progress concerning making this a persistent install? I’ve been running a non-encrypted, persistent USB install, but I’d really like to encrypt the entire drive.

Reply

kriggins December 8, 2011 at 7:31 am

@JB,

I’m not sure I understand your question. This method above results in a installation of Backtrack that retains changes between boots and is encrypted. It doesn’t use the persistence method that we used to use in, but it results in a similar end state.

Kevin

Reply

JB December 8, 2011 at 4:59 pm

After reading through all of your comments, I was under the impression that this was not a persistent install. Thank you for the clarification.

Sidenote: can I still use the guide to installing Nessus from your old BT4 guide?

http://www.infosecramblings.com/backtrack/backtrack-4-usbpersistent-changesnessus/#nessus

Reply

kriggins December 8, 2011 at 5:02 pm

@JB,

Nessus comes with Backtrack 5 so you don’t need to install it.

Kevin

Reply

Infosec-Ninja December 8, 2011 at 9:21 am

What do you need 500M on the /boot partition for??

Only ~84M are used and the rest remain free.
I have been installing on a 8gb flash disk and i could really use that wasted ~420M.

Also its a usb stick, its static. Maybe on a hard drive you give the boot partition 500M for grub changes or whatever but on a usb stick i dont really see the need….

Please add at the point when you give +500M to first partition, a notice saying that if you are using a 8gb stick you can get away with giving it just 100-150M.

Thanks.

Reply

kriggins December 8, 2011 at 10:26 am

First, a USB install isn’t necessarily static. Updates, specifically kernel updates can and do happen. That being said, at one time creating a 200MB boot partition did not allow the install to finish. I made it 500 to avoid that issue. Further, a full install on an 8 GB stick didn’t leave much room at all and so I recommend a 16 GB stick.

If you feel like confirming the minimum amount that allows the install finish, I’d be happy to update the install.

Reply

Infosec-Ninja December 8, 2011 at 9:23 am

P.S. : Is there a way to move 400 mb from /boot to the encrypted partition?

Reply

router December 14, 2011 at 5:22 am

Once we install BT5 with encryption on a USB drive , can we use it to boot from any PC / laptop without any problem like a live CD ? At same time save changes(persistence) ?

Is this the same persistent install like BT4 but with encryption ?

Reply

Nikolay December 18, 2011 at 7:59 am

Dear friends, I feel so stupid trying to find that boot partition of my USB stick for a dozen of times….. I successfully get to the point where we launch a GUI of the installer, choose language etc. Then I change the partition type of vg-root to ext4, just as it’s ritten above. BUT then I do really stuck – I’ve got ONLY ONE stupid partition on my sdc (in my case) device, it’s called sdc1 and has almost the same size like that vg-root one. But I don’t see any other sdc2,3 etc.! PLEASE tell me someone what’ s going wrong? Where do I find that 500M boot partition??? Thank you very much beforehand!!!

Reply

Johnny_Murkin December 20, 2011 at 4:32 pm

When you 1st creating you partitions, you have to add
“# delete existing partitions. [There may be more than one].”
Command (m for help): d
Partition number (1-4): 1
Command (m for help): d
Partition number (1-4): 2
[ETC. tills all partitions are gone]
Command (m for help): n
Command action
e extended or p primary partition (1-4) [type p]
Partition number (1-4): 1
First cylinder (1-2022, default 1):
Using default value 1
Last cylinder, +cylinders or +size{K,M,G} (1-2022, default 2022): +500M
Command (m for help): n
Command action
e extended or p primary partition (1-4) [type e]
Partition number (1-4): 2
First cylinder (66-2022, default 66):
Using default value 66
Last cylinder, +cylinders or +size{K,M,G} (66-2022, default 2022): [Default may not be 2022, don’t change it to 2022. I did that and ran into some problems first time around]
Using default value 2022
Command (m for help): n
Command action
l logical (5 or over) or p primary partition (1-4) [type l]
First cylinder (66-2022, default 66):
Using default value 66
Last cylinder, +cylinders or +size{K,M,G} (66-2022, default 2022): [again default maybe different]
Using default value 2022
Command (m for help): t
Partition number (1-4): 1
Hex code (type L to list codes): 83 [check you hex code list, for some reason a friends had a weird config on it (IDK how it happened), just dub. check 83 is ext3
Command (m for help): a
Partition number (1-4): 1
Command (m for help): w

Try it that way and see if it help, I know I’m vary pick on details so I follow his lines to the letter. Also check to see that if you C&P his lines you drive is sdb and not sdc ETC. you may have partitioned the wrong drive or never encrypted you files for the USB. Hope it helps.

P.S It mostly his guide with my inputs [].

Reply

JF December 19, 2011 at 6:14 am

So I had this working perfectly for months (using the first method). I have updated the kernel etc with apt-get and all worked fine. A few days ago I booted this with VMware and installed the VMware tools – they installed fine once I made sure the kernel headers were in place, problem is now it won’t boot. I get the following and then it drops in to a useless ramfs shell.

Alert! /dev/mapper/vg-root does not exist. Dropping to a shell!!

I’ve unlocked and mounted the volume using a debian live-cd, have then chrooted and uninstalled VMware tools but it’s still broken. Pretty sure it’s something to to with the initramfs boot image but I have no idea how to fix it – help please!

JF.

Reply

Johnny_Murkin December 20, 2011 at 4:11 pm

I’m new to backtrack, but know a bit in writing lines in Terminal/Console/~ ETC (Counter-Strike Source). I told a friend to use your guide as I did when I made my boot-able copy on my 16g flash. In fixing his mistakes, I noticed that if you copy and paste the lines you’ll run into some partitions mistakes/confusions. My friend had C&P you lines and his drive was not sdb, but sdc. Ex. “dd if=/dev/urandom of=/dev/sdb5” (Your line) was entered for random data copy and he had placed it into his main drive. Can you place {} or [] or anything to let people know that their drive in that line maybe different? I sent everyone that asks me how I made my Flash run to your guide (Most unfamiliar with Linux or Backtrack). Just a thought for helping out first timers and such. All in all, Great Job on the revisions and making this guide as simply and fast as possible. Thanks again!

JCD

Reply

cipi December 21, 2011 at 3:14 pm

Hi I have a problem, after boot and passphrase input I receive the following error:
ALERT! /dev/mapper/vg-root does not exist. Dropping to a shell!
ls -al /dev/mapper/
I have only control and pvcrypt and not vg-root.
When I try from live CD “cryptsetup luksOpen /dev/[your logical partition] pvcrypt” vg-root appear in /dev/mapper/
What am I doing wrong?
Thanks.

Reply

cipi December 21, 2011 at 3:45 pm

I realized what was wrong, I jumped from step
sys mount-t sysfs / sys
to step
vi / etc / crypttab
and I miss “apt-get update apt-get install lvm2 hashalot”
now everything is ok.

Reply

Jeff December 27, 2011 at 3:50 pm

So hypothetically, if someone was to screw this up and this person knew very little about linux-based operating systems, is there a way they could un-encrypt their usb drive and return it to it’s original, pre-backtrack condition?

Reply

dev/null December 27, 2011 at 3:58 pm

You should be able to simply reformat the drive.

Reply

guye December 29, 2011 at 7:48 am

Thank you for the wonderful tutorial. But I have a problem.. I have an 8GB usb memory. In my first attempt I did cancel the process during install.
When I tried re-installing I had 7.5GB…
I tried every kind of fdisk and partition tools on Windwos and Linux..
I can not seem to get my 500MB partition back..
Besides the problem is the inconsistency causes failures in the backtrack and on windows..
Is there a way for me to get the 8GB back 🙂
Thank you for the beautiful tutorial…
Cheers
Guye

Reply

cadu January 1, 2012 at 2:59 pm

hi,
I am having problems to create the encrypted disk as below…
oot@root:~# cryptsetup -y –cipher aes-xts-plain –key-size 512 luksFormat /dev/sdc5

WARNING!
========
This will overwrite data on /dev/sdc5 irrevocably.

Are you sure? (Type uppercase yes): YES
Enter LUKS passphrase:
Verify passphrase:
root@root:~# cryptsetup luskOpen /dev/sdc5 pvcryptUsage: cryptsetup [-?vyrq] [-?|–help] [–usage] [-v|–verbose] [–debug]
[-c|–cipher=STRING] [-h|–hash=STRING] [-y|–verify-passphrase]
[-d|–key-file=STRING] [–master-key-file=STRING]
[-s|–key-size=BITS] [-S|–key-slot=INT] [-b|–size=SECTORS]
[-o|–offset=SECTORS] [-p|–skip=SECTORS] [-r|–readonly]
[-i|–iter-time=msecs] [-q|–batch-mode] [–version]
[-t|–timeout=secs] [-T|–tries=INT] [–align-payload=SECTORS]
[–non-exclusive] [–header-backup-file=STRING]
[OPTION…] ]
cryptsetup: Unknown action.

help please… I had my bt4 installed perfectly using this tutorial..
tnx

Reply

Klathmon February 1, 2012 at 9:25 pm

root@root:~# cryptsetup luskOpen /dev/sdc5 pvcryptUsage: cryptsetup
^^^^
it should be luks not lusk, just a typo 🙂

Reply

Gar January 2, 2012 at 12:43 pm

I do not know uf this is normal or what to do. But when i execute the command
vi /etc/fstab

I get this:

# /etc/fstab: static file system information.
#
# Use ‘blkid -o value -s UUID’ to print the universally unique identifier
# for a device; this may be used with UUID= as a more robust way to name
# devices that works even if disks are added and removed. See fstab(5).
#
#
proc /proc proc nodev,noexec,nosuid 0 0
/dev/mapper/vg-root / ext4 errors=remount-ro 0 1
# /boot was on /dev/sdc1 during installation
UUID=4241c315-939a-4143-98b3-74e95c853189 /boot ext4 defaults 0 2

Should i correct something. If so what?

Reply

Evo January 11, 2012 at 7:31 am

“If you happen to get an error with mentions something like “..the partition table failed with error 16:…”, you need to reboot before continuing with the how-to. You might be able to get away with continuing, but there is a good chance you will experience some problems. After rebooting, you will need to re-execute the startx command and the cryptsetup luksOpen commands.”

I just got that error, what are you mean by . Can I reboot DVD with BT5R1, “startx” again and continue with this tutorial (so my next step will be “apt-get update” and then further with cryptsetup luksOpen commands)? What about stuff I have done (psyhically partition of my new USB) if I rebooted? I don’t understand…

Thank you in advance for help!
Evo

Reply

Raven January 16, 2012 at 10:23 am

Just had to say, excellent guide! Thank you very much. I’m a relative newb and I was able to get it done. The instructions were very thorough if you have had even some exposure to linux.

Only comment is that this part is a little confusing:
The only line we need to change is the line for vg-root which is bolded above. For those new to vi, position the cursor on first ‘U’ of the line using your arrow keys and type ‘dd’, then move the cursor to the ‘#’ in the line above and type the letter o, then type the line below, hit the esc key and type ‘:wq’ without the quotes to save the file. The line needs to look like below when done:

The reason being that I couldn’t figure out why you would type “dd” or “o”. In the version of vi I was using, it seemed to already be in edit mode so typing those letters actually added them to the document.

I looked it up and found out that if you press “Esc” and then those letters, it will delete or add a line. I’m not sure if that is a mistake on my part or something that might need to be added to the guide, but I thought it might be worth mentioning.

Once again, excellent work. Thanks Kevin!

Reply

StealthRedneck January 17, 2012 at 2:54 pm

Okay, after I believe 4 or 5 attempts, this appears to be working! =D 3 of those I attribute to my “hand-on” learning style where I would rather do and fail then read a whole boring page of stuff. However, there was quite a bit of funny issues and confusion… I’ll try and list a couple of those things out now and hopefully get some constructive feedback to help future readers.

0.) Very first attempt was with a totally wiped, 8GB Patriot Xporter. Install failed using the tutorial to the letter as there was NOT enough space. By the comments it looks like you should probably decrease the boot partition by at least 200MB to avoid any errors. I just used it as an excuse to get a Cruzer Fit 16GB for $17.99

1.) The first issue I ran across was Back|Track yelling and screaming as I attempted to delete the flash drives partitions. That error 16 bogus. The only thing that worked? Delete the partitions and make the new ones, write, THEN boot up your GUI via startx.

2.) The dd urandom command took 3.5 hours on a 16GB flash drive. It also is impossible to tell where it’s at if your impatient. Good news! Type this out in another console… [kill -USR1 `pidof dd`]

3.) The /etc/fstab portion is rather confusing. I didn’t know if I had to edit it or not… A picture of before AND after would be very helpful. Having 3 different UUIDs in your tutorial confused me a bit as well.

4.) Lastly, all appears to work… strangely though after booting, hitting F8, and trying to type my luks passphrase… Well it has 4 characters already typed in and every key I hit, whether it is backspace, or a letter to MY passphrase…the terminal repeats a long unlocking the disk by uuid command until the whole screen is filled up with garbage. Is this normal?

Thanks for the tutorial! GL and HF everyone.

Reply

Stealth Redneck January 18, 2012 at 8:32 pm

@Saint Patrick

Eek, looks like the UUID error is indeed a problem with a USB 3.0 device on a USB 3.0 port…I got the same error. I just tried your fix after booting a live-dvd of BT5…

” mkdir /mnt/backtrack5
mount /dev/mapper/vg-root /mnt/backtrack5
mount /dev/sdb1 /mnt/backtrack5/boot
chroot /mnt/backtrack5
mount -t proc proc /proc
mount -t sysfs sys /sys ”

Followed by your instructions. I got the following error after attemping the update:

“grep: /proc/modules: No such file or directory”

I’ll reboot and still see if I get any success!

Reply

Gorgio January 25, 2012 at 2:17 am

Hi,
i followed tutorial step-byl-step twice and i always had same problem.

Every step had OK, no errors, but after i reboot and try to boot from USB i get blank screen only with blinking cursor in left corner. Grub loader dont workink. LED indicator on USB dont lighting. I tryed to format stick and do everythink again, again with no error, but same problem. I am littlebit frustrated.
I was even trying to install on other flash stick but same…

Please help
Thank Gorgio

Reply

kriggins January 25, 2012 at 6:23 am

@gorgio,

Did you try this bit?

IMPORTANT

In my case, the system boots and looks like it is hanging at the Backtrack 5 splash screen. Simply press F8 to get to the console, where it is waiting for you to enter your luks passphrase. Type that bad boy in and, if all goes well, your system will boot.

Kevin

Reply

Gorgio January 25, 2012 at 11:40 am

Yes i tryed this, but that is solution for splash screen, i even did not get there. When usually start boot loader menu a have there only blank screen with blinking cursor. I cannot type anythink.

Reply

Zachary Galifianakis February 1, 2012 at 11:19 am

I have tried and tried to make this work, but am still getting the same error when trying to boot from the encrypted drive…

Begin: waiting for encrypted source device… …

I then wait for a few min’s and then it shows:

-r ALERT! /dev/disk/by-uuid/2875495c-f54f-4130-9ed4-be8f7192812d does not exist. Dropping to a shell!

BusyBox V1.13.3 (Ubuntu 1:1.13.3-1ubuntu11) built-in shell (ash)
Enter ‘help’ for a list of built in commands.

(initramfs)

This is NOT a problem relating to USB 3.0 as mentioned above.
Any suggestions?

Reply

kriggins March 1, 2012 at 3:54 pm

You might try using the the device for the scsi disk just to ensure that everything else is okay, e.g. /dev/sd[x] where x is your device.

Not sure exactly what might cause the problem above unless there is an erroneous character in the UUID.

Kevin

Reply

Martin Nuc February 7, 2012 at 5:34 pm

Hi everybody. I was fighting with “Alert! /dev/mapper/vg-root does not exsist. Dropping to a shell.”
Nothing here helped so here I post what worked for me:
http://www.nuc.cz/backtrack-5-persistent-usb-devmappervg-root-d

Reply

kriggins March 1, 2012 at 3:55 pm

Martin,

Thanks for the posting this. This happens when you do a apt-get dist-upgrade. It removes the cryptsetup stuff.

Kevin

Reply

Cassiopeia February 13, 2012 at 3:12 pm

hey i got a peculiar problem with my bt5r1

i boot up, dont even have to put in a password, then it spits out
“cant find /dev/mapper/bg-root does not exist, dropping to a shell”

and there i have a busybox shell. now im no expert, but somethings wrong…
now i read uptop that you should edit the /etc/fstab, BUT heres a fun fact, cant find it! is it any of my unmounted partitions?

Reply

Aaron February 15, 2012 at 4:53 am

i Don’t know whats going on
root@root:/# update-initramfs -u
update-initramfs: Generating /boot/initrd.img-2.6.39.4
/usr/bin/sha1sum: line 1: syntax error near unexpected token `\�.7i�∨�\!CYԑ�4䕌�\���d�ֹ�BgD����9�’
/usr/bin/sha1sum: line 1: `/�,�A��O�0t���P(\�.7i�∨�\!CYԑ�4䕌�\���d�ֹ�BgD����9� ����([hXx~ڻ�”~^!�&����<���4"�U1���p���u��ؗ� %���Y.WSo0�s�ש�����A
�_ҝ�LJ
�=R�Go��?*X�j��'

Reply

kriggins March 1, 2012 at 3:56 pm

I don’t know what is going on here. I hope you were able to work through it.

Reply

Rok February 15, 2012 at 12:51 pm

I ran to a few problems during the last step when updating fstab. Running commands

vi /etc/crypttab
vi /etc/fstab

usually doesn’t return the expected results. But when I do manage to update the files the command

update-initramfs -u

returns:

update-initramfs is disabled since running on read-only media

I suspect I missed a few lines of commands, but can’t figure out which. I went through instructions several times and I can’t find where the mistake was made. Please help.

Thanks in advance, Rok

Reply

kriggins March 1, 2012 at 3:57 pm

This usually happens when the chroot command either isn’t executed or doesn’t execute correctly.

Reply

Andrea De Pasquale February 20, 2012 at 5:22 am

Please note that running

dd if=/dev/urandom of=/dev/sdb5 bs=4M

instead of

dd if=/dev/urandom of=/dev/sdb5

took *much* less time to fill my USB drive.
IMO, you should at least mention it.
Anyway, thanks for the tutorial!

Reply

kriggins March 1, 2012 at 3:57 pm

Very good tip. Thanks! Will include in future versions.

Kevin

Reply

Maus Stearns February 24, 2012 at 12:58 am

Alternatively couldn’t you just as easily load a backtrack vm and give access to the sdcard that way? Just in case you didn’t have an extra thumbdrive around…

Reply

kriggins March 1, 2012 at 3:58 pm

Yup. I have done it that way too.

Reply

Rouca February 27, 2012 at 11:48 am

I have recently updated the USB drive to Linux 3.2.6 from 2.6.39.4, and I got
ALERT! /dev/mapper/vg-root does not exist. Dropping to shell!

Then I try to use your troubleshooting tip to dig into issue, I couldn’t get through the last step
mount -t devpts devpts /dev/pts
/dev/pts does not exist

Any suggestion? Thank you!

Reply

kriggins March 1, 2012 at 3:59 pm

The vg-root doesn’t exist error is probably because the initram build doesn’t have the right tools. Did you use an outside source to upgrade the kernel or did you just apt-get upgrade?

You can ignore the /dev/pts error when troubleshooting. Doesn’t mean anything.

Reply

richard February 27, 2012 at 3:39 pm

Nice! Worked as advertized (including the maddeningly long waits at exactly the points you promised). I did this with a 32″GB” (29.8 *real* GB) drive and ended up with about 22GB of free storage.

In anticipation of eventual failure of the stick (or id10t user error by yours truly), I used dd to make a snapshot iso file from the USB drive. I’ll repeat that periodically to create new backups from which to recreate the install without all the waits and to minimize losses of data and configuration changes. Just a thought.

Thanks much!

Reply

kriggins March 1, 2012 at 4:00 pm

That is an excellent idea on the dd backup. Gonna steal that (with attribution) and include it in the next rev of the how-to.

Kevin

Reply

richard March 1, 2012 at 8:31 pm

Just FYI…

My flash stick is a Patriot XT 32GB – USB 2.0. I’m running the BT5 install (stealth mode – from USB only) on an Asus Netbook 1018P-PU17-BK (1.66GHz Intel Atom, with 2GB RAM and a 460GB HD – base, single-boot OS is Kubuntu 10.04 LTS). There’s no point (I originally thought) to paying for a USB 3.0 stick, since the only bootable USB drive on the netbook is limited to the USB 2.0 port on the left-hand side of the netbook. Well, I say that, but, for the purposes of dd (cloning to the HD of the netbook base install), the 3.0 speed might be more satisfactory, since the two RIGHT-hand USB ports on the netbook support 3.0…start to finish a run of dd to clone the USB takes about 18 minutes.

As for swiping the dd idea, “plagiarism is the sincerest form of flattery.” Feel free (this is a “least” contribution to your superbly excellent tutorial).

Reply

Cassiopeia March 1, 2012 at 3:09 pm

hey have two questions again
how do i change password on the USB key?
and is it possible to boot it into say, Oracle VM Virtualbox?

Reply

kriggins March 1, 2012 at 4:01 pm

To change the password, just use the passwd command from a shell once you have booted to the completed install.

I use a Virtualbox VM during the testing of the how-tos all the time. Works great.

Kevin

Reply

Cassiopeia March 1, 2012 at 4:23 pm

wont passwd just switch the local root pass, i mean the one for unlocking the crypted part!

Reply

kriggins March 1, 2012 at 4:41 pm

Ah, sorry about that. I’ve never done it, but here is a set of instructions. You can actually have up to 8 passwords for a given volume if I remember right.

http://www.ehow.com/how_7428906_change-luks-password.html

Kevin

Reply

Cassiopeia March 1, 2012 at 5:32 pm

lovley thanks a bunch, btw do you have any guid readily avalible for setting ut up in a VMWare?, found this: http://agnipulse.com/2009/07/boot-your-usb-drive-in-virtualbox/ BUT i cant get past the first step really, it just says access denied but i am running CMD as admin and all.

Reply

kriggins March 3, 2012 at 5:39 pm

When testing this process, I use VirtualBox. I create a virtual disk, set the CD to mount the ISO and then just follow the guide. Should work for VMWare too. Alternatively, if you don’t care about encryption, just create the virtual machine with a virtual disk, mount the ISO to the CD, boot and click the install icon on the desk top after executing startx.

Reply

preetcher March 2, 2012 at 10:19 pm

Greetings..Incredibly interesting ‘torial. Have you “published” your pdf yet?
Question, so you did this on your macbook pro that natively runs snow leopard? And you now can boot bt5r1 from a stick? (similar as linux on windows box, connect hd, hit enter on post, hit f12, select ext hd – boom, bobs your uncle) Booting from the stick is as usual, just holding down the option key? And this bt5r1 will boots seamlessly on windows boxes?
Thanks much.

Reply

kriggins March 3, 2012 at 5:39 pm

Thanks and I just published the PDF today with the edits for R2.

I have not tried to boot to a USB in my Mac yet so can’t answer your questions. Sorry.

Reply

Marc Handelman March 3, 2012 at 5:28 pm

Outstanding tutorial Mr. Riggins,
Many Thanks!

Reply

kriggins March 3, 2012 at 5:40 pm

Thanks!

Reply

Ryan Morgenstern March 4, 2012 at 6:26 pm

Kriggins,
Thank you, your tutorial worked perfectly for my 16gb flash drive. How can I do this with a 64gb sandisk cruzer with exFAT file system? I tried to restore a 16gb image to my 64gb flash drive using USB Image Tool but it will not boot.

Reply

kriggins March 6, 2012 at 8:29 pm

Sorry Ryan, but I don’t have any experience with 64GB drives with this how-to.

Kevin

Reply

Ryan Morgenstern March 8, 2012 at 10:49 pm

No worries Kevin.. Thanks again for sharing your ingenuity and experience with the world, this tutorial was a phenomenal learning experience!

Reply

totoroha March 7, 2012 at 10:47 am

I read over your instruction again, and can you tell me how to install BT5 R2 without the encryption part ? Thanks you so much.

Reply

kriggins March 9, 2012 at 9:15 am

Basically all you have to do is have bootable media with Backtrack on it and a target drive and do the following:
1. Boot the Backtrack R2 USB/DVD/etc.
2. Type startx
3. Start networking if you want it.
4. Double click the install.sh icon on the desktop
5. Follow the instructions and partition the drive however you want it or let it partition the drive.
6. Wait.
7. Reboot.

Here is a fancier version from the backtrack-linux.org site:

http://www.backtrack-linux.org/wiki/index.php/Install_BackTrack_to_Disk

Kevin

Reply

Federico March 8, 2012 at 4:41 am

Hi,
I’ve been using BackTrack 5 R1 flawlessy on a laptop with an encrypted hard disk.
I’ve just tried to upgrade to BackTrack 5 R2 by following the guide at: http://www.backtrack-linux.org/backt…backtrack-5-r2, but after rebooting I got the error message “/dev/mapper/vg-root does not exist” and the boot process dropped to the initramfs prompt.
How can I recover the encrypted root partition during boot?
Thank you in advance for any hint.

Reply

kriggins March 8, 2012 at 7:11 am

I wonder if you you have gotten hit by the bug that removes various tools required for encryption to work. First thing to do is make a Backtrack CD/USB drive per the instructions at the beginning of the tutorial if you don’t already have one. It doesn’t need to be R2. Boot with that and then follow the troubleshooting tips towards the bottom of the how-to. That should get you back to where you can check to see if cryptsetup has been removed. If it has, run

apt-get install cryptsetup ecryptfs-utils keyutils

and then rebuild initramfs.

Kevin

Reply

Federico March 8, 2012 at 9:33 am

Do you mean the kernel on the CD/USB drive does not need to match the one installed on the hard disk? Would it still work if I used a Ubuntu 11.10 CD?
Many thanks!

Reply

kriggins March 8, 2012 at 10:05 am

I don’t know if an Ubuntu CD will work or not. I know another Backtrack CD/USB drive will.

Reply

Federico March 11, 2012 at 11:01 am

After investigating a little further, I realized the file /usr/share/initramfs-tools/scripts/local-top/cryptroot is missing since I upgraded to R2!
All the packages you mentioned (cryptsetup, ecryptfs-utils, keyutils and also hashalot) are still installed, but the initramfs configuration has somehow changed.
This is the new content of the scripts directory:

/# ls usr/share/initramfs-tools/scripts/*
usr/share/initramfs-tools/scripts/functions usr/share/initramfs-tools/scripts/nfs
usr/share/initramfs-tools/scripts/local

usr/share/initramfs-tools/scripts/init-bottom:
plymouth udev

usr/share/initramfs-tools/scripts/init-premount:
lvm2

usr/share/initramfs-tools/scripts/init-top:
all_generic_ide blacklist console_setup framebuffer keymap plymouth udev

usr/share/initramfs-tools/scripts/local-bottom:
ntfs_3g

usr/share/initramfs-tools/scripts/local-premount:
fixrtc ntfs_3g resume

usr/share/initramfs-tools/scripts/local-top:

usr/share/initramfs-tools/scripts/nfs-top:
udev

usr/share/initramfs-tools/scripts/panic:
console_setup keymap plymouth

What else is missing and how should I fix it?

Reply

kriggins March 12, 2012 at 8:17 am

I don’t know specifically what you are missing at this point. I would remove the packages listed previously and re-install them and see if that clears things up. Sorry I don’t have better guidance for you.

Kevin

Reply

Federico March 14, 2012 at 4:56 am

Hi Kevin,

I followed your suggestion and reinstalled all packages. The good news is I can boot the encrypted partition now! But I’m still experiencing odd behaviours: whenever initramfs is updated, the selected kernel image is the old 2.6.38 insted of 3.2.6, as shown below:

Processing triggers for initramfs-tools …
update-initramfs: Generating /boot/initrd.img-2.6.38

I manually ran update-initramfs with the option -k 3.2.6 and it worked out, but if I try to install any other package (like the nvidia drivers) that would trigger an initramfs update, then the old kernel is still selected!
The weird thing is the “uname -r” command outputs the new kernel (3.2.6)… Any idea of what might be still wrong?
Thank you so much for your support!

f0cker March 9, 2012 at 5:45 pm

I’ve got the same problem with the kernel upgrade. It looks like there’s no hashalot or lvm2 so it cant mount /mapper/vg-root. I can mount everything and re-trace all the steps but when I try to update-initramfs from the chroot environment it says “update-initramfs is disabled since running on read-only media”.

Reply

f0cker March 12, 2012 at 6:32 am

This isn’t a chroot issue either. I restored my system by removing the entry for the new kernel image in the grub config file and I still can’t update initramfs. It thinks the /boot partition is read-only and mount says otherwise – annoying.

Reply

kriggins March 12, 2012 at 8:16 am

Hmm. Haven’t run into that problem post install and don’t really know why it might be happening. Sorry.

Kevin

Reply

Ester March 29, 2012 at 7:29 am

I’ve got the same problem, every thing goes smooth and clean, less the problem with dev/pts as well, till the update-initramfs -u command when it says “update-initramfs is disabled since running on read-only media”.

I am probably talking nonsense but have noticed that the address assignement of the stick during installation, realized using a second stick with BTR2 on as boot drive is quite misplacing. During installation the target is assined the ‘sdc’ address and the booting one the ‘sdb’. when trying to boot with the encrypted installation the new key is registered with the sdb address (they seems to be assined in temporal succession to the differente usb devices, I tried to boot and install qith both the usbkeys in different positios but the rsult is always the same.
I found a little tricky and confused the /etc/fstab edition, given a difference in the options in my fstab arquive

proc /proc proc nodev,noexec,nosuid 0 0
/dev/mapper/vg-root / ext4 errors=remount-ro 0 1
# /boot was on /dev/sdc1 during installation
UUID=311986ab-5809-4bae-86ba-8bc2795250cb /boot ext4 defaults 0 2

that’s how I left it

cheers

Reply

Chris March 10, 2012 at 6:48 pm

hi Kevin,

i have today install BT5 R2 of my USB Stick.
But i cannot start my Xserver.
I get the following Message:

mktemp: failed to create file via template ´/tmp/serverauth.XXXXXXXXX´ :Read-only file system
/usr/bin/startx: line 155: cannot create temp file for here-dokument:Read-only file system xauth: error in locking authority file /rrot/.Xauthority

i have also no write right for ” ad user” or passwd”

can you please help

this Message get as root

Best regards
Chris

Reply

kriggins March 12, 2012 at 8:18 am

Sounds like your issue is similar to the one mentioned in the comment above by f0cker. Sounds like the filesystems have been mounted in read-only mode. Not sure how to fix this at this time.

Kevin

Reply

Ray March 12, 2012 at 9:57 pm

Great tutorial, Mr. Riggins… I managed to get this to work to boot from the USB Flash on my brand new Alienware m17x-R3 ;)… But I’m wondering if that, after backing up the entire content of a USB and dumping it into another one of greater capacity (I did this in a 16 GB USB flash drive, but now I’m using a 32 GB one), is it possible to resize the encrypted partition? I’d like to make use of all that wasted space 😛

Thanks in advance for your reply

Ray Vertti

Reply

kriggins March 13, 2012 at 5:20 am

Interesting you should ask that question. I was just having an email discussion about this topic with somebody else. I plan to explore it in depth and add how to do it to the update in the near future, but for now, this is the only resource I’ve found. Not sure what happens to the partition table when you dd from a smaller size to larger though.

https://help.ubuntu.com/community/ResizeEncryptedPartitions

Kevin

Reply

Ray March 14, 2012 at 9:40 pm

Hi Kevin

The partition table remains the same… I just have the rest of wasted disk space, unassigned to any partition… I’m checking that how-to as well… I’ll let you all know how it goes…

Ray

Reply

Ray March 16, 2012 at 2:07 pm

Hi all

For those like me looking to resize your encrypted partition I can tell you the link provided by Kevin works… I have successfully resized from 16G to twice that amount. You just have to follow the instructions provided in the link (https://help.ubuntu.com/community/ResizeEncryptedPartitions), in the section “Detailed resizing ~ Enlarging an encrypted partition”, with some minor changes:

In step 7:

7. Decrypt your file system.

sudo cryptsetup luksOpen /dev/[encrypted_partition: sda#, sdb#, etc,etc…] crypt1

In step 11:

Resize the (LVM) Physical Volume.

lvresize -L +(#amount of space)G /dev/mapper/vg-root <—-The LVM Physical Volume created in this how-to…

12. Resize the filesystem.

sudo e2fsck -f /dev/mapper/vg-root <—-Ditto…

sudo resize2fs -p /dev/mapper/hardy-root<—-Ditto…

After all this you can check with df -h the size of the encrypted volume. Mine's like this:

Filesystem Size Used Avail Use% Mounted on
/dev/mapper/vg-root 30G 15G 13G 54% /
none 2.0G 356K 2.0G 1% /dev
none 2.0G 0 2.0G 0% /dev/shm
none 2.0G 64K 2.0G 1% /var/run
none 2.0G 0 2.0G 0% /var/lock
none 2.0G 0 2.0G 0% /lib/init/rw
/dev/sdb1 486M 76M 385M 17% /boot

Good luck y'all!

Ray

Reply

steve March 13, 2012 at 8:26 am

this tutorial looks very much like mark knowles tutorial i did to ubutnu 10.04 back in june of 2010. i truely loved the set up even though it took me a few times for the install to complete and boot. here is the tutorial i think he did. http://ubuntuone.com/6slqS4UC0HcSfXgSErIzct tho he no longer has the tutorial up or the piece to download from him. i will have to take a look at this one and compare.

steve

Reply

kriggins March 13, 2012 at 8:37 am

Interesting. That name is familiar to me, but I don’t know where from. My original full disk encryption how-to for Backtrack 4 was published on December 29th, 2009.

Reply

steve March 13, 2012 at 8:43 am

https://mknowles.com.au/wordpress/ is his blog. that is where i originally found his how-to

Reply

RJ March 15, 2012 at 11:29 pm

So I did all of this letter for letter, and it went without a hitch, but now no system reads my USB drive to boot from. It doesn’t even appear. If I try to mount it in windows, OS X, or linux, it just says that the drive is unreadable and asks to reformat. Soo… what did I do wrong, or am I missing something here?

Reply

electrickoolaid March 18, 2012 at 5:26 pm

So, uh, how long is normal for the computer to seem stuck at 99% when actually installing Backtrack on the flash drive? I’ve been sitting here with it running in VMWare and the install has been on 99% for almost 2 hours now.

Also, if I hit “restart now” on the next screen, or otherwise fail to hit continue testing (ie, if the VM locks up and I have to restart it), what all do I have to redo?

Reply

Marcus March 22, 2012 at 7:05 pm

Definitely going to be testing this once I get a 16gb stick.
One question; Where can I get info about the encryption used? I’m curious about the encryption schema and the strength of it in this implementation.

Reply

Greg March 27, 2012 at 3:41 am

I have installed it and it’s working… but. after pressing F8 and writing my luksOpen passphrase there is this error:
“fsck.ext4: Device or resource busy while trying to open /dev/sdb5
File system mounted or opened exclusively by another program!
mountall: fsck/boot [536] terminated with status 8
mountall: unrecoverable fsck error: /boot
serious errors were found while trying checking the disk drive for /boot”

then it asks me what to do next: ignore(i)/skip(s)/manual repair(m) (or sthing like that)
I’m chosing ignore
then one more error (don’t mind this one when we will figure out with upper error from this post)
after – one more time question what to do -> I chose skip and it’s working…
what went wrong?? is it something that I didn’t do with setting boot disk??
btw – I’m writing from this very backtrack I’ve installed from this how-to 😀

Reply

Kenshin March 30, 2012 at 6:13 am

Hi, thanks for the great guide. It worked perfectly (BT5R2), until after a few weeks i forgot and ran: apt-get autoremove…
I’m now stuck at booting: “ALERT! /dev/mapper/vg-root does not exist. Dropping to a shell!”

I tried the troubleshooting procedure, but after the running the line:

chroot /mnt/backtrack5

i get this error: “openpty failed”.

See here for a complete log of the Terminal: http://pastebin.com/ywJUSBCF

Any help is greatly appreciated 🙂

Reply

Sam April 1, 2012 at 6:31 pm

Hi All,
Im trying to set this up on my USB drive. It is a 16GB drive. When I try to run this command update-initramfs -u I get this:
pdate-initramfs: Generating /boot/initrd.img-3.2.6
W: Possible missing firmware /lib/firmware/rtl_nic/rtl8168f-2.fw for module r8169
W: Possible missing firmware /lib/firmware/rtl_nic/rtl8168f-1.fw for module r8169
cryptsetup: WARNING: invalid line in /etc/crypttab –
Any thoughts?
It is the only issue i am having, so close!!!

Thanks,
Sam

Reply

Sam April 1, 2012 at 6:32 pm

Need to be notified of this….so another post haha

Reply

Celius April 1, 2012 at 8:59 pm

Sam, that’s not a problem, it’ll work anyway.

Reply

Sam April 1, 2012 at 9:11 pm

So my jump drive will still bootup backtrack even though that didn’t do the update correctly? And how do I run that jump drive then? Its the second jump drive that had the install done with it. Spent all day trying to work stuff out on this! Haha

Sam

Reply

Celius April 1, 2012 at 9:14 pm

I followed the instructions, except for filling up the drive with random data (It’s encrypted anyway), I got the same error as you did, and just kept going with the instructions, and everything worked fine.

My setup was: BT5R2 DVD & 16GB USB stick. (Obviously installing to the flashdrive).

Reply

Sam April 1, 2012 at 9:20 pm

Good to know. So how do I boot up the jump drive with the install then? Last I tried it to check it in backtrack it said it was unmountable because of being used by another block. Do I need to boot up backtrack first, then boot into the installed jump drive?

Sam

Reply

Celius April 1, 2012 at 9:23 pm

It’s really all in the instructions.
When you’re done and have followed all the steps successfully, all you do is reboot and remove any installation-media, and let it boot from the new flashdrive.
Hit enter at the first screen, and then f8 at the splashscreen to see the login prompt (use the luks password you set earlier.)

Reply

Sam April 1, 2012 at 9:33 pm

Sorry, don’t seem to act all newbie haha I figured it my be as simple as going back into my boot options at start up and running the other flash drive but I figured since my comp is off I’d just ask haha thanks for the help! I will let ya know how it goes, maybe tomorrow.

Sam

Reply

Sam April 1, 2012 at 9:47 pm

Ok i tried it haha i got “ALERT! /dev/mapper/vg-root does not exist. Dropping to a shell!” any ideas? What didnt i do?

Sam

Reply

Sam April 5, 2012 at 7:27 pm

Another issue! Anyone else get “WARNING failed to associate XX:XX:XX:XX:XX:XX (EEID linksys)” (something like that) like 100 times in a row, all after “trying pin 12345670”? I let it sit for about an hour and it just kept repeating the warning without changing pins :/

Sam

Reply

N0B0dySpecial April 7, 2012 at 5:39 am

hi Kevin,
great tutorial! well written and presented.. Kudos to you.

My question is on the UUID part in the /ect/fstab/, sorry bit of a noob, in the etc/fstab/ whnen using “vi” your pdf that is say to “dd” at the first U ? I’m getting confused here are you dleting the UUID ? if so where do i put my UUID in ?
If I can see a finished /etc/fstab with the UUID of the one we got from typing blkid /dev/sdb5 that will help me no end.

Reply

kriggins April 21, 2012 at 6:28 am

You delete the line with the UUID in it and uncomment the vg-root line. You don’t add your new UUID. Sorry for being unclear.

Kevin

Reply

Non Serviam April 8, 2012 at 5:17 pm

I have installed BT5 R2 64bit KDE on a usb 2.0 16gb drive, that has a read of 20mb/s (I have benchmarked it) but the system is unbelievably slow. The os freezes for many seconds and this is happening all the time. I have used it in 2 pc’s and turned the desktop effects off but the problem was the same. Is my usb drive very slow or the encryption slows everything down? Should I try it without encryption or it doesn’t matter? Thanks.

Reply

Celius April 8, 2012 at 5:41 pm

Encryption slows things down quite a bit, minimizing read/write operations will make it feel zippier.

Encryption is for protecting data, and the most common use of it is to encrypt the storage drive, not the drive with the OS (This has other issues, such as temp files and what not).

You could also look at loading the OS into RAM (If you have enough of it) as this would speed it up too (But it would still take as long for read/write of encrypted data.

Reply

Scott Dare April 9, 2012 at 7:40 pm

This clear and careful write was also useful for setting BT5 on a plain ‘ol hard drive as well. Thanks for the clarity and effort!

Reply

Deets April 12, 2012 at 10:51 pm

I followed your instructions and everything worked up to the part where I need to mount proc and sys. The errors I get are:
mount: proc already mounted
and
mount: sys already mounted or /sys busy
mount: according to mtab, none is already mounted on /sys

I show that non is mounted on both. I am installing R2. Have you seen this? What would you suggest to fix this?

Thanks,
Deets

Reply

Deets April 13, 2012 at 12:37 am

OK, I rebooted and that fixed the issue. I was able to go thru the steps and complete the install. I can’t get it to boot. I get following error.
First off, it boot to the grub screen with choices of what I can boot.
Then it hangs on the splash screen and never gives me a prompt to enter my password. Finally it gives the following: -r ALERT! /dev/disk/by-uuid/ does not exist. Dropping to a shell!

I did notice that after my reboot, I looked in the fstab file the UUID was different. Would/could that make a difference? or did I just fat finger something along the way?

Thanks again!

Reply

Celius April 13, 2012 at 12:44 am

Did you wait around 5-10 seconds when the splash screen loads and then hit F8?
That’s what I do with mine and it drops me into the shell and asks for the encryption password.

Reply

Deets April 13, 2012 at 9:24 am

Yes that what I do but that fails – I guess it can not find that UUID.(?)

Here is what I see when I boot up.
First, I get the GNU GRUB version 1.98-1ubuntu13 screen that give me the following boot options:
Ubuntu, with Linux 3.2.6
Ubuntu, with Linux 3.2.6 (recovery mode)
etc…
I assume I’m seeing this because I have Ubuntu (Backtrack 5, to be more specific) installed on the laptop I running this on.

After that it boots and gets to the splash screen and when I hit F8 I get the following message:
Begin: Loading essential drivers …
Done.
Begin: Running /scripts/init-premount …
Done.
Begin: Mounting Root file system… …
Begin: Running /scripts/local-top …
Begin: Waiting for encrypted source device …

Then nothing else happens until it drops out to the shell with the following error.

-r ALERT! /dev/disk/by-uuid/818b6364-206f-b402-ef3c2604ec21 does not exist. Dropping to a shell!

I assume that I might have done something wrong when setting the crypttab and fstab file. Like I said, I did have to reboot to get the proc and sys mounts to work in the steps. It looked like the UUID after the reboot was different, so I’m not sure if that caused the issue or not (or if I was just too tired and saw it wrong).

Any help would be greatly appreciated.

Reply

Deets April 13, 2012 at 10:02 am

OK, another update. Apparently my alcohol level last night and coffee level this morning were too low. I realized that I had the wrong UUID entered. It should be 5 groups of chars not 4. I updated the /etc/crypttab file to reflect the correct UUID but when I reboot I get the same error with the old UUID. Where else do I need to update that? As a note – I did the steps under the troubleshooting section to mount the drives and chroot before I updated it.

Once again, thanks!

Reply

Deets April 13, 2012 at 12:06 pm

Update: WooHoo!!!! success!

Here’s what happened. I updated the crypttab file and rebooted before I remembered (realized) I needed to run the “update-initramfs -u” command. I went back and ran that that it still did not work. I checked everything and ran the command again but still no luck. I checked /boot and noticed that the time/date stamp on the initrd.img file was never updated. I ran the “update-initramfs -v -u” command and checked the file and it it was updated. I rebooted and was able to get in. I’m not sure if the previous attemps to run the command were done wrong, if the -v option did something, or I just needed more beer (I’m always happy to try the 3rd one) but it worked.

Thanks for your help (or at least listening). This is a great how-to and I would have NEVER been able to do this without your help. Please, for people like me, keep up the good work. Hat tip to Celius, too.

Reply

Futta April 16, 2012 at 3:39 pm

Does this method allow you to keep dowloaded files / settings in backtrack? (Live install gives a “fresh” boot every time, wont save files/settings)

Cause I would like to boot up backtrack on my USB-Stick and dont have to redowload every file all the time.

Reply

kriggins April 21, 2012 at 6:27 am

Yes.

Kevin

Reply

lanzorg April 16, 2012 at 4:53 pm

Would not it be better to use a non-journaled filesystem like EXT2 on a USB key?

Reply

kriggins April 21, 2012 at 6:26 am

We turn off journaling on ext4 for this reason. The new installer tends to barf when selecting ext2. At least it does for me.

Kevin

Reply

chrisall April 17, 2012 at 2:33 pm

Fantastic resource, I have used it several times now. Noticed just a couple of typos that might catch people out:

1. Fixing the /etc/fstab file if necessary:

The only line we need to change is the line for vg-root which is bolded above…

It is actually the UUID line which is bolded in the code snippet, the line that needs editing is the line above:

# /dev/mapper/vg-root should be changed to /dev/mapper/vg-root / ext4 defaults 0 1

2. Cryptoroot patch:

patch -u /usr/share/initramfs-tools/scripts/local-top/cryptroot ./cryptroot-patch

It should be a period between cryptoroot and patch, not a hyphen;

patch -u /usr/share/initramfs-tools/scripts/local-top/cryptroot ./cryptroot.patch

Cheers

Reply

kriggins April 21, 2012 at 6:25 am

Thank you very much for pointing out these problems. I have corrected them.

Kevin

Reply

zarko April 21, 2012 at 5:48 pm

1) this is what i get when i use vi or gedit to edit etc/fstab
aufs / aufs rw 0 0
tmpfs /tmp tmpfs nosuid,nodev 0 0
/dev/sda7 swap swap defaults 0 0

what should i do?

And one more question. Can i install bt on USBdrive without encryption?
thanks!

Reply

zarko April 21, 2012 at 5:54 pm

I mean i already instaled BT5r2 using universal usb installer and allowed 2 gbof persistatn memory, but after apt-get upgrade it cant boot(inode somenumber deleted, or someth8ng)

Reply

zarko April 21, 2012 at 5:56 pm

and one more thing, i used BT5 in the process(not r1 or r2)

Reply

kriggins April 22, 2012 at 5:31 am

If you used the usb installer with persistence, this guide doesn’t offer any value to you. All edits are dependent on installing this way.

Kevin

Reply

Zach April 27, 2012 at 6:10 pm

Great work Keven! Everything worked flawlessly the first time. The only thing that I added to your install, and you may or may not want to add it to your tutorial, is that after I ran:

update-initramfs -u

I went ahead and ran:

fix-splash

That reloads the flash screen and brings back the eye candy.

Reply

Benny May 3, 2012 at 6:42 am

Hi, everything worked perfect for me during this install.
I didn’t run into any problems or had errors.
When I rebooted I got a black screen with “No OS Installed”
Lol now I am sitting here scratching my head.
Any ideas?
Thanks

Reply

kriggins May 6, 2012 at 8:24 am

Sounds like the boot loader didn’t get installed correctly. I’d run through it again.

Reply

Antonio May 6, 2012 at 8:09 am

Hello,
Thanks for the useful tutorial.
I think there is a minor mistake in the disk selection phase above: vg-root should not be reformatted by the installer, as we already formatted it by hand before.
This is especially important if we had removed the journaling to gain some speed: reformatting will put the journaling back in…
Regards
Antonio

Reply

kriggins May 6, 2012 at 8:31 am

That’s a very good point and thank you for pointing it out. I have run into some problems before with not formatting vg-root during install. Will have to check into that and maybe move the removal of journaling to later in the process.

Kevin

Reply

Micro May 7, 2012 at 3:10 am

Hi
You have written a very good tutorial here and you got me interested to install Backtack on an USB stick. I have two questions tho, you said that 16 GB is the minimum but a normal hard drive install of Backtrack 5 R2 takes up about 18GB so how does that work out?
And if it’s still possible to have Backtrack on a 16GB USB how much room will there be left on the USB? (If I don’t use encryption).

Thanks,
Micro

Reply

PatrickHimebaugh May 8, 2012 at 2:48 am

laptop /Samsung np-rv711 i3 4gb ram /PNY 16gb usb2.0HS M1 Apache.
Backtrack 5r2 Gnome 64

when booting from the LiveCD/USB 8gb Lexor the laptop would Dim and my CAPLOCK LED would blink.(halted hardware) (had to remove the battery, unplug. plugin and press power)

I found that when on Backtrack Boot screen counting down..
press Tab and change.
quiet splash i915.modeset=1 vga=791–
then….
startx

now.. the CDLIVE is slow when installing to usb drive.
So i just used the USBLIVE. this is faster

I had several problems at first.. the fact that you have to restart after partition in fdisk.
if you don’t it causes problems when trying to encrypt the drive.. I had no prior knowledge with linux before so I had to repeat steps over and over again till i got this tutorial to actually work like it is written. this is just a learning experience.

writing the rand 512 encryption took about 40min.
the install took under 2 hours.

took me a min to figure out that i have to type the password in its not going anywhere at the splash screen,PW enter and then f8) sometimes i had to retype the passphrase because of the extra ****.

ok i am now in .. looks good… however When installing anything (e.g open office/libreoffice, google chromium) as a small sized file took FOREVER.. i was shocked LibreOffice that is 139mb.. took over an hour to unpack. my hardware runs faster with 96 processes in Windows for Christ sake. and Bit locker encryption (saving extracting, installing etc.) doesn’t take this long.

Disk space usage… I was disappointed i had 2.4gb -2.0gb Left for storage.
dont think that is enough for what Back Track is designed to do… (e.g. gathering packets/ivs and saving these 2million packets and the others analyst monitoring apts.

Operating Google chromium… i kept getting (waiting for cache) every 2 seconds.. annoying that i had to wait maybe a minuet for the web page to come up..then freeze the wait. then load. then freeze the wait then load. Firefox forget it…. firefox doesnt tell you whats going on. and doesn’t have java or flash preinstalled. it just lags and your just scratching your head….

with 4 processors and running 15% and under…and under 500mb Ram.. you really start to wounder. is there anything I can do to speed this up.. PLEASE… answer is no… I spent a whole day.. thinking ok. what if i uninstall this or delete that. maybe the cache is overran.. what can I do to fix the performance and make this more tolerable. and not so SLOTH like.

Well I noticed with the USB/LIVE its pretty fast. I am agreeing with the fact that the encryption defiantly slows everything down. by 75% in my own opinion.

Overall Performance I am rating a 2.0 out of 10.

don’t get me wrong here I want Encryption.I actually would love to get my hands on Diamond2 but is this really needed. You are loading into and OS to perform tasks.

would it make more sense to have a 3rd partition. ENCRYPTED just for output files or private files to store. or make a separate usb storage drive with high encryption Just for private data captured.

there also seems to be a lot of tweaking to do.. like you really don’t need the whole 535mg boot partition. i tweaked mine to 104mb.

for now I am testing without encryption due to performance issues.

or….

Reply

Patrick Himebaugh May 10, 2012 at 4:31 am

I switched computers to a Netbook

Asus EeePc intell atom 1gb Ram
BTr2 32bit Gnome
8gb Lexor LIVEUSB
16 PNY M1 Attache`

1st take no encryption:
First problem…. None : LIVEUSB loaded extremely FASSSST..
working with connecting online wifi and opening firefox and working with commands was a lot faster.I gave it a 11out of 10 and no errors, black screens, i did not even have to type quiet splash or nothing at boot prompt.. =)

had to do the partitioning twice. this time it wanted a bigger partition from 104mb to 187mb so i set it to +200

now the install….
4:55am
15min= 30% 30min= 52% 45min=65% 60min=70% 75min=93% 83min=100%
1hour and 23min =(

restarted and loaded no errors. took about 2 min though

OK great… now to test out on the Samsung core i3

Reply

Patrick Himebaugh May 10, 2012 at 5:57 am

Amazing I now can use this drive on Multiple Pc’s. Just as i wanted..

I had problems with the graphics again when starting up.
Cap lock blinking display dim.
E….. i tried to change to quiet spash i915.modeset vga=915 gpfpayload=1024×768
seemed to work
once i entered in root and Pw
i typed in
$ dpkg-reconfigure xserver-xorg
$ Startx

and i was in… not performing like the netbook however i noticed the memory steady at 256mb firefox Has to go… that bugged me i would type stuff in and it will just hang for a minuet like i was never typing in anything.. then i back space.. then i couldnt see how far .. then it would finally catch up and just a pain…

not really sure if i really want to atempt the encryption again.. because im rating this 7out of 10 on my samsung.. still a little bit slow.. but a lot better ..lots lots better..

3.5gb left of free space on the PNY….ok if this is the best it will get then I am content.

Reply

PatrickHimebaugh May 9, 2012 at 5:32 pm

ok… Performance is more tolerable without encryption. Ill rate it 6 out of 10 defiantly increased but browsing the web still lags but not as bad as before. and come program install minor glitches.

Like Chromium didn’t load after install. said i cannot use Root..(had to find a fix for that)
space is around 3.4gb-3.0gb so I managed to get an extra gig.

My main Purpose to to have this flash drive install is to have as a tool around my neck and be ready for testing at any given moment. meaning using/finding the nearest computer.
Having the encryption would have been a plus(if lost/stolen)however i cant deal with the p1 386 Speeds.

I am overall pleased however Now I want to branch off this laptop and use another like a netbook. something small Lightweight battery last longer and more solid state.

when i place the flash drive in a netbook( not the computer i set up backtrack on)
The Grub loader comes up asking what do i want to boot into..

I am given several choices and these choices are tailored to my samsung HDD not my netbook..
for example
ubuntu 3.x.x
ubuntu 3.x.x recovery
Memory testing
Windows 7 bootloader (recovered)
Snow Leopard

the netbook just runs xp home

on the netbook When I choose ubuntu 3.x.x. just get a black screen and backtrack does’t load.

Now the only thing i did w/o encryption was set up the partitions 104mb and 15.1gb
and just used the install.sh editing the partitions to /boot and /

now I am probably missing some steps.. and not exactly sure what additional steps I need to do to make this usb drive bootable to work on other computers.

Any suggestions?

if i have to redo this again for the 6th time thats not a problem.

Reply

PatrickHimebaugh May 10, 2012 at 2:00 am

I just love it when Intel makes you believe you have a 64bit OS compatible processor.
Yeah!!! apparently intel Atom is an i686 I thought I read that it was 64bit. it probably is but not compatible with 64bit coded OS’s…

I tested it with a LIVEUSB… so there you go One problem solved
Why I am not able to use the usb install on another computer…

Time to switch to 32bit…. =/ a little disappointing..o well….

Well that was the issue..

Reply

Patrick Himebaugh May 14, 2012 at 12:25 am

Has anyone experienced Speed issues… or is it just me…. I don’t get it…

I have tried these methods
(Live USB with persistent casper-rw partition)
(Live USB with persistent casper-rw file using ( universal usb installer) (
(regular install)
(encrypted install)

None of the above perform at the speeds I would like. I would like the speeds as they are when using just the Live USB.
When I mention speed i’m focusing on start up times. anything you input in the terminal, connecting to a wifi network, to even typing this message.

I ended up installing an encrypted install on my partitioned Hard Drive..and That is the speed I am looking for. there are no issues at all with the encrypted hard drive.

could it be that I am just getting to many errors at start up while its trying to load persistent.

was writing random numbers to the USB another speed issue when trying to load backtrack save data read data cache data.

i have tried using another usb … didnt make a difference.. I really do not believe this is hardware issue.. the only thing i can think of is hardware is that I have intel HD graphics and by typing in i915.modeset=1 it does take a few to error and disable turbographics…but when i type that in with the LiveUSB it zooms past it.

i am kinda lost and a little tired… need someone smarter than me… thanks

Reply

Jimmy May 18, 2012 at 12:29 pm

What class of USB are you using. I upgraded for this install from a Class 4 USB to a Class 10 USB and the results are noticeable. I would have said the class 4 is the same or worse as the live CD but the Class 10 is much faster. From pressing the ON button on my computer to the graphical interface is about 30 seconds. Do your research and get a good class ten USB (or better) and you will see a significant difference in speed.

Reply

Jk May 18, 2012 at 9:42 am

Hello, thanks for the tutorial..
But I think I’ve some problems with booting..

I followed every step in tutorial and didn’t get any problems, but when I stick my 16g usb to laptop and press F12 and select boot: usb stick. After that I get black screen with flashing cursor and nothing else happens.. I’ve tried this tut with 2 different 16g usb sticks and both kde and gnome bt5 r2… Any ideas what I did wrong or is this some kind of bug etc.?

Reply

Jimmy May 18, 2012 at 12:22 pm

Everything is working for me OK but a couple of points and one question. First, some of the updates you have added to this webpage are NOT in the pdf files you reference in the beginning, so that can get confusing. Second, I used wget to update the issue with entering the password and while it fixed the **** problem it created another one. I disabled the splash screen. Now, the commands which are being echoed to the screen go right to the password prompt and get entered there so I still have to hit the enter key to get a clean password prompt. How do I turn the echoing off. I know it’s there for trouble shooting purposes but since everything is working fine I’d like to turn it off. I don’t want to mess up grub so any help here.

Finally, every time I boot it tells me the ext4 journaling has been corrupted and it need to fix it. Is this normal? It’s not caused any problem but it adds to boot time.

Reply

aaaa May 22, 2012 at 2:11 am

BT5 R2 with luks installed. Is possible upgrade cryptsetup to 1.4.2 whithout loose entire installation (i’ve ssd disk and i need to enable trim functionality) ?

Reply

RageyB June 4, 2012 at 4:36 pm

First, nicely written instructions!

Second, the PDF is missing the line “blkid /dev/sdb5 /dev/sdb5: UUID=”2c133ec5-2eb2-4261-b8ee-5f6924b24ee4″ TYPE=”crypto-LUKS””

Third, I don’t know if it’s just me, but a fresh download of BT5R2 did NOT have lvm2 included. It’s easy enough to install, I am just a little surprised since I understand that it is supposed to already be there.

Lastly, any thoughts on changing the splash instead of removing it and maybe be able to prompt for the passphrase within the splash?

Reply

invisible June 6, 2012 at 9:11 am

Hy.
Thanks for this great tutorial.
I followed your steps and it was a success from the beginning
Thanks on more time.
Sorry for the bad english

Reply

Eric June 18, 2012 at 5:15 am

Thank you for this tutorial. I also have a question regarding the size of storage-volume one can make out of an usb. I used a 16 Gb Kingston dataraveler. But df -h shows after the installation that only 3 GB is available.
I used
lvcreate -n root -l 100%FREE vg
stated in the instructions above, but you say one can play around to get bigger size. What commands does one use then?
Regards
Eric

Reply

Dunuin June 19, 2012 at 11:58 am

I’m now at the point where I have to edit the fstab with “vi /etc/fstab”…

This is my file:

aufs / aufs rw 0 0
tmpfs /tmp tmpfs nosuid,nodev 0 0

I’m using sdf5 with c81247a2-a793-48d9-9585-29684936d9b6 as uuid.

What should I type in there?

Reply

Dunuin June 19, 2012 at 12:06 pm

Got it…just had to “chroot /mnt/backtrack5” before…

Reply

iqmaster June 27, 2012 at 11:44 am

Awesome tutorial. Worked the first time.
I just been experiencing some odd problem is when I boot it up it takes sometime to start up. it freezes for about half minute then starts loading kernel options.

Any idea?
By the way, it might be related to that I chose to disable journaling on root filesystem.

Thanks,

Reply

kriggins July 4, 2012 at 5:52 pm

Haven’t seen this and I run with journaling turned off too.

Reply

Jess June 28, 2012 at 11:27 am

In your steps you have a line;

“Make a note of the ID_FS_UUID value which is in italics above.”

There is nothing above this step in italics. I referred to the BT4 instructions to see if there was the same step and there was, also with an output showing what you were referring to in italics. The output with the line needed in italics is missing from the BT5 steps.

Reply

kriggins July 4, 2012 at 5:52 pm

Jess,

Thanks for the heads up. It was a formatting error. The line got munjed together. It is fixed now.

Kevin

Reply

Richard June 30, 2012 at 7:33 am

I just checked back on your tutorial preparatory to taking a run at this process with Ubuntu 12.04 (Precise Pangolin) for a pet project. In the course of reading through the comments, looking for potentially useful, “after-market” info not yet included in your formal instructions (you DO have a bunch of smart readers, who offer nifty ideas), I noted performance complaints, etc. Just a few remarks from by my experience relative to some of the “issues” reported…

System spec reminders about my install so you don’t have to hunt:

– Asus 1018P-PU17-BK netbook (1.66GHz Intel Atom [N455: 1 core – 2 threads], 2GB RAM)
– BT5 installed to 32GB (29.8 *real* GB) Patriot XT (USB 2.0) stick
(with “full” encryption exactly per instructions)
– After initial install and update, the stick had 22GB of free storage per df -h
(implies about 8GB required by install and update)

Note: I added nano ( sudo apt-get install nano ) before doing file edits and updating, ‘cuz vi is not my friend.

I’ve never had to hit F8 to invoke a request from pvcrypt for my password. My boot sequence looks like:

– hit escape a few times to warn the BIOS that I want to choose the drive from which to boot
(it’s an Asus netbook thing)
– give my BIOS boot password (every little bit of security helps)
– pick the flash stick from the boot device menu
– wait for pvcrypt (quick like a bunny) to request my password
(altho’ that console screen is a train-wreck format-wise)
– login to BT in response to prompts
– run startx

I’m the speed-bump at each step, since I have to type stuff. After I type the required bits and hit “Enter,” the system again takes off like a scalded cat. The only speed difference I notice between the BT startup and that of the netbook’s base, Kubuntu Lucid install is the initialization of the desktop. The BT desktop takes about half-again to twice as long to initialize; however, this may just be BT or stick read-speed relative to the HD and have nothing to do with encryption. I don’t have an encrypted, base, HD install of BT against which to compare.

The netbook only supports flash boot from the single USB 2 port on its left-hand side. That drive registers as device sdb. My read-speed is great for a USB 2 stick with (or even without) encryption. The following three, example runs of hdparm show consistent values.

root@bt:~# hdparm -Tt /dev/sdb

/dev/sdb:
Timing cached reads: 1496 MB in 2.00 seconds = 747.95 MB/sec
Timing buffered disk reads: 88 MB in 3.00 seconds = 29.32 MB/sec

root@bt:~# hdparm -Tt /dev/sdb

/dev/sdb:
Timing cached reads: 1506 MB in 2.00 seconds = 753.19 MB/sec
Timing buffered disk reads: 90 MB in 3.06 seconds = 29.38 MB/sec

root@bt:~# hdparm -Tt /dev/sdb

/dev/sdb:
Timing cached reads: 1484 MB in 2.00 seconds = 742.57 MB/sec
Timing buffered disk reads: 90 MB in 3.07 seconds = 29.34 MB/sec

Not bad, since the stick’s manufacturer only promises 25MB/sec. I don’t *notice* any performance differences in general relative to the base, Kubuntu Lucid install on the netbook, once the desktop is up and running. Admittedly, I don’t run VMWare or Eclipse off the BT stick, and I don’t use it for video editing or gaming, but those kinds of programs are pretty far outside the purview of BT. The apps I do run perform without detectable lag, even when writing things like packet streams from multiple wireless AP sources to file.

I know none of this directly resolves anyone’s problems, but it does imply that many of the reported issues are likely related to user inattention during the setup or specific hardware frailties. Using good, (at least) relatively contemporary hardware (my netbook is 2010 hardware) and following the instructions closely seem to be the keys to good, problem-free performance.

I’m going to delay my new project until my new (used HP 6730b – late 2008 hardware) laptop arrives (mid-week next), since I intend to install Precise on it with LUKS encryption and then KDE it. That way I can check out all the little [rolling_eyes]quirks[/rolling_eyes] I may need to self-document prior to trying the on-a-stick approach for Precise/KDE. I’ll holler back once (if) I succeed.

NOTE – Reminder to dd-ers: When I dd my 32(29.8)GB stick to my HD on the netbook, it takes about 18 minutes. That’s a read-stick/write-HD transfer rate of about 27.59MB/sec. Again, I note that using a USB 3 stick might improve that for backing up the stick, even tho’ it wouldn’t enhance my speed for booting BT-on-a-stick on the netbook, since I can only boot using the USB 2 slot.

[Miracle_Max_Voice]Have fun storming the castle![/Miracle_Max_Voice]

Reply

Richard August 24, 2012 at 10:30 pm

Follow-up (late)…

The only expression I fund suitable for the install of Precise and my attempted transformation to KDE is “unmitigated disaster” (in a word, “yikes!”). The new laptop is now wiped of the Precise foolishness – it’ll be Lucid-ly reliable until sump’n WAY better comes screaming down the pike. What can I say? I like KDE.

I certainly won’t be taking a run at doing Precise on-a-stick.

Ending on a happy note, my original BT5 stick boots and runs perfectly on both my netbook and my new laptop (dual cores makes it run uber-quick on the laptop). I’ve also booted it from two “pure” Windows boxes that support boot from USB. Yes, I know people who live on the dark side…I’m married to one. The little woman’s laptop has slower processors than mine but 4 vs. 2 GB of RAM – BT5 stick performance is better on mine. Overall, it looks like processor speed more significantly affects performance than memory, but my sample is small.

Reply

Jimmyd July 3, 2012 at 8:27 pm

I made the mistake of updating my usb install using the BT5 update process. It broke my installation, which was working until I updated it. It now drops me into Busybox after the splash screen with the error that it cannot find vg-root. I tried the steps under Troubleshooting on this page but they don’t work because when I try to rebuild I get the error that update-initramfs is disabled since the CD is running in read-only mode. So my next attempt was to open Luks and backup my file to a disk and then just start over. I can open Luks (key slot 0 unlocked) but when I try to mount that partition so I can read the files I get an error message “unknown filesystem type ‘crypto-LUKS’.” I also tried via the graphical interface which sees that partition but won’t access it.

Reply

kriggins July 4, 2012 at 5:16 am

Jimmy,

The error on executing update-initramfs is usually an indicator that you either the chroot command did not get executed or it didn’t execute correctly. Try the troubleshooting commands again and make sure to execute the chroot command.

Kevin

Reply

jimmyd July 4, 2012 at 11:07 am

Thanks for the tip; it’s still broken though. I’ve tried several different times rebuilding and it still drops me back into Busybox after the splash screen. Both crypttab and fstab look perfect. I don’t get any errors of any kind until in plops me back into Busybox. The only possible issue I see is in grub.cfg. I noticed that the uuid in grub.cfg was different than the ones I used in the other two files. I don’t know if that means anything or not. Is it possible the BT5 upgrade overwrote grub.

Reply

kriggins July 4, 2012 at 5:51 pm

The only other thing I can think of is that the upgrade removed some stuff. In the tutorial there is reference to this happening and the fix is to execute after booting and performing the troubleshooting steps:

apt-get install cryptsetup ecryptfs-utils keyutils

If that doesn’t work, you may be to the point where you have to start over.

Reply

Jimmyd July 7, 2012 at 8:38 pm

That suggestion didn’t work either so started from scratch. The good news is that I was able to recover all my data files from the encrypted partition.

apt-get update
apt-get dist-upgrade
apt-get autoremove

Was what I did that busted it. I’m guessing it was the last line, the auto remove that caused the problem.

I noticed that when I was rebuilding the image after it broke it was calling version 2.6 but when I installed it this time it was calling version 3.6.

Thanks for your time. I’m off to back up right now with dd so I don’t have this issue again.

FInN July 9, 2012 at 12:15 am

root@bt:~# cryptsetup -y –cipher aes-xts-plain –key-size 512 luksFormat /dev/sdb5

WARNING!
========
This will overwrite data on /dev/sdb5 irrevocably.

Are you sure? (Type uppercase yes): YES
Cannot open device /dev/sdb5 for read-only access.

HELP ME PLEASE…….

Reply

kriggins July 9, 2012 at 7:35 pm

I have had this happen with the partition has been mounted automatically for some reason. Try making sure there is no file system on the usb drive before starting or making sure it is unmounted if it has been mounted accidentally.

Reply

syngress July 15, 2012 at 5:46 am

I have samll problem with installation BT5r2.
Everything from this tut* is ok till installation is finished and i try to hit the button “continue testing”.
Then i get system freeze – reset machine is only option i get.

Reply

syngress July 15, 2012 at 6:41 am

It works now ..

Reply

aron July 15, 2012 at 8:31 pm

I dont quite understand and have a couple questions (sorry i am very new to backtrack).

Do i need to use the unetbootin program AND follow the guide? or are they seperate?

Also i dont understand why i need one 16gb stick, and a second either 2gb or backtrack dvd. What is the second used for?

Reply

John July 17, 2012 at 3:30 pm

You need the LiveDVD or “Stick” to install it on the USB Stick. Otherwise you have only a LiveDVD and cant save changes.

Actaully for the BT5R2 I would recommend a 32 GB stick.

Reply

John July 17, 2012 at 2:09 pm

Thanks for the very detailed instructions. I have an issue booting from the created stick after typing in the pass ….. after running the /scripts/init-bottom…

I get the message that sdb5 cannot be mounted:


init: ureadahead main process (421) terminated with status 5
fsck from util-linux-ng 2.17.2
fsck from util-linux-ng 2.17.2
/dev/mapper/vg-root : clean, 404169/1921360 files, 2833618/7684096 blocks
fsck.ext4: device or resource busy while trying to open /dev/sdb5
filesystem mounted or opened exclusively by another program?
Serious errors were found while checking the disk drive for /boot
Press I to ignore, S to skip mounting or M for manual recovery
mountall: fsck /boot [443] terminated with status 8
mountall: Unrecoverable fsck error: /boot
[56.969727] Bad LUN (1:0)
[56.969923] Bad target number (1:0)
[56.970147] Bad target number (2:0)
[56.970379] Bad target number (3:0)
[56.970600] Bad target number (4:0)
[56.970820] Bad target number (5:0)
[56.971039] Bad target number (6:0)
[56.971258] Bad target number (7:0)

after skipping the mounting with S, I can lock in and startx. I can also access the data on the extended partition “File System” but of course the sdb5 is not mounted.

Any idea what is wrong and where I should start trouble shoot.

Reply

syngress July 18, 2012 at 1:54 am

Why, after installing I have 1.6GB of free space on USB Flash Drive 16GB ?

Look : http://i50.tinypic.com/34oy8lv.png

Did i made something wrong ?

Reply

John July 18, 2012 at 8:21 am

No the build is so big… the BT5R2 is quite big.

Reply

chris July 20, 2012 at 4:28 am

Hi followed each step and when I went to boot up from my USB I get to a screen that says (initramfs) and then waits for me to type something. Any idea what I did wrong or what my next step should be?

Reply

syngress July 20, 2012 at 10:55 am

Yep, hit ESC – and type your crypt passwd 😉

Reply

Sam July 27, 2012 at 3:55 am

Hi all,
I have tried installation without encryption (like cikasole has written)

Steps:

#First
fdisk /dev/sdb # use the appropriate drive letter for your system

# delete existing partitions. There may be more than one.

Command (m for help): d

Partition number (1-4): 1

# create the first partition

Command (m for help): n

Command action e extended p primary partition (1-4) p

Partition number (1-4): 1

First cylinder (1-2022, default 1):

Using default value 1 Last cylinder, +cylinders or +size{K,M,G} (1-2022, default 2022): +500M

# create the extended partition

Command (m for help): n

Command action e extended p primary partition (1-4) e

Partition number (1-4): 2

First cylinder (66-2022, default 66):

Using default value 66 Last cylinder, +cylinders or +size{K,M,G} (66-2022, default 2022):

Using default value 2022

# Create the logical partition.

Command (m for help): n

Command action l logical (5 or over) p primary partition (1-4) l

First cylinder (66-2022, default 66):

Using default value 66 Last cylinder, +cylinders or +size{K,M,G} (66-2022, default 2022):

Using default value 2022

# Setting the partition type for the first partition to ext3 Command (m for help): t

Partition number (1-4): 1

Hex code (type L to list codes): 83

# Setting the first partition active

Command (m for help): a

Partition number (1-4): 1

Command (m for help): w

#Second

Ext4 formating both (sdb1 (mount point “/boot”) and sdb5 (mount point “/”)

#Third

mkdir /mnt/BT5
mount /dev/sdb5 /mnt/BT5
mount /dev/sdb1 /mnt/BT5/boot
chroot /mnt/BT5
mount -t proc proc /proc
mount -t sysfs sys /sys

#Fourth

Reboot, and after that… Nothing happens (Doesn’t boot from USB).
Any ideas ?

P.S. I’m really new with *unix, so if You can, please explain step by step

Reply

Sam July 27, 2012 at 3:58 am

Oh, yeah in #Second, after formatting has to be written that I installed Backtrack 5 (of curse) and checked to install bootloader and install to /dev/sdb

Reply

tux_mind July 28, 2012 at 6:08 am

hi, can i suggest an improvement?
in the chroot run:
#apt-mark unmarkauto cryptsetup

this avoid the apt-get dist-upgrade and the apt-get autoclean issue with cryptsetup ( if needed also run it on lvm , i’m not using LVM ).
hope this help.

regards.

Reply

Sam July 29, 2012 at 5:41 am

Anyone can help me ?

Reply

nilotpal August 2, 2012 at 11:48 pm

i have installed back track5 on a laptop n selected the option “erase n occupy whle disk” due to this my win7 has been removed with all other data in my hard drive. Now i want to install win7 again but while trying to boot win7 it does not show up any option and Back Track5 boots as normal. I want to replace Back Track5 with win7…….!
Plzzzz………help me out…..soon…..!

Reply

vertroa August 14, 2012 at 9:26 am

If anyone is wondering this does working fine with backtrack 5 r3.

Reply

kriggins August 14, 2012 at 9:49 am

Thanks for letting my know. Will put a note at the top to that effect.

Kevin

Reply

ToddL August 14, 2012 at 1:52 pm

I didn’t have much luck with in on r3 – when I get to the step of loading the OS on the USB drive (after creating the encrypted FS, etc) ubiquity can see the encrypted volume but none of the other partitions, i.e. the 500M boot partition. fdisk -l clearly shows them all.

Going to give r2 a shot to see if its the release or just a case of pebkac 😉 Only thing that might be a bit different than the instructions is that I’m not allocating the entire USB drive – I’m leaving about 1/2 of it unallocated so that could be confusing things as well (I’ll play with that a bit also).

Reply

ToddL August 15, 2012 at 7:08 pm

Not pebkac – apparently there are some weird conditions where fdisk will create a partition table that can’t be read by whatever ubiquity uses. I saw someone else try gparted and that did the trick for both r2 and r3 (gparted couldn’t read the partition table either).

Reply

muelli September 17, 2012 at 3:10 am

au contraire, mon capitaine!

at least with the F8 pathc, this will not work with BT5R3.
following this manual exactly and applying the patch will result in boot failure, as grub will still want to boot as root=/dev/mapper/vg-root.
even adding the needed luks options manually does not work as the option to enter the passphrase is not displayed.

Reply

muelli September 17, 2012 at 3:22 am

upate: reverting back to the unpatched file and updating initramfs did not solve the problem. still no passphrase prompt. so the problem lies elsewhere.

Reply

mario August 17, 2012 at 3:20 am

I’ve installed and it works on pc which I installed on. But it doesn’t work on any other pc’s – stops at message: cryptsetup: lvm device nam does not begin with /dev/mapper.
What to do?

Reply

Lii August 22, 2012 at 12:55 am

Installed it on a 32GB USB and started it on a Mac OSX 10.6 with SuperGrubDisk. The boot works fine. But once it’s booted, you can hardly work with R3 ’cause it’s very slowly and freezes all the time. e.g. it took about half an hour to set up my network-connection.
R2 worked much better!!

Reply

nobody September 3, 2012 at 7:19 am

Does anyone know how to migrate BT5 with encryption from one USB stick to another? I initially installed on a 16GB but that’s getting a bit full now and would like to upgrade.

Cheers

Reply

Dunuin September 8, 2012 at 11:38 am

Can’t install BT5 RC3 GNOME 64bit to my 32GB Thumbdrive.

I get this Error: http://imageshack.us/photo/my-images/842/screenshotmol.png/

Any ideas?

Reply

mario September 8, 2012 at 11:41 am

maybe you’ve got broken iso file. Try to download it again (or check his checksum).

Reply

Dunuin September 8, 2012 at 11:54 am

Iso checksum was valid. Perhaps a burning error?

Reply

mario September 8, 2012 at 11:56 am

Use unetbootin and write BT to thumbdrive (4GB is enough), start from it and try to install to 32GB thumbdrive.

Reply

jazzycow September 11, 2012 at 1:15 am

I have a Corsair Flash 8GB USB3. When I try to install BT5 r3 I get a message telling me that 8GB isn’t enough space. click continue anyway, but the install fails.

Is 8GB really enough space to do this?

Reply

HG September 11, 2012 at 11:29 am

Greetings Kriggins:

How about a tutorial on making an encrypted usb that dual boots Backtrack and Ubuntu. Or, encrypted Ubuntu with Backtrack installed on Ubuntu. I would like to have both on a USB to do all my work with Linux. Thanks

Reply

sciencetor2 September 11, 2012 at 6:42 pm

I followed your instructions EXACTLY, finished building it, and went to reboot,but when i rebooted to the usb drive, nothing happened, black screen with a little white line waiting to mount an operating system that would never mount. What is going on here?

Reply

muelli September 20, 2012 at 6:54 am

this howto will not work with bt5r3.
if u follow this howto then after booting the kernel the system will drop to busybox because the rootfs cannot be mounted.

Reply

kriggins September 20, 2012 at 12:33 pm

Muelli,

Others have indicated that the how-to works with BT5R3; the only caveat being that an 8GB drive may no longer be big enough. I’m not sure what is causing your problem, but to categorically say that the how-to does not work is a bit over the top and un-true.

Kevin

Reply

spartan September 14, 2012 at 2:49 pm

I followed this tut exactly, but get stuck to this step :
cryptsetup -y –cipher aes-xts-plain –key-size 512 luksFormat /dev/sdb5

After I enter the passphrase twice, I get :
“device-mapper: reload ioctl failed: Invalid argument
Failed to setup dm-crypt key mapping for device /dev/sdb5
Check that kernel supports aes-xts-plain cipher…”

I’m trying to setup a persistent BT5 r3 on a 32gb usb thumb…
Any idea??,

Reply

HG September 18, 2012 at 3:59 pm

Greetings Kevin:

I have successfully compiled backtrack 4 from your instructions in the past. I am thinking about doing it again with backtrack 5r3 however, I have some concerns about the boot sector not being encrypted.

Question- I have been reading a lot about pre-boot authentication. Does ubuntu for Backtrack 4 and 5 provide pre – boot authentication. I have read about keyloggers that can compromise a users password from the Bios using the master boot record and then deleting the keylogger from memory so as to leave no evidence that your password has been compromised. Thanks for anyone that can provide some input on my concerns.

See links below:
http://www.castledragmire.com/Posts/BIOS_Level_Key_Logger
http://www.castledragmire.com/Archive/Posts/Tags/Boot_Loader

Reply

kriggins September 18, 2012 at 8:44 pm

Considering there is nothing on the boot sector but files need to boot, unless of course you save something there, the risk of an un-encrypted boot sector is negligible.

That being said, I cannot answer question as I do not know.

Reply

HG September 20, 2012 at 12:20 pm

Thanks Kevin:

I read the posts above, and with information from your posts and other information gleaned from the Internet, I think the solution is getting pretty clear. It always helps to do a little research and reading before posting. I was being a little lazy. Hopefully my goal of encrypting a dual boot of BT5 r-3 and Ubuntu on 128 GB USB in separate partitions will come to life. 🙂 Done right, pre-authentication and my concern of compromise of the boot sector should not be an issue. Thanks once again Kevin, you keep doing your thing, you are “the man!!”

Reply

carlito September 20, 2012 at 2:07 pm

Another BT5R3(KDE 64) success story here. Great tutorial. Thanks!

Reply

haerick September 22, 2012 at 3:04 pm

hey, did u install it with unetbooting or per dvd?

Reply

DeathSeeker152 September 29, 2012 at 11:49 am

i just used Universal-usb-installer
http://www.pendrivelinux.com/universal-usb-installer-easy-as-1-2-3/
try that if you are having issues

Reply

Patrck_Himebaugh November 9, 2012 at 9:29 am

GNOME 64bit R3 I cant get working.

Samsung 17.3in np-rv711
Intel HD graphics
Intel core i7 vpro
Samsung 128gb SSD 6gb/s
8GB DDR3 pc3 12800s

when partitioning the primary of 500 MB, which creates a 4g boot partition is buggy. i have to use 28 MB which make a 230MB partition, sounds like a Bug with r3.

I get all the way through at the point where I have to edit the fstab with “vi /etc/fstab”…
This is my file:
aufs / aufs rw 0 0
tmpfs /tmp tmpfs nosuid,nodev 0 0

chroot /mnt/backtrack5 again

and I am able to edit it . after I do and follow the rest of the instructions i edit the grub.cfg to how i have to start backtracks

quiet splash i915modeset=1 vga=791

and i just get the INITRAMFS prompt

the fact that initramfs doesnt update with the apt-get I manually edited it and still didnt update.

I have even seen that

pvcrypt /dev/disk/by-uuid/MY UUID none luks

just vanish and never saved.

From dirtyfilthy

Hey dudes, I finally got this howto working with backtrack r3 gnome 64 after battling with it for a solid six hours, (installed off an iso in vmware).
Two things I had to do:
1. make sure /etc/crypttab contains ONLY the line “pvcrypt /dev/disk/by-uuid/UR-UUID-HERE none luks” & delete the comment line starting with #
2. In the chroot environment, before you run the update-initramfs -u you need to install the latest version of cryptsetup from source, get it from here http://code.google.com/p/cryptsetup/downloads/list .Run ./configure, it will complain about dependencies so you need to install them, this is fairly straight forward, if it says it needs the uuid library, apt-get install uuid-dev, etc. The only gotcha here is the version of popt in the repo isn’t new enough, you need to install this from source too , i used the version at http://hpux.connect.org.uk/ftp/hpux/Development/Libraries/popt-1.16/popt-1.16-src-11.11.tar.gz. Once you finally have all the dependencies: ./configure; make && make install;
Then you can finally run update-initramfs -u and it should be all g in the h.

Does sound like a solution congrats on finding a way to get this working

However I have tried on 4 different attempts. I even said Fudge it lets skip the dd if=/dev/urandom of=/dev/sda5

I am thinking its best to work with R2 for this task its seems solid R3 I have noticed seems buggy even when backing up users encrypted accounts on exchange I have had the transfers freeze on my having to run a forced chkdsk on the external drive to get it working again.

Reply

Patrck_Himebaugh November 9, 2012 at 2:09 pm

ok I dont know why now that R2 when creating the first primary partition at 256MB makes a 1.4gb partition ……… SSD drive i guess… unknown issue

Reply

dirtyfilthy September 23, 2012 at 5:18 pm

Hey dudes, I finally got this howto working with backtrack r3 gnome 64 after battling with it for a solid six hours, (installed off an iso in vmware).

Two things I had to do:

1. make sure /etc/crypttab contains ONLY the line “pvcrypt /dev/disk/by-uuid/UR-UUID-HERE none luks” & delete the comment line starting with #

2. In the chroot environment, before you run the update-initramfs -u you need to install the latest version of cryptsetup from source, get it from here http://code.google.com/p/cryptsetup/downloads/list .Run ./configure, it will complain about dependencies so you need to install them, this is fairly straight forward, if it says it needs the uuid library, apt-get install uuid-dev, etc. The only gotcha here is the version of popt in the repo isn’t new enough, you need to install this from source too , i used the version at http://hpux.connect.org.uk/ftp/hpux/Development/Libraries/popt-1.16/popt-1.16-src-11.11.tar.gz. Once you finally have all the dependencies: ./configure; make && make install;

Then you can finally run update-initramfs -u and it should be all g in the h.

Reply

DeathSeeker152 September 29, 2012 at 10:34 am

Hey i don’t know if anyone has posted this or not, but when you get the error message “..the partition table failed with error 16:…” you don’t need to reboot, just make sure that the drive is not mounted, like if there is another icon that looks like a drive, to just to click places, then click on that particular drive then click the unmount button it saves the time of rebooting

Reply

5ha October 5, 2012 at 6:19 am

<<>>

i’m having exactly the same problem. build the stick in virtual box emulator, stick is formatet like correctly, readable and the boot partition should usualy work, but i dont rly get this 😀

Reply

5ha October 5, 2012 at 6:20 am

sry for double post:
“I followed your instructions EXACTLY, finished building it, and went to reboot,but when i rebooted to the usb drive, nothing happened, black screen with a little white line waiting to mount an operating system that would never mount. What is going on here?”

having same issue

Reply

Adam November 10, 2012 at 3:58 pm

I’m having the same issue as well. I’ve tripled checked everything after rebooting multiple times. When I try to boot to the drive after POST it just sits there at a black screen with a blinking cursor. I’m guessing something with grub is messed up as I’m not seeing any boot loader…. btw, I did use the patch file method, but I don’t think it’s getting that far so I don’t think that is the problem. I have done this before with BT5R1 with no problems. I got a new drive and decided to do a clean install with R3. Any ideas?

Reply

devilman October 6, 2012 at 6:32 pm

Tried Bt5R3 here, on 64 gb usb stick.
Apparently it does not asks for the Luks password in the beginning, so it later faults complaining about /dev/mapper/vg-root missing and drops me into busybox.
Any ideas how to fix this?
thanx in advance

Reply

devilman October 7, 2012 at 9:20 am

Just to add infos:
wben i issue upate-initramfs -u
i get the warning about the bad line in /etc/crypttab
i checked it a lot of times and it seems ok to me, but apparently it does not find it.
As said, it does not ask for the password, consequently it cannot access the root dir and comains about not finding it…
Hope someone can help me solve the issue

Reply

Al M October 8, 2012 at 3:10 am

OK, I have done it with few small personal tricks:

1. I created a non-bootable 2GB FAT32 partition at the beginning of thumb drive (and mounted it on /windows in fstab). This will allow the thumb drive to appear innocent on Microsoft operating systems. Otherwise MS-Windows will ask to format the whole drive. I had to find a USB flash that does not have a capacity label. The security experts of companies think that it is an innocent 2GB thumb drive and do not dare to check for hidden Linux partitions!!! They are as lazy as myself. Of course it was necessary to modify /boot to sdb2 in fstab…

I should complain that the default GRUB menu is disabled by default. People want to use memtest86+ from the same USB. I already enabled the GRUB menu for this feature.

But where is the forensic boot loader? The default boot loader screws users’ HDD!!! I do not want SWAP! Who needs a SWAP on HDD as most PCS have 4GB+ memory these days. There is a initrdf.img-3.2.6 in /boot but it is an absolute build; possibly used with original DVD.

I appreciate if you can update your guide to include the original Back-Track menu options i.e:
– No networking enabled
– No Drive or Swap mount
– ….

The GRUB menu options suck.

Thanks

Reply

Al M October 8, 2012 at 3:25 am

Oh. I forgot to mention 3 other personal tricks:

2. I used VMWare player together with “Plop Boot Manager” to install Backtrack to thumb drive in a Virtual Machine. This allows access to online guides. There will be no necessity to print the PDF guide!!!.

3. It is recommended to create a RAMFS mount in fstab to store temporary data of tools such as airodump-ng:
ramfs /mnt/ramfs ramfs size=256m 0 0

4. I created a non-root user for VLC player, Google Chrome, …. and added it to sudoers file.

Reply

X October 10, 2012 at 6:06 pm

Hey there,
I attempted to put 500MB on my sdb1 partition, but the maximum allowed was about 200. 204MB i believe. I continue through almost the end on the how-to, when I came across an error after I attempted the Finish the install.

“Error informing the kernel about modifications to partition /dev/sdb2 — Device or resource busy. This means Linux won’t know about any changes you made to /dev/sdb2 until you reboot — so you shouldn’t mount it or use it in any way before rebooting.”

I’m running this How-To on my VM ware. not sure how well it’s working if i’m getting errors. x[

Reply

Tom Vegard Larsen (@Tv3gard) October 17, 2012 at 4:48 am

hi.

trying out this extremely detailed tutorial as i write.
just one question: do you think it will be any problem by installing fedora (17) on the same usb drive afterwards?

tnx so much for the tutorial 😀

Reply

Tom Vegard Larsen (@Tv3gard) October 19, 2012 at 3:01 am

sorry for double post, but i wanted to ask something about backing up the installation.
since i made the install on a 500GB external harddrive, where the complete installation is about 20-30GB, and the rest is unallocated/free space, will this command make an image file that is 20-30GB or 500GB?:

dd if=/dev/[your device] of=/[destination]/backtrack5USB.img

i guess that i can’t copy the .img to a windows partition or what?

best regards

(in my world, there is no such thing as “stupid questions”. they are just the easiest to awnser)

Reply

kriggins October 19, 2012 at 5:39 am

Hi Tom,

The dd command will copy the entire disk so it is probably not the best method for backing up a hard disk install. However, you can us dd to just grab a partition. I do not know how well that will work for restoring though.

Also, you should be able to install multiple OSes on the same drive.

Kevin

Reply

Tom Vegard Larsen (@Tv3gard) October 19, 2012 at 8:57 am

tnx for the reply.

i just wanted to know how to make a successful backup so i have a easier way to restore/reinstall it if i suddenly did something completely stupid 😀

tnx once again

Reply

Shant Patrick Tchatalbachian November 23, 2012 at 4:53 pm

I’m not sure if anyone else has had this issue but at around 95% during the installation the installer crashes and says it was a Runtime error not sure what to do at this point it keeps crashing every time I’ve tried. Anyone have any suggestions?

Reply

Richarrd man January 2, 2013 at 2:35 pm

PLEASE I AM HAAVING PROBLEMS WITH THIS AS I BELIEVE ITS THE FULL DISK ENCRPYTING PART . SO MY QUESTION IS I AM NEW TO THIS AND WHAT IS FULL DISK ENCRYPTION FOR? IS IT TO PREVENT PEOPLE FROM GOING INTO MY BACKTRACK OR IS IT FOR LIKE WHEN I AM WORKING PEOPLE NOT ATTACKING or like compromising my actions? or wht?

Reply

anony January 12, 2013 at 7:15 am

i don’t get why two usbs are required? could someone explain it please 🙂 (new to backtrack) P.S. I read the other comments regarding this but still didn’t understand

Reply

John Smith February 13, 2013 at 6:43 pm

Because you need 1 USB for your Live install to boot from and another different USB to install to

Reply

Security junky January 13, 2013 at 4:04 pm

Nice tutorial Kevin!
BUT can ANYONE tell me how to make a self destruct option?
I’m a basic programer but not that creative…
I want the next thing on my encrypten disk:
– After 3 password failures, shred the entier disk serval times.
– No cancel option (inpossible… But it should be hard… So no crtl-C.)
– When interupted (shutdown), start shreding after reboot.
– And a panic command to unmount and start the progres when the f’s come in…

– two little ASCII fingers when the disk is f***ed up every boot. Only if its not possible to shred the mointpoint. Otherwise entire disk with zeros would be beter!

Please help!
And I know, many are looking for this!

Reply

IGadget January 14, 2013 at 12:35 pm

I have not read the earlier answers, so this will be as simple as I can make it. A single 16G USB is needed if you are booting from a live DVD. If you have a 4GB – 8GB USB drive that can be the source since the BT5R3 iso is only 3.1GB.

You need something to build from (Source) and something to act as the Destination. The Live build is static and doesn’t support encryption. To get encryption we need to rebuild. When rebuilding you can’t over write your source part way through the operation and expect to still be able to read it.

Analogy:
Imagine, a paper book written in your native language. 10,000 pages and technical. In the beginning is a table of contents and in the back is an index. Tear out those pages, and replace them with something written in elvish. Now give this book to someone who only knows your language. Tell them that you need them to look up where a specific detail is in 3 minutes or you will shoot them in the head.

Does this clarify it for you?

Reply

kranthi January 31, 2013 at 10:29 am

I followed every step as needed to install backtrack 5r3 32bit gnome on a hp 16gb drive. I did not get errors in any step. Its been like 7 hrs straight and the installation is still at 60%. This is very annoyying everytime i try to install backtrack on a usb drive. Is this normal? If not what can i do to speed up the process?

Reply

kranthi January 31, 2013 at 10:40 am

sorry i forgot to mention. im running the whole thing on a dell inspiron 9400 model laptop. I previously tried this tutorial twice on a dell inspiron 1520 and it took about same time to complete the installation.

Reply

Ben February 1, 2013 at 12:29 am

If somebody ever has problems, installing BT3r3 on a encrypted btrfs: the solution is to use klibc-utils and libklibc from the ubuntu precise repository (there is a bug in version 1.5.17 that prevents cryptsetup to mount the disk complaining »unknown fstype«)
I.e.
1. go into the chroot environment
2. download the klibc-debs >1.5.17
3. dpkg -i *klibc*
4. update-initramfs -u

Reply

Adama February 3, 2013 at 12:47 pm

Great tutorial. I got it working ok on BT5 R3 Gnome 64

I did have a little trouble with the /etc/fstab stage – not sure if I made the problem myself but I put the UUID for the encrypted partition (sdb5) on the bottom line for /boot and I was getting the /dev/mapper/vg-root not found problem.

Once I corrected this to use the UUID from sdb1 it worked fine – it may have actually had the sdb1 UUID originally before I changed it to the sdb5 one but I will never know now!

My only issue is the performance is really sluggish (not your problem of course). I’m using a 16GB Kingston Datatraveller. I’m just now trying to decide whether the encryption benefit is worth the drop in responsiveness of the OS. It takes forever to respond to commands issued.

Thanks for a great setup guide though.

Reply

John Smith February 13, 2013 at 6:40 pm

Hi, I have done this many times but never tried the backup command with DD ( dd if=/dev/[your device] of=/[destination]/backtrack5USB.img )

I have followed your method but instead for installation to HDD, not USB (I have also done the USB though – great tutorial btw)
Can you please confirm from your statement ‘You will need to have free space available on the target drive equivalent to the size of the USB drive’ Do you mean if my hdd with the encrypted install is 350gb and I want to save a backup image I need a 350gb minimum drive to send the backup to OR do you mean I need a drive equivalent to the size of the current space used on the drive eg. 8gb used by BT5 for the install?
Any help is greatly appreciated

Reply

John Smith February 13, 2013 at 6:46 pm

I apologise, I just read through all the questions and comments and answered my own question. I should probably have read through it all first. Thanks

Reply

M.V February 28, 2013 at 11:07 am

Hi!
Thanks for sharing. I’m interested in installing the backtrack r3 64-bit on a sd card (or an usb stick), but i’m really afraid of all this partitioning, since i had big problems after installing ubuntu once. I’m wondering, could you do the same with a partition managing tool? Why do we need partitions anyway? Why can’t we install it just like here
http://askubuntu.com/questions/170454/can-i-install-ubuntu-to-my-32-gb-usb-pen-drive/170456#170456
since backtrack is ubuntu based?
Thanks!
Mile

Reply

kriggins February 28, 2013 at 12:46 pm

If all you want to do is get Backtrack on an SD card, there is a builtin installation routine which will get that done. Remember that this how-to is about making sure that we are installing on an encrypted partition. The builtin routine does not do that.

Kevin

Reply

M.V February 28, 2013 at 2:54 pm

Thank you very much and have a nice day!

Reply

GeorgeW March 7, 2013 at 2:43 pm

Thanks for all this work. I now have a BT5R3 persistent, bootable USB with “full” volume encryption. Excellent work.

I had to make one minor change to get it to work on multiple systems. Right at the end, when you make the suggestion:

“To make the system boot to the console, edit the /boot/grub/grub.cfg file, search for the word ‘splash’, without the quotes, and delete the word splash and only that word. The line will end up looking like this:

linux /vmliunx-3.2.6 root=/dev/mapper/vg-root ro text vga=791”

I had to change it slightly to deal with different laptops that may load the system, by adding “i915.modeset=1” to just before the vga=791. Otherwise, one of the laptops I tried it on went into kernel panic, complete with blackscreen and flashing Caps Lock key.

so the new line was like this:

linux /vmliunx-3.2.6 root=/dev/mapper/vg-root ro text i915.modeset=1 vga=791

Thanks again!

Reply

yolo March 28, 2013 at 9:49 am

#If you happen to get an error that mentions something like “..the partition table failed with error 16:…”, you need to reboot before continuing with the how-to.# after reboot “missing operating system”.

Reply

g May 11, 2013 at 2:54 pm

Hi
I’ve followed all the instructions, all seems fine. I reboot, and get prompted for the passphrase, and that seems fine. Once into KDE, when I try to view the encrypted drive though, i get the message “‘Volume (crypto_LUKS)’ needs a password to be accessed. Please enter a password.” I enter the password, dont get an error, but still cant access the drive.
“/dev/sdb5” at the Terminal, give me the error “bash: /dev/sdb5:Permission denied”.
Any thought on what might be wrong?

Reply

DrearNevada4 May 13, 2013 at 9:47 am

Hey! I have a copy of Backtrack R3 x64 GNOME and a 16 GB usb drive, when I try to create a live usb using unetbootin, all the process goes fine but when I try to boot it, it says that BOOTMGR is missing. Any Help???
oh….and I am using Inspiron 5521 if it helps…..
Note: I’ve installed R2 x32 using the same software and it worked like charm but that was almost a year ago…….but it was on a 4GB usb.
Thanks in Advance

Reply

Henri June 25, 2013 at 7:30 am

Well, just dd-ing the ISO to a thumbdrive and then ‘booting’ the MacBook with ‘option’ key pressed let me select EFI-boot an BOOM! it was there

Reply

Silent August 24, 2013 at 11:42 pm

I did everything and have the same problem with “unknown filesystem type” in grub after reboot 🙁

Reply

Richard August 28, 2013 at 12:12 pm

So, it finally happened. After installing a package that I oughtn’t, I needed to restore my flash image from my latest dd snapshot. Restoring the flash stick with dd worked like a charm, BUT…writing TO the stick takes about five times as long as writing FROM. Considering how much time I’ve spent tailoring the BT install and tweaking things, that’s still WAY better than starting from scratch, but for my 32GB stick it takes about 2.5 hours to restore.

For the new readers, I remind all that my flash stick is USB 2. I picked it as cheaper by a factor of 2 at the time of purchase – back when USB 3 was young, since the only USB port from which I can boot on the box I usually use does not support USB 3. However, I reiterate an earlier expression of curiosity as to whether a USB 3 stick might be better for doing the dd process.

Related note on being impatient and needing a visual update on dd status… I installed pv ( apt-get install pv ). Backing up and restoring the stick from the backup image is now managed (in scripts) by the commands:

dd if=/dev/sdb | pv | dd of=/home/richard/xbtbu/pxt32.iso (backing up)

and

dd if=/home/richard/xbtbu/pxt32.iso | pv | dd of=/dev/sdb (restoring)

For the curious or novice reader, /dev/sdb is always the device reference for my flash stick, when I’m doing either the backup or restore operation, and “xbtbu” is for “eXternal BackTrack BackUp” with “pxt32” being my “Patriot XT 32” gigabyte flash drive. The raw, console-oriented output of pv is not a terribly sophisticated display, but it’s enough to reassure me that progress IS being made.

Reply

Daniel K September 4, 2013 at 9:38 am

I was having trouble determining which drive I should be partitioning and was hoping I would be able to get some help. Wasn’t sure if I should be using sda or sdb. Any and all help would be appreciated.
root@bt:~# dmesg | egrep hd.\|sd.
[ 0.064003] NMI watchdog enabled, takes one hw-pmu counter.
[ 0.148069] NMI watchdog enabled, takes one hw-pmu counter.
[ 1.452795] sd 0:0:0:0: [sda] 312581808 512-byte logical blocks: (160 GB/149 GiB)
[ 1.452808] sd 0:0:0:0: Attached scsi generic sg0 type 0
[ 1.457692] sd 0:0:0:0: [sda] Write Protect is off
[ 1.460155] sd 0:0:0:0: [sda] Mode Sense: 00 3a 00 00
[ 1.460214] sd 0:0:0:0: [sda] Write cache: enabled, read cache: enabled, doesn’t support DPO or FUA
[ 1.658894] sda: sda1 sda2
[ 1.661698] sd 0:0:0:0: [sda] Attached SCSI disk
[ 2.399765] forcedeth 0000:00:0a.0: highdma pwrctl mgmt lnktim msi desc-v3
[ 3.050288] sd 6:0:0:0: Attached scsi generic sg2 type 0
[ 3.050741] sd 6:0:0:0: [sdb] 31309824 512-byte logical blocks: (16.0 GB/14.9 GiB)
[ 3.052991] sd 6:0:0:0: [sdb] Write Protect is off
[ 3.053243] sd 6:0:0:0: [sdb] Mode Sense: 23 00 00 00
[ 3.055963] sd 6:0:0:0: [sdb] No Caching mode page present
[ 3.056239] sd 6:0:0:0: [sdb] Assuming drive cache: write through
[ 3.063009] sd 6:0:0:0: [sdb] No Caching mode page present
[ 3.063271] sd 6:0:0:0: [sdb] Assuming drive cache: write through
[ 3.065005] sdb: sdb1
[ 3.071980] sd 6:0:0:0: [sdb] No Caching mode page present
[ 3.072300] sd 6:0:0:0: [sdb] Assuming drive cache: write through
[ 3.072528] sd 6:0:0:0: [sdb] Attached SCSI removable disk
[ 14.021313] sdhci: Secure Digital Host Controller Interface driver
[ 14.021318] sdhci: Copyright(c) Pierre Ossman
[ 14.131690] sdhci-pci 0000:02:05.1: SDHCI controller found [1180:0822] (rev 22)
[ 14.131928] sdhci-pci 0000:02:05.1: PCI INT B -> Link[LNK2] -> GSI 7 (level, low) -> IRQ 7
[ 14.132961] sdhci-pci 0000:02:05.1: Will use DMA mode even though HW doesn’t fully claim to support it.
[ 15.406405] snd_hda_intel 0000:00:07.0: PCI INT A -> Link[LAZA] -> GSI 21 (level, low) -> IRQ 21
[ 15.406410] hda_intel: Disabling MSI
[ 15.406475] snd_hda_intel 0000:00:07.0: setting latency timer to 64

Reply

omsasak November 25, 2013 at 11:41 am

nice tutorial..

but I have a question,Does It possible installing Backtrack on Portable Hard drive ?

Reply

deathgrin February 2, 2014 at 10:00 pm

DeathGrin

Hey Kevin thanks for the tutorial its awesome, but how do i format the usb drive after encrypting it? so i can use it as a regular usb again?

Thank you

Reply

Daniel January 15, 2015 at 6:41 pm

How to create a bootable Flash is very helpful to me. Thank you for sharing your knowledge with me.

Reply

spiked October 16, 2013 at 2:31 pm

Great article thanks!!

Reply

Leave a Comment

{ 26 trackbacks }