-   Linux - Software (
-   -   only root can login (

piratas 09-05-2009 11:21 PM

only root can login
I built a customized root file system based on Ubuntu 9.04 (built for ARM), then I found that I can only login as root. When login as other user, it shows last login time and then immediately goes back to login prompt.

I guess this is a privilege related issue, but I checked every file and directory i can think of, they all seems have right privileges.

The /var/log/auth.log shows no error, but login session close immediately after it opened.

Sep 6 03:48:39 myhost login[1336]: pam_unix(login:session): session opened for user newuser by LOGIN(uid=0)
Sep 6 03:48:39 myhost login[1336]: pam_unix(login:session): session closed for user newuser

Any ideas? Thanks.

AlucardZero 09-06-2009 12:59 AM

does the user's shell exist? what is it?

piratas 09-06-2009 01:13 AM

Thanks for the reply AlucardZero.

I don't think shell has been executed.

The default shell is bash, I put "date > ~/login.txt" in the bottom of .bashrc , but nothing happened.

piratas 09-06-2009 07:19 PM

BTW, what's the procedure of login?

fotoguy 09-08-2009 04:19 AM

Ok you have a customized version, did you add any user to the new root filesystem? if you did, did you do it by the command line or a graphical program. If you did it by the command line, you may have not added the default login shell, or home directory for that user

There may also be some of the programs that are required for a user to login which may not be installed. check and make sure you have files /etc/passwd /etc/shadow /etc/group.

It may also be a permission problem, make sure that the users home directory exists, and is read/write/executable by the user. If no home directory is given, it will default to / (root), and since this is only accessable by root, it may force you back to the console and not login.

piratas 09-09-2009 09:26 PM

Thanks for all you guys.
The issue turned out to be a kernel specific problem.

This is clipped from

####### change vm security settings
# Due to changes in vm security a change must be made in /etc/sysctl.d/10-process-security.conf.
# vm.mmap_min_addr should be set to 32768 (This change is safe for any kernel version).
# If this is not done it is likely that you will not be able to login remotely.
# Although you should still be able to login as root on the main console.

Changing vm.mmap_min_addr to 32768 fixed my problem.

Thanks to cbxbiker61, who pointed this out.

Wim Sturkenboom 09-09-2009 10:55 PM

Thanks for the feedback. I'm sure it will be highly appreciated by other people who run into the same problem in future.

I suggest that you mark your thread as solved using the thread tools just above the opening post.

All times are GMT -5. The time now is 04:25 AM.