Find the answer to your Linux question:
Results 1 to 3 of 3
Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1

    Post Moving location of applications


    Hi Guys,

    I am playing with debian & ubuntu at the moment (which I am loving).

    I am wondering how I can change the location of applications. For example, if I want to move Firefox and/or the whole X system to another partition or drive and then run it from there (eg, a RAID array /dev/md1).

    I am looking at the prospect of increasing response time for certain apps.

    Can this be done?

    Thanks in advance

  2. #2
    That can be done although it would only speed up the loading of the program and not execution speed of the program once it is running.

    To do what you are asking, I suggest copying the entire contents of the /usr directory to the other drive and then editing /etc/fstab to mount the other drive on /usr. This will move almost all of your applications to the faster drive which should actually be simpler to do and maintain then just moving some of them.

    The actual steps for doing this are a little more involved. A simple skeleton of the steps is given below to get you started.
    You will first need to mount the RAID array on some directory (let's say /mnt/tempusr),
    Code:
    $mkdir -755 /mnt/tempusr
    $mount /dev/md1 /mnt/tempusr
    Copy the complete file structure from /usr to /mnt/tempusr,
    (Note that I am assuming /dev/md1 is already formatted but empty. If this is not the case then the steps I am suggesting are not right for your situation).
    Code:
    $cp -pr /usr/* /mnt/tempusr
    or
    Code:
    $rsync -aHS /usr/ /mnt/tempusr
    Rename /usr,
    Code:
    $mv /usr /usr-old
    Backup the original fstab file,
    Code:
    $cp /etc/fstab /etc/fstab.backup
    Edit /etc/fstab so that the RAID array device will be mounted on /usr at boot time. You will need to investigate what to add/edit here because it will depend on your setup and objectives. The new line should be similar to:
    Code:
    /dev/md1      /usr     ext4    defaults    1 2

  3. #3
    Awesome, I'll give that a try.

    And yes, I am aware this will only affect load times and not actual application speed.

  4. $spacer_open
    $spacer_close

Posting Permissions

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