File system command differences between ext3 and xfs.
Task | ext4 | xfs |
Creating a file system | mkfs.ext4 | mkfs.xfs |
Mounting a file system | mount | mount |
Resizing a file system | resize2fs | xfs_growfs |
Repairing a file system | e2fsck | xfs_repair |
Changing the label on a file system | e2label | xfs_admin -L |
Reporting on disk space and file usage | quota | quota |
Debugging a file system | debugfs | xfs_db |
Saving critical file system metadata to a file | e2image | xfs_metadump |
Online RTMP Players
Here are several online RTMP players:
I prefer the Wowza test players. The last two has annoying ads.
Encrypt Volume via Terraform
Here’s the Terraform script to encrypt an unencrypted volume. It creates a snapshot, encrypts a snapshot, and encrypts the volume.
# # Set Variables # variable "volume" { description = "The Volume to encrypt: vol-12345678901234567" } variable "region" { description = "The Region: us-east-2" } variable "az" { description = "The AZ: us-east-2a" } # # Set Credentials # provider "aws" { access_key = "put-your-access-key-here" secret_key = "put-your-secret-key-here" region = "${var.region}" } /* # # Create Unencrypted Volume # resource "aws_ebs_volume" "unencrypted_volume" { availability_zone = "${var.az}" size = 10 tags = { Name = "Unencrypted_Volume" } } */ # # Create Unencrypted Snapshot # resource "aws_ebs_snapshot" "unencrypted_snapshot" { #volume_id = "${aws_ebs_volume.unencrypted_volume.id}" volume_id = "${var.volume}" tags = { Name = "Unencrypted_Snapshot" } } # # Create Encrypted Snapshot # resource "aws_ebs_snapshot_copy" "encrypted_snapshot" { source_snapshot_id = "${aws_ebs_snapshot.unencrypted_snapshot.id}" source_region = "${var.region}" encrypted = true tags = { Name = "Encrypted_Snapshot" } } # # Created Encrypted Volume # resource "aws_ebs_volume" "encrypted_volume" { availability_zone = "${var.az}" snapshot_id = "${aws_ebs_snapshot_copy.encrypted_snapshot.id}" tags = { Name = "Encrypted_Volume" } } |
Terraform Installation
Where did I install Terraform?
cd /usr/local/bin/ terraform --version |
Sudoers Directory
What’s in the /etc/sudoers.d/ directory? It’s a group of files with the following format as displayed in the code below. In the example, the file allows a Linux group or an AD group to assume the role of root, via the sudo command. As long as the group uses the correct format, and is located inside the /etc/sudoers.d/ directory, that group will have access to root.
%groupname ALL=(ALL) NOPASSWD: ALL |
Convert PFX to PEM format
SSL certificates comes in multiple formats. Some providers will hand you over certificates in PFX format which comes in a single file. If you need to import it to AWS Certificate Manager, you will need to convert it from PFX to PEM format. The following set of commands uses OpenSSL and pkcs12 to convert a SSL certificate from PFX to PEM format.
openssl pkcs12 -in cert.pfx -nocerts -out key.pem openssl rsa -in key.pem -out server.key openssl pkcs12 -in cert.pfx -clcerts -nokeys -out cert.pem openssl pkcs12 -in cert.pfx -nodes -nokeys -out chain.pem |
It result in 3 files.
- server.key is the private key
- cert.pem is the certificate
- cert.pem and chain.pem are the full chain.
Once you have them, you can the proceed to import it to ACM.

Who’s Logged in?
Find out who is logged in to the system.
$ w $ who |
Find the Biggest File
Find the biggest files in the current directory. Sort by from large to small. Display only the top 20. Display in human readable format.
find -type f -exec du -Sh {} + | sort -rh | head -n 20 |