2

I am having problems similar to those described in Boot much slower after partition resize. To summarise I repartitioned my hard drive to get more space in /. To do this I deleted the swap space, resized and then repartitioned swap. Everything went cleanly except when trying to boot it takes about 1-2 minutes to get the login screen.

As suggested in these other posts:

  1. Deleted Swap, now boot takes forever
  2. Really slow boot on 16.04

I checked the blkid outputs with those in /etc/fstab and edited it so they match. This did not solve the long boot times though. Any suggestions?

Further Info:

systemd-analyze

Startup finished in 8.469s (kernel) + 3min 351ms (userspace) = 3min 8.820s

Output from systemd-analyze blame is here

Uninteresting output from cat /etc/rc.local is here

Output from cat /var/log/boot.log is here

fstab

sudo blkid output

lackos
  • 43
  • Please run these two commands in a terminal and post the outputs here: systemd-analyze and systemd-analyze blame – PyGeek03 Oct 31 '16 at 02:48
  • systemd-analyze: Startup finished in 8.469s (kernel) + 3min 351ms (userspace) = 3min 8.820s systemd-analyze blame: http://paste.ubuntu.com/23405395/ – lackos Oct 31 '16 at 02:57
  • Can you post the contents of the file /etc/rc.local and /var/log/boot.log? – PyGeek03 Oct 31 '16 at 03:04
  • cat /etc/rc.local: http://paste.ubuntu.com/23405424/
    cat /var/log/boot.log : http://paste.ubuntu.com/23405433/
    – lackos Oct 31 '16 at 03:09
  • Yes. the UUID for / /home and swap partitions match the output to blkid. Though there is nothing beneath #/dev/mapper/cryptswap1 none swap sw 0 0 #/dev/mapper/cryptswap2 none swap sw 0 0 in the fstab file. I am not sure what these even are. – lackos Oct 31 '16 at 03:19
  • OK, I guess the problem is this: The swap is encrypted, and now repartitioning has made the configurations for swap encryption incorrect. Now, disable cryptswap2: cryptsetup remove cryptswap2, remove the line in /etc/fstab containing cryptswap2 then reboot. Create the swap and encrypt it again. – PyGeek03 Oct 31 '16 at 03:22
  • If that still doesn't solve the problem, try the suggestions in the answers to this question: https://askubuntu.com/questions/711016/slow-boot-a-start-job-is-running-for-dev-disk-by – PyGeek03 Oct 31 '16 at 03:24
  • Okay sure thing. Should I also remove cryptswap1? Thanks for all your help. – lackos Oct 31 '16 at 03:24
  • According to the file /var/log/boot.log, there was no problem with cryptswap1, maybe because you didn't touch it, so I think you don't have to remove it. – PyGeek03 Oct 31 '16 at 03:26
  • Do you want/need encrypted swap? Post the output of cat /etc/fstab and sudo blkid, and a screenshot of gparted /dev/sda. – heynnema Oct 31 '16 at 15:35
  • I am not sure what encrypted swap does, so I probably don't need it (thought that might be very ignorant). The outputs are, – lackos Oct 31 '16 at 22:58
  • The outputs are, cat /etc/fstab: http://paste.ubuntu.com/23409042/ sudo blkid: http://paste.ubuntu.com/23409046/ – lackos Oct 31 '16 at 23:05
  • @lackos In future please [edit] further info into your post as comments can be deleted for a number of reasons and may even go unread. – Elder Geek Nov 01 '16 at 16:06
  • Related: https://bbs.archlinux.org/viewtopic.php?id=215914 – Elder Geek Nov 01 '16 at 16:10
  • Sorry, I'll keep that in mind for next time. Thank you for all your help. – lackos Nov 01 '16 at 23:48
  • @lackos It would be great if you have a hint for me on a similar issue. – JJD Jan 24 '19 at 14:51

1 Answers1

0

So I ended up fixing it by removing /etc/crypttab as suggested here (link courtesy of PyGeek03). However it was still booting slowly until I commented out the crpytswap line in fstab. After this it booted up at normal speeds. Just for reference here is my new fstab file,

fstab

Thanks again for everyone's help and suggestions.

lackos
  • 43