[GH-ISSUE #3909] [BUG] mods-update installs the wrong Metamod for CS:GO #2534

Open
opened 2026-02-27 03:03:38 +03:00 by kerem · 1 comment
Owner

Originally created by @borzaka on GitHub (Jun 28, 2022).
Original GitHub issue: https://github.com/GameServerManagers/LinuxGSM/issues/3909

User Story

As a server owner and maintainer, I want to update my mods, fixing crashes caused by new game updates time to time.

Basic info

  • Distro: [Debian 10]
  • Game: [CS:GO]
  • Command: [mods-update]
  • LinuxGSM version: [v22.1.0]

Further Information

Recently, a new CS:GO update broke SourceMod and Metamod. So I waited out to the fix available.
The fix is arrived, but when I tried to update, the server still crashed. It turned out, that LGSM installed the wrong Metamod. It installed the Metamod (Half-life 1 Classic Engine) instead of Metamod:Source.

To Reproduce

Steps to reproduce the behaviour:

  1. Server is an existing install with CS:GO, metamod and sourcemod
  2. Run ./csgoserver mods-update
  3. it downloads the wrong ZIP for metamod: metamod-1.21.1-am.zip
  4. server craches, because this metamod is not for CS:GO

Expected behaviour

Install the correct Metamod:Source version for CS:GO

Extra info

  • server was an existing install
  • LGSM was constantly updated
  • it worked before, couple of months ago
  • solution I came up: remove metamod, install metamodsource

mods-update log:

the metamod-1.21.1-am.zip file is not for csgoserver

$ ./csgoserver mods-update
[ INFO ] Updating mods csgoserver: Update addons/mods: 3 addons/mods will be updated
        * Metamod (retain common custom files)
        * SourceMod (retain common custom files)
        * SteamWorks (overwrite)

==> Updating Metamod
creating mod download directory /home/csgoexecutes/lgsm/mods/tmp...OK
######################################################################################################################################################################################################################################################### 100.0%
extracting metamod-1.21.1-am.zip...OK
the following files/directories will be preserved:
        * serverfiles/addons/metamod/plugins.ini
building metamod-files.txt...OK
copying Metamod to /home/csgoexecutes/serverfiles/csgo...OK
tidy up metamod-files.txt...OK
clearing mod download directory /home/csgoexecutes/lgsm/mods/tmp...OK

==> Updating SourceMod
creating mod download directory /home/csgoexecutes/lgsm/mods/tmp...OK
                                                    #=#=-  #       #                                                                                                                                                                                                                                               #=O=#     ######################################################################################################################################################################################################################################################### 100.0%
extracting sourcemod-1.10.0-git6545-linux.tar.gz...OK
the following files/directories will be preserved:
        * serverfiles/cfg
        * serverfiles/addons/sourcemod/configs
building sourcemod-files.txt...OK
copying SourceMod to /home/csgoexecutes/serverfiles/csgo...OK
tidy up sourcemod-files.txt...OK
clearing mod download directory /home/csgoexecutes/lgsm/mods/tmp...OK

==> Updating SteamWorks
creating mod download directory /home/csgoexecutes/lgsm/mods/tmp...OK
######################################################################################################################################################################################################################################################### 100.0%
extracting SteamWorks-git132-linux.tar.gz...OK
building steamworks-files.txt...OK
copying SteamWorks to /home/csgoexecutes/serverfiles/csgo...OK
tidy up steamworks-files.txt...OK
clearing mod download directory /home/csgoexecutes/lgsm/mods/tmp...OK

[  OK  ] Updating mods csgoserver: Mods update complete

mods-remove and mods-install logs:

note the Error! metamod is not a valid addon/mod. message

$ ./csgoserver mods-remove
(23) Failed writing body

Counter-Strike: Global Offensive Removing mods
=================================
Remove addons/mods
=================================
metamod - Metamod - Plugins Framework
sourcemod - SourceMod - Admin Features (requires Metamod: Source)
steamworks - SteamWorks - Exposing SteamWorks functions to SourcePawn

Enter an addon/mod to remove (or exit to abort): metamod
Error! metamod is not a valid addon/mod.
Warning! You are about to remove metamod.
 * Any custom files/configuration will be removed.
Continue? [Y/n] Y
removing Metamod
* 5 files to be removed
* location: /home/csgoexecutes/serverfiles/csgo
removing Metamod 1 / 5 : addons/metamod...
removing Metamod 2 / 5 : addons/metamod/dlls...
removing Metamod 3 / 5 : addons/metamod/dlls/metamod.dylib...
removing Metamod 4 / 5 : addons/metamod/dlls/metamod.so...
removing Metamod 5 / 5 : addons/metamod/dlls/metamod.dll...
OK
removing metamod-files.txt...OK
removing metamod from installed-mods.txt...OK
Metamod removed

mods-install logs:

$ ./csgoserver mods-install

Counter-Strike: Global Offensive Installing mods
=================================
Installed addons/mods
=================================
 * sourcemod
 * steamworks

Available addons/mods
=================================
Metamod: Source - Plugins Framework - https://www.sourcemm.net
 * metamodsource
...
Enter an addon/mod to install (or exit to abort): metamodsource

Installing Metamod: Source
=================================
creating mod download directory /home/csgoexecutes/lgsm/mods/tmp...OK
                                                   #=#=-  #       #                                                                                                                                                                                                                                               #=O=#     ########################################################################################################################################################################################################################################################## 100.0%
extracting mmsource-1.11.0-git1148-linux.tar.gz...OK
building metamodsource-files.txt...OK
copying Metamod: Source to /home/csgoexecutes/serverfiles/csgo...OK
tidy up metamodsource-files.txt...OK
clearing mod download directory /home/csgoexecutes/lgsm/mods/tmp...OK
Metamod: Source installed
Originally created by @borzaka on GitHub (Jun 28, 2022). Original GitHub issue: https://github.com/GameServerManagers/LinuxGSM/issues/3909 ## User Story As a server owner and maintainer, I want to update my mods, fixing crashes caused by new game updates time to time. ## Basic info * **Distro:** [Debian 10] * **Game:** [CS:GO] * **Command:** [mods-update] * **LinuxGSM version:** [v22.1.0] ## Further Information Recently, a new CS:GO update [broke](https://github.com/alliedmodders/sourcemod/issues/1788) SourceMod and Metamod. So I waited out to the fix available. The fix is arrived, but when I tried to update, the server still crashed. It turned out, that LGSM installed the wrong Metamod. It installed the Metamod (Half-life 1 Classic Engine) instead of Metamod:Source. ## To Reproduce Steps to reproduce the behaviour: 1. Server is an existing install with CS:GO, metamod and sourcemod 2. Run ./csgoserver mods-update 3. it downloads the wrong ZIP for metamod: metamod-1.21.1-am.zip 4. server craches, because this metamod is not for CS:GO ## Expected behaviour Install the correct Metamod:Source version for CS:GO # Extra info - server was an existing install - LGSM was constantly updated - it worked before, couple of months ago - solution I came up: remove metamod, install metamodsource ## mods-update log: the `metamod-1.21.1-am.zip` file is not for csgoserver ``` $ ./csgoserver mods-update [ INFO ] Updating mods csgoserver: Update addons/mods: 3 addons/mods will be updated * Metamod (retain common custom files) * SourceMod (retain common custom files) * SteamWorks (overwrite) ==> Updating Metamod creating mod download directory /home/csgoexecutes/lgsm/mods/tmp...OK ######################################################################################################################################################################################################################################################### 100.0% extracting metamod-1.21.1-am.zip...OK the following files/directories will be preserved: * serverfiles/addons/metamod/plugins.ini building metamod-files.txt...OK copying Metamod to /home/csgoexecutes/serverfiles/csgo...OK tidy up metamod-files.txt...OK clearing mod download directory /home/csgoexecutes/lgsm/mods/tmp...OK ==> Updating SourceMod creating mod download directory /home/csgoexecutes/lgsm/mods/tmp...OK #=#=- # # #=O=# ######################################################################################################################################################################################################################################################### 100.0% extracting sourcemod-1.10.0-git6545-linux.tar.gz...OK the following files/directories will be preserved: * serverfiles/cfg * serverfiles/addons/sourcemod/configs building sourcemod-files.txt...OK copying SourceMod to /home/csgoexecutes/serverfiles/csgo...OK tidy up sourcemod-files.txt...OK clearing mod download directory /home/csgoexecutes/lgsm/mods/tmp...OK ==> Updating SteamWorks creating mod download directory /home/csgoexecutes/lgsm/mods/tmp...OK ######################################################################################################################################################################################################################################################### 100.0% extracting SteamWorks-git132-linux.tar.gz...OK building steamworks-files.txt...OK copying SteamWorks to /home/csgoexecutes/serverfiles/csgo...OK tidy up steamworks-files.txt...OK clearing mod download directory /home/csgoexecutes/lgsm/mods/tmp...OK [ OK ] Updating mods csgoserver: Mods update complete ``` ## mods-remove and mods-install logs: note the `Error! metamod is not a valid addon/mod.` message ``` $ ./csgoserver mods-remove (23) Failed writing body Counter-Strike: Global Offensive Removing mods ================================= Remove addons/mods ================================= metamod - Metamod - Plugins Framework sourcemod - SourceMod - Admin Features (requires Metamod: Source) steamworks - SteamWorks - Exposing SteamWorks functions to SourcePawn Enter an addon/mod to remove (or exit to abort): metamod Error! metamod is not a valid addon/mod. Warning! You are about to remove metamod. * Any custom files/configuration will be removed. Continue? [Y/n] Y removing Metamod * 5 files to be removed * location: /home/csgoexecutes/serverfiles/csgo removing Metamod 1 / 5 : addons/metamod... removing Metamod 2 / 5 : addons/metamod/dlls... removing Metamod 3 / 5 : addons/metamod/dlls/metamod.dylib... removing Metamod 4 / 5 : addons/metamod/dlls/metamod.so... removing Metamod 5 / 5 : addons/metamod/dlls/metamod.dll... OK removing metamod-files.txt...OK removing metamod from installed-mods.txt...OK Metamod removed ``` ## mods-install logs: ``` $ ./csgoserver mods-install Counter-Strike: Global Offensive Installing mods ================================= Installed addons/mods ================================= * sourcemod * steamworks Available addons/mods ================================= Metamod: Source - Plugins Framework - https://www.sourcemm.net * metamodsource ... Enter an addon/mod to install (or exit to abort): metamodsource Installing Metamod: Source ================================= creating mod download directory /home/csgoexecutes/lgsm/mods/tmp...OK #=#=- # # #=O=# ########################################################################################################################################################################################################################################################## 100.0% extracting mmsource-1.11.0-git1148-linux.tar.gz...OK building metamodsource-files.txt...OK copying Metamod: Source to /home/csgoexecutes/serverfiles/csgo...OK tidy up metamodsource-files.txt...OK clearing mod download directory /home/csgoexecutes/lgsm/mods/tmp...OK Metamod: Source installed ```
Author
Owner

@h3o66 commented on GitHub (Aug 22, 2022):

I think this was broken due #3104 .
This did not migrate the old to the new name.
I have seen this as well on a old server on my side some time ago.

Options:

  1. manually fix this with the following:
sed -i 's/^metamod$/metamodsource/' lgsm/mods/installed-mods.txt
mv lgsm/mods/metamod-files.txt lgsm/mods/metamodsource-files.txt
  1. write a migration script for the mods module.

fyi: @tkrn as i think you broke this with the mentioned PR

<!-- gh-comment-id:1223030873 --> @h3o66 commented on GitHub (Aug 22, 2022): I think this was broken due #3104 . This did not migrate the old to the new name. I have seen this as well on a old server on my side some time ago. Options: 1. manually fix this with the following: ``` sed -i 's/^metamod$/metamodsource/' lgsm/mods/installed-mods.txt mv lgsm/mods/metamod-files.txt lgsm/mods/metamodsource-files.txt ``` 2. write a migration script for the mods module. fyi: @tkrn as i think you broke this with the mentioned PR
Sign in to join this conversation.
No labels
Atomic
Epic
cannot reproduce
command: backup
command: console
command: debug
command: details
command: fast-dl
command: install
command: mods
command: monitor
command: post-details
command: restart
command: send
command: start
command: stop
command: update
command: update-lgsm
command: validate
command: wipe
distro: AlmaLinux
distro: Arch Linux
distro: CentOS
distro: Debian
distro: Fedora
distro: RedHat
distro: Rocky Linux
distro: Ubuntu
distro: openSUSE
engine: goldsrc
engine: source
game: 7 Days to Die
game: ARMA 3
game: Ark: Survival Evolved
game: Assetto Corsa
game: Avorion
game: BATTALION: Legacy
game: Barotrauma
game: Battalion 1944
game: Battlefield 1942
game: Black Mesa: Deathmatch
game: Blade Symphony
game: Call of Duty 2
game: Call of Duty 4
game: Call of Duty: United Offensive
game: Counter-Strike 1.6
game: Counter-Strike 2
game: Counter-Strike: Global Offensive
game: Counter-Strike: Source
game: Day of Infamy
game: Dayz
game: Death Match Classic
game: Don't Starve Together
game: ET: Legacy
game: Eco
game: Factorio
game: Factorio
game: Garry's Mod
game: Half-Life
game: Hurtword
game: Insurgecy
game: Insurgecy
game: Insurgency: Sandstorm
game: Just Cause 3
game: Killing Floor
game: Killing Floor 2
game: Left 4 Dead 2
game: Minecraft
game: Minecraft Bedrock
game: Mordhau
game: Multi Theft Auto
game: Mumble
game: Natural Selection 2
game: No More Room in Hell
game: Pavlov VR
game: Post Scriptum
game: Project Zomboid
game: Quake 3
game: QuakeWorld
game: Red Orchestra: Ostfront 41-45
game: Return to Castle Wolfenstein
game: Rising World
game: Rust
game: San Andreas Multiplayer
game: Satisfactory
game: Soldat
game: Soldier of Fortune 2
game: Squad
game: Squad 44
game: Starbound
game: Stationeers
game: Sven Co-op
game: Team Fortress 2
game: Teamspeak 3
game: Teeworlds
game: Terraria
game: The Front
game: Unreal Tournament 2004
game: Unreal Tournament 3
game: Unreal Tournament 99
game: Unturned
game: Valheim
game: Wurm Unlimited
game: Zombie Master Reborn
game: label missing
good first issue
help wanted
info: alerts
info: dependency
info: docker
info: docs
info: email
info: query
info: steamcmd
info: systemd
info: tmux
info: website
info: website
needs more info
outcome: duplicate
outcome: issue resolved
outcome: issue resolved
outcome: issue unresolved
outcome: pr accepted
outcome: pr rejected
outcome: unconfirmed
outcome: wontfix
outcome: wrong forum
potential-duplicate
priority
pull-request
type: bug
type: feature
type: feature
type: feature request
type: game server request
type: refactor
waiting response
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/LinuxGSM#2534
No description provided.