{"id":9268,"date":"2025-08-19T18:38:11","date_gmt":"2025-08-19T13:08:11","guid":{"rendered":"https:\/\/pheonixsolutions.com\/blog\/?p=9268"},"modified":"2025-08-19T18:38:22","modified_gmt":"2025-08-19T13:08:22","slug":"how-to-install-ubuntu-server-and-zabbix-on-raspberry-pi","status":"publish","type":"post","link":"https:\/\/pheonixsolutions.com\/blog\/how-to-install-ubuntu-server-and-zabbix-on-raspberry-pi\/","title":{"rendered":"How to Install Ubuntu Server and Zabbix on Raspberry Pi"},"content":{"rendered":"\n<h2 class=\"wp-block-heading\">Introduction:<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">The <strong>Raspberry Pi<\/strong> isn\u2019t just a hobbyist gadget \u2013 it\u2019s powerful enough to run servers, monitor networks, and support real IT operations. One of the best tools for monitoring infrastructure is <strong>Zabbix<\/strong>, an open-source monitoring solution used by enterprises worldwide. <\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Prerequisites:<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Before starting the installation, make sure you have the following:<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Hardware:<\/h2>\n\n\n\n<ul class=\"wp-block-list\">\n<li>Raspberry Pi 4 (2GB RAM minimum) or Raspberry Pi 5 (recommended)<\/li>\n\n\n\n<li>16GB or larger microSD card (Class 10 or better)<\/li>\n\n\n\n<li>MicroSD card reader for your PC\/laptop<\/li>\n\n\n\n<li>Power supply (official Raspberry Pi adapter recommended)<\/li>\n\n\n\n<li>HDMI cable + monitor (optional if using headless SSH setup)<\/li>\n\n\n\n<li>USB keyboard &amp; mouse (optional if using headless setup)<\/li>\n\n\n\n<li>Internet connection (Ethernet preferred, Wi-Fi also works)<\/li>\n<\/ul>\n\n\n\n<h2 class=\"wp-block-heading\">Software (on your PC\/laptop):<\/h2>\n\n\n\n<ul class=\"wp-block-list\">\n<li><a>Raspberry Pi Imager<\/a> to flash OS<\/li>\n\n\n\n<li>Ubuntu Server image (64-bit, preferably <strong>Ubuntu Server 24.04 LTS<\/strong>)<\/li>\n\n\n\n<li>SSH client (e.g., <strong>PuTTY<\/strong> on Windows or built-in <code>ssh<\/code> command on Linux\/macOS)<\/li>\n<\/ul>\n\n\n\n<h3 class=\"wp-block-heading\">Part 1: Install Ubuntu Server on Raspberry Pi:<\/h3>\n\n\n\n<h4 class=\"wp-block-heading\">Requirements:<\/h4>\n\n\n\n<ul class=\"wp-block-list\">\n<li>Raspberry Pi 4 or Pi 5 (2GB+ RAM recommended)<\/li>\n\n\n\n<li>16GB+ microSD card<\/li>\n\n\n\n<li>Card reader for flashing the OS<\/li>\n\n\n\n<li>Power supply<\/li>\n\n\n\n<li>Ethernet cable or Wi-Fi<\/li>\n\n\n\n<li>A laptop\/PC (Windows, macOS, or Linux)<\/li>\n<\/ul>\n\n\n\n<h5 class=\"wp-block-heading\">Step 1: Download Ubuntu Server:<\/h5>\n\n\n\n<p class=\"wp-block-paragraph\">This is the lightweight OS that will power your Raspberry Pi as a server.<\/p>\n\n\n\n<ol class=\"wp-block-list\">\n<li>Visit <a class=\"\" href=\"https:\/\/ubuntu.com\/download\/raspberry-pi\" target=\"_blank\" rel=\"noopener\">Ubuntu Raspberry Pi Downloads<\/a>.<\/li>\n\n\n\n<li>Download <strong>Ubuntu Server 24.04 LTS (64-bit)<\/strong>.<\/li>\n<\/ol>\n\n\n\n<h5 class=\"wp-block-heading\">Step 2: Flash the OS to microSD Card:<\/h5>\n\n\n\n<p class=\"wp-block-paragraph\">This process installs Ubuntu Server onto your SD card so the Pi can boot from it.<\/p>\n\n\n\n<ol class=\"wp-block-list\">\n<li>Install <a>Raspberry Pi Imager<\/a>.<\/li>\n\n\n\n<li>Open Imager \u2192 <strong>Choose OS<\/strong> \u2192 <code>Other general-purpose OS \u2192 Ubuntu \u2192 Ubuntu Server 24.04 LTS (64-bit)<\/code>.<\/li>\n\n\n\n<li>Select your microSD card under <strong>Choose Storage<\/strong>.<\/li>\n\n\n\n<li>Click <strong>Write<\/strong>.<\/li>\n<\/ol>\n\n\n\n<h5 class=\"wp-block-heading\">Step 3: Boot the Raspberry Pi:<\/h5>\n\n\n\n<p class=\"wp-block-paragraph\">The Raspberry Pi will automatically boot into Ubuntu Server for the first time.<\/p>\n\n\n\n<ol class=\"wp-block-list\">\n<li>Insert the microSD card into the Pi.<\/li>\n\n\n\n<li>Connect monitor, keyboard, and network.<\/li>\n\n\n\n<li>Power on the Pi \u2013 it will boot into Ubuntu Server.<\/li>\n<\/ol>\n\n\n\n<h5 class=\"wp-block-heading\">Step 4: First Login:<\/h5>\n\n\n\n<p class=\"wp-block-paragraph\">On first login, Ubuntu forces you to set a new password for security.<\/p>\n\n\n\n<ol class=\"wp-block-list\">\n<li>Default username: <strong>ubuntu<\/strong><\/li>\n\n\n\n<li>Default password: <strong>ubuntu<\/strong><\/li>\n\n\n\n<li>You\u2019ll be asked to change the password after first login.<\/li>\n<\/ol>\n\n\n\n<h5 class=\"wp-block-heading\">Step 5: Update System:<\/h5>\n\n\n\n<p class=\"wp-block-paragraph\">This ensures you have the latest security patches and updated software before installing Zabbix.<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>sudo apt update &amp;&amp; sudo apt upgrade -y<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">At this point, your Raspberry Pi is running <strong>Ubuntu Server<\/strong>.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Part 2: Install Zabbix on Ubuntu Server (Raspberry Pi)<\/h3>\n\n\n\n<h5 class=\"wp-block-heading\">Step 1: Install Required Packages;<\/h5>\n\n\n\n<p class=\"wp-block-paragraph\">These are necessary tools to download and manage the Zabbix repository.<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>sudo apt install -y wget gnupg2 software-properties-common\n<\/code><\/pre>\n\n\n\n<h5 class=\"wp-block-heading\">Step 2: Add Zabbix Repository:<\/h5>\n\n\n\n<p class=\"wp-block-paragraph\">This registers the official Zabbix repository so you can install the latest version.<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>wget https:\/\/repo.zabbix.com\/zabbix\/7.0\/ubuntu\/pool\/main\/z\/zabbix-release\/zabbix-release_7.0-2+ubuntu24.04_all.deb\nsudo dpkg -i zabbix-release_7.0-2+ubuntu24.04_all.deb\nsudo apt update\n<\/code><\/pre>\n\n\n\n<h5 class=\"wp-block-heading\">Step 3: Install Zabbix Server, Frontend, and Agent:<\/h5>\n\n\n\n<p class=\"wp-block-paragraph\">This installs the Zabbix components along with MySQL, which is required for storing monitoring data.<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>sudo apt install -y zabbix-server-mysql zabbix-frontend-php zabbix-apache-conf zabbix-sql-scripts zabbix-agent mysql-server\n<\/code><\/pre>\n\n\n\n<h5 class=\"wp-block-heading\">Step 4: Configure Database:<\/h5>\n\n\n\n<p class=\"wp-block-paragraph\">This creates a database and user account where Zabbix will store all monitoring data.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">1.Secure MySQL:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>sudo mysql_secure_installation<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">2.Create Zabbix database:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>sudo mysql -uroot -p\nCREATE DATABASE zabbix CHARACTER SET utf8mb4 COLLATE utf8mb4_bin;\nCREATE USER 'zabbix'@'localhost' IDENTIFIED BY 'StrongPassword';\nGRANT ALL PRIVILEGES ON zabbix.* TO 'zabbix'@'localhost';\nFLUSH PRIVILEGES;\nEXIT;<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">3.Import initial schema:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>zcat \/usr\/share\/zabbix-sql-scripts\/mysql\/server.sql.gz | mysql -uzabbix -p zabbix\n<\/code><\/pre>\n\n\n\n<h5 class=\"wp-block-heading\">Step 5: Configure Zabbix Server:<\/h5>\n\n\n\n<p class=\"wp-block-paragraph\">This tells Zabbix how to connect to the database you created.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Edit the Zabbix server config:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>sudo nano \/etc\/zabbix\/zabbix_server.conf\n<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">Set the database password:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>DBPassword=StrongPassword\n<\/code><\/pre>\n\n\n\n<h5 class=\"wp-block-heading\">Step 6: Start and Enable Services:<\/h5>\n\n\n\n<p class=\"wp-block-paragraph\">This starts Zabbix services and ensures they run automatically after reboot.<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>sudo systemctl restart zabbix-server zabbix-agent apache2 mysql\nsudo systemctl enable zabbix-server zabbix-agent apache2 mysql\n<\/code><\/pre>\n\n\n\n<h5 class=\"wp-block-heading\">Step 7: Access Zabbix Frontend:<\/h5>\n\n\n\n<p class=\"wp-block-paragraph\">Complete the web setup wizard using your database details.<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>Open your browser \u2192 <code>http:\/\/&lt;RaspberryPi-IP&gt;\/zabbix<\/code><\/li>\n\n\n\n<li>Follow the web installer wizard:\n<ul class=\"wp-block-list\">\n<li>Database \u2192 use <code>zabbix<\/code> \/ <code>StrongPassword<\/code><\/li>\n\n\n\n<li>Default login \u2192 <code>Admin<\/code> \/ <code>zabbix<\/code><\/li>\n<\/ul>\n<\/li>\n<\/ul>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Zabbix running on Raspberry Pi<\/strong> with Ubuntu Server!<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Conclusion:<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">By installing <strong>Ubuntu Server<\/strong> and <strong>Zabbix<\/strong> on your Raspberry Pi, you\u2019ve turned a tiny device into a <strong>powerful monitoring solution<\/strong>. You can now monitor your websites, servers, IoT devices, and applications in real time \u2013 all from a Pi!<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Introduction: The Raspberry Pi isn\u2019t just a hobbyist gadget \u2013 it\u2019s powerful enough to run servers, monitor networks, and support [&hellip;]<\/p>\n","protected":false},"author":519,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"site-sidebar-layout":"default","site-content-layout":"","ast-site-content-layout":"default","site-content-style":"default","site-sidebar-style":"default","ast-global-header-display":"","ast-banner-title-visibility":"","ast-main-header-display":"","ast-hfb-above-header-display":"","ast-hfb-below-header-display":"","ast-hfb-mobile-header-display":"","site-post-title":"","ast-breadcrumbs-content":"","ast-featured-img":"","footer-sml-layout":"","ast-disable-related-posts":"","theme-transparent-header-meta":"","adv-header-id-meta":"","stick-header-meta":"","header-above-stick-meta":"","header-main-stick-meta":"","header-below-stick-meta":"","astra-migrate-meta-layouts":"default","ast-page-background-enabled":"default","ast-page-background-meta":{"desktop":{"background-color":"var(--ast-global-color-5)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"tablet":{"background-color":"","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"mobile":{"background-color":"","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""}},"ast-content-background-meta":{"desktop":{"background-color":"var(--ast-global-color-4)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"tablet":{"background-color":"var(--ast-global-color-4)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"mobile":{"background-color":"var(--ast-global-color-4)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""}},"_jetpack_newsletter_access":"","_jetpack_dont_email_post_to_subs":false,"_jetpack_newsletter_tier_id":0,"_jetpack_memberships_contains_paywalled_content":false,"_jetpack_feature_clip_id":0,"_jetpack_memberships_contains_paid_content":false,"footnotes":"","jetpack_publicize_message":"","jetpack_publicize_feature_enabled":true,"jetpack_social_post_already_shared":false,"jetpack_social_options":{"image_generator_settings":{"template":"highway","default_image_id":0,"font":"","enabled":false},"version":2},"jetpack_post_was_ever_published":false},"categories":[1022],"tags":[],"class_list":["post-9268","post","type-post","status-publish","format-standard","hentry","category-web-architecture","psol-cat-web-architecture"],"jetpack_publicize_connections":[],"jetpack_shortlink":"https:\/\/wp.me\/phn2x7-2pu","jetpack_sharing_enabled":true,"jetpack_featured_media_url":"","_links":{"self":[{"href":"https:\/\/pheonixsolutions.com\/blog\/wp-json\/wp\/v2\/posts\/9268","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/pheonixsolutions.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/pheonixsolutions.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/pheonixsolutions.com\/blog\/wp-json\/wp\/v2\/users\/519"}],"replies":[{"embeddable":true,"href":"https:\/\/pheonixsolutions.com\/blog\/wp-json\/wp\/v2\/comments?post=9268"}],"version-history":[{"count":0,"href":"https:\/\/pheonixsolutions.com\/blog\/wp-json\/wp\/v2\/posts\/9268\/revisions"}],"wp:attachment":[{"href":"https:\/\/pheonixsolutions.com\/blog\/wp-json\/wp\/v2\/media?parent=9268"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/pheonixsolutions.com\/blog\/wp-json\/wp\/v2\/categories?post=9268"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/pheonixsolutions.com\/blog\/wp-json\/wp\/v2\/tags?post=9268"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}