Logo 
Search:

Unix / Linux / Ubuntu Forum

Ask Question   UnAnswered
Home » Forum » Unix / Linux / Ubuntu       RSS Feeds

Can't find my Home directory

  Date: Dec 12    Category: Unix / Linux / Ubuntu    Views: 710
  

My upgrade from Ubuntu 8.04 to 8.10 did go well and on top of that I
had changed some file permissions (by GUI) in my home director. As a
result of the mess-up I decided to recover a backup my original 8.04
'/' partition and the separate 'home' partition. Unfortunately I was
forced, to reformat my original home partition before the backup
program would do the restore.

First I edited the /etc/fstab to update the UUID on the new partitions
as follows;-

# Entry for /dev/sdb3 :
UUID=4c3172bd-f447-41f1-a4c9-84c4da6ba86e / ext3
defaults,errors=remount-ro 0 1

# Entry for /dev/sdb5 Ubuntu-home:
UUID=cc2d397d-8148-48fc-9037-d95bca8ccce0 /home ext3
defaults,errors=remount-ro 0 1


After the login screen on boot up I get 'your home directory is
listed /home/username but does not appear to exist'

I have made several attempts at chown, chmod on /home/username .dmrc
and .ICEauthority.

If I look in /home on 'sdb3 labelled Ubuntu' it is completely empty,
is this normal? On sdb5 labelled 'ubuntu-home' I have the usual
directories 'lost & found' 'Recycled' and 'username'. Every thing
inside 'username' seems OK but I am not certain that the permissions
set are all correct.
There seems to be a missing connection/permission from /home on root /
to 'home/username' separate partition I am the only user.
Can I fix this without a complete reinstall? I would appreciate any help.

Share: 

 

7 Answers Found

 
Answer #1    Answered On: Dec 12    

I assume that you are booting and logging in normally to another
account? Or that you can login with no home? (I have not tried that in
years and don't remember what the results are in Linux, some Unices
allow it.) If you are booting from a live CD, the following commands
will have to be modified.

What does "grep username /etc/passwd" give? I get:

jbuchana@flenser$ grep jbuchana /etc/passwd
jbuchana:x:1000:1000:Jim Buchanan,,,:/dp1/home/jbuchana:/bin/bash

NOTE: I do not have my home in the standard location.

Then if you take the location of the home from the passwd file and
list the directory, what do you see? I get:

jbuchana@flenser$ ls -ld /dp1/home/jbuchana
drwxr-xr-x 135 jbuchana jbuchana 4096 2009-02-24 16:13 /dp1/home/jbuchana

if you don't have the directory, that is the problem. Otherwise, if
you post the above information, we can see if we can provide further
help.

 
Answer #2    Answered On: Dec 12    

You just showed us that your /home was on /dev/sdb5 not sdb3 ...
Is your home partition mounted as expected ??? You may well be
looking at the mount point alone...

Check output of "df" does it show /dev/sdb5 mounted on /home ?

If not, you might not have the correct UUID. Just try the following
command : sudo blkid . It will show the correct UUID of your
partitions. Correct your fstab and do a "sudo mount /home". It should
be OK!

 
Answer #3    Answered On: Dec 12    

I have found the following via #shell
booting in recovery mode from grub:

1 "grep walter /etc/passwd"
walter:x:1000:1000:Walter,,,:/home/walter:/bin/bash ..agree OK

2 "ls -ld /home/walter
drwxr--r-- 71 walter walter 4096 2009-02-25 11:13 /home/walter
..permissions?

3 "df -h" ...yes /dev/sdb5 is mounted as /home

4 "blkid" does confirm UUIDs

5 "mount /home" ...gives 'according to mtab /dev/sdb5 is already
mounted /home'

So far so good except for the permissions in 2 are different. I hope
that helps to take it further.

Furthermore, should there be an entry in / as /home, which is empty?
Is there a confusion here with /home in two places? What should I
expect to see in / with respect to 'home'?

 
Answer #4    Answered On: Dec 12    

That looks good the permissions should not be a problem, I'm going to
have to think about it some more.

What does "ls -l /home/walter" produce? No need to tell us the names
of any files or directories listed, just a general description would
do.

 
Answer #5    Answered On: Dec 12    

Having an empty /home directory on /dev/sdb3 is perfectly normal. You
are looking at the mount point for the disk that contains the
filesystem of your /home. That's what fstab is supposed to do: mount
the drive /dev/sdb5 over /home so that you see it as an normal
directory. And it looks it's not working, but you tell me that ubie
tells you that the filesystem is mounted. That's what puzzle me.

Do you see any messages about sd5 or home from the command "dmesg".
You could try : dmesg|egrep 'sd5|home|mount|filesystem|ERROR'

And check that the permissions on your /home are the following:
drwxr-xr-x user=root group=root.
The execute bit must be turned on for all if you want to be able to
access sub-directories.

If I list the permission of the device that contains my home
filesystems, it shows this:

pluton log # ls -ailgd /dev/sda3
3378 brw-r----- 1 disk 8, 3 Feb 21 12:40 /dev/sda3

My fstab entry for home shows this:
# /dev/sda3
UUID=ffffffff-ffff-ffff-ffff-ffffffffffff /home ext3
relatime 0 2

 
Answer #6    Answered On: Dec 12    

I'm making some progress at last , back to # terminal via
recovery mode:
ls -l /home/walter

listed all directories drwxr--r-- 5 777 boot (744)
and files -rw-r--r-- 1 777 files... (644)

So these may not be correct and need sorting out.

However I did a chmod -R 755 /home rebooted and got that haunting
drum role back

 
Answer #7    Answered On: Dec 12    

I'm making progress and permissions do seem to be the
problem, this is how I have progressed:

dmesg|egrep 'sd5|home|mount|filesystem|ERROR'
ext3-fs: mounted fs with ordered datamode

the permissions on ls /home :
drw-r--r-- 2 777 root 4096 Feb..... Recycled (644)
drw-r--r-- 777 root 16304 Jan..... Lost & Found (644)
drwxr--r-- 71 walter walter 4096 Feb..... walter (744)

ls -ailgd /dev/sda5 :
3378 brw-rw--- 1 disk8 21 Feb 27 /dev/sdb5 (/home
part'n 660 yours were 640)
brw-rw--- 1 disk8 ......... /dev/sdb3
(/ partition) 660)

fstab entry for home /dev/sda5 :
UUID=.................................................... /home ext3
defaults, errors=remount -ro 0 1

The /home permissions don't look right. You said I needed drwxr-xr-x
= 755 on the home partition so I did :-

chmod -R 755 /home and got the following:
drwxr-xr-x 2 777 root 4096
drwxr-xr-x 777 root 4096 Recycled, also Lost & Found
drwxr-xr-x 71 walter walter 4096 walter


Well I rebooted and got that haunting drum role back and into my long
lost system, so nearly there.
I see above the disk permissions may not be quite correct but how do I
change those?.

Some programs and functions would not run so I do not have correct
permissions in some areas yet, and got the following errors which
suggests I need more write/execute permissions.

Error 'can't overwrite existing read only value /apps/deskbar/keybinding
.........................................................................../apps\
/gnome-settings

I did a search but could not find /apps, could you hlep me to locate
and correct this?

I appreciate the help from yourself and Jim and have now got my
system nearly there.
If any of the above suggests I can further resolve the permissions
with your help it would be most appreciated. Would there be a better
command/routine to reset all the permissions to default value?

 
Didn't find what you were looking for? Find more on Can't find my Home directory Or get search suggestion and latest updates.




Tagged: