Cannot enter home directory. Using /

Hi all.

After a reboot today (kernel update, but had started OK the first time after this), my user account is not longer able to login.
Things I’ve tried/established so far:
-I’ve fscked the partition
-the home directory and its permissions look fine, and I did a chown -R just in case.
-Affects login via KDM to KDE and IceWM (returns Cannot enter home directory. Using /), and also TTY1 (which returns change directory failed: permission denied )
-Root is fine in X and terminal
-I created a totally new user, with same result, so seems unlikely it’s just my normal user home

I’m a bit stumped. I’d rather not do a full reinstall if anyone has any ideas?

Thanks, Alex

NVIDIA driver?
See here: openSUSE 12.3 Release Notes

Sorry, somehow I overlooked this:

Could you please post the output of:

ls -la /home

In addition: please also post output of

mount

Wow,thanks for the speedy replies.
i’m just heading out and its powered down so will have to be a ltlle later wth tge further details, but:

  • No nvidia -intel 3000
  • ls -la home looked normal when i did it before ( permission all relevant users)
  • didnt see anything crazy in mounts either.

will post full outputs later on

while we’re at it, also


cat /etc/fstab

And check that the home partition is not full:

df

But I guess you have done that already?:wink:

On 05/31/2013 11:56 AM, agt499 wrote:
>
> - didnt see anything crazy in mounts either.

and, none of /home /var / are near full?


dd

Hi All.

Outputs below, and nothing obvious to me -space and permissions look OK, mount output is loaded but as I seldom check it out I figure that’s normal?

So I’ve got below for you:

  • ls -la /home /data/home (main user profile is on the /data partition - /home in root contains test users -u3 being freshly created with this prob. No users except root can log in)
  • mount
  • cat /etc/fstab (note part 3 is the windows system partition which I don’t mount)
  • df
  • df
  • du -hs /home /data/home /var

Thanks again!

GERTY:~ # ls -la /home /data/home
/data/home:
total 16
drwxr-xr-x  4 root root     4096 Mar  5 22:07 .
drwxr-xr-x 18 agt  pvtusers 4096 May 22 10:11 ..
drwxr-xr-x 61 agt  pvtusers 4096 May 31 20:16 agt

/home:
total 20
drwxr-xr-x  5 root root  4096 May 31 23:38 .
drwx------ 28 root root  4096 May 31 23:36 ..
drwxr-xr-x 26 u1   users 4096 Mar  1 19:10 u1
drwxr-xr-x 23 u2   users 4096 Apr 17 15:44 u2
drwxr-xr-x  7 u3   users 4096 May 31 20:58 u3

GERTY:~ # mount
devtmpfs on /dev type devtmpfs (rw,relatime,size=3973772k,nr_inodes=993443,mode=755)
tmpfs on /dev/shm type tmpfs (rw,relatime)
tmpfs on /run type tmpfs (rw,nosuid,nodev,relatime,mode=755)
devpts on /dev/pts type devpts (rw,relatime,gid=5,mode=620,ptmxmode=000)
/dev/sda1 on / type ext4 (rw,noatime,data=ordered)
proc on /proc type proc (rw,relatime)
sysfs on /sys type sysfs (rw,relatime)
securityfs on /sys/kernel/security type securityfs (rw,nosuid,nodev,noexec,relatime)
tmpfs on /sys/fs/cgroup type tmpfs (rw,nosuid,nodev,noexec,mode=755)
cgroup on /sys/fs/cgroup/systemd type cgroup (rw,nosuid,nodev,noexec,relatime,release_agent=/usr/lib/systemd/systemd-cgroups-agent,name=systemd)
cgroup on /sys/fs/cgroup/cpuset type cgroup (rw,nosuid,nodev,noexec,relatime,cpuset)
cgroup on /sys/fs/cgroup/cpu,cpuacct type cgroup (rw,nosuid,nodev,noexec,relatime,cpuacct,cpu)
cgroup on /sys/fs/cgroup/memory type cgroup (rw,nosuid,nodev,noexec,relatime,memory)
cgroup on /sys/fs/cgroup/devices type cgroup (rw,nosuid,nodev,noexec,relatime,devices)
cgroup on /sys/fs/cgroup/freezer type cgroup (rw,nosuid,nodev,noexec,relatime,freezer)
cgroup on /sys/fs/cgroup/net_cls type cgroup (rw,nosuid,nodev,noexec,relatime,net_cls)
cgroup on /sys/fs/cgroup/blkio type cgroup (rw,nosuid,nodev,noexec,relatime,blkio)
cgroup on /sys/fs/cgroup/perf_event type cgroup (rw,nosuid,nodev,noexec,relatime,perf_event)
cgroup on /sys/fs/cgroup/hugetlb type cgroup (rw,nosuid,nodev,noexec,relatime,hugetlb)
systemd-1 on /proc/sys/fs/binfmt_misc type autofs (rw,relatime,fd=26,pgrp=1,timeout=300,minproto=5,maxproto=5,direct)
mqueue on /dev/mqueue type mqueue (rw,relatime)
hugetlbfs on /dev/hugepages type hugetlbfs (rw,relatime)
tmpfs on /var/lock type tmpfs (rw,nosuid,nodev,relatime,mode=755)
tmpfs on /tmp type tmpfs (rw,nosuid,nodev,noexec,relatime)
debugfs on /sys/kernel/debug type debugfs (rw,relatime)
tmpfs on /var/run type tmpfs (rw,nosuid,nodev,relatime,mode=755)
fusectl on /sys/fs/fuse/connections type fusectl (rw,relatime)
/dev/sda4 on /d2 type fuseblk (rw,nosuid,nodev,noexec,relatime,user_id=0,group_id=0,default_permissions,allow_other,blksize=4096)
/dev/sda2 on /data type ext4 (rw,noatime,data=ordered)
vmware-vmblock on /var/run/vmblock-fuse type fuse.vmware-vmblock (rw,nosuid,nodev,relatime,user_id=0,group_id=0,default_permissions,allow_other)
vmware-vmblock on /run/vmblock-fuse type fuse.vmware-vmblock (rw,nosuid,nodev,relatime,user_id=0,group_id=0,default_permissions,allow_other)
none on /var/lib/ntp/proc type proc (ro,nosuid,nodev,relatime)
gvfsd-fuse on /run/user/0/gvfs type fuse.gvfsd-fuse (rw,nosuid,nodev,relatime,user_id=0,group_id=0)
gvfsd-fuse on /var/run/user/0/gvfs type fuse.gvfsd-fuse (rw,nosuid,nodev,relatime,user_id=0,group_id=0)

GERTY:~ # cat /etc/fstab
/dev/disk/by-id/ata-ST750LX003-1AC154_W200JLQY-part1 /                    ext4       noatime,acl           1 1
/dev/disk/by-id/ata-ST750LX003-1AC154_W200JLQY-part2 /data                ext4       noatime,acl           1 2
tmpfs                /tmp                 tmpfs nodev,nosuid,noexec,mode=1777 0 0 
proc                 /proc                proc       defaults              0 0
sysfs                /sys                 sysfs      noauto                0 0
debugfs              /sys/kernel/debug    debugfs    noauto                0 0
devpts               /dev/pts             devpts     mode=0620,gid=5       0 0
/dev/disk/by-id/ata-ST750LX003-1AC154_W200JLQY-part4 /d2                  ntfs-3g    users,uid=agt,gid=pvtusers,fmask=133,dmask=022,locale=en_US.UTF-8 0 0

GERTY:~ # df
Filesystem     1K-blocks      Used Available Use% Mounted on
devtmpfs         3973772        44   3973728   1% /dev
tmpfs            3990320        68   3990252   1% /dev/shm
tmpfs            3990320       872   3989448   1% /run
/dev/sda1       25805692   8721656  15773164  36% /
tmpfs            3990320         0   3990320   0% /sys/fs/cgroup
tmpfs            3990320       872   3989448   1% /var/lock
tmpfs            3990320        20   3990300   1% /tmp
tmpfs            3990320       872   3989448   1% /var/run
/dev/sda4      203031548  22383040 180648508  12% /d2
/dev/sda2      433492760 156541848 254930664  39% /data

GERTY:~ # du -hs /home /data/home /var
207M    /home
2.1G    /data/home
du: cannot access ‘/var/lib/ntp/proc/8527/task/8527/fd/4’: No such file or directory
du: cannot access ‘/var/lib/ntp/proc/8527/task/8527/fdinfo/4’: No such file or directory
du: cannot access ‘/var/lib/ntp/proc/8527/fd/4’: No such file or directory
du: cannot access ‘/var/lib/ntp/proc/8527/fdinfo/4’: No such file or directory
1.6G    /var

Hm, strange setup you have there… Why don’t you just symlink /home to /data/home or mount /home as separate partition?

Are you sure, your user’s home directories are correctly set?
Check /etc/passwd for that…

My attention is drawn to your fstab:

On 2013-05-31, agt499 <agt499@no-mx.forums.opensuse.org> wrote:
> GERTY:~ # cat /etc/fstab
> /dev/disk/by-id/ata-ST750LX003-1AC154_W200JLQY-part1 / ext4 noatime,acl 1 1
> /dev/disk/by-id/ata-ST750LX003-1AC154_W200JLQY-part2 /data ext4 noatime,acl 1 2
> tmpfs /tmp tmpfs nodev,nosuid,noexec,mode=1777 0 0
> proc /proc proc defaults 0 0
> sysfs /sys sysfs noauto 0 0
> debugfs /sys/kernel/debug debugfs noauto 0 0
> devpts /dev/pts devpts mode=0620,gid=5 0 0
> /dev/disk/by-id/ata-ST750LX003-1AC154_W200JLQY-part4 /d2 ntfs-3g users,uid=agt,gid=pvtusers,fmask=133,dmask=022,locale=en_US.UTF-8 0 0

I cannot see where your /home partition is mounted. If it’s the same as `/data’, I wonder why you don’t just call it
/home? Or is there something obvious I’m missing?

Your /home looks like this:


drwx------ 28 root root  4096 May 31 23:36 ..

So, no access to anybody but root (which doesn’t need /home, since /root is it’s user folder.

The best solution is to mount the partition mounted on /data/ on /home instead.

EDIT: that would be


/dev/disk/by-id/ata-ST750LX003-1AC154_W200JLQY-part2 /home ext4 noatime,acl, user_xattr 1 2



On 05/31/2013 02:06 PM, agt499 wrote:
> So I’ve got below for you:
>
> - ls -la /home /data/home (main user profile is on the /data
> partition - /home in root contains test users -u3 being freshly
> created with this prob. No users except root can log in)
> - mount
> - cat /etc/fstab (note part 3 is the windows system partition which
> I don’t mount)
> - df
> - df
> - du -hs /home /data/home /var

so, anytime i see that someone has gotten creative with their disk
layout i have to ask: Why?

i ask because a default openSUSE install would have a df output kinda
like this:


linux-os114:~ # df
Filesystem           1K-blocks      Used Available Use% Mounted on
rootfs                20641788   7953212  11639952  41% /
devtmpfs                497332       248    497084   1% /dev
tmpfs                   502844         4    502840   1% /dev/shm
/dev/sda6             20641788   7953212  11639952  41% /
/dev/sda7            108696520  41228672  66473980  39% /home
linux-os114:~ #

you might notice that /home has its own partition (sda7), named
home…and, i have to wonder why and how yours got to be different…

i’m not saying there is anything ‘wrong’ with it, but frankly i can’s
see what the problem is without understanding…

and, please show us the terminal output and input, as well as the
beginning prompt and exit prompt, from

lsb_release
-sircd

copy/paste the in/output back to this thread using the
instructions here: http://goo.gl/i3wnr

ok, so i admit your set up has me a little confused.


dd
http://tinyurl.com/DD-Caveat

Hm, no. Those are the permissions for ‘/’. (‘…’ is the parent directory, which is / for /home ;))
But yes, I think they should be drwxr-xr-x as well.

Edit: Well, maybe /tmp and /var/tmp have wrong permissions as well?
Try to run “chkstat --system --set”

The best solution is to mount the partition mounted on /data/home on /home instead.

I agree, but it seems he wants to use the directory home on the partition /data for that.
He would have to create a new partition.
That’s why I suggested a symlink…

On 2013-05-31, flymail wrote:
> I cannot see where your /home partition is mounted. If it’s the same
> as `/data’, I wonder why you don’t just call it /home?

On 2013-05-31, wolfi323 wrote:
> Hm, strange setup you have there… Why don’t you just symlink /home to
> /data/home or mount /home as separate partition?

On 2013-05-31, DenverD wrote:
> you might notice that /home has its own partition (sda7), named
> home…and, i have to wonder why and how yours got to be different…

On 2013-05-31, Knurpht wrote:
> The best solution is to mount the partition mounted on /data/ on /home
> instead.

It looks like 4/4 are in near-agreement! Somethings wrong :o! What’s changed?? :smiley:

On 2013-05-31, wolfi323 <wolfi323@no-mx.forums.opensuse.org> wrote:
>> The best solution is to mount the partition mounted on /data/home on
>> /home instead.
> I agree, but it seems he wants to use the directory home on the
> partition /data for that.
> He would have to create a new partition.
> That’s why I suggested a symlink…

Phew! Dissent at last :D.

Here’s what /home should look like, no matter whether it’s a mount point or the “real” home folder:


# ls -ld /home
drwxr-xr-x 10 root root 4096 29 mei 21:12 /home

A thing the OP could do, is add this to /etc/fstab (at the end)


/home    /data/home    bind   defaults,bind   0 0

I agree. But his /home does look like that: (both of his homes look like that, to be exact :wink: )

Yup, I misread the output. My wrong.
I thiink though, that using fstab is better than symlinking /home.

To be able to traverse directory user needs “x” bit on this directory. Having 700 on / means that no user is able to access any file below /, unless user starts from some lower level directory already.

When user tries to access /foo/bar/baz, system checks permissions of every component. /, /foo and /foo/bar all must have “x” bit for this user, otherwise user gets permissions denied.