FastDL
Сообщения
25
Реакции
36
knik добавил(а) новый ресурс:

FastDL - Простой и высокопроизводительный FastDL HTTP сервер

Решение для простого запуска FastDL. Плагин Metamod позволяет быстро запустить полноценный FastDL HTTP сервер без необходимости поднимать и настраивать отдельный веб-сервер.

Плагин запускает полноценный HTTP сервер способный обрабатывать десятки тысяч запросов в секунду на средней машине. В настройках можно указать ограничения на скачивание файлов, запретить или разрешить некоторые файлы.

Некоторые особенности
  • Кэширование файлов для снижения нагрузки.
  • Безопасность...
Узнать больше об этом ресурсе...
 
Сообщения
26
Реакции
8
Предупреждения
5
i have install on my server but server dont start this message

panic: host is not set
goroutine 17 [running, locked to thread]:
main.init.0.metaQueryFn.func7()
/home/runner/work/fastdl-mm/fastdl-mm/main.go:168 +0x690
github.com/et-nik/metamod-go.Meta_Query(0xf28ffbac, 0x9b0c510, 0x9b0c554)
/home/runner/go/pkg/mod/github.com/et-nik/metamod-go@v0.3.3/meta_api.go:46 +0x101
/entrypoint.sh: line 15: 12 Aborted (core dumped) ${MODIFIED_STARTUP}
PTDL_CONTAINER_ERR: There was an error while attempting to run the start command.


its the problem on gamepanel when i write status my ip is 0.0.0.0:27015
 
Сообщения
250
Реакции
30
Помог
7 раз(а)
добавляет поддержку <windows> :hunter:
 
Сообщения
167
Реакции
32
maybe i will sound harsh, but what is the practical purpose of this module? can anyone give any example?
the reasoning for not understanding the purpose could be the bad translation...or I'm just stupid, i don't deny that ;)
 
Сообщения
25
Реакции
36
i have install on my server but server dont start this message

panic: host is not set
goroutine 17 [running, locked to thread]:
main.init.0.metaQueryFn.func7()
/home/runner/work/fastdl-mm/fastdl-mm/main.go:168 +0x690
github.com/et-nik/metamod-go.Meta_Query(0xf28ffbac, 0x9b0c510, 0x9b0c554)
/home/runner/go/pkg/mod/github.com/et-nik/metamod-go@v0.3.3/meta_api.go:46 +0x101
/entrypoint.sh: line 15: 12 Aborted (core dumped) ${MODIFIED_STARTUP}
PTDL_CONTAINER_ERR: There was an error while attempting to run the start command.


its the problem on gamepanel when i write status my ip is 0.0.0.0:27015
Hmmm, interesting case, will do an update for this.

In general you should specify host instead of 0.0.0.0.0 (For example -ip 1.33.7.x instead of -ip 0.0.0.0)
But in the container ip can change, and you should use 0.0.0.0.

Wait for an update, I will make an update for this case.

maybe i will sound harsh, but what is the practical purpose of this module? can anyone give any example?
the reasoning for not understanding the purpose could be the bad translation...or I'm just stupid, i don't deny that ;)
Simple FastDL. You just need to install the metamod plugin.

You don't need to set up nginx/apache and configure it. Or you don't need to copy the files to a separate server somewhere else, you get rid of double work.
 
Сообщения
78
Реакции
21
Or you don't need to copy the files to a separate server somewhere else, you get rid of double work.
То есть я правильно понимаю, этот метамод плагин создаёт фастдл сервер там же, где находится сам игровой сервер, но занимает другой порт, и берёт для отправки ровно те же файлы, что в то же время использует игровой сервер?
 
Сообщения
88
Реакции
3
Помог
4 раз(а)
knik, будет ли для Винды такой же Метамодик?
 
Сообщения
25
Реакции
36
То есть я правильно понимаю, этот метамод плагин создаёт фастдл сервер там же, где находится сам игровой сервер, но занимает другой порт, и берёт для отправки ровно те же файлы, что в то же время использует игровой сервер?
Да, всё верно.
С возможностью ограничить раздачу файлов, которые задействованы в текущей карте.

knik, будет ли для Винды такой же Метамодик?
В процессе. Надеюсь никаких подводных камней не будет.
 
Сообщения
32
Реакции
2
knik, все файлы которые нужны автоматически добавляются в FastDL?
 
Сообщения
5
Реакции
12
Hi, the download is working fine but I'm getting hlds_run process up to 100%. And it becomes unplayable.

Im using:

ReHLDS version: 3.14.0.0-dev Build date: 08:29:43 Dec 26 2024 (3911)
ReGameDLL version: 5.27.0.715-dev Build from: https://github.com/s1lentq/ReGameDLL_CS/commit/ad1c58c
Metamod-r v1.3.0.149
AMX Mod X 1.9.0.5294

YAML:
# fastdl.yaml

# The host of the FastDL HTTP server.
# Leave it empty if you want to use the same IP as the game server.
# host: "127.0.0.1"

# The port of the FastDL HTTP server.
# Leave it empty if you want to use random port.
port: 8081

# The range of random ports for the FastDL HTTP server.
# If the port is not specified, the plugin will use a random port from this range.
# If the port is specified, the plugin will use the specified port, ignoring this range.
#portRange: 40000-50000

# Serve only precached files.
# If enabled, the plugin will not allow downloading files that are not in the precache list.
servePrecached: false

# Generate auto index page for directories.
# It allows to see the list of files in the directory.
autoIndexEnabled: true

# Cache size for downloaded files.
# The plugin will delete the oldest files if the cache is full.
cacheSize: 50MB

# Forbidden files and directories by regular expressions.
forbiddenRegexp:
  - mapcycle.*
  - .*textscheme.*
    
# Allowed file extensions.
# Files with extensions not in this list can not be downloaded.
allowedExtentions:
  - bmp
  - bsp
  - gif
  - jpeg
  - jpg
  - lmp
  - lst
  - mdl
  - mp3
  - png
  - res
  - spr
  - tga
  - txt
  - wad
  - wav
  - zip

# Allowed paths.
# Files from directories not in this list can not be downloaded.
allowedPaths:
  - gfx
  - maps
  - media
  - models
  - overviews
  - sound
  - sprites

Also can provide all info you request.
 
Сообщения
25
Реакции
36
yuyi, What OS distribution are you using? How many cpu cores do you have? RAM?
If your VDS is limited to one core, then this may be a problem, you need to increase it to two. FastDL web server runs in a separate thread of the operating system and needs another separate cpu core for good performance.
 
  • Нравится
Реакции: yuyi
Сообщения
5
Реакции
12
yuyi, What OS distribution are you using? How many cpu cores do you have? RAM?
If your VDS is limited to one core, then this may be a problem, you need to increase it to two. FastDL web server runs in a separate thread of the operating system and needs another separate cpu core for good performance.
Oh, the issue that I'm using 1 core. Thanks I will try to upgrade my setup. Anyways my set up is Ubuntu 22.04.5 with 1 core and 2gb RAM.
 
Сообщения
210
Реакции
488
Помог
3 раз(а)
FastDL web server runs in a separate thread of the operating system and needs another separate cpu core for good performance.
У меня аналогичная ситуация на WSL2 Debian 12. Комп нормальный.
Ранее сталкивался с похожей проблемой, и дело оказалось не в недостатке ресурсов, а именно в отдельном потоке, который запускался с помощью STL. На некоторых ОС это приводило к тому, что нагрузка на hlds показывала 100% (как и в этом случае).
Насколько я понял, это связано с тем, как потоки реализованы в конкретной ОС, ядре и libstdc++.
Вопрос решился использованием низкоуровневых POSIX-потоков напрямую, вместо оберток вроде std::thread.
Подозреваю, здесь такая же фигня с горутинами.
 
Сообщения
423
Реакции
118
Помог
3 раз(а)
the_hunter, а можешь показать вывод ps M <PID_HLDS>, когда он начинает отжирать 100% CPU. Запусти пару раз, через 15-20 секунд...
 
Сообщения
423
Реакции
118
Помог
3 раз(а)
knik, возможно так в 181 строке main.go:

Код:
++runtime.GOMAXPROCS(runtime.NumCPU())

go func() {
--    runtime.LockOSThread()

    err := p.RunServer(gameDir)
    if err != nil {
        panic(err)
    }
}()
Возможно, в 1.23 достаточно добавить runtime.GOMAXPROCS(runtime.NumCPU()). На крайняк можно попробовать так :crazy: :
Код:
++runtime.GOMAXPROCS(runtime.NumCPU())

go func() {
    runtime.LockOSThread()

++    go func() {
        err := p.RunServer(gameDir)
        if err != nil {
            panic(err)
        }
++    }()
}()
 
Последнее редактирование:
Сообщения
120
Реакции
76
Помог
4 раз(а)
atego1317,
Try to statically select an IP and a free port in the module.
And open the port on the machine where pterodactyl is installed
sudo ufw status (show open port)
sudo ufw allow 27115 (open port)
 

Пользователи, просматривающие эту тему

Сейчас на форуме нет ни одного пользователя.
Сверху Снизу