[SOLVED] Boot Problem - MDM

All Gurus once were Newbies
Forum rules
There are no such things as "stupid" questions. However if you think your question is a bit stupid, then this is the right place for you to post it. Please stick to easy to-the-point questions that you feel people can answer fast. For long and complicated questions prefer the other forums within the support section.
Before you post please read how to get help
velky_pivo
Level 2
Level 2
Posts: 50
Joined: Fri Sep 30, 2011 10:02 pm

[SOLVED] Boot Problem - MDM

Postby velky_pivo » Fri Jul 27, 2012 1:50 pm

Can anyone direct me to a solution to this problem:

Bootup does not finish, but instead shows a blue window with this error message:
"Server Authorization directory (daemon/ServAuthDir) is set to /var/lib/mdm but
this does not exist. Please correct MDM configuration and restart now"

When I click OK (there is no other option), it takes me to login where it will not recognize user or password, and is stuck there

I would like to try sudo mdmsetup on sda (filesystem is on sda5) device where the problem installation is but I do not know how to run terminal command on sda partition from a working sdc partition.
Or, do I need to run the terminal from live cd, if so how do I make sure it runs the mdmsetup on sda and not on sdc ?

(Also could anyone point me toward explanation on difference between gdm and mdm ?)
Last edited by velky_pivo on Thu Aug 02, 2012 8:49 pm, edited 1 time in total.

User avatar
viking777
Level 14
Level 14
Posts: 5126
Joined: Mon Dec 01, 2008 11:21 am

Re: Boot Problem - MDM

Postby viking777 » Fri Jul 27, 2012 2:55 pm

gdm=gnome display manager mdm=mint display manager. They both do the same job but mdm is supposed to have more options (meaning themes mainly). You can also interchange them fairly easily by installing gdm and then running

Code: Select all

sudo dpkg-reconfigure gdm


but it helps if you can boot first, and you can't.

The easiest way to run commands in another partition is through chroot, but that only works with command line commands and unfortunately mdmsetup is a gui so you can't use it.

You mention that you have a working sdc partition, but you don't say what is on it, if it is windows then it is useless, but if it happens to be some other linux version then you can use that to connect to sda through chroot and be able to try a couple of commands.

So assuming it is linux on sdc then boot into that and make sure that your mint partition on sda is mounted. For the purpose of this explanation I will assume that your Mint partition is mounted on /mnt/mint within your sdc distro. As these are only assumptions you will have to substitute the correct values. So:

Code: Select all

sudo chroot /mnt/mint


followed by

Code: Select all

sudo dpkg-reconfigure mdm


There is a possibility that this might correct the error in mdm, there is also a possibility it wont, the only way to find out is to reboot and see. Before doing that hit CTL/d twice to exit the chroot and the terminal.

Assuming this has worked and you can now boot into Mint you can then run

Code: Select all

sudo mdmsetup


And play with that to your heart's content.

Assuming that is hasn't worked you do this instead (from your sdc linux partition):

Code: Select all

sudo chroot /mnt/mint


followed by

Code: Select all

sudo apt-get install gdm


followed by

Code: Select all

sudo dpkg-reconfigure gdm


This should ask you if you want to make gdm your default login manager - answer yes.

Ctl/d twice then reboot and this time gdm should log you in. Hopefully this will work. If it does, and you want to try mdm again then the command to run is as above:

Code: Select all

sudo dpkg-reconfigure mdm


or maybe (I am not sure, I haven't done it)

Code: Select all

sudo dpkg-reconfigure gdm


but in either case choose mdm as the default login manager. Of course this time you don't need the chroot bit.

You can then try

Code: Select all

sudo mdmsetup
again.

If that doesn't work then I give up.
Fujitsu Lifebook AH532. Intel i5 processor, 6Gb ram, Intel HD3000 graphics, Intel Audio/wifi. Realtek RTL8111/8168B Ethernet.Lubuntu 13.10,Ubuntu12.10 (Unity), Mint16 (Cinnamon), Manjaro (Xfce).

velky_pivo
Level 2
Level 2
Posts: 50
Joined: Fri Sep 30, 2011 10:02 pm

Re: Boot Problem - MDM

Postby velky_pivo » Fri Jul 27, 2012 4:08 pm

ok, i got the sda mount figured out

Maya is on sda2, with filesystem on sda5 and swap on sda6 (with Windows on sda1), sdc has working Julia on it and I do not want to screw this partition up

ok, this is what I got:

$ cd /mnt/sda5
/mnt/sda5 $ sudo chroot /mnt/sda5
# sudo dpkg-reconfigure mdm
sudo: unable to resolve host xxxx
debconf: DbDriver "config": could not open /var/cache/debconf/config.dat
# sudo apt-get install gdm
sudo: unable to resolve host xxxx
E: Could not open lock file /var/lib/dpkg/lock - open (2: No such file or directory)
E: Unable to lock the administration directory (/var/lib/dpkg/), are you root?
#

(I named both hosts same when installing Maya on sda and Julia on sdc if that means anything here)

What am i doing wrong ?

User avatar
oobetimer
Level 7
Level 7
Posts: 1879
Joined: Tue Jun 01, 2010 12:53 pm
Location: Finland / above the Arctic Circle
Contact:

Re: Boot Problem - MDM

Postby oobetimer » Fri Jul 27, 2012 5:26 pm

velky_pivo wrote:ok, i got the sda mount figured out

Maya is on sda2, with filesystem on sda5 and swap on sda6 (with Windows on sda1), sdc has working Julia on it and I do not want to screw this partition up

If Maya is on sda5 (sda2 = extented partition?), so the prosedure goes like this:
sudo mount /dev/sda5 /mnt
sudo mount --bind /dev /mnt/dev
sudo mount --bind /sys /mnt/ sys
sudo mount --bind /proc /mnt/proc
sudo chroot /mnt

dpkg-reconfigure mdm
... or
dpkg-reconfigure gdm
... if MDM or GDM are not installalled, you can install them
apt-get install mdm gdm3
exit

sudo umount /mnt/dev
sudo umount /mnt/sys
sudo umount /mnt/proc
sudo umount /mnt

velky_pivo
Level 2
Level 2
Posts: 50
Joined: Fri Sep 30, 2011 10:02 pm

Re: Boot Problem - MDM

Postby velky_pivo » Fri Jul 27, 2012 6:01 pm

ok, the result:

$ sudo mount /dev/sda5 /mnt
$ sudo mount --bind /dev /mnt/dev
$ sudo mount --bind /sys /mnt/sys
$ sudo mount --bind /proc /mnt/proc
$ sudo chroot /mnt
/ # dpkg-reconfigure mdm
debconf: DbDriver "config": could not open /var/cache/debconf/config.dat
/ # sudo dpkg-reconfigure mdm
sudo: unable to resolve host xxxx
debconf: DbDriver "config": could not open /var/cache/debconf/config.dat
/ # apt-get install mdm
E: Could not open lock file /var/lib/dpkg/lock - open (2: No such file or directory)
E: Unable to lock the administration directory (/var/lib/dpkg/), are you root?
/ # sudo apt-get install mdm
sudo: unable to resolve host xxxx
E: Could not open lock file /var/lib/dpkg/lock - open (2: No such file or directory)
E: Unable to lock the administration directory (/var/lib/dpkg/), are you root?
/ #

I can see /var/lib on sda but no var/lib/dpkg and there is no var/cache
It looks like hosed up istallation, is there a way to copy these files over somehow, would it work ?
BTW, thanks for the help, but what now ?

User avatar
viking777
Level 14
Level 14
Posts: 5126
Joined: Mon Dec 01, 2008 11:21 am

Re: Boot Problem - MDM

Postby viking777 » Sat Jul 28, 2012 6:37 am

I can see /var/lib on sda but no var/lib/dpkg and there is no var/cache
It looks like hosed up istallation, is there a way to copy these files over somehow, would it work ?


I guess it is time for a re-install given what you say, copying these folders over is not likely to work out well imo, you will just be storing up trouble for the future if you get it to work at all. Also, if the previous installation has failed to write some fairly major parts of the file system, I think you want to have a close look at your installation medium before you try again. Did you notice any error messages or abnormalities during the install process?
Fujitsu Lifebook AH532. Intel i5 processor, 6Gb ram, Intel HD3000 graphics, Intel Audio/wifi. Realtek RTL8111/8168B Ethernet.Lubuntu 13.10,Ubuntu12.10 (Unity), Mint16 (Cinnamon), Manjaro (Xfce).

velky_pivo
Level 2
Level 2
Posts: 50
Joined: Fri Sep 30, 2011 10:02 pm

Re: Boot Problem - MDM

Postby velky_pivo » Sat Jul 28, 2012 1:43 pm

Maya would not install on sdc, could not get sdc bootable, and since sda was set bootable I tried to install it there to see what happens.
It was just an experiment to see if I could get Maya installed but I did not remove slide show before installing, and I did not install from USB - which appears to be the fix.
This was a mistake, I really did not want to put anything alongside the Windows.

1) Now I need to remove 20GB file system and swap from extended partitions sda5 and 6, and pray that it will leave my Windows intact,
and will still boot Windows afterwards. (maybe remove unwanted Grub boot menu entries before that ?)

2) I would also like to make my sdc bootable (it boots from sda now),

This way I will have both drives bootable: sda - Windows only, sdc - Linux only

I do not want to damage Windows (lotsa expensive programs installed, but do not have installers any longer), if that happens I am dead.

Since Julia is running nicely on sdc I do not want to loose that either.

I had not so good previous experience with Grub. How do I start Grub2 gui anyway ? Then there is gparted with ntfs utilities, and kde partition manager, and Windows disk stuff.

Can you please help ?

Some more HD info might help:

Disk /dev/sda: 160.0 GB, 160041885696 bytes
255 heads, 63 sectors/track, 19457 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x39fd39fd

Device Boot Start End Blocks Id System
/dev/sda1 * 1 16704 134174848+ 7 HPFS/NTFS
/dev/sda2 16705 19458 22114305 5 Extended
/dev/sda5 16705 19197 20018176 83 Linux
/dev/sda6 19197 19458 2095104 82 Linux swap / Solaris

Disk /dev/sdb: 82.0 GB, 81964302336 bytes
255 heads, 63 sectors/track, 9964 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x0008c0ce

Device Boot Start End Blocks Id System
/dev/sdb1 1 9965 80041984 b W95 FAT32

Disk /dev/sdc: 1000.2 GB, 1000204886016 bytes
255 heads, 63 sectors/track, 121601 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x0001baab

Device Boot Start End Blocks Id System
/dev/sdc1 * 1 120837 970616832 83 Linux
/dev/sdc2 120837 121602 6142977 5 Extended
/dev/sdc5 120837 121602 6142976 82 Linux swap / Solaris

User avatar
viking777
Level 14
Level 14
Posts: 5126
Joined: Mon Dec 01, 2008 11:21 am

Re: Boot Problem - MDM

Postby viking777 » Sun Jul 29, 2012 7:21 am

I would try again to install Maya on sdc alongside Julia and this time incorporate the 'no slideshow' fix to see if that makes it install.

Regarding sdc not being set bootable, this 'boot flag' idea is purely windows nonsense, Linux completely ignores these flags.

Can you confirm two things. Is the grub that you have on Julia grub2 or grub legacy? It should be the former. Run

Code: Select all

grub-install -v


to find out - if the version starts with 1.something it is grub2.

The second thing is do you boot windows from the Julia grub menu? I am sure you do but I just want to know for certain.

If you have grub2 and you boot windows from the Julia menu then you have no real need to interfere with grub at all, you don't even have to install it on Maya. If you look closely enough during the install process there will be an option to install grub in various places the default being /dev/sda probably. Somewhere in the list of places to install it you should find an option to not install it anywhere - select this option. If you can't find it then select the next safest option which is to install it to the same partition that you are installing Maya on and this will be something like /dev/sdc3 or some other number, but not simply /dev/sdc.

Assuming Maya installs properly reboot into Julia and then run

Code: Select all

sudo update-grub


This should now display entries for Julia, Maya and Windows but if the install of Maya has failed for any reason it will still display the Julia and Windows entries because the MBR hasn't been touched. This gives a built in measure of safety that overwriting the mbr (the default option) does not.

Once you have done that your grub menu will already have been tidied up a bit so you probably wont have to do it yourself, removing the Maya and swap partition from sda should not be in the least problematic unless you choose the wrong partition to delete - if you do that is your fault and nothing to do with Linux :lol:

You mention something about making sdc bootable. Well this can be done, by installing Maya's grub into /dev/sdc but the thing is although you can have as many boot loaders as you like on a hard disk (I have 5 myself) only one of them at a time can actually do the booting, so if you wanted both disks to be bootable you would have to enter the bios on every boot and choose the device you want to use this time - it is not a very good idea imho. There may be some boot manager somewhere that allows you to do this 'on the fly' so to speak but I don't know about it and it would be just another lever of complication to allow things to get screwed up, so personally I would forget that idea.

Hope you work it out anyway.

Edit. I just had a thought about that last paragraph - some computers have a function key (F11, F12 something like that) that allow you to change boot devices without entering the bios, so if you have one of those then you could have both disks bootable I guess.
Fujitsu Lifebook AH532. Intel i5 processor, 6Gb ram, Intel HD3000 graphics, Intel Audio/wifi. Realtek RTL8111/8168B Ethernet.Lubuntu 13.10,Ubuntu12.10 (Unity), Mint16 (Cinnamon), Manjaro (Xfce).

velky_pivo
Level 2
Level 2
Posts: 50
Joined: Fri Sep 30, 2011 10:02 pm

Re: Boot Problem - MDM

Postby velky_pivo » Sun Jul 29, 2012 4:47 pm

I think it is Julia's Grub on sda because I used it to correct previous unbootable mess caused by Maya install.
Windows boots from grub menu (whatever that version is below), and then it jumps to windows boot menu with w2k and Mepis choices on it
(Mepis is long gone, only menu entry remains, Mepis was on sdb long time ago, sdb is now clean)

$ sudo grub-install -v

grub-install.real (GRUB) 1.98+20100804-5ubuntu3-1mint1

Yes I can change the boot order by F12 without having to go through BIOS.
However I will be installing a hard drive switch in few days.
I want to be able to have independent HD installs of Windows and Linuxes with occassional chance to fix crapped out stuff from different place
(usually fix Windows from Linux).

Somebody also suggested leaving sda5 and 6 partitions alone (i.e. do not resize) and make them shareable so that any OS can use it.
Would I have to format this to NTFS so that my Windows2k can also see it ?
Not sure how to do this safely, especially how to join 18GB sda5 and 2GB sda6 swap back to one 20GB partition.

User avatar
viking777
Level 14
Level 14
Posts: 5126
Joined: Mon Dec 01, 2008 11:21 am

Re: Boot Problem - MDM

Postby viking777 » Mon Jul 30, 2012 5:28 am

Would I have to format this to NTFS so that my Windows2k can also see it ?


Yes you would.

Not sure how to do this safely, especially how to join 18GB sda5 and 2GB sda6 swap back to one 20GB partition.


Well I would do it from the gui program gparted - which will also convert it to ntfs as well if that is what you want (install it if it is not there already it is available in the software or package manager). The easiest and quickest way to do this with gparted is just to delete the two partitions and then create one new ntfs one (assuming there is nothing on the partitions that you want to keep that is). Just make sure you choose the correct partitions before deleting them!

I want to be able to have independent HD installs of Windows and Linuxes


So you want Windows on sda with a windows boot loader and Linux on sdc with a linux boot loader is that correct?

If that is the case you will have to replace the grub boot loader on sda with a windows one. There is a good tutorial on that here:

viewtopic.php?f=42&t=108274

However if you do that first you will no longer be able to boot Julia - so don't.

To summarise, in order to get what you want:

1) Install Maya on sdc and make SURE that the boot loader is written to sdc not sda. You should now be able to boot all three distros from sdc. (if anything goes wrong with this process you can still boot windows and julia from sda)
2) Use the tutorial above to replace windows bootloader on sda. (if anything goes wrong with this process you can still boot windows from grub on sdc)
3) Use gparted to delete unwanted partitions on sda and recreate them as one ntfs partition.
Fujitsu Lifebook AH532. Intel i5 processor, 6Gb ram, Intel HD3000 graphics, Intel Audio/wifi. Realtek RTL8111/8168B Ethernet.Lubuntu 13.10,Ubuntu12.10 (Unity), Mint16 (Cinnamon), Manjaro (Xfce).

velky_pivo
Level 2
Level 2
Posts: 50
Joined: Fri Sep 30, 2011 10:02 pm

Re: Boot Problem - MDM

Postby velky_pivo » Mon Jul 30, 2012 5:19 pm

You got it !
That is exactly how I want it.
And yes, gparted is already installed with ntfs library support too on Julia, I just hope that it can grow the ntfs partition without a hickup.

Thanks so much for clear, great advice !!!

I am now running to OfficeMax to pickup external USB drive (on sale for $40 off), so that I can backup lotsa GBs of stuff before I tear into this.

I also came across easyUS free home edition partitioning tool sw that claims that it will restore bootloader to default windows bootloader.
Although this sounds intriguing, I will follow vikng777's directions right above first.

User avatar
viking777
Level 14
Level 14
Posts: 5126
Joined: Mon Dec 01, 2008 11:21 am

Re: Boot Problem - MDM

Postby viking777 » Tue Jul 31, 2012 6:20 am

I just hope that it can grow the ntfs partition without a hickup.


Erm. That wasn't what I said though. Growing partitions and trying to change file systems at the same time is not impossible but it is slow and usually buggy.

What I said was DELETE the existing partitions then create a new one with the new filesystem - this is 10x quicker. Naturally you will lose all data on the deleted partitions, but if I understand you correctly we are talking about a swap partition and Mint Maya partition neither of which are likely to contain personal data and if there is anything on there you want to keep then just copy it to a usbkey or some such device before you delete.
Fujitsu Lifebook AH532. Intel i5 processor, 6Gb ram, Intel HD3000 graphics, Intel Audio/wifi. Realtek RTL8111/8168B Ethernet.Lubuntu 13.10,Ubuntu12.10 (Unity), Mint16 (Cinnamon), Manjaro (Xfce).

velky_pivo
Level 2
Level 2
Posts: 50
Joined: Fri Sep 30, 2011 10:02 pm

Re: Boot Problem - MDM

Postby velky_pivo » Thu Aug 02, 2012 8:48 pm

Got it to work flawlessly, except that Grub menu showed 7 Maya installs on sda.
Should have deleted the Maya sda partition first but no big deal, just deleted all those entries in grub.cfg
I used gparted from sdc for sda deletion, and then easeUS home free edition to resize/merge freed up space on sda as well as to knock out Grub and reinstall Windows MBR.
Just don't like the ugly Ubuntu style default Grub boot screen.
I've been playing with different backgrounds and fonts but it is not working right.

Thanks for help, I am done.


Return to “Newbie Questions”

Who is online

Users browsing this forum: No registered users and 11 guests