pdss - ryzom/ryzomcore GitHub Wiki


title: PD Support Service (PDSS) description: Batch analytics service for scanning character and guild save files published: true date: 2026-03-14T00:00:00.000Z tags: editor: markdown dateCreated: 2026-03-14T00:00:00.000Z

The PD Support Service (PDSS) is a batch analytics service that scans character and guild PDR save files from Backup Service snapshots and generates statistical reports. Despite its name suggesting a relationship with the Persistent Data Service (PDS), PDSS reads the standard BS-based PDR character saves — the same files that CPlayerManager writes via CBackupMsgSaveFile.

The service binary is pd_support_service (ryzom/server/src/pd_support_service/). It is built on the same generic module host as GUS, but its real functionality comes from a built-in character/guild scanning system and scheduled job commands.

What It Does

PDSS reads character save files (account_*_?_pdr.bin) from a BS backup directory, deserializes them into CStatsScanCharacter objects (a lightweight PDR-compatible mirror of the full character data), applies filters, extracts information, and writes CSV-style output files.

This was used at Nevrax to generate daily player activity reports: active player counts, inactive player analysis, per-shard breakdowns, churn metrics.

How It Works

Scan Scripts (.pdss_css files)

Scan jobs are defined in script files (under scripts/) with three types of directives:

  • inputFileRule — select which save files to scan (FDC cache, file age, date range, largest file per account)
  • filter — select which characters pass through (by skill level, guild membership, money, shard)
  • infoExtractor — select which data to extract from matching characters (name, position, skills, play time, activity dates)

Example — filters_active.pdss_css:

inputFileRule AddFilesFromFdcCache
inputFileRule FileAge 0 14
inputFileRule LargestFile

Example — fields_active.pdss_css:

infoExtractor Name
infoExtractor Race
infoExtractor Cult
infoExtractor Position
infoExtractor HighestSkills
infoExtractor Money
infoExtractor Sessions
infoExtractor PlayTime
infoExtractor ActivityDuration
infoExtractor FirstActivityDate
infoExtractor LastActivityDate
infoExtractor ActiveMissions

Example — filters_lvl1_inactive.pdss_css (low-level players who quit):

inputFileRule AddFilesFromFdcCache
inputFileRule Since 01/01/2007
inputFileRule FileAge 7
inputFileRule LargestFile

filter BestSkill 1 1
filter NoGuild

Job Execution

Jobs are queued via the addCharScanJob command with an output path and one or more script files:

addCharScanJob ../stats/active14_aniro  filters_active.pdss_css fields_active.pdss_css filters_aniro.pdss_css

Multiple script files are combined — the first might define what "active" means, the second what fields to extract, and the third filters to a specific shard.

The JobUpdatesPerUpdate setting controls how many file reads happen per service update tick, keeping the service responsive.

Output

Each job produces:

  • A character table CSV with one row per matching character and columns for each info extractor
  • Frequency tables that count occurrences of values (e.g. how many characters last logged in on each date)

Available Filters

Filter Arguments Description
Guild <guildId> [...] Characters in specific guilds
NoGuild Characters not in any guild
Money <min> [<max>] Characters with money in range
BestSkill <min> [<max>] Characters whose best skill level is in range
Shard <shard_name> Characters on a specific shard
FileAge <min_days> [<max_days>] Only files modified within a day range (used as inputFileRule)
Since <dd/mm/yyyy> Only files modified since a date (used as inputFileRule)
Before <dd/mm/yyyy> Only files modified before a date (used as inputFileRule)
LargestFile When multiple saves exist per account, use only the largest (used as inputFileRule)
AddFilesFromFdcCache Use the pre-cached file list (used as inputFileRule)

Available Info Extractors

Extractor Output column Description
Name name Character name
Position position fields Character world position
Stats stat fields Character stats (HP, etc.)
PlayTime play_hours Total hours played
Sessions session count Number of login sessions
FirstActivityDate start_date First connection date
LastActivityDate last_date Last connection date
ActivityDuration active_days Days between first and last connection
RecentPlayHistory history fields Recent play session history
DeathPenalty penalty fields Current death penalty state
HighestSkills skill fields Highest skill levels per branch
Race race Character race
Cult cult Character cult allegiance
Money money Character money
ActiveMissions mission fields Currently active missions

File Description Cache (FDC)

Scanning a backup directory with tens of thousands of save files is expensive. The FDC cache (fdcCacheAddFileSpecRecurse) pre-scans the directory listing once and caches it in memory, so multiple scan jobs can share the file list without re-scanning the filesystem.

fdcCacheClear
fdcCacheAddFileSpecRecurse /home/nevrax/save_shard_backups/latest/characters/account_*_?_pdr.bin

Scheduled Execution

PDSS supports HourlyCommands and DailyCommands config variables. In the Nevrax deployment, daily commands would:

  1. Run external shell scripts (hourly_script.sh, daily_script.sh)
  2. Rebuild the FDC cache from the latest BS backup snapshot
  3. Queue scan jobs for various reports (active 7-day, active 14-day, inactive per-shard, inactive by date range)

Guild Scanning

In addition to character scanning, PDSS can scan guild save files via stats_guild_scan_job.cpp and stats_guild_commands.cpp, extracting guild-level statistics.

Configuration

PDSS runs standalone — no NS, no TICKS, no shard connection needed:

DontUseNS = 1;
DontUseTS = 1;
DontUseAES = 1;

InputFileDirectory = "/path/to/save_shard_backups/latest/characters/";
OutputFileDirectory = "../stats/";
ScriptDirectory = "../live/service_pd_support_service/scripts/";

Current Status

PDSS is built as part of the Ryzom Core server suite. The scanning code is functional and can read current PDR character saves. The original .pdss_css script files are included in the source tree under ryzom/server/src/pd_support_service/scripts/. PDSS is not part of the standard Ryzom Core 4 shard deployment but can be run standalone against any BS backup directory containing character saves.

See also

⚠️ **GitHub.com Fallback** ⚠️