Showing posts with label Ubuntu. Show all posts
Showing posts with label Ubuntu. Show all posts

Friday, February 06, 2026

Added Cockpit to Ubuntu 25.10 on the Pi 500+

Today, I wanted to add Cockpit to the Pi 500+ Ubuntu install, but I didn't want to sit at the desk where I'd placed the keyboard.

When I tried to ssh into the Pi, I kept getting connection refusals, which I thought was odd.  I ended up having to spend some time at the Pi keyboard, investigating why I couldn't connect to it on port 22.

I found out that I'd never installed ssh!  I could've sworn I did, but maybe it was the Pi OS install that I installed it.

So, after I installed it, I installed Cockpit (I wanted to try it instead of using WebMin).  I then found that, after the install, when logged into Cockpit, it was only allowing my user limited administrator access.  It gave the option to gain full admin privileges, but when I clicked it, it gave an error that sudo couldn't be leveraged to escalate privileges.  When I googled that error, I found that one of the suggested fixes was to add your user to the wheel group.  My Pi didn't have a wheel group, so I had to create one.  Once I created the wheel group, I had to add my user to that group.  

I then double-checked my research and found a link to a Cockpit bug report of this exact issue back in October 2025.  The issue was that sudo was recently redeveloped in Rust code, and apparently does not support the --askpass flag, which is used by Cockpit.  The fix is to run the following (it's the non-Rust sudo implementation, which is still available):  

# update-alternatives --set sudo /usr/bin/sudo.ws

Now, I've Ubuntu all over the house on various machines, most of them running Cockpit.  I've not seen this issue before, and I've done a bunch of recent installs of Ubuntu 25.10.  In fact, I installed Cockpit on my docker container host, today.  It didn't exhibit this issue/bug.  I'm wondering why I'm only now seeing it.  I'm glad there's a workaround, though.


Sunday, January 18, 2026

I Just Set Up a Web Server to Use an SSL Cert, Using Let's Encrypt!

Yesterday, I was bored and had been contemplating setting up one of my public web sites to use an SSL certificate.

While most business websites use SSL certificates, SSL certs aren't really mandatory for use in just serving web content for reading purposes.  I've been using Apache to serve web pages a LONG time and never felt the need to enable HTTPS, as it wasn't required.  That changed when I found that I wanted my website to be more noticeable within search engine results.  To place higher within search engine results, HTTPS is required to be used on the web server that is serving the content.

As I host my own server, my options were to set up my own SSL certificate or to buy an SSL certificate for use with my server.  I decided to set up and deploy my own.

I used this link's instructions (I used CertBot, which uses Let's Encrypt, which I'll reference as LE) to set everything up.  Keep in mind that I'm using Ubuntu 25.10 to host my server, using Linode as a server.

After I built the certificates, I had a difficult time determining how to leverage them.  I initially tried using a WordPress plugin to import the certificate, but I tried like 5 different plugins and neither worked.  I then pivoted and tried a different method - I'm running Apache to serve Wordpress, so I set up the Apache config file to use HTTPS and pointed Apache to the LE certs.  I then used an SSL checker to check that everything was working.  It was.

Afterward, I then set up a cron job to renew the certs automatically.

Now, when I check the browser for indications that the website is using SSL, there's no lock icon that I can see, but I researched and saw that I also had to ensure the website's prior content wasn't using HTTP links to intneral server content, so I used some Wordpress tools to search and change HTTP links pointing to my web server to use HTTPS.  I also saw that a lot of my plugins and themes are using HTTP links that that's supposed to be a no-no for HTTPS compliance - I can't control how plugin providers construct their plugins, so I'm not sure what to do with that.

I think I'm going to enable SSL with with my other domain, as well (unixfool.us).

Eventually, I plan to replace my Wordpress website with a docker instance.  I'd need to research how to use SSL certs within a docker compose YML file.  I'm thinking it should be pretty straight-forward.  The only thing I can think of that might be an issue is the automatic renewal bit (the bit where I added a cron job to renew the certificate).

UPDATE (1/20/2026):  I just checked again and I can now see that the web page (https://wigglit.com) is showing as secure!  

Friday, January 02, 2026

Rasberry Pi OS, Begone!

Last night, I tried to use a docker container on the new Pi system that I've been able to use on other systems without issue.

This experience was pretty much a nightmare.

I was able to install Docker without issue and the 'hello world' container worked fine.

When I tried to run a Wordpress container, there were cascading issues.  Granted, I know that the Pi runs on the ARM chipset, so I did have to make adjustments for that, which wasn't all that difficult.

The main issue I had related to the Pi OS misconfiguring things.  There were things being blocked by the OS due to bad routing.

While I was able to get the Worpdress container to run, I couldn't connect to it initially.  In fact, I couldn't reach the internet, using curl or any other browser client.  Apparently, curl is kinda weird on the Pi OS, as it requires usage of port 80 and I'd tried to use port 80 as the Wordpress service port.  Since I wasn't using port 80 or any other service that was configured to use port 80, I initially felt it was safe to use port 80 for the Wordpress container.  NOPE!  When I did, it broke some things relating to curl and routing.  After ChatGPT informed me that it's best to not use port 80 for the Wordpress container, I changed the port to 8888 with no success.   It ended up taking me like 6 hours to determine the issue.  ChatGPT kept repeating repair steps that weren't working, until I forced it to look for other issues.

At 4 AM this morning, I finally was able to reach the container using curl, Chromium, and Firefox, but was still experiencing connection drops when trying to use Duckduckgo.  I also noticed several other connection drops (some Wordpress plugins requires backend callbacks to 'home' using curl - those started breaking again.

The fix was to remove some default routes that were associated with the containers.  I also had to remove some rules from IPTables.  I also had to remove some IP links, and also had to add additional config context to the wp.config.php and compose.yml files.

Later in the day, I checked the container again and noticed that the problem routes that I'd removed had been re-added by Pi OS, reverting my work.

I got fed up and decided to start from scratch with another OS.  

I chose Ubuntu, since I'm already familiar with it.  The only wildcard is that this Pi system is still powered by ARM, so I might still run into some things that are currently unknown to me...I'll just have to be prepared for any chipset-related issues that may occur, but I trust Ubuntu more than Pi OS at this point.

Ubuntu 25.10 is now installed on the system's internal SSD.  I used the Pi boot options to reinstall the OS...that's a cool option, but I wish it would also give the option to use wireless connections instead of ethernet, as I had to jump through hoops to ensure I could use the ethernet where the Pi system is currently located.

As well, I wasn't prepared for the new OS install to take 45 minutes.

As frustrated as I was, it's all a learning experience for me.  As well, there's less frustration in reinstalling when I'm using a Pi.

I'd post some of my ChatGPT session, but it was messy and an hours-long chat.

I'll keep you all updated on my progress with Ubuntu on the Pi.

UPDATE (1/2/2026):  Yeah, I already deployed a docker instance of Wordpress in Ubuntu, on the Pi.  I had none of the issues I had last night with deploying the same .yml file on the Pi OS, beyond another issue with changing code so that the images being pulled supported ARM.  The two install experiences were very different.

UPDATE (1/3/2026):  I've still not noticed any issues.  All is well, I think!

UPDATE (1/10/2026):  One issue I've noticed - I've lost sound (thru HDMI connection).  I'm not able to hear system sounds or anything like Youtube audio or music streaming using Audacious.  I've been working on getting it to work but have yet to see success.  With Audacious, I can actually see the music playing, but can't hear it at all (the audio devices are showing as up).  UPDATE to this update (3/11/2026):  The sound issue is related to the monitors;  I've been trying different monitors and some have speakers while others do not.

Sunday, November 09, 2025

Containers Update

I posted awhile back that I was having issues with a containerized deployment of Pihole.

I also posted not long ago that I decided to use Portainer to manage my deployment container stacks.

I thought I could fix the original Pihole container, but after seeing it die again, I immediately began work on using a different system as a host for the containers.  

I have three laptops that weren't being used.  Each was running Window desktop OS variants.  I wanted to install Linux on each.

The three candidate replacement systems were:

Dell Latitude E5530:  This system is a very old system that I bought used for $100 - 4 GB of RAM; i5-3380 CPU

Alienware 15 R2:  This system is also an older system, but not quite as old as the E5530 system mentioned above.  This was used by my daughter.  We initially thought the system was broken but I couldn't find anything wrong with it.  It has 8 GB of RAM and uses the i5-6300 CPU.  It has a 1 TB HDD.  It also has a small (256 GB) SSD.

Alienware M17x R3:  This system is also an older system but has the best specs of the three candidate systems:  12 GB RAM, i7-2760QM CPU; 750 GB SSD

I installed Ubuntu 24.04 onto each of the three systems, testing to determine how well that Ubuntu version would operate on those hardware platforms (while also keeping in mind that they were laptops).

I found that the Alienware M17x system was the most robust and ran Ubuntu without issues.  The other two systems run Ubuntu well enough, but I noticed they were under higher load when idle.

As the systems already had Ubuntu, it was pretty easy for me to install the prerequisite packages for Docker.  It was super easy to get my containers up and running again on the new host.

On top of that, I installed Portainer not long after getting the new host sorted.  I then had to duplicate the Pihole container from within Portainer so that Portainer would have full control over it.  Until I did that, I had limited control over Pihole using Portainer.  Note that I've already posted about Portainer.

I've been monitoring the new host and redeployed hosts.  I've noticed no issues.

I also kept the original system running (a Dell XPS 8930 with an i5-8400 CPU, 8 GB RAM, and 1 TB HDD).  A Pihole container is still running on that host and it hasn't thrown errors since I moved to a new hosting system, oddly enough.  

About the only thing that I had to enable as a requirement was for the M17x system to not sleep/hibernate when I closed the lid.  I found a way to disable hibernation on that host.

As a server, the M17x runs like a champ, especially when Linux is used.

I'd still be using that system if it weren't for the fact that it tends to eat GPUs.  It's been through two Nvidia GeForce 580M GPUs and those weren't cheap.  I think it was the 580Ms that were fragile.

In fact, all of those Dell systems responded extremely well to Linux, especially the Alienware 15 R2, as Windows was choking it...this was why my daughter stopped using it.  It was running Windows 10 when she stopped using it and while I couldn't find anything wrong with the system, when I was troubleshooting, I saw that the HDD appeared to be what was choking the system. Drive resources were constantly pegged when monitoring Task Manager.  That all stopped when I installed Ubuntu.  That's the power of Linux right there!

I'll update the blog if I see anything bad, but I've been monitoring the new host for almost 2 months and I've not seen any issues.

Sunday, February 09, 2025

Pihole & Docker FTW!

I'd been planning to mess with Pihole but didn't want to mess with a Rasberry Pi.  I did some research and found that I'd the option to install Pihole on a running Linux system.  While looking at what that entailed, I also found that I could easily do it with Docker, too.

I've been running a Ubuntu system for a while now.  It is mainly a box I set up for use with NextCloud.  I hate NextCloud and stopped using it and the Ubuntu system.  The system was pretty much idle until I decided to set up a Wordpress instance in Docker for development of my Wordpress site that's on my Linode instance.  Whenever I'm trying something new in Wordpress, I test it on my Dockerized Wordpress instance first.  Eventually I'll work on replacing the Wordpress instance on my Linode host with a Dockerized instance.

Since I already have Docker set up on the Ubuntu box, I decided to give Pihole a spin in Docker.

I used this website to set up Pihole in Docker.  The whole setup was quick and painless.  In fact, my Wordpress setup uses three different Docker containers, and with Pihole now running, I'm now using four containers on that Ubuntu host.  None of them are consuming resources (thus far).

I'm now testing Pihole.  I'm totally unfamiliar with it but it doesn't appear to be a high maintenance setup.  At some point, I'll want to back up the Pihole configs, though, so I won't have to spend a lot of time setting it up again (when/if I end up blowing away the instance).

I've several hosts on my LAN using the Pihole setup and my daughter is trying it, as well.  She had a Rasberry Pi and was planning to install Pihole on it, but I told her that this is far simpler - she should use the Pi for something else, IMO.

I've added some ad lists (block lists and some whitelisting), as well.

The biggest pain as far as adware goes is Youtube, and I don't think Pihole is going to be able to block Youtube ads when using the Youtube app.  I've had some luck blocking Youtube ads on my Macbook, but I view videos on the browser when using that notebook (and I've the uBlock Origin browser extension installed in MS Edge).

Wednesday, June 19, 2024

Docker, Wordpress, and Linode

Maybe a week ago, I decided to refresh my Linode instance.  I'd been using Ubuntu 16.04 LTS on it the past 10 years.  16.04 has been unsupported for quite a while now, but I was being lazy while still watching the server for possible compromises (the server was locked down very well).

Initially, I'd planned on a slow rollover to Ubuntu 24.04 LTS, by deploying a new host and slowly migrating over to it from the old server.  One day, I just said, "fuck it" and started from scratch.  I kept my old disk volume and mounted it to the new host so that I could grab old data whenever I needed it...having config files from the old host would help me when reinstalling the software I was using on the old host.

The plan was to migrate my two Wordpress sites to the new host but today I tried running Wordpress on Docker on an old Dell XPS 8930 and it worked well.  I first tried to just get to the point where Wordpress could install onto it.  I then tried to restore a backup of one Wordpress site onto the Dockerized Wordpress instance and I was immediately successful.  It happened so quickly that I spent the rest of the day testing it, to the point that I decided to do the same thing on the 24.04 server tonight.  It's now up and running and I've already been posting to it.  I'll monitor it the next few days and will probably back it up, tear down the whole thing, and then try some different setups, such as trying to run both Wordpress sites from one set of containers (the problem is, I need both Wordpress sites to be serving on port 80 and there's only one port 80 on the server.

Currently the setup is using three small containers (one for MySQL, one for Wordpress, and one for phpmyadmin).  I leveraged the YAML files of two other nerds, using both to build my own YAML file, which I used to pull the images and configure the containers.  I ran in to issues more than a few times, but between what I learned last year on acloud.guru and trial and error, it wasn't all that difficult.  What I haven't done (YET) is build my own dockerfiles.

I usually also use the Linode host as a file server (sharing pictures with friends and forums), and I was doing that using Apache, so that's a 3rd application that I'd need to use port 80...not sure how I'm going to set all this up, but the neat thing about Docker is that I can blow it away and start over (keeping my .yml compose files to work with and tweak), again and again, until I get it right.

This was the first time outside of training that I used Docker and I honestly should've been using it a long time ago.

I actually had a lot of fun doing this.

UPDATE (7/28/2024):

I'm having some issues trying to determine how to host two sites on one Dockerized Wordpress setup.  I can probably use the muti-site Wordpress setup but I need to study up on how to alter the wp-config file using the docker-compose.yml file.

Or, I can probably just run two Docker setups, one for my firearms blog and one for my car blog.

I also want to be able to share my many pictures and files using Apache, but found that I can't run Apache AND Worpdress, as both use port 80.  I may have to use some type of proxying.

Lastly, I can just reinstall Wordpress in a non-Dockerized fashion, while experimenting with Wordpress in Docker.  This is probably the more reasonable approach, as I can study up how to leverage Docker at my own leisure but have a production (and native) Wordpress setup.

Thursday, May 26, 2022

Ubuntu Desktop 22.04 and Dell XPS 8930

2-3 years ago, I bought my daughter a Dell XPS 8930.  It was nothing special but was a good base in case she needed to expand the system a bit.

Not long after purchase, the motherboard went bad.  I had on-site support for it but never got around to getting it repaired until maybe a month before support expired.  A contractor showed up and replaced the mainboard. 

My daughter only used it a few months then decided to build her own.  The XPS was sitting in a corner, barely used.

I've a cheap system I bought from TigerDirect that is running Ubuntu.  It is currently running Ubuntu Desktop 18.04.  I'd installed Owncloud on it, but the install got jacked up.  it's all out of sync now, package-wise.  I'd attempted to update Owncloud and it choked.  I've not been able to get it running again and it has crucial data on it (it has two drives and the Owncloud data is on the 2nd non-system drive).

I decide to run Ubuntu Desktop 22.04 on the XPS.  I'd initially installed LTS 22.04 but at this time that version has issues with systems that have Nvidia cards and I didn't want a headless system (I already have several of those), so I opted for Desktop.  The Desktop install was seamless.

Desktop 22.04 already has a cloud-based system included in the default install - Nextcloud.  I'm still playing with it but I'll more than likely use that since it's within the Ubuntu repository (Owncloud wasn't when I last checked).

Some things I don't like about these latest Ubuntu versions (noticed this will LTS as well):

  • vim wasn't installed by default.  vi is installed by default.  I think this is a licensing thing (I don't believe vim is POSIX).  As well, if vi is already installed, I guess vim wouldn't need to be.  If anyone needs vim, they can use apt to install it post-install.
  • ifconfig was not installed by default.  IMO, ifconfig should be essential to a default install.  You might need to troubleshoot a network issue immediately after installing the distro and if you don't have a network connection, you're screwed.  ifconfig is included in the net-tools package.  That package shouldn't be excluded from the base install.

Everything else seems to be good with this distro version, but I'm sure I'll find something amiss as I use the system.

Tuesday, September 30, 2014

Wordpress Woes

I did a dumb thing last week.

I'd been holding back on upgrading my Ubuntu server to 14.04...for good reason:  I was running software versions that weren't compatible with my version of Ubuntu.

Well, I upgraded anyways (after months of holding off).  It broke my web server and also reverted my Wordpress site back a few versions (3.8.x or something like that...I'd been running version 4.0).

That was this past Saturday.  Today is Tuesday afternoon and I'm almost finished restoring the site.

Things that broke:

Wordpress
PSAD
Apache

I'm going to specifically speak to Wordpress now.

This was actually an Apache/Wordpress combination issue.  I believe the version that Apache was upgraded to was 2.4.x.  It changed the default webserver location from /var/www to /var/www/html, which broke a LOT of my content.  The fix was easy:  I moved everything from /var/www to /var/www/html, ensuring the file and directory permissions didn't change.

Then, I found a multitude of issues with my Wordpress site's content:


  1. All image links broke, meaning they wouldn't render, even after moving content to /var/www/html (but I could upload new pictures without issue -- and they'd render).
  2. I couldn't perform upgrades to v4.0 via the GUI.
  3. I couldn't install new plugins.
  4. I couldn't install templates.


First thing I did was upgrade (manually, via CLI) to v4.0.  That cleared up some issues.

Next, I worked on trying to get the plugins to work.  I couldn't install new plugins.  I also couldn't update old plugins to new versions.  The error I would get was, "Unable to locate Wordpress content directory".  I'd also get "Unable to locate Wordpress plugin directory".  What I did was download (via web browser) the "third party host fix" plugin.  I loaded it to my Ubuntu server via SCP.  I then unzipped it, and moved the uncompressed directory to the plugins folder.  It still wouldn't work.  I found that a symlink was missing from /var/lib/wordpress/wp-content/plugins, so I created a new one:

lrwxrwxrwx 1 root root 60 Sep 30 19:48 third-party-host-fix -> /usr/share/wordpress/wp-content/plugins/third-party-host-fix

That's linked to /usr/share/wordpress/wp-content/plugins/third-party-host-fix...that also the directory where the actual plugin content is located.

After I did that, I was able to see the plugin in the UI.  I activated it successfully.  I then tried to update a plugin...I got a different error:  "Wordpress could not create directory".  Ugh...

I found the solution on how to fix that issue at https://help.ubuntu.com/community/WordPress.  I went to /usr/share/wordpress/wp-config.php and edited the following:

Changed:

define('WP_CONTENT_DIR', '/var/lib/wordpress/wp-content');

to read:

define('WP_CONTENT_DIR', '/var/www/wordpress/wp-content');

That fixed the issues of installing or updating templates and plugins.

The only issue I need to resolve now is the image rendering issue, but I think I'll just reload all the images, one at a time (there aren't all that many, I believe).

This was a horrible experience but the benefit was that it got me to delve and fix the issue (vs. just wiping everything and reinstalling the whole distribution).

UPDATE:

New issues --
  1. Can't remove plugins.  Error message:  "Plugin could not be deleted due to an error: Unable to locate WordPress Plugin directory."
  2. Using Photo Gallery plugin - galleries will render but the images will not show within the gallery UI.  I also can't seem to view the images via browser...may be another incorrect coding issue or even a permissions issue.
UPDATE 2:

  1. I've fixed the issue with the Photo Gallery plugin.  I basically dumped the picture back in the directory where the plugin was looking for them (/usr/share/wordpress/wp-content/uploads/photo-gallery).  I hate how hodge-podge this is...crap is everywhere without standardization, but I'm to the point where I just want the site functional again.  I just hope things don't break when I next upgrade Wordpress.
  2. I'll look into the "can't remove plugins" issue tomorrow.