Results 1 to 5 of 5

Thread: redirected home folder

  1. #1
    Join Date
    Jan 2010

    Question redirected home folder

    Some background info:
    In the interest of privacy and saving space, I've relocated my home directory as such:
    /dev/sda1 / 15G
    /dev/sda2 swap 8G
    /dev/sda3 /datastore 1.66T

    /etc/passwd records my home directory as /home/<myusername> but I've moved it to /datastore/<myusername> and put a (dereferenced) symbolic link in its place.
    i.e. I own the link, not root

    lrwxrwxrwx 1 myusername myusergroup 21 May 4 10:05 myusername -> /datastore/myusername

    Here is a noob question.
    When I open a terminal, my prompt is:
    pwd: /datastore/myusername

    What I want is my prompt to be:
    pwd: /home/myusername

    I don't want any hint that my home directory is other than where it ought to be.
    any ideas?

    p.s. my .bashrc is unaltered so I have not posted it here
    Last edited by AIM Systems; August 8th, 2013 at 02:27 PM. Reason: corrected permissions on home folder

  2. #2
    Join Date
    Mar 2005
    Isle of Bute, Scotland
    Ubuntu Gnome 14.04 Trusty Tahr

    Re: redirected home folder

    Could you post the results of the following:
    sudo fdisk -l
    Running 14.04 on my HP Pavilion g6 4 Gig Ram 320 Gig Disc

  3. #3
    Join Date
    Nov 2008
    Sheffield, UK

    Re: redirected home folder

    You'd be a lot better off moving home to the other partition

    Makes your next install a lot nicer easier too

  4. #4
    Join Date
    Dec 2005
    Western Australia
    Ubuntu 12.04 Precise Pangolin

    Re: redirected home folder

    What you need to do is to mount /dev/sda3 into /home and change /etc/passwd back to what it should be (because your home directory will be literally mounted under /home/<username>

    So, change the /etc/passwd entry, go into /etc/fstab and create a new line there mounting /dev/sda3 to /home/ and reboot.
    I try to treat the cause, not the symptom. I avoid the terminal in instructions, unless it's easier or necessary. My instructions will work within the Ubuntu system, instead of breaking or subverting it. Those are the three guarantees to the helpee.

  5. #5
    Join Date
    Jun 2009
    SW Forida
    Ubuntu 16.04 Xenial Xerus

    Re: redirected home folder

    I use data partitions but link the folders in the data partitions back into /home.

    The actual user settings are small. My /home is 2GB with most of that as .wine with Picasa which I have not yet moved to my /data. Because /home is small I now keep it as part of / (root).
    Then I can have a fully functioning system on one drive but have data linked in from other partitions on other drives.

    Data can be shared without the possible conflicts of user settings being different in different versions. I only copy some settings from one install to the next, normally. But I have to separately back up /home and the /data partition. Also saves the error of reformating a /home partition accidentally. I never reformat my /data and just configure / for install.

    Splitting home directory discussion and details:
    Link is on move home but see post by bodhi.zazen on data partition #6
    Severals posts on size of / and use of linking to data partition.
    For more info on UEFI boot install & repair - Regularly Updated :
    Please use Thread Tools above first post to change to [Solved] when/if answered completely.

Tags for this Thread


Posting Permissions

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