How To Install Plex Media Server on AlmaLinux 10
Setting up a robust media streaming solution has become essential for modern home entertainment systems. Plex Media Server on AlmaLinux 10 provides the perfect combination of enterprise-grade stability and powerful media streaming capabilities. This comprehensive installation guide covers every step needed to successfully deploy Plex on the latest AlmaLinux release.
AlmaLinux 10 represents a significant milestone in enterprise Linux distributions, offering enhanced security features and improved performance that make it ideal for hosting media servers. When combined with Plex Media Server’s intuitive interface and extensive client support, this configuration delivers a professional-grade streaming solution suitable for both home users and small businesses.
This tutorial provides detailed step-by-step instructions, troubleshooting solutions, and performance optimization techniques. Whether you’re migrating from another platform or setting up your first media server, this guide ensures a smooth installation process while establishing security best practices from the start.
Prerequisites and System Requirements
Hardware Requirements
Minimum system specifications for Plex Media Server installation on AlmaLinux 10 vary significantly based on intended usage patterns and media transcoding requirements. For basic direct streaming without transcoding, a dual-core processor with 4GB RAM suffices.
Transcoding requirements scale dramatically with concurrent users and video quality. 4K transcoding demands Intel Core i7 processors or equivalent AMD Ryzen CPUs with hardware acceleration support. Systems handling multiple simultaneous transcoding sessions benefit from 16-32GB RAM and dedicated graphics cards supporting hardware encoding.
Storage considerations extend beyond simple capacity calculations. SSD storage significantly improves database performance and metadata loading times, particularly for libraries containing thousands of media files. Network-attached storage (NAS) systems provide expandable capacity but may introduce latency affecting real-time transcoding performance.
Software Prerequisites
AlmaLinux 10 installation requires 64-bit processor architecture and minimum 10GB available disk space for the base system. Fresh installations prevent potential conflicts with existing services and ensure optimal performance for Plex deployment.
Administrative privileges through sudo access are essential for package installation and system configuration modifications. Active internet connectivity enables package downloads, Plex account authentication, and metadata retrieval during library setup.
Domain name configuration or static IP addressing facilitates remote access setup and SSL certificate implementation for secure connections. Dynamic DNS services provide alternatives for home networks without static IP assignments.
Preparing AlmaLinux 10 for Installation
System Updates and Package Management
Comprehensive system updates ensure compatibility with Plex Media Server packages and eliminate potential security vulnerabilities. The DNF package manager handles dependency resolution and maintains system integrity during installation processes.
Execute these commands to update the AlmaLinux 10 system:
sudo dnf update -y
sudo dnf install -y wget curl epel-release
sudo dnf groupinstall "Development Tools" -y
Development Tools package group provides compilation utilities and libraries that may be required for certain Plex features or third-party plugins. The EPEL repository expands available software packages beyond the standard AlmaLinux repositories.
Reboot the system after major kernel updates to ensure all changes take effect properly. System reboots also verify that critical services start correctly with updated configurations:
sudo reboot
Firewall Configuration Basics
AlmaLinux 10 implements firewalld as the default firewall management system, providing zone-based security policies and dynamic rule updates. Understanding firewall zones helps configure appropriate access controls for Plex Media Server.
Check current firewall status and active zones:
sudo firewall-cmd --state
sudo firewall-cmd --get-default-zone
sudo firewall-cmd --list-all
The public zone typically serves as the default configuration for internet-facing services. Plex requires specific port configurations that will be addressed during the network configuration phase.
SELinux integration with firewalld provides additional security layers for AlmaLinux systems. Verify SELinux status to understand security policy enforcement:
sudo getenforce
sudo sestatus
Installing Plex Media Server
Downloading Plex Media Server
Navigate to the official Plex downloads page to obtain the latest RPM package specifically designed for Red Hat Enterprise Linux distributions. AlmaLinux maintains compatibility with RHEL packages, ensuring proper functionality and support.
Download the latest stable release using wget
with the official Plex repository URL:
cd /tmp
wget https://downloads.plex.tv/plex-media-server-new/1.40.4.8679-424562606/redhat/plexmediaserver-1.40.4.8679-424562606.x86_64.rpm
Version numbers change regularly as Plex releases updates. Check the official downloads page for the most current version number before executing download commands.
Verify download integrity by checking file size and ensuring the download completed successfully:
ls -lh plexmediaserver-*.rpm
RPM Installation Process
DNF package manager handles RPM installations with automatic dependency resolution and GPG signature verification. The installation process creates system users, directories, and service files required for Plex operation.
Install Plex Media Server using DNF:
sudo dnf install -y ./plexmediaserver-*.rpm
GPG key import may be required during first-time installation. Accept the key import when prompted to complete the installation process. The installation creates a dedicated ‘plex’ system user with restricted privileges for security purposes.
Verify successful installation by checking package information:
rpm -qi plexmediaserver
Installation directories include:
/usr/lib/plexmediaserver/
– Application files/var/lib/plexmediaserver/
– Data directory/etc/systemd/system/
– Service configuration
Service Configuration and Startup
Systemd service management controls Plex Media Server startup, shutdown, and automatic restart functionality. Enable the service for automatic startup during system boot sequences.
Configure and start the Plex service:
sudo systemctl enable plexmediaserver.service
sudo systemctl start plexmediaserver.service
sudo systemctl status plexmediaserver.service
Service status output indicates running state, process ID, and recent log entries. Active status confirms successful startup and proper service configuration.
Log file monitoring helps troubleshoot startup issues and performance problems:
sudo journalctl -u plexmediaserver.service -f
Firewall and Network Configuration
Opening Required Ports
Plex Media Server requires port 32400 for web interface access and client connections. Additional ports may be needed for specific features like DLNA or network discovery protocols.
Open Plex ports through firewalld:
sudo firewall-cmd --permanent --add-port=32400/tcp
sudo firewall-cmd --permanent --add-service=plex
sudo firewall-cmd --reload
Predefined Plex service definitions simplify firewall configuration by automatically opening all required ports. Custom port configurations may be necessary for non-standard installations or security requirements.
Verify firewall rules:
sudo firewall-cmd --list-ports
sudo firewall-cmd --list-services
Additional ports for advanced features:
- 1900/udp – DLNA discovery
- 3005/tcp – Plex Companion
- 8324/tcp – Roku via Plex Companion
- 32410-32414/udp – Network discovery
Network Security Considerations
IP address restrictions enhance security by limiting access to specific networks or IP ranges. Home networks benefit from restricting access to local subnet addresses while maintaining internet accessibility for remote users.
Configure rich rules for IP-based restrictions:
sudo firewall-cmd --permanent --add-rich-rule='rule family="ipv4" source address="192.168.1.0/24" port protocol="tcp" port="32400" accept'
sudo firewall-cmd --reload
SELinux context management ensures Plex operates within defined security policies without compromising system integrity. SELinux may require specific contexts for media directories and network access.
Check and configure SELinux contexts:
sudo setsebool -P httpd_can_network_connect on
sudo semanage fcontext -a -t httpd_exec_t "/usr/lib/plexmediaserver/Plex Media Server"
sudo restorecon -R /var/lib/plexmediaserver/
Initial Plex Setup and Configuration
Web Interface Access
Access the Plex web interface through a local browser connection to complete initial configuration. The setup wizard guides users through account creation, server naming, and basic preferences.
Open a web browser and navigate to:
http://localhost:32400/web
Account creation or sign-in links the server to Plex services and enables remote access features. Existing Plex accounts provide immediate access to purchased content and preferences.
Server naming conventions should reflect the server’s purpose and location for easy identification across multiple devices. Descriptive names like “Home-Media-Server” or “Living-Room-Plex” improve user experience in multi-server environments.
Network discovery settings determine how the server appears to clients on the local network. Enable local network access for better performance and reduced bandwidth usage for local streaming.
Library Creation and Media Organization
Media library setup requires proper directory structure and file naming conventions for optimal metadata detection. Plex supports multiple media types including movies, TV shows, music, and photos with specialized scanning engines for each type.
Create dedicated directories for different media types:
sudo mkdir -p /media/plex/{movies,tvshows,music,photos}
sudo chown -R plex:plex /media/plex/
sudo chmod -R 755 /media/plex/
File naming conventions significantly impact metadata accuracy and library organization. Follow Plex’s recommended formats:
- Movies:
Movie Title (Year)/Movie Title (Year).ext
- TV Shows:
Show Name/Season XX/Show Name - sXXeYY - Episode Title.ext
Library scanning performance improves with organized directory structures and consistent naming patterns. Large libraries benefit from periodic maintenance and optimization procedures.
Advanced Configuration Options
Reverse Proxy Setup with Apache
Apache reverse proxy configuration enables SSL termination, custom domain access, and enhanced security features. This setup centralizes web traffic management and provides professional deployment characteristics.
Install and configure Apache:
sudo dnf install -y httpd mod_ssl
sudo systemctl enable httpd.service
sudo systemctl start httpd.service
Create virtual host configuration for Plex:
<VirtualHost *:443>
ServerName plex.example.com
SSLEngine on
SSLCertificateFile /etc/ssl/certs/plex.crt
SSLCertificateKeyFile /etc/ssl/private/plex.key
ProxyPreserveHost On
ProxyRequests Off
ProxyPass / http://localhost:32400/
ProxyPassReverse / http://localhost:32400/
# WebSocket support
ProxyPass /:/websockets/notifications ws://localhost:32400/:/websockets/notifications
ProxyPassReverse /:/websockets/notifications ws://localhost:32400/:/websockets/notifications
</VirtualHost>
SSL certificate configuration requires valid certificates from trusted authorities or properly configured self-signed certificates. Let’s Encrypt provides free SSL certificates suitable for home installations.
Remote Access Configuration
Remote access functionality allows streaming from anywhere with internet connectivity. Plex offers both automatic UPnP configuration and manual port forwarding options for different network scenarios.
Enable remote access through Plex settings:
- Navigate to Settings → Remote Access
- Enable “Enable Remote Access”
- Configure public port (default: 32400)
- Test connectivity
Manual port forwarding may be required for networks without UPnP support. Router configuration varies by manufacturer but generally requires forwarding external port 32400 to the server’s internal IP address.
Upload bandwidth significantly impacts remote streaming quality. Configure appropriate quality settings based on available upload speed:
- 720p: 4 Mbps upload minimum
- 1080p: 10 Mbps upload minimum
- 4K: 25+ Mbps upload minimum
Dynamic DNS services provide consistent access for networks with changing IP addresses. Popular services include No-IP, DuckDNS, and DynDNS offering free and paid options.
Performance Optimization
Hardware Transcoding Configuration
Hardware-accelerated transcoding dramatically improves performance and reduces CPU usage during media conversion. Modern Intel processors support Quick Sync Video technology while NVIDIA graphics cards provide NVENC encoding capabilities.
Enable hardware transcoding in Plex settings:
- Settings → Transcoder
- Enable “Use hardware acceleration when available”
- Configure transcoding quality settings
- Test with sample media files
Intel Quick Sync requires specific CPU models and proper driver installation. Verify hardware support:
sudo lspci | grep VGA
sudo lshw -c video
NVIDIA hardware transcoding requires proprietary drivers and CUDA toolkit installation. Community repositories provide pre-compiled packages for AlmaLinux systems.
Transcoding performance monitoring helps optimize settings for specific hardware configurations. Monitor CPU usage, memory consumption, and transcoding queue status during peak usage periods.
Database Optimization
Plex database maintenance improves performance for large media libraries and reduces scanning times. Regular optimization procedures prevent database fragmentation and corruption issues.
Database maintenance commands:
sudo systemctl stop plexmediaserver.service
sudo -u plex /usr/lib/plexmediaserver/Plex\ SQLite /var/lib/plexmediaserver/Library/Application\ Support/Plex\ Media\ Server/Plug-in\ Support/Databases/com.plexapp.plugins.library.db "VACUUM;"
sudo systemctl start plexmediaserver.service
Cache size adjustments optimize memory usage for different system configurations. Systems with abundant RAM benefit from larger cache sizes while resource-constrained systems require conservative settings.
Implement automated backup procedures for critical database files:
#!/bin/bash
sudo systemctl stop plexmediaserver.service
sudo cp -R /var/lib/plexmediaserver/Library/Application\ Support/Plex\ Media\ Server/Plug-in\ Support/Databases/ /backup/plex-db-$(date +%Y%m%d)/
sudo systemctl start plexmediaserver.service
Troubleshooting Common Issues
Connection and Access Problems
Server detection failures often result from firewall misconfigurations or network connectivity issues. Systematic troubleshooting helps identify and resolve access problems efficiently.
Common connection troubleshooting steps:
- Verify service status:
sudo systemctl status plexmediaserver.service
- Check port accessibility:
sudo netstat -tlnp | grep 32400
- Test local access:
curl http://localhost:32400/identity
- Review firewall rules:
sudo firewall-cmd --list-all
Remote access troubleshooting requires verification of both local configuration and external network settings. Router configuration, ISP restrictions, and dynamic IP changes commonly cause remote access failures.
Network diagnostic commands:
# Test internal connectivity
telnet localhost 32400
# Check external port accessibility
nmap -p 32400 your-external-ip
# Verify DNS resolution
nslookup plex.example.com
Log analysis provides detailed information about connection attempts and error conditions. Enable debug logging for comprehensive troubleshooting information.
Permission and File Access Issues
File permission problems frequently occur when media files are owned by different users or have restrictive permissions. Plex requires read access to media files and read/write access to its data directory.
Correct common permission issues:
# Fix media directory permissions
sudo chown -R plex:plex /media/plex/
sudo chmod -R 755 /media/plex/
# Fix Plex data directory permissions
sudo chown -R plex:plex /var/lib/plexmediaserver/
sudo chmod -R 755 /var/lib/plexmediaserver/
SELinux context errors may prevent Plex from accessing media files even with correct UNIX permissions. Verify and configure appropriate SELinux contexts for media directories.
SELinux troubleshooting commands:
# Check current contexts
ls -laZ /media/plex/
# Set appropriate contexts
sudo semanage fcontext -a -t httpd_exec_t "/media/plex(/.*)?"
sudo restorecon -R /media/plex/
Network file system permissions require additional consideration for NFS, CIFS, or other network-mounted storage. Mount options must preserve file permissions and user mappings for proper Plex operation.
Security Best Practices
User and Permission Management
Dedicated system accounts provide security isolation and limit potential damage from security breaches. The Plex installation automatically creates a restricted ‘plex’ user account with minimal system privileges.
Verify Plex user configuration:
id plex
sudo getent passwd plex
sudo groups plex
Access control implementation restricts administrative functions to authorized users while maintaining operational functionality. Avoid running Plex with elevated privileges unless absolutely necessary for specific configurations.
Configure sudo access for Plex management:
# Create plex-admin group
sudo groupadd plex-admin
# Add users to plex-admin group
sudo usermod -a -G plex-admin username
# Configure sudo rules
echo "%plex-admin ALL=(ALL) NOPASSWD: /usr/bin/systemctl * plexmediaserver.service" | sudo tee /etc/sudoers.d/plex-admin
Network Security Hardening
Intrusion detection systems monitor for suspicious activity and potential security breaches. Fail2ban provides automated response to repeated authentication failures and suspicious network behavior.
Install and configure fail2ban:
sudo dnf install -y fail2ban
sudo systemctl enable fail2ban.service
sudo systemctl start fail2ban.service
SSL certificate implementation encrypts data transmission and provides authentication for remote connections. Let’s Encrypt certificates offer free SSL/TLS encryption suitable for most installations.
Configure automatic certificate renewal:
sudo dnf install -y certbot
sudo certbot --apache -d plex.example.com
sudo systemctl enable --now certbot-renew.timer
Network monitoring helps detect unusual traffic patterns and potential security incidents. Log analysis tools provide insights into access patterns and system behavior.
Maintenance and Updates
Regular System Maintenance
Automated update procedures ensure security patches and feature improvements are applied promptly while maintaining system stability. Configure automatic updates for critical security patches while manual approval for major version changes.
Configure automatic security updates:
sudo dnf install -y dnf-automatic
sudo systemctl enable --now dnf-automatic-install.timer
Log rotation and cleanup prevents disk space exhaustion and maintains system performance. Configure logrotate for Plex-specific log files:
sudo tee /etc/logrotate.d/plexmediaserver << EOF /var/lib/plexmediaserver/Library/Application Support/Plex Media Server/Logs/*.log { daily missingok rotate 7 compress notifempty create 644 plex plex postrotate sudo systemctl reload plexmediaserver.service > /dev/null 2>&1 || true
endscript
}
EOF
Performance monitoring helps identify resource bottlenecks and optimization opportunities. System monitoring tools track CPU usage, memory consumption, and disk I/O patterns during normal operation.
Backup and Recovery Procedures
Comprehensive backup strategies protect against data loss from hardware failures, software corruption, or administrative errors. Backup procedures should include database files, configuration data, and custom metadata.
Create backup script for critical Plex data:
#!/bin/bash
BACKUP_DIR="/backup/plex-$(date +%Y%m%d-%H%M%S)"
mkdir -p "$BACKUP_DIR"
# Stop Plex service
sudo systemctl stop plexmediaserver.service
# Backup database and configuration
sudo cp -R "/var/lib/plexmediaserver/Library/Application Support/Plex Media Server/" "$BACKUP_DIR/"
# Restart Plex service
sudo systemctl start plexmediaserver.service
# Compress backup
sudo tar -czf "$BACKUP_DIR.tar.gz" -C "$BACKUP_DIR" .
sudo rm -rf "$BACKUP_DIR"
echo "Backup completed: $BACKUP_DIR.tar.gz"
Recovery testing verifies backup integrity and restoration procedures. Regular recovery tests ensure backups remain viable and restoration procedures work correctly under various scenarios.
Automated backup scheduling using cron jobs ensures consistent backup creation without manual intervention:
# Add to crontab for weekly backups
0 2 * * 0 /usr/local/bin/plex-backup.sh
Congratulations! You have successfully installed Plex. Thanks for using this tutorial for installing Plex Media Server on your AlmaLinux OS 10 system. For additional help or useful information, we recommend you check the official Plex website.