AlmaLinux 10 Minimal
Overview
AlmaLinux is a community-driven enterprise Linux distribution, produced by the AlmaLinux OS Foundation to be binary compatible with Red Hat Enterprise Linux 10. This is the Minimal edition. It is the same base with the packages that a headless cloud server never uses removed, so the machine you run has a smaller installed package set and a smaller attack surface to patch and audit.
This guide covers the deployment and configuration of AlmaLinux 10 Minimal on Microsoft Azure, using SecureAnyCloud's preconfigured virtual machine image from the Azure Marketplace.
The image is cut from AlmaLinux 10 (Kitten), the rolling development track that follows upstream Red Hat Enterprise Linux 10 ahead of AlmaLinux's own numbered point releases. SecureAnyCloud's existing "AlmaLinux 10" offer uses the same base. On this image, cat /etc/almalinux-release reports AlmaLinux Kitten release 10 (Lion Cub) rather than a 10.N point release.
What "Minimal" removed on this base, measured at build time: the image trims two packages, the tuned tuning daemon and the sosreport support collector. Cockpit, linux-firmware, the boot splash (plymouth) and the bundled GeoIP datasets were already absent from the stock AlmaLinux 10 cloud image, so there was nothing to remove there. This differs from the AlmaLinux 8 and 9 Minimal editions, where several of those packages were present and had to be trimmed.
The measured result is a root filesystem of 1.5 GB instead of 1.8 GB at build time, roughly 14 percent smaller. A running machine reports slightly more than the build-time figure as logs and caches accumulate.
What you get:
- AlmaLinux 10 (Kitten), binary compatible with the current RHEL 10 development lineage
- A reduced package set with no tuned daemon and no sosreport support collector. Cockpit,
linux-firmware, plymouth and the GeoIP datasets were already absent on this base. - Every available update applied at build time, verified with a zero-pending check
- Unattended updates already armed, so the machine keeps patching itself
- Azure Linux Agent (waagent) and cloud-init for Azure integration
- chronyd for NTP time synchronization
- SELinux in enforcing mode, both at runtime and persisted for the next boot
- BaseOS and AppStream repositories enabled, with signature checking on
- Exactly one externally reachable port: SSH on 22
- Gen2 Hyper-V virtual machine support
- 24/7 SecureAnyCloud support
Platform: Microsoft Azure (Gen2 Hyper-V). Default user: azureuser.
What "Minimal" means here, precisely
This image removes the packages that a headless cloud server has no use for: the tuned tuning daemon and the sosreport support collector. Each is one less service or dataset to keep patched and to account for in a security review.
The Cockpit web console, the boot splash, the residual wireless and sound card firmware, and the bundled GeoIP datasets were never installed on this AlmaLinux 10 base. Earlier AlmaLinux Minimal editions had to remove them explicitly.
The image deliberately keeps systemd, NetworkManager, the SSH server, cloud-init, the Azure Linux Agent, dnf, sudo, chrony and dnf-automatic. The build fails closed if any of them is missing after the trim. The image is rebooted before capture to prove that it still boots and reaches the network.
Confirm the footprint on your own machine:
df -h / | awk 'NR==2 {print "root filesystem used: " $3 " of " $2}' rpm -qa | wc -lExpected output on a freshly deployed machine:
root filesystem used: 1.6G of 29G 414Security posture
This image ships with no known credential. There is no default password and no baked-in SSH key:
- The root account password is locked, so no one can log in as root with a password.
PasswordAuthenticationis disabled in the SSH daemon, so every login is by key.KbdInteractiveAuthenticationis also disabled, which closes the other password path.PermitRootLoginis set toprohibit-password, so root cannot be reached with a password even if one is set later.- The only key that works is the public key you supply when you create the virtual machine. Azure injects it into
azureuserat first boot, so no two machines you launch share a secret. - SSH host keys are not baked into the image. cloud-init regenerates them on every machine, so no two customers share a host identity.
Verify the effective SSH configuration on your own machine. This reads the parsed values rather than the file text:
sudo sshd -T | grep -E '^(permitrootlogin|passwordauthentication|kbdinteractiveauthentication|permitemptypasswords) 'Expected output:
permitrootlogin without-password passwordauthentication no kbdinteractiveauthentication no permitemptypasswords no1. Connect to the machine
Connect over SSH. Replace the address with your virtual machine's public IP:
ssh azureuser@<YOUR-VM-IP>2. Confirm the release and patch level
cat /etc/almalinux-release uname -rThis is a major-version image. It reports the AlmaLinux 10 identity as of the build at capture time, not a pinned minor release. Confirm that no updates are outstanding:
sudo dnf -q check-update >/dev/null 2>&1; echo "check-update rc=$? (100 would mean updates pending)"3. Confirm the trim actually shipped
The packages that this edition removes are absent, and the platform essentials are present. Confirm both:
for p in tuned sos cockpit linux-firmware plymouth; do rpm -q $p >/dev/null 2>&1 && echo "$p: present" || echo "$p: absent"; donefor p in systemd NetworkManager openssh-server cloud-init WALinuxAgent dnf
sudo chrony; do rpm -q $p >/dev/null 2>&1 && echo "$p: present" || echo "$p: MISSING"; done4. Confirm Azure integration and SELinux
systemctl is-active waagent.service 2>/dev/null || systemctl is-active walinuxagent.servicegetenforce5. Unattended updates
The image arms dnf-automatic, so the machine keeps patching itself after you deploy it. Check the timer:
systemctl is-enabled dnf-automatic.timergrep -E '^(upgrade_type|apply_updates|download_updates)' /etc/dnf/automatic.confAfter the timer has run at least once, review what it will do and when:
systemctl list-timers dnf-automatic.timer --all --no-pager6. Adding software back
The trim does not stop you from installing anything you need. The full AlmaLinux repositories are enabled and signature-checked:
sudo dnf install -y tuned sos7. Support
SecureAnyCloud provides 24/7 support for this image at sales@secureanycloud.com.
AlmaLinux is free and open source software. It is not under a single license. The distribution is assembled from thousands of independently packaged components, each with its own terms. You can read every package's license with rpm -qi <package> or under /usr/share/licenses/. No subscription, license key or support contract is required to use AlmaLinux itself.
AlmaLinux is a trademark of the AlmaLinux OS Foundation. SecureAnyCloud is not affiliated with, endorsed by, or sponsored by the AlmaLinux OS Foundation. The name is used only to identify the distribution that this image contains.
Deploy on Azure
Launch AlmaLinux 10 Minimal on Azure with 24/7 support from SecureAnyCloud.
View this image
Need Help?
Our support team is available 24/7.
sales@secureanycloud.com
Overview
AlmaLinux 10 is a free, community-built enterprise Linux distribution that is binary compatible with Red Hat Enterprise Linux 10 and maintained until 2035.
This guide covers launching and verifying the AlmaLinux 10 Minimal AMI from SecureAnyCloud on Amazon EC2. It is one version of the SecureAnyCloud AlmaLinux listing on AWS Marketplace. You select it as the software version when you subscribe and launch. Every release and variant in the listing is described at /guides/almalinux-aws/.
This image starts from AlmaLinux 10.2 for EC2 and adds four things:
- A trimmed package set. Packages that a cloud server does not need are removed: on this build, the
tunedtuning daemon and thesossupport-report collector, along with the dependencies that left with them. Each removal is simulated first and refused if it would take a package that the instance needs to boot, network or be reached. The list ships on the image. The out-of-date AWS tools that the base image carried outside any repository (an old CloudWatch agent, a bundled AWS CLI and EC2 Instance Connect) are removed too, and the Systems Manager agent is brought to its current release. - CIS Level 1 Server remediation. The image is remediated with the OpenSCAP CIS Level 1 Server profile from SCAP Security Guide 0.1.82 (AlmaLinux's own signed
scap-security-guidepackage), then rebooted and evaluated. On this build, 285 of 286 scored rules pass (99.7%). Seven rules are waived because they cannot work on an EC2 image, each with its reason. The HTML report, the machine-readable results, the waiver list and a summary ship in/usr/share/doc/sac/. - EC2 defaults that keep you in control. These include key-only SSH as
ec2-user, root locked, no password on any account, SELinux enforcing and IMDSv2 required. A host firewall (firewalld) allows SSH in and everything out. The image also includes the current AWS Systems Manager agent and time from the Amazon Time Sync Service. - Fully patched at build time, with
dnf-automaticapplying security updates on your instance.
What is on the image: AlmaLinux 10.2 (the RHEL 10 compatible 6.12 kernel), cloud-init, OpenSSH, firewalld, chrony, SELinux (targeted policy, enforcing), the AWS Systems Manager agent, auditd, rsyslog, AIDE file integrity checking, dnf-automatic, OpenSCAP and the pinned SCAP Security Guide content used for the evaluation.
Default user: ec2-user. Architecture: x86_64. Boot mode: UEFI (preferred). Root volume: 10 GiB gp3, XFS (grows to the size you choose at launch).
These images are remediated with an OpenSCAP profile and ship their own evaluation report. They are not CIS Hardened Images, and CIS has not reviewed or certified them.
Connecting to your instance
Connect over SSH as the ec2-user user. The root device of AlmaLinux 10 Minimal is /dev/sda1 (10 GiB gp3).
Security posture
- No known credential. There is no default password and no baked-in SSH key. The only key that works is the EC2 key pair you choose at launch, which cloud-init installs for
ec2-useron first boot. - Key-only SSH.
PasswordAuthentication no,PermitRootLogin no, and keyboard-interactive authentication off. The root account has no password and is locked. EC2 Instance Connect, which adds a second way to push SSH keys, is not installed. - Per-instance identity. SSH host keys and the machine ID are generated fresh on every instance, so no two instances share a host key.
- IMDSv2 required. The AMI is registered with
ImdsSupport v2.0, so instances launched from it refuse token-less (IMDSv1) metadata requests by default. - SELinux enforcing with the targeted policy, as AlmaLinux ships it.
- Host firewall. The firewalld
publiczone allows only SSH and the DHCPv6 client inbound, and allows all outbound traffic. The SSM agent, metadata service, DNS, time sync and package updates keep working. - Only SSH listens on the network. Nothing else on the image listens on any address.
Prerequisites
- An AWS account and permission to launch EC2 instances
- An EC2 key pair in the Region you launch in
- A security group that allows TCP 22 from your own address, not from the whole internet
Recommended instance type: m5.large. The image runs on any current x86_64 instance type. Like every AlmaLinux 10 build for x86_64, it needs a processor with the x86-64-v3 feature level (AVX2). Current-generation EC2 x86 instance types provide it.
Launch the instance
Option A: AWS Marketplace console
- Open the SecureAnyCloud AlmaLinux listing on AWS Marketplace. Choose View purchase options, then Subscribe. One subscription covers every version in the listing.
- When the subscription is active, choose Launch your software.
- Choose One-click launch from AWS Marketplace, or Launch from EC2 Console for full control. In Version, choose AlmaLinux 10 Minimal - YYYY-MM-DD (the date is when the version was added), then choose your Region.
- Choose an instance type.
m5.largeis recommended, and any current x86_64 type works. The software charge is $0.04 per vCPU per hour. - Choose your EC2 key pair. It is the only way in. RSA and ED25519 keys both work.
- Configure the security group to allow inbound TCP 22 from your own IP address or network only.
- Set the storage. The root volume is 10 GiB gp3 by default. Choose a larger size if you need one. cloud-init grows the root partition and filesystem to fill it on first boot.
- Leave the metadata defaults, because the image already requires IMDSv2. Then choose Launch.
Option B: AWS CLI
Run this command on your own workstation. Replace the AMI ID with the one shown for your Region on the Marketplace launch page. Replace the key pair, security group and subnet with your own. The root device of this AMI is /dev/sda1:
aws ec2 run-instances \
--image-id ami-0123456789abcdef0 \
--instance-type m5.large \
--key-name my-key-pair \
--security-group-ids sg-0123456789abcdef0 \
--subnet-id subnet-0123456789abcdef0 \
--block-device-mappings 'DeviceName=/dev/sda1,Ebs={VolumeSize=20,VolumeType=gp3}' \
--tag-specifications 'ResourceType=instance,Tags=[{Key=Name,Value=almalinux-10-minimal}]'You do not need --metadata-options, because the AMI already requires IMDSv2.
Connect via SSH
From your workstation, connect as ec2-user with the key pair you chose:
ssh -i ~/.ssh/my-key-pair.pem ec2-user@<public-ip>There is no password to enter. If SSH asks for one, or reports Too many authentication failures, see Troubleshooting below.
You can also connect without opening port 22 through AWS Systems Manager Session Manager, if the instance has an instance profile that allows Systems Manager. The agent is installed and running on this image.
Confirm the release
cat /etc/almalinux-release grep -E '^(NAME|VERSION|ID|VERSION_ID|PLATFORM_ID|PRETTY_NAME)=' /etc/os-release uname -srmExpected output:
AlmaLinux release 10.2 (Lavender Lion) NAME="AlmaLinux" VERSION="10.2 (Lavender Lion)" ID="almalinux" VERSION_ID="10.2" PLATFORM_ID="platform:el10" PRETTY_NAME="AlmaLinux 10.2 (Lavender Lion)" Linux 6.12.0-211.67.1.el10_2.x86_64 x86_64This version follows AlmaLinux 10. It receives every AlmaLinux 10 minor release (10.2 at build time) through normal dnf updates. Your kernel version may be newer if updates have installed since this image was built.
See what the Minimal trim removed
The image lists exactly what was removed. If a removal would have taken another needed package with it, that package is kept and listed instead:
cat /usr/share/doc/sac/minimal-manifest.txt rpm -qa | wc -lExpected output:
Minimal version: packages 412 -> 404 Removed: tuned sos Kept (a removal would have taken a protected package, or it failed): 416The trim takes the package count from 412 to 404, including the dependencies that left with those two packages. Nothing had to be kept back. The base image is already small, so most of the candidate list (wireless and sound firmware, Cockpit, Plymouth) was never installed.
After the trim, the CIS remediation adds the tools it needs (OpenSCAP, AIDE, the journal upload client and their libraries), and the build removes the superseded kernels. This is why a new instance has 416 packages. The count on your instance changes by a few as kernels and updates install.
Anything removed is one sudo dnf install away from the standard AlmaLinux repositories.
Read the compliance evidence
The evaluation that the build ran after its reboot ships on the image. List the files:
ls -lh /usr/share/doc/sac/ python3 -c "import json; s=json.load(open('/usr/share/doc/sac/cis-l1-summary.json')); print('profile: ', s['profileLabel'], '(SCAP Security Guide', s['ssgVersion'] + ')'); print('scored rules: ', s['scored'], ' pass:', s['pass'], ' fail:', s['fail'], ' rate:', str(s['ratePct']) + '%'); print('waived: ', s['waived'], ' not applicable:', s['notapplicable']); print('evaluated at: ', s['evaluatedAt'])"Expected output:
total 32M -rw-r--r--. 1 root root 29M Oct 19 23:36 cis-l1-arf.xml -rw-r--r--. 1 root root 2.4M Oct 19 23:36 cis-l1-report.html -rw-r--r--. 1 root root 1.3K Oct 19 23:36 cis-l1-summary.json -rw-r--r--. 1 root root 1.9K Oct 19 23:36 cis-l1-tailoring.xml -rw-r--r--. 1 root root 2.9K Oct 19 23:36 cis-l1-waivers.txt -rw-r--r--. 1 root root 129 Oct 19 23:33 minimal-manifest.txt -rw-r--r--. 1 root root 1.6K Oct 19 23:33 scap-security-guide-LICENSE.txt profile: CIS Level 1 Server (SCAP Security Guide 0.1.82) scored rules: 286 pass: 285 fail: 1 rate: 99.7% waived: 7 not applicable: 31 evaluated at: 2026-10-19T23:36:49Zcis-l1-report.htmlis the full OpenSCAP report, rule by rule. Copy it to your workstation and open it in a browser.cis-l1-arf.xmlis the same evaluation in the machine-readable ARF format, for compliance tooling.cis-l1-tailoring.xmlis the exact tailoring used, so you can re-run the same evaluation (Step 6).- The pass rate is pass / (pass + fail + error + unknown). Rules that are not applicable to this machine, not selected or waived are not counted.
To copy the report to your workstation, run this command on the workstation:
scp -i ~/.ssh/my-key-pair.pem ec2-user@<public-ip>:/usr/share/doc/sac/cis-l1-report.html .The seven waived rules
grep -v '^#' /usr/share/doc/sac/cis-l1-waivers.txt | cut -f1,2Expected output:
partition_for_tmp [single-volume-partitions] grub2_password [serial-console-and-boot] ensure_root_password_configured [serial-console-and-boot] accounts_maximum_age_login_defs [key-only-account-aging] account_disable_post_pw_expiration [key-only-account-aging] sshd_limit_user_access [ssh-access-list] service_systemd-journal-upload_enabled [log-remote-destination]The full reason for each rule is in the third column of the same file. In short:
- Separate /tmp partition. This version boots from one EBS root volume. The LVM versions of this listing provide separate volumes for /tmp, /var, /var/log, /var/log/audit, /var/tmp and /home.
- Boot loader and root passwords. A GRUB or root password would have to be baked into the image, which would give every instance the same secret. Root stays locked with no password. Set your own if you need serial console access (see Step 11).
- Password aging defaults. The accounts that cloud-init creates are key-only. An aging limit would expire them and lock the SSH key out. Accounts that do have a password are still aged.
- SSH AllowUsers/AllowGroups. A list fixed at build time would refuse accounts that you create later. Your security group restricts who can reach port 22.
- Journal upload to a remote log server. The profile switches on
systemd-journal-uploadbut sets no destination, and an image cannot know your log server. With no destination, the service fails at every boot.systemd-journal-remoteis installed and the upload service is left off. To enable it, putURL=for your collector in/etc/systemd/journal-upload.conf, then runsudo systemctl enable --now systemd-journal-upload.
The one rule that does not pass
python3 -c "import json; [print(r) for r in json.load(open('/usr/share/doc/sac/cis-l1-summary.json'))['failingRules']]"Expected output:
ensure_journald_and_rsyslog_not_active_togetherThe benchmark wants one logging system, not both. AlmaLinux runs journald and rsyslog together by default. journald keeps the structured system journal (persistent, in /var/log/journal). rsyslog writes the traditional text logs (/var/log/messages, /var/log/secure, /var/log/cron) that many log shippers and audit procedures read.
The image keeps both, so neither kind of tooling loses its logs. If you standardize on one, for example the journal only, run sudo systemctl disable --now rsyslog on your instance and re-run Step 6.
Re-run the evaluation yourself
You can repeat the evaluation at any time with the same content and tailoring. It takes under a minute. Run it:
sudo oscap xccdf eval \
--tailoring-file /usr/share/doc/sac/cis-l1-tailoring.xml \
--profile xccdf_co.sac_profile_cis-l1_ec2_single \
--results /tmp/cis-check-results.xml --report /tmp/cis-check-report.html \
/usr/share/xml/scap/ssg/content/ssg-almalinux10-ds.xml > /tmp/cis-check.log 2>&1 echo "oscap exit code: $? (2 = at least one rule did not pass)"
sudo python3 -c "import re,collections; c=collections.Counter(re.findall(r'<result>(\w+)</result>', open('/tmp/cis-check-results.xml').read())); s=sum(c[k] for k in ('pass','fail','error','unknown')); print(dict(sorted(c.items()))); print('pass rate: %.1f%%' % (100.0*c['pass']/s))"Expected output:
oscap exit code: 2 (2 = at least one rule did not pass) {'fail': 1, 'notapplicable': 31, 'notselected': 756, 'pass': 285} pass rate: 99.7%Your own report is at /tmp/cis-check-report.html. As you install software and change settings, re-run the evaluation to see how your changes affect the result.
Confirm IMDSv2 is required
curl -s -o /dev/null -w 'IMDSv1 request without a token: HTTP %{http_code}\n' http://169.254.169.254/latest/meta-data/instance-id
TOKEN=$(curl -s -X PUT -H 'X-aws-ec2-metadata-token-ttl-seconds: 60' http://169.254.169.254/latest/api/token)
curl -s -H "X-aws-ec2-metadata-token: $TOKEN" -w '\n' http://169.254.169.254/latest/meta-data/placement/regionExpected output (your Region may differ):
IMDSv1 request without a token: HTTP 401 us-east-1A request without a session token is refused with HTTP 401, and the same request with a token works. Scripts and SDKs on the instance must use IMDSv2. Every current AWS SDK and the AWS CLI do this automatically.
The host firewall and listening ports
sudo firewall-cmd --state sudo firewall-cmd --list-all sudo ss -tlnpExpected output:
running public (default, active) target: default ingress-priority: 0 egress-priority: 0 icmp-block-inversion: no interfaces: eth0 sources: services: dhcpv6-client ssh ports: protocols: forward: yes masquerade: no forward-ports: source-ports: icmp-blocks: rich rules: State Recv-Q Send-Q Local Address:Port Peer Address:PortProcess LISTEN 0 128 0.0.0.0:22 0.0.0.0:* users:(("sshd",pid=1070,fd=7)) LISTEN 0 128 [::]:22 [::]:* users:(("sshd",pid=1070,fd=8))- Only
sshdlistens, on port 22. Nothing else on the image opens a TCP port. - The
publiczone allowssshanddhcpv6-client, which carries replies to the instance's IPv6 DHCP client. This is how an instance in an IPv6-enabled subnet gets its address. The AlmaLinux defaultcockpitservice is removed from the zone, and Cockpit is not installed. - The loopback interface sits in the firewalld
trustedzone, with rules that drop traffic claiming a loopback source from anywhere else (a CIS requirement).
To open a port for your own service, allow it in two places: the instance's security group and firewalld. For example, for a web server on 443, run this on the instance:
sudo firewall-cmd --permanent --add-service=https sudo firewall-cmd --reloadIf a port is open in the security group but not in firewalld, or the other way round, the traffic does not arrive.
Time sync and the Systems Manager agent
systemctl is-active chronyd amazon-ssm-agent chronyc -n sourcesExpected output (the pool servers and timings vary):
active active MS Name/IP address Stratum Poll Reach LastRx Last sample =============================================================================== ^- 23.186.168.125 2 6 17 45 -977us[ -186us] +/- 55ms ^- 216.66.48.42 1 6 17 45 +1876us[+2667us] +/- 9570us ^- 108.61.56.35 2 6 17 45 -453us[ +338us] +/- 50ms ^- 69.10.208.170 2 6 17 45 -586us[ +205us] +/- 67ms ^* 169.254.169.123 3 4 77 13 +12us[ +379us] +/- 644usThe ^* marks the source that chrony is using: 169.254.169.123, the Amazon Time Sync Service. It is reachable from every instance without internet access, so time stays correct in a private subnet too. The public AlmaLinux pool servers are fallbacks.
The AWS Systems Manager agent is installed from Amazon's own package at its current release (3.3.5390.0 on this build). It is not in the AlmaLinux repositories, so dnf does not update it. Systems Manager can keep it current for you, using the AWS-UpdateSSMAgent document or the Auto update SSM Agent setting in Fleet Manager.
Patch level and automatic updates
The image is fully patched at build time. Check which updates are pending now:
sudo dnf -q check-update --refresh echo "dnf check-update exit code: $? (0 = nothing to update, 100 = updates available)" grep -E '^(upgrade_type|apply_updates)' /etc/dnf/automatic.conf systemctl is-enabled dnf-automatic.timer uname -rExpected output on an instance launched soon after the image was built (later launches list the updates released since, with exit code 100):
dnf check-update exit code: 0 (0 = nothing to update, 100 = updates available) upgrade_type = security apply_updates = yes enabled 6.12.0-211.67.1.el10_2.x86_64dnf-automatic runs daily (06:00, with a random delay of up to an hour) and installs security updates automatically. To update everything now, run:
sudo dnf -y upgradeReboot if a new kernel was installed:
sudo systemctl rebootSecurity settings on the instance
getenforce
sudo passwd -S root
sudo sshd -T | grep -E '^(permitrootlogin|passwordauthentication|pubkeyauthentication|maxauthtries|clientaliveinterval|banner) ' cat /etc/issue.netExpected output:
Enforcing root L 2024-12-14 0 99999 7 -1 maxauthtries 4 clientaliveinterval 300 permitrootlogin no pubkeyauthentication yes passwordauthentication no banner /etc/issue.net Authorized users only. All activity may be monitored and reported.Enforcingmeans SELinux is on and enforcing the targeted policy. Keep it on. If your own software is denied, checksudo ausearch -m avc -ts recentrather than disabling SELinux.Lin the second column means the root account is locked.maxauthtries 4andclientaliveinterval 300come from the CIS profile. SSH allows four authentication attempts per connection and checks idle sessions every five minutes.- The banner text is shown before login.
EC2 Serial Console and recovery. No account on this image has a password, so the serial console cannot log in until you set one. If you want serial console access, set a password for your own user on your running instance. The password is yours and is not on the image:
sudo passwd ec2-userDisk size, swap and file integrity
df -hT /
sudo grep -E 'cc_growpart.*(resized|NOCHANGE)' /var/log/cloud-init.log | tail -1 swapon --noheadings --show | wc -l sudo grep -h aide /etc/crontabExpected output with the default 10 GiB root volume (on a larger volume, Size is larger and the cloud-init line says resized):
Filesystem Type Size Used Avail Use% Mounted on /dev/nvme0n1p4 xfs 8.8G 1.5G 7.4G 17% / 2026-10-19 23:58:17,083 - cc_growpart.py[DEBUG]: '/' NOCHANGE: no change necessary (/dev/nvme0n1, 4) 0 05 4 * * * root /usr/sbin/aide --check- Disk layout. The instance boots with UEFI. The root filesystem is XFS on partition 4 of the root volume.
/boot(XFS) and/boot/efiare separate small partitions. - Disk growth. cloud-init grows the root partition and filesystem to the volume size on first boot. To grow the volume later, increase the EBS volume size in the console or with
aws ec2 modify-volume. Then runsudo growpart /dev/nvme0n1 4 && sudo xfs_growfs /, or reboot. - Swap. The image has no swap. Add a swap file yourself if your workload needs one.
- AIDE. The file integrity database is built from the image's own files, and the CIS profile schedules
aide --checkdaily at 04:05 from/etc/crontab.
Install software and add users
The instance uses the standard AlmaLinux 10 repositories (BaseOS, AppStream, CRB and Extras):
sudo dnf -q list --available nginxExpected output (the version changes over time):
Available Packages nginx.x86_64 2:1.26.3-6.el10_2.7 appstreamInstall and start software in the usual way, for example sudo dnf -y install nginx then sudo systemctl enable --now nginx. Open its port in the security group and firewalld (Step 8). The AWS CLI is not on the image. If you need it, install the current version from AWS (see the AWS CLI install guide).
To add another administrator, create the account, add it to the wheel group and give it an SSH key:
sudo useradd -m -G wheel alice
sudo install -d -m 700 -o alice -g alice /home/alice/.ssh echo "ssh-ed25519 AAAA... alice@laptop" | sudo tee /home/alice/.ssh/authorized_keys
sudo chown alice:alice /home/alice/.ssh/authorized_keys && sudo chmod 600 /home/alice/.ssh/authorized_keys
sudo restorecon -R /home/alice/.sshBecause SSH is key-only, a new account needs its key in authorized_keys. The restorecon command gives the file the SELinux label that sshd expects.
The new account has no password, so sudo cannot authenticate it until you give it one with sudo passwd alice. SSH stays key-only, and sudo uses the password. Only ec2-user, created by cloud-init, has password-free sudo.
Common use cases
- A base for workloads that must show CIS Level 1 alignment on enterprise Linux 10, with the evaluation report already on the machine
- Software certified or packaged for RHEL 10 compatible systems, with SELinux enforcing from the first boot
- Container hosts and automation targets that want a small base supported until 2035
- Fleets managed through Systems Manager, with IMDSv2 required from the first boot
- A starting point for your own golden image. Add your software, re-run Step 6, and keep the report with your build.
Troubleshooting
SSH says "Too many authentication failures"
The SSH server allows four authentication attempts per connection. If your SSH agent holds several keys, it can use up the attempts before it offers the right key. Tell SSH to offer only the key you name:
ssh -o IdentitiesOnly=yes -i ~/.ssh/my-key-pair.pem ec2-user@<public-ip>Cannot connect via SSH
- Check that the instance is running and has passed its status checks.
- Check that the security group allows TCP 22 from your current public address.
- Use the user name
ec2-userand the key pair that you chose at launch. Password login is disabled, so a wrong key never falls back to a password prompt. - If you changed firewalld, make sure the
sshservice is still allowed. Session Manager (Step 2) still works if SSH is blocked, provided the instance has a Systems Manager instance profile.
The instance does not boot on an older instance type
AlmaLinux 10 for x86_64 is built for the x86-64-v3 feature level. Very old instance families whose processors lack AVX2 cannot run it. Choose a current-generation type such as m5, m6i, m7i, c6i or t3.
My service is running but not reachable
Allow the port in both the security group and firewalld (Step 8). Run sudo firewall-cmd --list-all to see the firewalld rules. Run sudo ss -tlnp to see whether the service listens on all addresses or only on loopback.
If the service runs on a non-standard port, SELinux may also need to allow it. Install the SELinux management tools with sudo dnf -y install policycoreutils-python-utils. Then, for example, run sudo semanage port -a -t http_port_t -p tcp 8080 for a web server on 8080.
A tool that uses instance metadata fails
The image requires IMDSv2. Old scripts that call http://169.254.169.254/ without a token get HTTP 401. Update them to request a token first (Step 7), or use the AWS CLI or a current SDK.
Package manager issues
Refresh the metadata first:
sudo dnf -q makecache --refresh && echo "repository metadata refreshed"If the repositories are unreachable, check that the instance has outbound internet access (a public IP or a NAT gateway) and that DNS resolves:
getent hosts repo.almalinux.orgImportant notes
AlmaLinux is free and open source software. It is a distribution of thousands of packages, each under its own license (GPL, LGPL, MIT, BSD, Apache 2.0 and others). rpm -qi <package> shows each package's license. No subscription or license key is needed to run this image.
The compliance tooling is OpenSCAP (LGPL 2.1 or later) and SCAP Security Guide content (BSD 3-Clause, license text in /usr/share/doc/sac/scap-security-guide-LICENSE.txt).
AlmaLinux 10 is maintained by the AlmaLinux OS Foundation until 2035. This version tracks the AlmaLinux 10 release stream, so new minor releases arrive as ordinary updates.
The CIS Level 1 Server profile used here is the OpenSCAP profile published in SCAP Security Guide. These images are not CIS Hardened Images and are not certified by the Center for Internet Security. A pass rate measures this image as built. Your own changes affect it, which is why you can re-run the evaluation (Step 6).
AlmaLinux is a trademark of the AlmaLinux OS Foundation. Red Hat Enterprise Linux is a trademark of Red Hat, Inc. CIS is a trademark of the Center for Internet Security. These names are used only to identify the software, its compatibility and the profile. SecureAnyCloud is not affiliated with or endorsed by the AlmaLinux OS Foundation, Red Hat or the Center for Internet Security.
Support
For help with this image, contact SecureAnyCloud support:
- Website: secureanycloud.com
- User Guides: secureanycloud.com/guides
- AlmaLinux on AWS hub: secureanycloud.com/guides/almalinux-aws
Deploy on AWS
Launch AlmaLinux 10 Minimal on AWS with 24/7 support from SecureAnyCloud.
View on Marketplace
Need Help?
Our support team is available 24/7.
sales@secureanycloud.com