Courseiva
Container Operations And LifecyclehardMultiple ChoiceObjective-mapped

EX188 Container Operations And Lifecycle Practice Question

An administrator wants to generate a systemd unit file for an existing Podman container named 'app_server' so that it can be managed as a system service. Which command should be used to generate this unit file and write it directly to the user systemd directory?

Answer choices

Why each option matters

Answer the question above first, then reveal the full breakdown to understand why each option is right or wrong.

Correct answer & explanation

podman generate systemd --new --files --name app_server

The 'podman generate systemd' command is used to create systemd unit files, and the '--new' flag ensures the unit file creates a new container on start rather than relying on an existing stopped container.

Answer analysis

Option-by-option breakdown

For each option: why learners choose it and why it is or isn't the right answer here.

  • podman export systemd app_server > /etc/systemd/system/app_server.service

    Why it's wrong here

    The 'podman export' command exports a container's filesystem to a tar archive, not a systemd unit file.

  • podman service generate --container app_server --output ~/.config/systemd/user/

    Why it's wrong here

    This is a syntactically invalid command structure for Podman.

  • podman generate systemd --new --files --name app_server

    Why this is correct

    The 'podman generate systemd' command with '--new' and '--files' writes the unit file directly into the current working directory, which can then be moved to the systemd folder.

  • podman systemd create --name app_server > ~/.config/systemd/user/container-app_server.service

    Why it's wrong here

    Podman has no 'systemd create' subcommand.

About these practice questions

One of 296 original EX188 practice questions on Courseiva, each with a full explanation and wrong-answer analysis — not exam dumps or protected exam content. Learn why practice questions differ from exam dumps →

How Courseiva writes practice questions · Editorial policy

JA

Written and reviewed by Johnson Ajibi, MSc IT Security

Senior Network & Security Engineer · founder of Courseiva

Last reviewed August 2026 · checked against the official Red Hat exam blueprint

This EX188 practice question is part of Courseiva's free Red Hat certification practice question bank. Courseiva provides original exam-style practice questions with explanations, topic-based practice, mock exams, readiness tracking, and study analytics to help learners prepare for the EX188 exam.