Driver FixRecommendedSound, Wi-Fi or graphics acting up? Check drivers firstFind missing or outdated drivers fast.Check DriversHalloween DealsAmazon USHalloween week deals: useful picks before month-endAmazon US: current deals, useful picks and tech finds.Check DealsWindows FixRecommendedWindows errors stealing your time? Find the fix fastScan stability, cleanup and performance issues.Fix Now×
Skip to content
World desk11 min

How to Install Magento with Sample Data on a Linux VPS

A release-specific, step-by-step guide to installing Magento with sample data on a Linux VPS, including Composer authentication, OpenSearch or Elasticsearch preparation, developer mode, database updates, verification, and cleanup.
Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

The reliable way to install Magento with sample data on a Linux VPS is to select the exact Adobe Commerce or Magento Open Source release first, match every server component to that release’s compatibility matrix, install the application with Composer, switch to developer mode, run bin/magento sampledata:deploy as the file-system owner, apply the update, and then verify the storefront and Admin in a browser. Sample data is intended for learning and development, not for a production catalog.

What you need before starting

Magento is a complete application stack rather than a single package. The VPS must provide a supported Linux x86-64 operating system, PHP, Composer, a supported MySQL-compatible database, a web server, and a supported search engine. Exact versions vary by Magento or Adobe Commerce release and patch line, so choose the release before installing anything.

As an Amazon Associate I earn from qualifying purchases.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Open Adobe’s System Requirements page, select the precise release row, and record every value in that row. Do not copy PHP, database, OpenSearch, Elasticsearch, nginx, Composer, or cache-service versions from an older tutorial. Compatibility tables change between release lines, and a server that worked for one release can fail during installation of another.

Component How to choose it Why it matters
Operating system Use a supported Linux x86-64 distribution listed for the selected release. Unsupported system libraries can prevent PHP extensions, the web server, or search services from starting correctly.
PHP Install the PHP version shown in the selected release row, including all extensions required there. Magento checks PHP compatibility during Composer installation and setup.
Composer Use the Composer major and minor version specified for the release. Composer resolves Magento packages and their dependencies; an incompatible Composer version can produce dependency errors.
Database Use the listed MariaDB or MySQL release. Schema creation and data upgrades depend on the database engine and version.
Search engine Choose OpenSearch or Elasticsearch only if the selected release supports that engine and version. Magento uses the search service for catalog indexing and, in recent releases, requires it during installation.
Web server and cache services Match the nginx and cache-service versions in the same matrix row. Version mismatches can cause routing, session, cache, or static-file problems after installation.

A VPS size is not a guarantee of success. The official installation material does not promise that a particular amount of CPU, memory, or storage will run every catalog. Leave room for the operating system, database, Composer’s temporary files, generated static assets, logs, and search indexes, and monitor resource use during installation.

#1 Best Overall
Sale
TOZO A1 Wireless Earbuds Bluetooth 5.3 Light Weight in Ear Headphones | IPX5 Waterproof,2 Mics for AI Calls,Immersive Premium Sound Bass Headset with Charging Case,32 EQ via App Black
  • [Ultra-Lightweight Ear Buds Designed for Small Ears] Each earbud weighs only 3.7g and features a compact, ergonomic in-ear design made especially for small ears. Secure, low-profile, and comfortable for workouts, all-day wear or overnight sleeping.The ultra-slim profile sits flush in your ear with no hard edges poking or rubbing, so you can even sleep on your side without discomfort.
  • [Immersive Stereo Sound with TOZO OrigX Technology] TOZO OrigX tuning delivers clear vocals, balanced mids, and natural stereo sound for music, podcasts, and videos.
  • [Long Battery Life for Daily Use] Get up to 7 hours of playtime on a single charge, with up to 32 hours total using the charging case—ideal for workdays, commuting, and extended listening sessions.
  • [Bluetooth 5.3 & Stable Connection] Bluetooth 5.3 provides fast pairing, stable wireless performance, and reduced dropouts as you move around home or office.
  • [Deep Bass with Clear Vocals] High-performance drivers produce punchy bass while keeping vocals clean and detailed for everyday listening.

Prepare the VPS and service accounts

Provision the selected Linux x86-64 image and update it using the distribution’s normal package manager. Install only the versions listed for your Magento release. Keep administrative access separate from the account that owns the Magento files: use an administrator account for operating-system changes, and a dedicated non-root account for Composer and bin/magento commands.

Create the web root, database, and search service before running the Magento installer. Give the web server read access to the application and write access only to the directories Magento documents as writable. After extracting or creating the project, make the file-system owner consistent across the entire application tree:

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
sudo chown -R magento:magento /var/www/magento

The user and group in that command are examples of a dedicated account and must match the account you actually use. Do not run Composer or Magento CLI commands as root. Mixed ownership is a common cause of later failures when Composer, the web server, and Magento try to write different files.

Install and test the search engine first

Adobe states that you must install and configure either Elasticsearch or OpenSearch before installing Adobe Commerce 2.4.4 and later. The supported engine and version are release-specific; do not assume that the newest OpenSearch or Elasticsearch release is valid for your chosen Magento package.

Install the engine listed in the exact compatibility row, bind it to the address your Magento application can reach, and protect it from public Internet access. Record the host, port, and any authentication details. Before launching Magento’s installer, test the service from the VPS with the engine’s own health or information endpoint. A successful response proves that the daemon is running and reachable; it does not prove that Magento supports that version, so verify both facts independently.

During setup:install, select the matching search-engine option and provide the same host, port, and credentials. If the installer cannot connect, stop and fix the search service or its firewall rules rather than trying to complete Magento without search.

Free tools Windows power users keep installed

One-click scans. No signup required.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
Rank #2
Sale
Smart Watch for Men Women Compatible with iPhone Samsung Android Phone 1.69 inch Full Touch Screen IP68 Waterproof Bluetooh Fitness Tracker Heart Rate/Sleep Monitor (Black)
  • 【IP68 Waterproof Multifunctinal Smart Watch】Torjalph fitness activity tracker smart watch is IP68 waterproof technology ,you can wear it when swimming,handwashing,it's rain-proof which means that you perform multiple exercise modes outside without worrying about sweat or rain corroding your fitness smart watch,and this watch equipped with a 230 mAh large capacity battery magnetic charging ,and this sports activity tracker watch can be used 5-7 days If fully charged.
  • 【Larger 1.83'' Full Screen Watch & Multi-dial Selection】1.83 inch full HD color touch screen smart watch for men / women provides excellent 240*284 resolution image quality ,This Bluetooth smart watch offers a better touch experience and remarkable immersion and ,more than 200 watch faces for you to choose from App"Da Fit ", you can change the dial style according to your mood to wear keeping the world on your wrist
  • 【Accurate Activity Tracker Smart Watch 】sports watch activity tracker uses sweat and dust resistant breathable silicone strap, our Fitness Tracker Smart Watch for Android iOS Phones supports 12 sports modes,walking,running,bicycle,swimming,badminton,basketball,football,rope skipping. This bluetooth calls smart watch for men women is lightweight and stylish, bringing more convenient and relaxing sports experience while also providing more protection.
  • 【Your 24 Hour Personal Daily Health Monitor】Fitness watch for women men full touch screen IP67 waterproof bluetooth smartwatch for Android iOS Phones with heart rate blood pressure monitor multifunction Andriod smart watch with steps counter sleep monitor sports fitness watch, monitoring blood oxygen saturation allows you to understand your physical condition in real time to track fitness progress ,to know your health status in time.
  • 【More Functions Bluetooth Call Smart Watch】This fitness activity smart watch full screen for iPhone and Android phones includes a bunch of new features including:The bluetooth smart watch can hang up the phone, receive and display WhatsAPP /Text /Facebook /Twitter /Messenger reminder.Support sedentary reminder, alarm clock, stopwatch, timer,weather information,music control, remote camera control compatible with Android 5.0 and above or iOS 9.0 and above smartphones.

Configure Composer authentication

Magento packages are downloaded from repo.magento.com. Adobe provides authentication keys through the account that has permission to download the edition and release you selected. The public key is the Composer username; the private key is the password. Use the same keys when installing the application and when downloading sample-data packages.

You can configure credentials globally with Composer variables, avoiding a private key in shell history:

read -p "Composer public key: " COMPOSER_PUBLIC_KEY
read -s -p "Composer private key: " COMPOSER_PRIVATE_KEY
echo
composer config --global http-basic.repo.magento.com "$COMPOSER_PUBLIC_KEY" "$COMPOSER_PRIVATE_KEY"

Alternatively, run the Composer command and enter the credentials when Composer prompts. Never publish the private key in a script, a screenshot, a ticket, or a publicly readable file. If the VPS will be rebuilt, store the keys in your organization’s secret-management system and reconfigure Composer during provisioning.

Install Magento with Composer

Use Adobe’s installation tutorial for the exact create-project command, package name, and release constraint. The package differs between Magento Open Source and Adobe Commerce, so do not substitute one edition’s package for the other. The following pattern illustrates a Magento Open Source project location; select the release constraint that matches the row you chose:

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
cd /var/www
composer create-project --repository-url=https://repo.magento.com/ magento/project-community-edition magento

For Adobe Commerce, use the enterprise package and release command documented for your licensed account. Composer will resolve dependencies, download the application, and create the bin/magento CLI in the project root. If Composer reports that a PHP extension, version, or package cannot be installed, treat that as a compatibility or authentication problem. Do not force an older dependency simply to make the command finish.

After Composer completes, ensure the project is owned by the dedicated file-system account and that the web server can read the application. Work from the Magento root for every subsequent CLI command:

Rank #3
New Bee Guitar Cable 10ft Electric Instrument Bass AMP Cord
  • [Low Noise High Fidelity] New bee guitar cord with 22AWG oxygen-free-copper center conductors provides enhanced signal transfer, the PVC insulation material and the high-density stranded copper double shield provide noise rejection for quiet operation
  • [Ideal for Choice] New bee 1/4 straight and right angle metal connectors, ensures a secure connection in any instrument, pedal, or amp jack. L shape great fro on stage guitar stands
  • [Wide Compatible] Suitable for mixer, power amplifier, microphone, effector, decoder, equalizer, electoronic organ, electric guitar, electric bass and other electronic equipments. Widely used in the installation of smart home, karaoke speaker, professional stage audio, etc
  • [Easy Disassemble] Making incidental repairs quick and easy! Very nice, flexible cable
  • [Dont Hesite to Order] 24 hours customer services and professional technology team are standing by
cd /var/www/magento
sudo chown -R magento:magento /var/www/magento

Run the Magento installer

The installer creates the database schema, writes the application configuration, and registers the search service. Run it as the file-system owner. Supply the database name and user you created, the base URL for the VPS, an administrative username and password, a locale, a currency, a time zone, and the release-appropriate search options.

Use the official Adobe command for your release because search flags and supported values differ. A typical command has this shape:

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
bin/magento setup:install 
  --base-url=https://shop.example.net/ 
  --db-host=127.0.0.1 
  --db-name=magento 
  --db-user=magento 
  --db-password="database-password" 
  --admin-firstname=Store 
  --admin-lastname=Administrator 
  [email protected] 
  --admin-user=admin 
  --admin-password="administrative-password" 
  --language=en_US 
  --currency=USD 
  --timezone=UTC 
  --use-rewrites=1 
  --search-engine=opensearch

The domain, credentials, and search-engine value in this example are illustrative. Replace them with the values for your VPS and the option supported by your selected release. Use a strong, unique Admin password and do not reuse the database password. If your release requires additional OpenSearch or Elasticsearch flags, add exactly those documented by Adobe.

When setup finishes, Magento prints the Admin URI. Save it; some installations use a generated path rather than a simple /admin URL. Configure the web server’s document root and PHP handler according to Adobe’s deployment instructions, then point the DNS record at the VPS before browser testing.

Deploy the sample data

Sample data is a pre-generated store simulation. It supplies a Luma demonstration storefront with products, categories, customer registration, and related entities. It is useful for learning themes, testing extensions, demonstrating checkout flows, and confirming that indexing and media handling work. It is not a clean starting catalog for a live business.

Adobe explicitly warns that sample-data installation fails when the application is in production mode. From the Magento root, switch to developer mode and deploy the packages as the file-system owner:

Rank #4
BSIMB 15.6" Digital Family Calendar & Chore Chart, No Subscription Fees
  • Digital Family Calendar: BSIMB digital calendar wall touch screen puts an end to your chaotic life. Designed for busy families, the digital calendar keeps you organised and in step with your family. Assign different colours and tasks to each family member to make family scheduling easier and more intuitive.
  • Easy Setup and Auto-Sync: Plug in, connect to WLAN and auto-syn your electric calendar in minutes. Digital wall calendar compatible with Google calendar, iCloud calendar, Outlook calendar, Cozi calendar and Yahoo calendar. Add events directly on the device or through the ecalendar app. Electronic calendar stays current whether you're at work or traveling—no manual updates needed.
  • All-In-One Home Assistant: Smart calendar builds habits and encourage independence with personalised chores. Display daily meal plan to reduce the daily ‘What's for dinner?’ stress. To-do lists keep track of everything you want. Turning chores into valuable achievements with stars and rewards, making life easier and more enjoyable.
  • Manage Anytime Anywhere: BSIMB electronic calendar for family stay connected with the powerful ecalendar app. Access and manage your digital wall calendar anytime, anywhere with free features like stars & rewards, photo screensaver, chore charts, meals plans, to-do lists etc. Electronic planner paid features like Magic Import tailor advanced tools for users with special needs.
  • Stay in Touch with Loved Ones: Share photos or videos from your phone to electronic wall calendar with app, instantly update your life moment, and keep in touch with your family, especially those who are far away; you can also surprise your smart calendar digital wall by sending him a wish card; it's also great for keeping tech-illiterate elders in touch with the youngsters.
  1. Become the Magento file owner. Use the dedicated account that owns /var/www/magento; do not use root.
  2. Switch modes.
    bin/magento deploy:mode:set developer
  3. Download and register sample-data modules.
    bin/magento sampledata:deploy
  4. Authenticate if prompted. Composer may ask for the repo.magento.com keys. Enter the same keys used for the application packages.

sampledata:deploy adds the sample-data packages and module configuration; it does not by itself replace the database schema and data with the new module’s declarations. That is why the update step is required when sample data is added after the application installation.

Apply schema and data updates, then clean caches

Run the update and cache commands from the project root, still as the file-system owner:

bin/magento setup:upgrade
bin/magento cache:clean

setup:upgrade applies schema and data changes introduced by Magento modules and the sample-data packages. cache:clean removes Magento’s cached configuration and blocks so the new catalog and module state can be read. Wait for each command to complete and read its output; do not start several Magento CLI operations concurrently.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

If the deployment was interrupted, correct the reported problem first, confirm ownership again, and rerun the failed command. Repeating the entire installation blindly can obscure the original error and may leave partially generated configuration.

Independent reader supportYour contribution helps us test, update, and keep practical guides available for everyone.Support on Ko-Fi

Verify the storefront and Admin

Open the configured storefront URL and the Admin URI in a browser. A successful sample-data installation should make the Luma theme and demonstration catalog visible. Check the following in order:

  • The home page loads without a web-server or PHP error.
  • Category pages show sample products and product detail pages display prices, images, and options.
  • Search returns catalog results through the configured OpenSearch or Elasticsearch service.
  • The customer-registration page is present.
  • The Admin login accepts the account created by setup:install.
  • Admin catalog and category screens contain the demonstration entities.

Browser verification tests the complete path: DNS and TLS, the web server, PHP, Magento configuration, the database, the search service, and generated application data. If the storefront loads but catalog search fails, investigate search connectivity rather than reinstalling sample data.

Composer deployment versus the Git repository method

Most VPS operators should use Composer packages. The Git method is intended for contributing developers who have cloned Magento Open Source and need the sample-data source tree linked into a development checkout.

What’s actually slowing this PC down?

Pick the symptom - the matching free tool is one click away.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
Deployment method Who should use it Authentication Maintenance and permissions Release stability
Composer packages Ordinary development, staging, and VPS installations. Requires the repo.magento.com authentication keys for the application and sample-data packages. Composer manages package versions; keep the project owned by one file-system account and run Magento commands consistently. Use the released package and its documented dependency matrix.
Git repository Contributors working from a matching Magento Open Source source checkout. Uses the repository checkout and the permissions required by that development workflow. Clone the matching released branch of magento2-sample-data, run build-sample-data.php with --ce-source to create links, set ownership and group-write permissions, then run bin/magento setup:upgrade. More moving parts and greater risk of branch or source-tree mismatch; not the normal VPS deployment path.

Do not mix a sample-data branch from one Magento release with an application from another. If you are not contributing to Magento Open Source, the Composer route is simpler and less likely to leave incorrect links or permissions.

Troubleshoot common failures

Symptom Likely cause Action
Composer requests credentials or returns an authorization error. The keys are missing, belong to an account without package access, or are entered incorrectly. Configure the public and private keys for repo.magento.com, confirm that the account can download the selected edition, and rerun the Composer operation.
sampledata:deploy fails immediately in production mode. Adobe does not support installing sample data while production mode is active. Run bin/magento deploy:mode:set developer as the file owner, then rerun the deployment.
The installer cannot connect to search. The engine is not running, the host or port is wrong, a firewall blocks it, or the engine version is outside the release matrix. Test the service locally, compare its version with the exact Adobe compatibility row, correct network or authentication settings, and rerun the installer.
CLI commands report permission denied. Commands were run as different users or files are owned by root. Stop running as root, restore ownership with chown, and execute Composer and Magento commands as the dedicated file-system owner.
The storefront shows an empty or incomplete catalog after deployment. The sample-data modules were downloaded but their schema and data updates were not applied, or stale cache remains. Run bin/magento setup:upgrade followed by bin/magento cache:clean, then reload the storefront.
The page returns a server error or blank response. PHP, web-server, Magento, or search logs contain the underlying exception. Review those logs, correct the first reported error, verify ownership and service connectivity, and only then repeat the affected command.

Remove or reset sample data

Adobe provides commands for managing the sample-data modules:

bin/magento sampledata:remove
bin/magento sampledata:reset

Use the command that matches your goal and follow it with the required database update and cache maintenance described in Adobe’s sample-data documentation. Removing the modules is not the same as converting the demonstration catalog into a production catalog: sample products and related entities should be removed and replaced with deliberately curated data before launch.

Production hand-off checklist

A sample-data VPS is a development environment until you harden and repopulate it. Before any public launch:

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
  • Remove sample data and its products rather than exposing the demonstration catalog to customers.
  • Switch out of developer mode only after deployment and testing are complete.
  • Replace demonstration administrator and customer accounts, review all credentials, and remove unused accounts.
  • Restrict database and search ports to the application network; do not expose the search service directly to the Internet.
  • Configure HTTPS. Adobe’s requirements specify TLS 1.2 or later for PayPal integrations and access to repo.magento.com.
  • Confirm that the PHP, database, search engine, web server, Composer, and cache versions still match the selected release’s support matrix.
  • Back up the database and application configuration before upgrades or module changes.

Keep the release number, dependency versions, Composer keys, search endpoint, database details, and Admin URI documented for the people who will maintain the VPS. When upgrading Magento, consult the compatibility matrix again instead of assuming that the current server remains valid.

Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.

Leave a Reply

Your email address will not be published. Required fields are marked *

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

More from the Wire

  1. World desk4 min
    How to Spot an AI Voice Scam Before Sending MoneyDon’t rely on how a caller sounds. Pause, call back through a known number, and verify the emergency with another trusted person before sending money.
  2. Mountain View desk4 min
    Google’s SynthID Detector: How to Check AI-Generated Images, Video and AudioGoogle’s SynthID Detector looks for an embedded watermark in supported images, video and audio. Here is what its results do—and do not—show.
  3. Redmond desk20 min
    How to create a link to File or Folder in Windows 11Windows 11 gives you several ways to point to a file or folder without moving or duplicating it. You can create a desktop shortcut,…
Recommended PC Tool
Recommended PC Tool
Outdated Drivers Are Slowing You DownFree scan - exact matches
PC Slower Than It Used to Be?Free scan - under a minute

Two free Windows tools

One Free Minute Could Fix That PC

Before you go - each of these free tools takes about a minute and tackles what quietly slows a Windows PC down.

Special offer. View Outbyte info, uninstall instructions, EULA, and Privacy Policy.