Category Archives: Guides

Using a Proxy With DNF

By | 2020-11-27

Using a proxy with DNF is straightforward. You can edit /etc/dnf/dnf.conf, set the relevant environment variable, or use the shell sub command. DNF supports both HTTP and SOCKS proxies and several authentication methods. Keep in mind a few things when caching package repositories: Package repositories running on HTTPS cannot be cached without something like Squid’s… Read More »

Using a Proxy With Curl

By | 2020-11-21

Using a proxy with Curl is straightforward and flexible. There are a few methods you can use. You can specify the proxy URL on the command line, or set the appropriate environment variable. Using -x This is the most straightforward way to use a proxy server with curl. Using the -x option guarantees that you… Read More »

Following Redirects With Curl

By | 2020-11-12

The curl command is a great tool with a lot of uses. When used for HTTP, it doesn’t follow redirects. However, following redirects with curl is easy. If you are in a hurry, the short answer is the -L option: $ curl http://tylersguides.com > tylersguides.html % Total % Received % Xferd Average Speed Time Time… Read More »

Linux – How to Tell Which Shell

By | 2020-09-23

The easiest way to tell which shell you are using is by looking at what the exe link points to in your shell process’s /proc directory. You can use the command ls -l /proc/$$/exe. Below is an example: $ ls -l /proc/$$/exe lrwxrwxrwx 1 tyler tyler 0 Sep 22 19:39 /proc/19867/exe -> /bin/bash The special… Read More »

Listing All Users In Linux

By | 2020-09-21

Listing all users on Linux is best done with the getent passwd command. This isn’t the only way, but it should work an practically any system. Unlike other methods, it uses your systems /etc/nsswitch.conf configuration to show users from all sources. The format is the format used in the file /etc/passwd. $ getent passwd root:x:0:0:root:/root:/bin/bash… Read More »

HAProxy LDAP Backend

By | 2020-05-31

There are a few good reasons for setting up an HAProxy LDAP backend. Perhaps the client’s TLS implementation is lacking. Maybe the application only supports a single server and you can’t afford down time. In the latter scenario, setting up multiple address records in DNS with the same domain name. The problem with that is… Read More »

Mebibytes vs Megabytes

By | 2020-02-13

Discussing mebibytes vs megabytes can easily segue into other topics, but I’ll keep this short and to the point. The short answer is a megabyte is 1,000,000 bytes while a mebibyte is 1,048,576 bytes. Mega is the SI prefix for 1,000,000. Mebi is the IEC prefix for 220. The IEC versions of the other SI… Read More »

Listing Files In a Package With DNF

By | 2020-01-04

Listing files in a package with dnf is easy. Just follow the example below: # dnf repoquery -l crontabs Last metadata expiration check: 0:12:18 ago on Sat 04 Jan 2020 09:40:27 AM EST. /etc/cron.daily /etc/cron.hourly /etc/cron.monthly /etc/cron.weekly /etc/crontab /etc/sysconfig/run-parts /usr/bin/run-parts /usr/share/licenses/crontabs /usr/share/licenses/crontabs/COPYING /usr/share/man/man4/crontabs.4.gz /usr/share/man/man4/run-parts.4.gz Replace crontabs with the name of the package you wish to… Read More »

Install MATE on CentOS 8

By | 2020-01-01

UPDATE 2023 April 12: I was going to build RPMs to post here, but found that MATE packages are available in EPEL. Follow the instructions here for setting up the EPEL repositories. I am going to leave the instructions up to assist package maintainers and for anyone interested in the process of building a major… Read More »