How do i get my root access back? i cant even get in using the login prompt as a normal user but i can access it on console mode(ctrl+alt+F1), i tried as a single user but its the same. everytime i try to get a root access (su) heres what i get.
setgid: operation not permitted
and the output from the login prompt even if i change DE
GDM could not write to your authorization file. This could
mean that you are out of disk space or that your home
directory could not be opened for writing. In any case, it is not
possible to log in. Please contact your system administrator.
heres what happen after losing the permission. check svn of choqok. i put a couple of flash drives, copy/transfer files, change permissions of directories. installed cmake and i know that there still a couple of gigs left so i know that is not yet out of disk space.
Last edited by skip on 08 Jul 2009, 09:29, edited 1 time in total.
login console mode (ctrl+alt+F1) and type startx, or init 1 after that type init 5. you should get a graphical environment
If sudo works you can try sudo su - to get a root terminal
EDIT:
can you post what linux dist you are running?
seems "changing permissions" caused this problem.....if you are able to login as root via terminal (or login as user and su to root) check the file permissions of /etc/password and /etc/shadow
/etc/password should have -rw-r--r-- (644)
/etc/shadow should have -rw-r----- (640)
if not, chmod them....
also check in /etc/fstab if the drive which contains the home directory is mounted with read-write permissions (rw) or read-only (ro)...it should be "rw", if not change it.
bb: Tried on a single user to access root on maintenance and it worked. i change the file permissions of /etc/passwd to 644 and /etc/shadow to 640. i also checked the fstab but i changed the permission of the drive where the root is mounted, from ro to rw. I can edit the fstab, startx runs as well before i change permissions on passwd, shadow and fstab. after that and a reboot. i think it got worse. i cant modify fstab, it says read only file system. startx wont even run.
hm, fstab looks ok, but the error you got when trying to start X points to a permission problem.....login as root, cd to / and give tmp 777 permissions with setting the sticky bit:
best check if there are subdirectories in tmp, if yes also chmod 1777 them (don't do chmod -R 1777 because the sticky bit has a different function for directories and files).
if still problems appear post the output of ls -al of the / directory.
hm, I am not too familiar with that feature and what problems it might cause....but if there is a general problem with the file system or the HDD fsck will find it...
Could not start the X
server (your graphical environment)
due to some internal error.
Please contact your system administrator
or check the syslog to diagnose.
In the meantime this display will be
\disabled. Please restart GDM when
the problem is corrected.
or like these errors? they appear every time i boot up. should i post them all?
Starting periodic command scheduler: cron/user/sbin/cron: cant open or create /var/run/crond.pid: Read-only filesystem It will ignored in the future release
failed!
Enabling additional executable binary formats: binfmt-supportWARNING: All config files need .conf : /etc/mod/probe.d/display_class,
WARNING: All config files need .conf: /etc/mod/probe.d/blacklist. It will ignored in the future release
WARNING: All config files need .conf: /etc/mod/probe.d/pnp-hotplug. It will ignored in the future release
.
Cannot create /var/run/kdm/Xaccess
and the output for fsck when i put it in the console
I tried the rescue option and change the permissions of passwd and shadow to 777 and the /tmp to 1777 and its subdirectories, but i cant change anything on fstab using vi, the cursor (blinking square) wont go down. After that, its still wont go inside even if i type startx. same errors. Which folders or files should i change? what other options should i do?
I can go inside the gui before i change the permissions but i turned it back (i think) and now it wont go inside.