Today while was I transferring one of my Debian partitions to another hard drive using “tar” command, I happened to get the following message when I tried to boot from the hard drive on which I moved my partition.

Server authorization directory (daemon/ServAuthDir) is set to /var/lib/gdm but does not exist. Please correct GDM configuration and restart GDM.

It was a standard Debian Lenny install with GNOME and GDM as graphical environment. If you are also getting the error message it is likely because of directory permission issues. Don’t try to do anything else before you have absolutely made sure that your permission are sane. Here is an example of why this happened.

On the offending system I did an:

#ls -l /

Output:

drwx------ 2 root root 4096 2009-08-19 16:58 bin
drwxr-xr-x 3 root root 4096 2009-08-17 16:34 boot
lrwxrwxrwx 1 root root 11 2009-08-19 16:51 cdrom -> media/cdrom
drwxr-xr-x 12 root root 13980 2009-08-19 17:22 dev
drwx------ 79 root root 4096 2009-08-19 17:22 etc
drwxr-xr-x 3 root root 4096 2009-02-26 13:58 home
drwx------ 11 root root 4096 2009-08-19 16:58 lib
drwx------ 2 root root 4096 2009-02-26 13:41 lost+found

drwxr-xr-x 7 root root 4096 2009-08-17 16:26 media
drwxr-xr-x 2 root root 4096 2009-03-06 17:01 mnt
drwxr-xr-x 2 root root 4096 2009-02-26 13:42 opt
dr-xr-xr-x 74 root root 0 2009-08-19 17:22 proc
drwxr-xr-x 25 root root 4096 2009-08-19 17:18 root
drwx------ 2 root root 4096 2009-08-19 16:58 sbin
drwxr-xr-x 2 root root 4096 2008-09-16 00:38 selinux
drwxr-xr-x 2 root root 4096 2009-02-26 13:42 srv
drwxr-xr-x 12 root root 0 2009-08-19 17:22 sys
drwxrwxrwt 4 root root 4096 2009-08-19 17:22 tmp
drwx------ 11 root root 4096 2009-08-19 16:56 usr
drwx------ 13 root root 4096 2009-08-19 16:51 var

lrwxrwxrwx 1 root root 43 2009-08-19 16:51 vmlinuz -> boot/vmlinuz-2.6.30

Those directories in blue color above have problem with their permissions. As you can they are readable/writable/executable by the root user itself. This is definitely create some major problem with your system. We need to restore the permission of these directory.

Here are the actual permissions for the normal system:

drwxr-xr-x 2 root root 4096 2009-08-19 16:58 bin
drwxr-xr-x 3 root root 4096 2009-08-17 16:34 boot
lrwxrwxrwx 1 root root 11 2009-08-19 16:51 cdrom -> media/cdrom
drwxr-xr-x 12 root root 13980 2009-08-19 17:22 dev
drwxr-xr-x 79 root root 4096 2009-08-19 17:22 etc
drwxr-xr-x 3 root root 4096 2009-02-26 13:58 home
drwxr-xr-x11 root root 4096 2009-08-19 16:58 lib
drwx------ 2 root root 4096 2009-02-26 13:41 lost+found

drwxr-xr-x 7 root root 4096 2009-08-17 16:26 media
drwxr-xr-x 2 root root 4096 2009-03-06 17:01 mnt
drwxr-xr-x 2 root root 4096 2009-02-26 13:42 opt
dr-xr-xr-x 74 root root 0 2009-08-19 17:22 proc
drwxr-xr-x 25 root root 4096 2009-08-19 17:18 root
drwxr-xr-x2 root root 4096 2009-08-19 16:58 sbin
drwxr-xr-x 2 root root 4096 2008-09-16 00:38 selinux
drwxr-xr-x 2 root root 4096 2009-02-26 13:42 srv
drwxr-xr-x 12 root root 0 2009-08-19 17:22 sys
drwxrwxrwt 4 root root 4096 2009-08-19 17:22 tmp
drwxr-xr-x11 root root 4096 2009-08-19 16:56 usr
drwxr-xr-x13 root root 4096 2009-08-19 16:51 var

lrwxrwxrwx 1 root root 43 2009-08-19 16:51 vmlinuz -> boot/vmlinuz-2.6.30

The corrected ones are in green color.

How to change the permission

Solution 1: I strongly suggest that you re-transfer your files again from the original hard drive.

Solution 2: If you got this error message even when there was no actual transfer of partition/files, then try setting the appropriate permission for the offending directories using the chmod command. Here is a good article explaining how to use chmod command.

That’s it!

Be Sociable, Share!