Page 1 of 2 12 LastLast
Results 1 to 10 of 15
  1. #1
    cablewinderuperer personthingy's Avatar
    Join Date
    Dec 2004
    Location
    The hovel.
    Posts
    2,564

    Talking Linux - /home/me on a portable HDD?

    Hello peoples,
    I'm wondering if i can avoid alot of complications by running /home/me on a portable HDD?

    My ex laptop HDD is now travelling with me, USB cable attached, and i figure that if i can get both my machine, and the one i am a frequent guest on to recognise sda1 as /home/me , then i can save alot of hassle.

    Mepis comes close to offering what i want with the "on the go" username, which effectively, from what i can gather, is "CDRW disk = /home/on the go"

    I'm not sure if this is a new Mepis thing, or a new KDE thing, but it is teasingly close to being exactly what i want.

    Unfortunatly there was no option to make an on the go disk on anything other than a CDRW

    So anyways..... What does one have to do to make /home/me work from the portable USB HDD? Are there any drawbacks to this, apart from the obvious that if i lose my portable HDD, i will be back to the last backup of /home/me ?

  2. #2
    Senior Member
    Join Date
    Jan 2005
    Posts
    1,366

    Default Re: Linux - /home/me on a portable HDD?

    Edit the fstab. Something like

    /dev/??? /home ext3 rw 2 2

    Drawback is that you must remember to plug the USB at boot otherwise init gets very confused.

  3. #3
    Pedant and proud of it
    Join Date
    Dec 2004
    Location
    Christchurch
    Posts
    6,047

    Default Re: Linux - /home/me on a portable HDD?

    There is no problem ... except potential confusion. You can mount any disk or directory (with loopback) using /home/me as the mount point. Whatever is in that (mount point) directory disappears as long as the other is mounted. All operations are performed on the mounted directory.

    You don't need to change /etc/fstab, though this will enforce the presence of the external device on your "home" computer. It might be best not to on computers other than your two. You can use the mount command as required.

  4. #4
    Senior Member
    Join Date
    Jan 2005
    Posts
    1,366

    Default Re: Linux - /home/me on a portable HDD?

    Quote Originally Posted by Graham L
    There is no problem ... except potential confusion. You can mount any disk or directory (with loopback) using /home/me as the mount point. Whatever is in that (mount point) directory disappears as long as the other is mounted. All operations are performed on the mounted directory.
    Irrelevant to the original question.

    Quote Originally Posted by Graham L
    You don't need to change /etc/fstab, though this will enforce the presence of the external device on your "home" computer. It might be best not to on computers other than your two. You can use the mount command as required.
    Try booting without a valid /home and see what happens. Init must know where the /home is, otherwise it may just boot in the root account or worse. The only ways to do this is via the fstab, or of course, by passing an option into the boot routine, such as boot: /home = /dev/???. The fstab is much easier.

  5. #5
    Pedant and proud of it
    Join Date
    Dec 2004
    Location
    Christchurch
    Posts
    6,047

    Default Re: Linux - /home/me on a portable HDD?

    Sorry. Highly relevant. That's what Chris wants to do.

    Who needs a "valid /home" to boot? It's a bit essential to have a home directory, such as /home/chris for chris to log in. But the OS doesn't need users, or user home directories to start up. It doesn't "boot in the root account or worse". How would it do that? Linux does what it's told. It just puts up a login prompt on my machines. Wimpy GUI users might have problems, though I'm sure that would just start X Window, and put up a login prompt page. It won't need a home directory until it is told which user want to log in. Anyway, there is one. Chris wants to mount another device on his home directory -- referred to as "/home/me" . That's the mount point for his external device. That directory would have the standard '.' files put in it when the user was created. If the external isn't there, it will happily allow "me" to log in, and use the files present there. If the external has been mounted, "me" can log in and use the files on it.

    It is perfectly legal and reasonable to log in as root, mount the portable disk, then log in as a "user". It's not essential to have an entry in fstab.

  6. #6
    Debiant Myth's Avatar
    Join Date
    Feb 2005
    Location
    DFT
    Posts
    5,409

    Default Re: Linux - /home/me on a portable HDD?

    Quote Originally Posted by Graham L
    Sorry. Highly relevant. That's what Chris wants to do.

    Who needs a "valid /home" to boot? It's a bit essential to have a home directory, such as /home/chris for chris to log in. But the OS doesn't need users, or user home directories to start up. It doesn't "boot in the root account or worse". How would it do that? Linux does what it's told. It just puts up a login prompt on my machines. Wimpy GUI users might have problems, though I'm sure that would just start X Window, and put up a login prompt page. It won't need a home directory until it is told which user want to log in. Anyway, there is one. Chris wants to mount another device on his home directory -- referred to as "/home/me" . That's the mount point for his external device. That directory would have the standard '.' files put in it when the user was created. If the external isn't there, it will happily allow "me" to log in, and use the files present there. If the external has been mounted, "me" can log in and use the files on it.

    It is perfectly legal and reasonable to log in as root, mount the portable disk, then log in as a "user". It's not essential to have an entry in fstab.
    Would not his choice of Desktop Environment also be of importance? I think he mentioned he uses KDE right, which in turn uses kdm by default to signin. KDE hates root logins and will need a home account before it will allow a user signin. IIRC
    (morganj): 0 is false and 1 is true, correct?
    (alec_eso): 1, morganj

  7. #7
    Gentoo Addict
    Join Date
    Dec 2004
    Location
    Hunched over a keyboard.
    Posts
    262

    Default Re: Linux - /home/me on a portable HDD?

    Another option is to install a linux distro in the usb hard disk, along with a bootloader. This is only an option if both the computers allow you to boot of a usb HDD, and if your Hard Disk is big enough. Also the advantage with this is that you can perform updates to the system without burning another cdrom.

    This is just an alternative - just giving ideas
    # cat sig.txt | http://pressf1.co.nz/sig.php --set

    -- iLikeLinux

  8. #8
    Pedant and proud of it
    Join Date
    Dec 2004
    Location
    Christchurch
    Posts
    6,047

    Default Re: Linux - /home/me on a portable HDD?

    Quote Originally Posted by Tazz
    ... KDE hates root logins and will need a home account before it will allow a user signin.
    So? Tough. Linux will boot. A real OS doesn't need users to boot.

    The account exists. That's independent of the user's home directory, (which doesn't have to be in the /home tree ... it can be anywhere it's been put.) The OS is told where in the /etc/passwd entry for the user.

    Sure, KDE, Gnome, etc need the "dot"files in the user's directory to see configuration. bash, and other command line interpreters, will probably run happily on its defaults.

    You could log in as a user, using the "fixed" home directory, then mount the external disk over it. It probably wouldn't crash.

    However, thinking about it, I would not do it exactly like this. There are various files which are updated (invisibly) in the user home directory. I think I would make another directory (mount point), say, "/portable" and mount the external disk to that. Then in the user's login script, have a couple of lines to mount the external disk, and if that has been successful, "cd /portable". That way, the system can do what it wants to do in the user's home directory, and all other files live in the portable directory. (I suppose, for "consistency", the mount point could be put in the /home tree, but without creating a user of that name. ) (Or even /home/me/portable )

  9. #9
    cablewinderuperer personthingy's Avatar
    Join Date
    Dec 2004
    Location
    The hovel.
    Posts
    2,564

    Talking Re: Linux - /home/me on a portable HDD?

    Quote Originally Posted by Tazz
    Would not his choice of Desktop Environment also be of importance? I think he mentioned he uses KDE right, which in turn uses kdm by default to signin. KDE hates root logins and will need a home account before it will allow a user signin. IIRC
    Latest version of mepis seems to be quite happy to allow root logins, although the highly updated versions before it progressivly found more and more ways to refuse graphical login as root....

    And yes Mepis comes with KDE, and thats what i prefer to use.

  10. #10
    cablewinderuperer personthingy's Avatar
    Join Date
    Dec 2004
    Location
    The hovel.
    Posts
    2,564

    Talking Re: Linux - /home/me on a portable HDD?

    Anyway... putting aside if it's possible... lets assume that it is, so back to the original question....

    I'd like 2 machines to both be able to see /sda1 as /home/me... or some variation on that theme..

    What do i have to change to make this so, preferably done in such a way that i simply plug in the USB HDD, and log in as user "me" and the system will allways go happily to /sda1 as the space where /home/me gets its files from?

    What exactly must i edit and where?
    Somewhere in the debate over if it would work, i've totally failed to grasp what i must change to try this concept.


Similar Threads

  1. Home partition Linux
    By kjaada in forum PressF1
    Replies: 6
    Last Post: 11-08-2007, 01:34 PM
  2. Linux - Moving /home to new /home
    By personthingy in forum PressF1
    Replies: 3
    Last Post: 05-03-2006, 02:20 PM
  3. LINUX home server
    By hamstar in forum PressF1
    Replies: 6
    Last Post: 04-01-2004, 01:28 PM
  4. Home network XP to Linux
    By in forum PressF1
    Replies: 4
    Last Post: 13-06-2002, 04:16 PM
  5. Linux /home
    By in forum PressF1
    Replies: 0
    Last Post: 04-07-2000, 06:50 PM

Posting Permissions

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