GameServerManagers / LinuxGSM

The command-line tool for quick, simple deployment and management of Linux dedicated game servers.
https://linuxgsm.com
MIT License
4.31k stars 820 forks source link

jq does not exist in Ubuntu Server 18.04.1 default repositories #1985

Closed Synt3x closed 6 years ago

Synt3x commented 6 years ago

Game: Any (tested with teamspeak3)

I just installed clean Ubuntu Server 18.04.1 and the default repositories doesn't have jq. When you add universe repositories sudo add-apt-repository universe to the operating system you can install jq .

Command:

sudo dpkg --add-architecture i386; sudo apt update; sudo apt install mailutils postfix curl wget file bzip2 gzip unzip bsdmainutils python util-linux ca-certificates binutils bc jq libmariadb2

Output (after clean install):

Hit:1 http://archive.ubuntu.com/ubuntu bionic InRelease
Hit:2 http://archive.ubuntu.com/ubuntu bionic-security InRelease
Hit:3 http://archive.ubuntu.com/ubuntu bionic-updates InRelease
Reading package lists... Done
Building dependency tree
Reading state information... Done
All packages are up to date.
Reading package lists... Done
Building dependency tree
Reading state information... Done
Package mailutils is not available, but is referred to by another package.
This may mean that the package is missing, has been obsoleted, or
is only available from another source
E: Package 'mailutils' has no installation candidate
E: Unable to locate package jq
E: Unable to locate package libmariadb2```

Output (after "universe" added to repositories):

Hit:1 http://archive.ubuntu.com/ubuntu bionic InRelease
Hit:2 http://archive.ubuntu.com/ubuntu bionic-security InRelease
Hit:3 http://archive.ubuntu.com/ubuntu bionic-updates InRelease
Reading package lists... Done
Building dependency tree
Reading state information... Done
All packages are up to date.
Reading package lists... Done
Building dependency tree
Reading state information... Done
E: Unable to locate package libmariadb2

I don't know if there should be any information on the website about this? I know that it's just Minecraft that need jq in the current moment.

edit 1, 2, 3: more information

UltimateByte commented 6 years ago

I'm not sure what we're supposed to do about it. It seems kinda harsh to ask ubuntu users to install universe. This version of ubuntu breaks a lot of things, it's kinda boring... Maybe a conditional: if ubuntu 18 or upper is detected and jq is missing, provide a documentation link?

dgibbs64 commented 6 years ago

I will need t review the use of jq. It is however extremely useful for us. JSON.sh is an alternative we could possibly use.

dgibbs64 commented 6 years ago

universe is installed for my Linode image of Ubuntu 18.04. @Synt3x Is this a standard install of Ubuntu or a minimal install you used?

JohnFedorchak commented 6 years ago

universe is installed for my Linode image of Ubuntu 18.04. @Synt3x Is this a standard install of Ubuntu or a minimal install you used?

I just installed Ubuntu Server 18.04.1 LTS and am having trouble using GSM for Killing Floor 2 because of "Unable to locate package jq". Seems to be the same issue.

Synt3x commented 6 years ago

@dgibbs64 I just checked and there is no choice during the installation of Ubuntu Server 18.04.1. But the choice exist in Ubuntu Desktop 18.04.1. I can’t test if the problem exist in desktop version right now, but will do it when I come home.

edit: misspelled

dgibbs64 commented 6 years ago

Thanks. I would rather avoid complications on install if possible. However jq is very useful for LinixGSM.

Synt3x commented 6 years ago

jq could be installed on the following version of Ubuntu after updating the package lists (sudo apt update):

I retested Ubuntu Server 18.04.1 and like I said before Ubuntu Server 18.04.1 didn't include universe in it's repository, but after adding it to the repository it could find and install jq.

If you want this in a new ticket, I'll move it: I also notice that cs1.6 is having trouble in Ubuntu Server 18.04.1 to find a candidate for mailutils =>E: Package 'mailutils' has no installation candidate, but after adding universe everything went through.

edit: sentence, more information

JohnFedorchak commented 6 years ago

Can confirm that on Ubuntu Server 18.04.1 (64 bit), after running

sudo add-apt-repository universe

The LinuxGSM script for KF2 was able to automatically grab all of the pre-req packages it needed, including jq.

Bourne-ID commented 6 years ago

https://bugs.launchpad.net/subiquity/+bug/1783129

There is a known bug in 18.04.1 where the universe repo isn't being added to the sources list. This has been fixed in their daily feed and will be fixed in 18.04.2

As such I think we sould keep the jq dependency; it's a useful tool and this universe missing bug will eventually disappear as 18.04.1 will be retired for the next minor version. In the meantime we could add an os check / source check which warns users that the universe is missing with a link on how to fix. Thoughts?

Bug #1783129 “Only “main” component enabled after install” : Bugs : subiquity
[impact] Systems installed with the live-server installer do not have universe enabled, unlike systems installed with the d-i installer. [test case] Install system. Look for universe in /etc/apt/sources.list [regression potential] The coupling in livecd-rootfs is not always obvious and it's possible that the change that fixes this bug will break other images somehow. I really don't think so though. [original description] Maybe this is on purpose, and I also don't remember how the classic ...
dgibbs64 commented 6 years ago

@Bourne-ID I agree, thanks for the info. A hotfix for this can be released if you are happy to create a warning for a missing universe repo that would be great. It should go in the check_dependencies.sh file. Should also make it possible to activate the repo using the script if sudo is available.

lock[bot] commented 5 years ago

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.