Here is some information for anybody upgrading their installation to Ubuntu 18.04 and getting stuck because of the sysv-rc-conf package which does not exist on Ubuntu 18.
The thing is that if you do a fresh install of Ubuntu 18 and then install Fog, you don’t face this issue.
But if you are coming e.g. from Ubuntu 14, you get stuck and as a solution are told to remove the package from config.sh, see: https://forums.fogproject.org/topic/9998/upgrade-ubuntu-16-10-to-17-04-sysv-rc-conf-fail
This “riddle” has been asked but not answered here: https://github.com/FOGProject/fogproject/issues/258 before.
I noticed when comparing the two that for the install that gets stuck, the output is:
Installing package: sysv-rc-conf..............................Failed! (Will try later)
while for the fresh install that works it is:
Skipping package: sysv-rc-conf..............................(Does not exist)
I wondered what that meant and had a look at /lib/common/functions.sh
What happens here is that the installer calls:
eval $packagelist "$x"
which in this case is:
apt-cache pkgnames | grep sysv-rc-conf
Now on a fresh Ubuntu 18, this will give you no output and return code 1, while on an upgraded Ubuntu, it is
and the return code is 0, because the package has been removed, but is still listed by dpkg and marked as “rc”.
To cut a long story short, before you install Fog, completely purge sysvr-rc-conf, and you will be fine:
sudo apt purge sysv-rc-conf