Page 3 of 8 FirstFirst 12345 ... LastLast
Results 21 to 30 of 80

Thread: HOWTO GUIDE: TrueCrypt on new version of Ubuntu

  1. #21
    Join Date
    Jun 2005
    Location
    Finland
    Beans
    84
    Distro
    Ubuntu 9.10 Karmic Koala

    Re: HOWTO GUIDE: TrueCrypt on new version of Ubuntu

    Yes, you will have to compile it again. But you dont need to update at once to a new kernel if u dont want to? I know its a pain, on my older box (P4 1.6 Ghz) compiling the kernel and modules takes about 2 hours

    I also noticed as I installed Truecrypt on 2 fresh Dapper Drake boxes today that I needed to manually add "truecrypt" in /etc/modules, just running install.sh wasnt enough - Truecrypt just told me "kernel module not loaded" after running install.sh and rebooting. Then I did "sudo modprobe truecrypt", started working, so decided to add it in modules. Now works.
    Last edited by Mr.Auer; June 1st, 2006 at 07:59 PM.
    Anyone can do any amount of work provided it isn't the work he is supposed
    to be doing at the moment.
    -- Robert Benchley

  2. #22
    Join Date
    May 2006
    Beans
    17

    Re: HOWTO GUIDE: TrueCrypt on new version of Ubuntu

    Reading all the comments on this thread (thank you all for your responses and offers to help), I think that ultimately getting truecrypt to work is too much of a hassle.
    I use the windows version of it and that works with zero trouble. I see no reason why the linux version should put us through this much hassle.
    Since I'm not a linux hacker, I want to do a simple apt-get and expect it to work. There will at some stage be a nice guy who knows linux and makes a package that works. I will wait until this angel comes along.

  3. #23
    Join Date
    Jun 2006
    Beans
    Hidden!

    Mounting truecrypt volumes through a boot script

    Hi there,

    I've got truecrypt 4.2 running on Ubuntu Dapper Drake 6.06 and am interested in running a script at boot time to mount two truecrypt volumes. It should be run before I log in, since I would like to mount one of the volumes to /home.

    The problem is that I'm not entirely sure that it's possible to run interactive scripts (i.e. one which prompts the user for a password) as part of the system startup scripts. In Fedora Core 5 it was possible without any problems.

    Here is an example of the script which I have tried without success to run:

    #! /bin/sh
    #
    # This script was generated by The Ubuntu Linux Startup Script Builder
    # version 1.5 located at http://rob.pectol.com/startup_scriptbuilder/.
    #
    # Generated: Mon Jun 5 05:23:28 MDT 2006

    PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin

    if [ -r /lib/lsb/init-functions ]; then
    . /lib/lsb/init-functions
    logbegin="log_begin_msg"
    logend="log_end_msg"
    else
    logbegin="echo -n"
    logend=`printf "echo .\n"`
    fi

    # Exit if the daemon binary is NOT available, executable, etc.
    test -x /usr/local/bin/truecrypt || exit 0

    # Start function
    d_start() {
    /usr/local/bin/truecrypt -u /dev/hda3 /mnt/shared
    /usr/local/bin/truecrypt -k /mnt/shared/home.keyfile /dev/hda7 /home
    }

    # Stop function
    d_stop() {
    /usr/local/bin/truecrypt -d
    }

    case "$1" in
    start)
    $logbegin "Mounting Truecrypt Volumes"
    d_start
    $logend $?
    ;;
    stop)
    $logbegin "Dismounting Truecrypt Volumes"
    d_stop
    $logend $?
    ;;
    restart)
    $0 stop
    sleep 1
    $0 start
    ;;
    *)
    log_success_msg "Usage: truecrypt.sh {start|stop|restart}"
    exit 1
    ;;
    esac
    exit 0

    =====

    The problem is getting the password prompt to work for the first mount - I never get prompted during the Ubuntu boot. Has anyone had any success with this at all? Are there any other ways of entering a truecrypt password to mount the volume as part of the startup process?

    Thanks,

    Hamilton

  4. #24
    Join Date
    May 2006
    Beans
    Hidden!

    Re: HOWTO GUIDE: TrueCrypt on new version of Ubuntu

    First thank you for this nice howto.

    I would like to know if Tuecrypt can mount scramdisk containers.

    I tried to install Scramdisk (SD4L) (has a nice GUI), but the program doesn't mount containers, and the options window doesn't show completely.
    (there are a few errors during 'make' and 'make install')

    Does anyone has successfully installed SD4L in ubuntu 6.06 2.6.15-23-386?

    TIA.

  5. #25
    Join Date
    Apr 2006
    Beans
    5

    Re: HOWTO GUIDE: TrueCrypt on new version of Ubuntu

    I've had problems compiling the kernel
    *** Warning: Can't handle masks in drivers/net/wireless/mrv8k/mrv8k:1385
    LD [M] drivers/net/ndiswrapper/ndiswrapper.ko
    make: Leaving directory `/usr/src/linux-source-2.6.15'

    I found that if I removed and reinstalled the linux-sources that the problem fixed itself fine.
    aptitude purge linux-source-2.6.15
    aptitude install linux-source-2.6.15
    cd /usr/src
    tar xvjf linux-source-2.6.15.tar.bz2
    ln -s linux-source-2.6.15 linux

  6. #26
    Join Date
    Aug 2006
    Location
    USA
    Beans
    163
    Distro
    Ubuntu 6.10 Edgy

    Re: HOWTO GUIDE: TrueCrypt on new version of Ubuntu

    The .deb is now available for Ubuntu 6.06 at Truecrypt.org
    Dell Inspiron 1150 Celeron 2.6

  7. #27
    Join Date
    Aug 2006
    Beans
    6

    Re: HOWTO GUIDE: TrueCrypt on new version of Ubuntu

    The .deb from truecrypt site does not work for me.. looks like i386 I use i686 kernel

  8. #28
    Join Date
    Aug 2006
    Beans
    93

    Re: HOWTO GUIDE: TrueCrypt on new version of Ubuntu

    Do you have to repeat this howto each time you update your kernel? How often does Ubuntu updates kernel? Like once a month?

  9. #29
    Join Date
    Dec 2005
    Location
    Colorado, US
    Beans
    145
    Distro
    Ubuntu 14.04 Trusty Tahr

    Re: HOWTO GUIDE: TrueCrypt on new version of Ubuntu

    Every time you update the kernel, you must rebuild the kernel module, otherwise it won't be able to load the module and truecrypt will spit out an error when you try to mount something.
    It doesn't seem like they created a script that will compile only the kernel module while still updating your kernel .config file.

    I finally got this to compile correctly for the 686 kernel after looking inside the build.sh script and finding that it was not using the current running kernel config, but instead an older one that was left in the /usr/linux-source-2.6.15/.config from one of my previous kernel compiles.
    Doing a make oldconfig was bad in my case since the older config wasn't for the currently running 686 kernel. First, I had to do a make clean inside the linux source directory.
    Then, I finally figured out to copy /boot/config-$(uname -r) to /usr/src/linux/.config . (with $(uname -r) evaluating to 2.6.15-27-686, and the symlink /usr/src/linux pointing to /usr/src/linux-source-2.6.15 in my case)


    The problem arose from this part in the build.sh script:
    Code:
    if [ ! -f "$KERNEL_SRC/.config" ]
    then
    	if [ -f /proc/config.gz -o -f /boot/config-$(uname -r) ]
    	then
    		echo -n "Configure kernel source according to the currently running kernel? [Y/n]: "
    		read A
    		if [ -z "$A" -o "$A" = "y" -o "$A" = "Y" ]
    		then
    			echo -n "Configuring kernel source in $KERNEL_SRC... "
    			
    			if [ -f /proc/config.gz ]
    			then
    				zcat /proc/config.gz >$KERNEL_SRC/.config || exit 1
    			else
    				cp /boot/config-$(uname -r) $KERNEL_SRC/.config || exit 1
    			fi
    			
    			make -C $KERNEL_SRC oldconfig </dev/zero >/dev/null || exit 1
    			echo Done.
    		fi
    	fi
    
    	if [ ! -f "$KERNEL_SRC/.config" ]
    	then
    		error "Kernel not configured. You should run make -C $KERNEL_SRC config"
    		exit 1
    	fi
    fi
    This part in the script makes it so it only asks you if you want to configure using the currently running kernel's config when it doesn't find a .config file there already!
    This won't usually cause problems assuming that for every different kernel version you'd have a separate folder for it: (ex: linux-source-2.6.15-27-686, linux-source-2.6.15-27-386, linux-source-2.6.15-26-386). That way there would be a separate config file in each one, and the script would use it by default.
    However, it seems ubuntu keeps the kernel config separate from the base source tree. So for every kernel version or revision, there is just the one source tree. The actual config files for the different kernel versions (686, 386, k7), and revisions are kept in their respective /usr/src/linux-headers-<REVISION>-<VERSION>/.config files.

    I'd have the script ask all the time whether or not you want to use the current kernel's config instead of only when one isn't found.
    It is safe to remove that outermost if statement (or comment out the if, then and fi) so that it asks every time, but still dies if no .config file is found if you were to say no, or the copy commands failed. I've just tested it and it worked for me, but I don't want people blaming me if it somehow breaks their system, so I don't guarantee anything

    So a fix would be to replace the code with this:
    Code:
    	if [ -f /proc/config.gz -o -f /boot/config-$(uname -r) ]
    	then
    		echo -n "Configure kernel source according to the currently running kernel? [Y/n]: "
    		read A
    		if [ -z "$A" -o "$A" = "y" -o "$A" = "Y" ]
    		then
    			echo -n "Configuring kernel source in $KERNEL_SRC... "
    			
    			if [ -f /proc/config.gz ]
    			then
    				zcat /proc/config.gz >$KERNEL_SRC/.config || exit 1
    			else
    				cp /boot/config-$(uname -r) $KERNEL_SRC/.config || exit 1
    			fi
    			
    			make -C $KERNEL_SRC oldconfig </dev/zero >/dev/null || exit 1
    			echo Done.
    		fi
    	fi
    
    	if [ ! -f "$KERNEL_SRC/.config" ]
    	then
    		error "Kernel not configured. You should run make -C $KERNEL_SRC config"
    		exit 1
    	fi
    So: if you are having problems with truecrypt complaining about the wrong kernel module or 'unknown symbols', then try doing what I did, or edit the script.
    If that still fails, try simply uninstalling all linux-source and linux-headers packages for your current kernel, go into the /usr/src/ directory and `sudo rm -r` any folders that stuck around (only the ones that have your current kernel version of course), then re-install from synaptic the linux-source and linux-headers packages.

    If you haven't edited the script, you should be able to hotwire it by making an empty .config file in your source directory too, then choosing to use the current running kernel's config.

    Hope this helps all the people who have been able to compile everything ok, but are getting those kernel module errors.
    Last edited by TrinitronX; October 3rd, 2006 at 11:56 PM.

  10. #30
    Join Date
    Sep 2006
    Location
    Washington, DC
    Beans
    85
    Distro
    Kubuntu 9.04 Jaunty Jackalope

    Question Re: HOWTO GUIDE: TrueCrypt on new version of Ubuntu

    I'm having a spot of trouble with this.

    I was running truecrypt on Kubuntu 6.06 (Dapper) with NVIDIA and all was good with the world.

    Then I did the dist-upgrade to Kubuntu 6.10 (Edgy) a few weeks ago, and truecrypt stopped working (because of the kernel change to 2.6.17 I assume). NVIDIA drivers kept right on working however. At no point did I try to change or update my video drivers or play with the new beryl or compiz stuff for Edgy.

    So I tried to install the Ubuntu 6.10 .deb file from truecrypt.org, and of course that didn't work. Next I uninstalled everything truecrypt related and followed the excellent instructions on this forum to build the truecrypt kernel modules and everything worked great!

    Then something bad happened after I shutdown my laptop - NVIDIA threw an error about loading the kernel module, and xwindows will no longer start for any window manager (KDE, E17, Fluxbox). But truecrypt still works from the CLI.

    I tried force reinstalling the NVIDA drivers, but no luck. My next step tonight is to download the vanilla Ubuntu 6.10 kernel and try to get my video drivers back in shape.

    My question at large is - has anyone else had this problem? It seems to me that there was some conflict between the kernel for 6.10 settings script that the truecrypt installer used and the NVIDIA kernel modules, but it's all just a little bit more technical than I am.

    Any advice would be appreciated - I'm going to keep banging away on this for another day or two before just formatting and starting with a clean Edgy install.

    Thanks,

    - Jon Pruett
    --| There is serenity in Chaos.
    --| Seek ye the Eye of the Hurricane.
    --| http://montanamax.net

Page 3 of 8 FirstFirst 12345 ... LastLast

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •