ADVERTISEMENT

Going over to Bullseye

Published Jan 19, 2022 09:08 am

The Raspberry Pi OS distribution has been upgraded to the latest Debian Bullseye version a couple of months ago. My Pi-hole, DNS, media server and file server runs the previous version, so I thought that I’d just run the usual apt command to upgrade to the latest. Unfortunately, it does not work for this version, so I have decided to re-create the server from scratch.

Luckily, I have a spare Raspberry Pi 4b (let’s call it RPi_new) that I use for experimenting with different distributions and configurations, so I burned the latest Bullseye version to an SD card and off I went.

After running the configurations after first run of a new operating system, I have enabled SSH so I can easily manage it from my Macbook Pro. RPi_new connects to the network using its WiFi, so I configured its wired interface to use the same static IP as the original Raspberry Pi that it is going to replace without disrupting any services on the network (the wire is not connected, of course).

I could have used the image without a desktop, but then again, for some services, I would need to connect to it via VNC. There are applications bundled (Geany, Thonny and VLC) that are useless for my purposes so I deleted them. Next comes the third-party applications that I need to complete replace the original Raspberry Pi.

Running Pi-Hole is the main function of the Raspberry Pi on my network, so running its installer is pretty straightforward, whilst temporarily assigning it to listen to the wireless interface. Once completely installed, I configured it to listen to all interfaces, as a temporary measure when it gets connected via the wired interface.

With Pi-Hole working, next was to install Unbound. Following the Pi-hole documentation with Unbound makes this a breeze. Once Unbound has been configured to work with the Pi-Hole, limiting all DNS queries to the local network, the next to configure was support for IPv6. A couple of flags on the configuration of both Unbound and Pi-hole were made and IPv6 was up and running. Just one last thing to do to optimize Pi-Hole, and that is to install log2ram to reduce the strain on the SD card. Finding the sweet spot on the size depends on how much logging you have set up and how many devices are on your network, so choose wisely. 

Next up was copying the original Raspberry Pi’s /etc/fstab so I can auto-mount the same drives on RPi_new (BTW, I am just replacing the SD card on the original Raspberry Pi with the one running on RPi_new). With the external drives configured to auto-mount, it was time to swap the SD cards.

Running the RPi_new SD card on the original Raspberry Pi (let’s call it BullsEye) worked as planned, with Pi-Hole providing services on all network interfaces. Next thing was to re-configure Pi-Hole to listen to the wired interface and then set the static IPv6 address. Perfect! All devices on my network didn’t even flinch, and users did not notice that I did some changes.

BullsEye serves as a media server, so next install was for Plex Media Server. With the external hard drives auto-mounting, configuring the Plex Media Server to scan and monitor the specific subdirectories was all it took to make it available on the network. Testing it on the Apple TVs revealed two Plex Media Servers — the old one and BullsEye — so for the moment, I use unpinned the old server, until I get to delete it completely from my plex account. All media played perfectly well, along with being able to delete old media off of the Apple TV Plex application. *whew* 

A quick raspi-config run enabled VNC and configured it to use VNC password so it’d work with the MacOS without installing VNC. This is one of those times that I will need to access BullsEye’s desktop remotely. Installing rclone.org serves as my file-server interfaces to local and cloud drives. I just copied the rclone config from the old Raspberry Pi and all previously configured servers were accessible, except for one that requires authentication. Re-authenticating access to Microsoft One Drive required launching the browser, hence remote desktop access. All went well after, so success! 

BullsEye will serve as a Wireguard VPN server for those times that I need to access the local server (the printer, files) when I’m not home. PiVPN provides this functionality. It was just a matter of creating the new QR code and scanning it on my iPhone to replace the old Wireguard config. Dropping to 5G and connecting via Wireguard VPN to access the home network worked! Solved.

A couple more tools to configure, e.g., the command-line speedtest tool, and the YouTube downloader, yt-dlp, and BullsEye’s finally replaced the old server. 

It took an hour to do all of these configurations, and now I have the peace of mind that the server is running the latest and greatest version of the operating system. Now back to your regular programming.

ADVERTISEMENT
.most-popular .layout-ratio{ padding-bottom: 79.13%; } @media (min-width: 768px) and (max-width: 1024px) { .widget-title { font-size: 15px !important; } }

{{ articles_filter_1561_widget.title }}

.most-popular .layout-ratio{ padding-bottom: 79.13%; } @media (min-width: 768px) and (max-width: 1024px) { .widget-title { font-size: 15px !important; } }

{{ articles_filter_1562_widget.title }}

.most-popular .layout-ratio{ padding-bottom: 79.13%; } @media (min-width: 768px) and (max-width: 1024px) { .widget-title { font-size: 15px !important; } }

{{ articles_filter_1563_widget.title }}

{{ articles_filter_1564_widget.title }}

.mb-article-details { position: relative; } .mb-article-details .article-body-preview, .mb-article-details .article-body-summary{ font-size: 17px; line-height: 30px; font-family: "Libre Caslon Text", serif; color: #000; } .mb-article-details .article-body-preview iframe , .mb-article-details .article-body-summary iframe{ width: 100%; margin: auto; } .read-more-background { background: linear-gradient(180deg, color(display-p3 1.000 1.000 1.000 / 0) 13.75%, color(display-p3 1.000 1.000 1.000 / 0.8) 30.79%, color(display-p3 1.000 1.000 1.000) 72.5%); position: absolute; height: 200px; width: 100%; bottom: 0; display: flex; justify-content: center; align-items: center; padding: 0; } .read-more-background a{ color: #000; } .read-more-btn { padding: 17px 45px; font-family: Inter; font-weight: 700; font-size: 18px; line-height: 16px; text-align: center; vertical-align: middle; border: 1px solid black; background-color: white; } .hidden { display: none; }
function initializeAllSwipers() { // Get all hidden inputs with cms_article_id document.querySelectorAll('[id^="cms_article_id_"]').forEach(function (input) { const cmsArticleId = input.value; const articleSelector = '#article-' + cmsArticleId + ' .body_images'; const swiperElement = document.querySelector(articleSelector); if (swiperElement && !swiperElement.classList.contains('swiper-initialized')) { new Swiper(articleSelector, { loop: true, pagination: false, navigation: { nextEl: '#article-' + cmsArticleId + ' .swiper-button-next', prevEl: '#article-' + cmsArticleId + ' .swiper-button-prev', }, }); } }); } setTimeout(initializeAllSwipers, 3000); const intersectionObserver = new IntersectionObserver( (entries) => { entries.forEach((entry) => { if (entry.isIntersecting) { const newUrl = entry.target.getAttribute("data-url"); if (newUrl) { history.pushState(null, null, newUrl); let article = entry.target; // Extract metadata const author = article.querySelector('.author-section').textContent.replace('By', '').trim(); const section = article.querySelector('.section-info ').textContent.replace(' ', ' '); const title = article.querySelector('.article-title h1').textContent; // Parse URL for Chartbeat path format const parsedUrl = new URL(newUrl, window.location.origin); const cleanUrl = parsedUrl.host + parsedUrl.pathname; // Update Chartbeat configuration if (typeof window._sf_async_config !== 'undefined') { window._sf_async_config.path = cleanUrl; window._sf_async_config.sections = section; window._sf_async_config.authors = author; } // Track virtual page view with Chartbeat if (typeof pSUPERFLY !== 'undefined' && typeof pSUPERFLY.virtualPage === 'function') { try { pSUPERFLY.virtualPage({ path: cleanUrl, title: title, sections: section, authors: author }); } catch (error) { console.error('ping error', error); } } // Optional: Update document title if (title && title !== document.title) { document.title = title; } } } }); }, { threshold: 0.1 } ); function showArticleBody(button) { const article = button.closest("article"); const summary = article.querySelector(".article-body-summary"); const body = article.querySelector(".article-body-preview"); const readMoreSection = article.querySelector(".read-more-background"); // Hide summary and read-more section summary.style.display = "none"; readMoreSection.style.display = "none"; // Show the full article body body.classList.remove("hidden"); } document.addEventListener("DOMContentLoaded", () => { let loadCount = 0; // Track how many times articles are loaded const offset = [1, 2, 3, 4, 5, 6, 7, 8, 9, 10]; // Offset values const currentUrl = window.location.pathname.substring(1); let isLoading = false; // Prevent multiple calls if (!currentUrl) { console.log("Current URL is invalid."); return; } const sentinel = document.getElementById("load-more-sentinel"); if (!sentinel) { console.log("Sentinel element not found."); return; } function isSentinelVisible() { const rect = sentinel.getBoundingClientRect(); return ( rect.top < window.innerHeight && rect.bottom >= 0 ); } function onScroll() { if (isLoading) return; if (isSentinelVisible()) { if (loadCount >= offset.length) { console.log("Maximum load attempts reached."); window.removeEventListener("scroll", onScroll); return; } isLoading = true; const currentOffset = offset[loadCount]; window.loadMoreItems().then(() => { let article = document.querySelector('#widget_1690 > div:nth-last-of-type(2) article'); intersectionObserver.observe(article) loadCount++; }).catch(error => { console.error("Error loading more items:", error); }).finally(() => { isLoading = false; }); } } window.addEventListener("scroll", onScroll); });

Sign up by email to receive news.