TEKBYTE https://tekbyte.net Learn a lot, one byte at a time.Mon, 10 May 2021 02:40:48 +0000en-AU hourly 1 https://wordpress.org/?v=5.7.1https://tekbyte.net/wp-content/uploads/2020/08/cropped-favicon-1-32x32.pngTEKBYTE https://tekbyte.net 3232Running MATLAB on iPadOS https://tekbyte.net/2021/running-matlab-on-ipados/ https://tekbyte.net/2021/running-matlab-on-ipados/#respondMon, 10 May 2021 02:40:48 +0000https://tekbyte.net/?p=377So iSwitched to iPadOS for most of my productivity work and I must say, it’s quite breathtaking.

Ok, well it isn’t that insane but paired with a keyboard+trackpad and the legendary Apple Pencil, you have yourself a productivity beast. I’m planning to put out more articles in regards to productivity and just getting work done on the iPad as a whole. The more I use it, the more I’m impressed what the OS and the device is capable of. For instance, I’m running an iPad Air 4 here with the Logitech Folio case and Apple Pencil 2. All together, it’s a solid setup which allows you to not only smash out notes, do audio-production but also is a breeze for office-related work. So much so that you can plug in your external drives, output to an external display all while running fan-less, having superb battery life and an excellent screen.

What does it for me is the Safari web browser which has very pleasant to use. It’s no frills but it works like you’re on a desktop, I love it. I’m also make use of some other programs outside of the usual office stuff like “Shelly” which is a great little SSH client.

Coming to the main topic of this post, I’ve been using MATLAB quite extensively as of late and I noticed that you can run MATLAB from your browser. At first, I thought it would run terribly and you most likely couldn’t upload files but turns out, it’s actually quite flexible and runs nicely.

“Wait, that’s illegal!”

Yup, there you have it. Running MATLAB with imported data. I’m actually quite impressed by how well it works but there are some quirks to it. For instance, I wasn’t able to make use of certain toolboxes that require graphical horse-power. In the figure above, the basic MATLAB figures work but as soon as you make use of something from the Communications Toolbox, you’re going to run into some issues with displaying certain data.

That said, it works remarkably well and it’s also very responsive. The only downside of course is that it isn’t offline but whenever I use MATLAB, I’m constantly search online for documentation so it’s not a drawback for me.

There you have it folks, you can run MATLAB on your iPad. There is also a native application which does the exact some thing as pictured in the figure above but doesn’t give you the full tools. I also prefer this interface much more.

Stay tuned for more iPad articles. 😎

Installing MATLAB on Fedora 34 https://tekbyte.net/2021/installing-matlab-on-fedora-34/ https://tekbyte.net/2021/installing-matlab-on-fedora-34/#respondSun, 04 Apr 2021 04:45:30 +0000https://tekbyte.net/?p=367If you’re like me and you need to use MATLAB and you run Fedora, you would have likely ran into some issues with launching MATLAB. For instance, when you go to run file with ./install , you will get this error:
terminate called after throwing an instance of 'std::runtime_error'
what():  Unable to launch the MATLABWindow application

It took me quite a long time to find a swift and easy solution for this one. Turns out, all you need to do is have the following packages installed on your system and then remove one file.

# install these packages:

sudo dnf install libxcrypt-compat libnsl

The next step is to navigate into the bin/glnxa64 folder inside the MATLAB Linux installation folder. In there, you want to either remove or rename the “libcrypto.so.1.1” file. I’ve renamed it so I have a backup just in case.

mv libcrypto.so.1.1 libcrypto.so.1.1_old

After that, you can run the installer as root.

sudo ./install

Once you’ve picked what you want installed and everything is activated, you can run MATLAB by typing matlab into the terminal and that will launch it.

Ah yes, the MATLAB splash-screen!
Ready to rock and roll!

While I can create a shortcut with “menulibre” so that I can launch it by typing, MATLAB is not something I use all the time so I’m happy to launch it from the terminal. I had some issues with creating a launcher where MATLAB would just crash, it could be because of GNOME Wayland but I’m not quite sure.

Also, big thanks to tinkertailorsoldiersponge for making the original guide. The original guide can be found here. (tinkertailorsoldiersponge’s guide) – I’ve simply omitted the need for installing the XFCE4 desktop as I use GNOME and I don’t find it’s necessary to get MATLAB working.

If you run into any issues, feel free to share them below and we’ll see what we can do. This guide is just for folks like me who run Linux and are running into the std::runtime_error error.

Thanks for reading and happy MATLABing!

Installing WiFi Driver For Realtek 802.11ac on Linux (0bda:c811) https://tekbyte.net/2021/installing-wifi-driver-for-realtek-802-11ac-on-linux-0bdac811/ https://tekbyte.net/2021/installing-wifi-driver-for-realtek-802-11ac-on-linux-0bdac811/#respondWed, 10 Mar 2021 01:57:40 +0000https://tekbyte.net/?p=354So you just purchased one of those 802.11ac USB WiFi cards but it’s not working on Linux. Not to worry, I’ve compiled a list of steps to get it working on your Fedora or Debian based distribution. If you’re on Arch Linux or a derivative, the steps will be similar but you’ll have to use pacman to make sure you have the right dependencies.

For Fedora and RPM-esque distributions

Fedora was a bit tricky so you need to make sure you update your system and ensure you have kernel-devel installed. I have the steps for you below

# Ensure your system is up-to-date

sudo dnf update

# If there are new kernel updates, please restart. Once done, install the kernel-devel and dkms package

sudo dnf install kernel-devel kernel-devel-debug dkms

# Once done, you can proceed with the following one-liner

cd /tmp && git clone https://github.com/brektrou/rtl8821CU.git && cd rtl8821CU && chmod +x dkms-install.sh

# Now you can install the dkms script

sudo ./dkms-install.sh

# If all goes well, you can now run the modprobe command

sudo modprobe 8821cu 

For Ubuntu and Debian-esque distributions

Very similar to Fedora, we’re just going to use apt to install a few packages.

# Ensure your system is up-to-date

sudo apt update && sudo apt upgrade

# If there are new kernel updates, please restart. Once done, install the build-essential git and dkms packages.

sudo apt install build-essential git dkms

# Once done, you can proceed with the following one-liner

cd /tmp && git clone https://github.com/brektrou/rtl8821CU.git && cd rtl8821CU && chmod +x dkms-install.sh

# Now you can install the dkms script

sudo ./dkms-install.sh

# If all goes well, you can now run the modprobe command

sudo modprobe 8821cu 

If you run into any issues, feel free to let me know.

Thanks for reading.

Fixing Flatpak GTK Theme Integration Issues https://tekbyte.net/2021/fixing-flatpak-gtk-theme-integration-issues/ https://tekbyte.net/2021/fixing-flatpak-gtk-theme-integration-issues/#respondWed, 03 Mar 2021 23:11:44 +0000https://tekbyte.net/?p=351So I’ve been playing around with some GTK themes recently, one that took my attention was “WhiteSur” which is a theme inspired by Apple’s “Big Sur” design style.

Anyhow, one thing I came across was that you need to tell Flatpak where to look for themes. By default, your options are to install the Flatpak variant of your GTK theme or have your themes stored in the ~/.local/share/themes directory.

Unfortunately, having them in this directory breaks GTK2 compatibility, at least in my experience.

To keep this short, assuming you have your GTK themes stored in ~/.themes, simply run the following command and you should be good to go.

sudo flatpak override --filesystem=~/.themes

Restart your Flatpak applications and you should see that it uses your 3rd party GTK theme.

Thanks for reading.

CWSA-1 & CWA- My Experience With Getting cPanel & WHM Certified! https://tekbyte.net/2021/cwsa-1-cwa-my-experience-with-getting-cpanel-whm-certified/ https://tekbyte.net/2021/cwsa-1-cwa-my-experience-with-getting-cpanel-whm-certified/#respondSun, 28 Feb 2021 04:51:26 +0000https://tekbyte.net/?p=328Hey folks, it’s been a while since I wrote up something so I thought I’d share what I’ve been working on over the past few months. Ever since I started my journey in technical support, I have been learning a lot! A few things I spent a lot of time on were cPanel, WHM, and server administration. I’ll be going through what it takes to get a CWSA-1 (or CWA), and maybe it will inspire you to get one yourself.

While I wouldn’t consider myself a l33t sysadmin by any means (I’m always learning), I can say that I learned a lot over the past few months and I would like to share my experience with the various cPanel certificates, more specifically, CWSA-1.

What cPanel certificates are available?

There are four primary certificates which range from entry-level cPanel administration to advanced command-line and WHM administration. I’ve got them all 😛 (weird flex, I know…)

  • CPP – This is an entry-level certificate which is great for understanding the basic concepts of cPanel and WHM. This certificate will get you up to speed on concepts of DNS, email and other server administration tasks.
  • CPSP – This one is for sales. I personally didn’t find this to be super-useful from a web hosting perspective but it definitely teaches you what the cPanel folks have to offer and is a stepping stone for the CWA certification.
  • CWA – I’d say this one is the primary certificate you should aim for if you want to gain knowledge and experience in cPanel and WHM. It gets deep into email, DNS, databases and web server related topics so be prepared to learn a lot!
  • CWSA-1 – This one is similar to the CWA however it aims to teach server administration from a command-line perspective. I would classify this one to be the more difficult one to get but with enough practice, it is doable and a solid certificate to get under the belt.

Why cPanel?

cPanel & WHM are used extensively in the web hosting industry and for good reason too! I’m not going to shill for cPanel here but I can say that it is very easy to use. The extensibility and integration it offers with systems like LiteSpeed web server, Acronis backup services and other utilities makes it a powerful tool for hosting and managing websites.

If you’re looking to learn a lot about DNS, email and explore databases at a greater detail, the folks at cPanel have done an excellent job at making the course interactive and easy to follow.

Furthermore, cPanel university is completely free! No exam fees, no course fees, you can learn anything and everything from university.cpanel.com!

What’s inside?

The CWA and CWSA-1 are certifications aimed at understanding the underlying behaviour of cPanel and WHM as well as the various programs that are interfaced from it. Basically, you are going to use Linux command-line utilities to perform analysis and administration on mail, DNS, database and web server sub-systems.

Mail Administration

If you have done the CWA, the CWSA-1 section will dive deep into administering services like Dovecot, Exim and SpamAssassin directly from the command-line. You will soon learn that mail-headers, mail-logs and exim-logs are very important in troubleshooting issues with cPanel accounts.

DNS Administration

cPanel University has done an excellent job at teaching you the basics as well as the administrative tasks one might do through WHM, cPanel or via the CLI. This includes managing DNS records, taking backups of the zone and much more.

MySQL Administration

In the CWSA-1 database section, you will get right into diagnosing and fixing common issues with MySQL databases as well as maintaining, backing up and interacting via the CLI.

Web Server Administration

In the web server administration side of things, you get right into managing and customizing PHP versions and configurations. Depending on the technologies you’re using, this can be about Apache, Nginx, LiteSpeed. Since Apache (or LiteSpeed) is the primary focus here, you’ll get to learn about administering these services.


If you’re planning to get into the web hosting industry or looking to sharpen your skills, check out cPanel University and maybe you’ll earn a certificate or two from the courses they offer. I would highly recommend having an instance of cPanel and WHM on a server so you can play around with it and get familiar.

If you have any questions regarding cPanel certification or want to share your ideas on it, feel free to comment below! Thanks for reading.

Fixing the “Add New Plugins” Button Not Showing (WordPress) https://tekbyte.net/2021/fixing-the-add-new-plugins-button-not-showing-wordpress/ https://tekbyte.net/2021/fixing-the-add-new-plugins-button-not-showing-wordpress/#commentsThu, 28 Jan 2021 10:33:48 +0000https://tekbyte.net/?p=339So I’ve came across an issue when working on a WordPress website where the “Add New Plugins” button wouldn’t show. I also couldn’t add any themes or update WordPress.

After much digging, I found out that there are two lines which need to be set to false in order for the website to behave.

Such swift solution to an annoying problem!

If you’re having another issue, this guide might not be for you.

The Solution

Go into your wp-config.php and locate the following lines:

define( 'DISALLOW_FILE_MOD' , true);
define( 'DISALLOW_FILE_EDIT', true);

Now set the true values to false

It’s as simple as that.

Also, where’s the content?

For those wondering why I haven’t been posting articles, I’ve been pretty busy with other things in life so I didn’t have the time to write up articles.

I’m thinking of writing up more workflow/computing related stuff and less tutorials. I feel like there are tutorials for everything (unless it is something important and worth sharing).

I’ve got a few things planned so stay tuned! 🙂

PowerToys – Improve Your Windows 10 Experience https://tekbyte.net/2020/powertoys-improve-your-windows-10-experience/ https://tekbyte.net/2020/powertoys-improve-your-windows-10-experience/#respondTue, 17 Nov 2020 04:34:34 +0000https://tekbyte.net/?p=291PowerToys is a free and open-source application developed by Microsoft which is designed to bring a set of utilities for power users who want to improve their productivity and benefit from additional features. Whether you are a home-user, a developer or want to deploy certain features for an enterprise, this suite of useful utilities will be greatly appreciated by most.

PowerToys is a revival of the “PowerToys” project that was available on Windows 95.

This program will offer something for everyone, whether you are a keyboard-oriented user or someone after productivity, this software is for you.

Useful features that I use

Fancy Zones: If you have used any tiling window manager, you wold know how beneficial they are for your workflow. PowerToys comes with a tiling feature called “FancyZones” which allows you to position windows into various layouts. You can create custom layouts, whether it is for development, monitoring windows or graphics design, I found FancyZones to be super helpful.

Reassigning Keyboard Shortcuts: Keyboard shortcuts are one of those things that are hard to let go, especially if you have used it to move and manipulate windows around. I like to maximise my windows with Start + X and close them with Start + C.

Remapping Keys: Ever wonder why the caps-lock key is hardly ever used? I tend to think it’s meant to be remapped to something else. By default, you cannot map keys on Windows but with PowerToys you can. Over the years, I have made caps lock my escape key. I find it very convenient for many situations especially if you use text editors like VIM.

Colour Picker: Sometimes I just want to pick a colour from my desktop without having to install a colour picking tool. If you’re a keyboard driven person and you do any form of graphics design, you will appreciate this feature.

It automatically copies to the clipboard, it can be activated by pressing

Start + Shift + C

Notable mentions

Image Resizer: If you want to resize images without having to open a photo editing program like GIMP, you can use this built-in utility for quickly resizing images directly from the Windows File Explorer.

PowerToys Run: For ex-Mac users or those who want a different way to launch applications. This convenient utility can be triggered with Alt + Space and then you start typing. It is open-source and the functionality can be extended with plugins.

Reminds me of the macOS “Spotlight” feature. You can also run with administrator and even do quick maths calculations.

PowerRename: This is more convenient than I thought but I hardly do bulk-renaming. However for those who have many files in a folder and would like to bulk-rename things, this is the tool for you. Once PowerToys is installed, it is associates itself with Windows Explorer so you can simply select your files and perform bulk-renaming.

Things to note

I would recommend running PowerToys as administrator, especially if you plan to use custom keyboard shortcuts as some applications won’t respond to shortcuts if you don’t. As the app is under heavy-development, there are some bugs however they are quick to fix it and often each release comes with new or improved features.

Neat little Windows 10 progress bar notification!

Get it now!

If you want to try it out, download it from GitHub (scroll down to “Assets”) or you can read more on the repository home page.

Login to your server with SSH keys! https://tekbyte.net/2020/login-to-your-server-with-ssh-keys/ https://tekbyte.net/2020/login-to-your-server-with-ssh-keys/#commentsThu, 12 Nov 2020 11:17:25 +0000https://tekbyte.net/?p=178Using SSH keys to login to servers and computers is a great way to add a layer of security as well as remove the hassle of typing your password. In this article I will show you how you can create your unique and password-proteced SSH key so you can login to your server without ever needing to enter passwords. Also, this means you can disable password login on your server and that will stop hackers from trying to brute-force their way into your server.

Let’s get cracking…

Alright, if you don’t have a .ssh directory created, make it and make sure you give access to only yourself.

mkdir -p ~/.ssh
chmod 700 ~/.ssh
cd ~/.ssh

Next thing is to create a RSA key. To do this, use the ssh-keygen command.

ssh-keygen -t rsa
  • It will ask you to enter a file to save the key into, just press enter.
  • For the next part, you can create a passphrase as an added layer of protection. I’d highly recommend you do this as if someone grabs your key, they’ll need a password to use it as well. Depending on the OS you’re using (Linux, Windows, macOS) and the SSH client, the behaviour will be different.

Once done, you want to use the ssh-copy-id command to copy the public part of your SSH key to the remote server you want to connect to. Here’s an example

ssh-copy-id -i ~/.ssh/id_rsa.pub user@server.com
  • Replace user with the username you use to connect to the server.
  • Replace server.com with your server address
  • If you use a specific port number, make sure to append -p <port_num> before the “user@server.com” parameter.
  • You’ll be prompted to enter your remote server password, enter it.

That’s it! You can now connect to your server without entering passwords, all you need is a username, hostname and maybe port number. If you want to simplify things further, you can create a SSH profile and all you have to type is ssh myserver to connect.

Some things to consider

  • Once you have a successful connection estabilished, you should backup your private and public keys. You don’t want to lose them when distro hopping 😉
  • Try using a different port number than 22 on your remote servers. Especially if you have a website, pick a random 4-5 digit port number.
  • If you can be bothered, disable root-login and only login with another user which has superuser access. This is the desired behaviour and adds another layer of protection as the root account cannot be used for loggin into the server.
JNCIA-Junos – My experience with getting certified! https://tekbyte.net/2020/jncia-junos-my-experience-with-getting-certified/ https://tekbyte.net/2020/jncia-junos-my-experience-with-getting-certified/#respondTue, 10 Nov 2020 10:25:09 +0000https://tekbyte.net/?p=262After weeks of studying for the Juniper JNCIA-Junos exam and getting familiar with the OS, I got my first network certification!

What was the exam like?

I studied using the Juniper Genius online lessons and I would recommend them as they are very detailed and easy to understand. One thing I should have done was search for more practice tests as the Juniper practice tests did not cover everything. That said, the majority of the practice questions were very similar to the one on the actual exam.

I was fortunate enough to spend time on the Juniper virtual routers at my university. If you don’t have access to the routers, I believe there are virtual images which you can use with GNS3.

To summarize what’s on the test, I would highly recommend studying the following:

Junos OS fundamentals

  • Software architecture
  • Control and forwarding planes
  • RE and PFE
  • Exception traffic

User Interfaces (CLI mostly)

  • CLI functionality
  • CLI modes
  • CLI navigation
  • CLI help
  • Filtering output
  • Active versus candidate configuration
  • Reverting to previous configurations
  • Modifying, managing, and configuration files
  • Viewing, comparing and loading configuration files
  • J-Web (core and common functionality only)

Configuration Basics

  • Factory-default state
  • Initial configuration
  • User accounts
  • Login classes
  • User authentication methods
  • Interface types and properties
  • Configuration groups
  • Additional initial configuration elements such as NTP, SNMP and syslog
  • Configuration archival
  • Logging and tracing
  • Rescue configuration

Operational Monitoring and Maintenance

  • Show commands
  • Monitor commands
  • Interface statistics and errors
  • Network tools such as ping, traceroute, telnet, SSH, etc.
  • Junos OS installation and upgrades
  • Powering on and shutting down Junos devices
  • Root password recovery

Routing Fundamentals

  • Traffic forwarding concepts
  • Routing tables
  • Routing versus forwarding tables
  • Route preference
  • Routing instances
  • Static routing
  • Advantages of and use cases for dynamic routing protocols

You can read more on Juniper’s website.

90 minutes is given to complete the exam but if you’re well prepared, you should be able to finish it fairly quickly with plenty of time to spare. There are 65 questions on the exam and I would highly recommend going through the practice and voucher tests one-last-time as well as any other questions you find online as they will be fresh in your mind.

About Pearson Online Proctoring

From what I read online, many had a poor experience with the Pearson OnVUE Online Proctoring system however for me it went well. To take the test, you need some form of ID verification like a driver’s license. I would recommend clearing your desk and putting any pens, notebooks, books out of reach.

Since the proctoring software locks down your computer, I would recommend creating a local user account separate from your personal one to do the test. You’re basically going to give a 360 degree view of your room / testing environment before the exam but apart from that, they are going to look at you. I would prefer doing it at a testing venue but due to covid lockdowns, this was my only option.

What’s next?

I’m happy with my performance on the exam however I do have to work on my firewall policies. My next goal is to look at JNCIS-Junos and Microsoft Azure.

Hope this helps!

Fixing The Nextcloud Quota Configuration Error https://tekbyte.net/2020/fixing-the-nextcloud-quota-configuration-error/ https://tekbyte.net/2020/fixing-the-nextcloud-quota-configuration-error/#respondTue, 20 Oct 2020 12:19:19 +0000https://tekbyte.net/?p=245So I run an instance of Nextcloud on my VPS and it’s been very reliable until today where I ran into error 500. This tells me there is a configuration error on the server so I went digging. Looking at the logs, there appears to be not enough space on the system according to the “quota”. After further investigation, I found out that Linux actually has the ability to set quotas which is often used by system administrators.

Checking for quota

Because I don’t need this utility, I decided to disable this and the place you want to look is inside your file system table. To view it, simply run:

cat /etc/fstab

If you see quota, usrquota or grpquota, then you have quota enabled. To see if this is indeed the issue, assuming you’re already SSH’d into the server, simply type the command:

quotaoff -v /

You may have to replace “ / “ with the directory your server is installed on. E.g. “quotaoff -v /home”. If this solves your problem and Nextcloud can be accessed again, we can proceed to disable the quota functionality.

Disabling quota

To disable, simply open the /etc/fstab file in your text editor. nano comes preinstalled on most distributions so you can use that if you are unsure. Now you need to remove any mention of “quota” from the partition. This is generally found after the file system type (e.g. ext4, btrfs, zfs)

Hope this helps. As always, be sure to read your logs before you copy-paste commands as your problem can be different to the one in this article.