Aun's Blog

Welcome to my blog !


Alter system calls with LD_PRELOAD

Published at October 17, 2021 ·  4 min read

Use LD_PRELOAD to alter library calls I have a program that is failing because it is making a system call to change permissins on a file with chmod, fchmodat, and fchmod -S 2. The program does not own the file, and doesn’t need to change the permission but fails with -1 EPERM on this call. This was determined with strace -f -e chmod,fchmod,fchmodat $program Example program This program simulates the behaviour of the application with the issue....

Mount a block device image

Published at October 16, 2021 ·  2 min read

How to mount a block device image Task: An image of a block divice has been created with dd for data recovery purposes. Mount the filesystem from the image and access files. Review image partition information Confirm that the image size matches the size of the source block device. If the size is incorrect review the block device options or try another program such as ddrescue to read a failing block device....

DevOps notes

Published at September 6, 2021 ·  5 min read

Notes from a DevOps class....

Linux kernel module basics

Published at August 19, 2021 ·  2 min read

A basic example of a loadable kernel module, loading, debugging and build....

zpool reimport

Published at July 30, 2021 ·  2 min read

Import ZFS pool into a new computer In this example hardware has failed and the zpool disks are connected to a new computer. Need to reconstruct the zpool filesystem for continued data use. All disks from the zpool are now connected to a new computer. Find the pool root@nas:~# zpool import pool: zfsdata id: 466262796876421602 state: ONLINE status: The pool was last accessed by another system. action: The pool can be imported using its name or numeric identifier and the '-f' flag....

HTML 5 routes & deep links with Apache

Published at April 14, 2019 ·  3 min read

HTML5 client routing Deep links to client side applications using frameworks that make use of HTML5 routing, such as Angular, can be problematic. The web browser client side application utilizes regular URL paths for client side application navigation that appear in the browser address to be locations of actual resources. This however is not the case, the running application in the browser makes use of javascript pushstate to navigate to states within the client side application and does not request the resource shown in the browser address bar when running....

Networking Observability

Published at January 5, 2019 ·  2 min read

Notes on networking observability commnads For many years and many UNIXen the netstat command has been the way to get information on the current state of TCP/IP and UNIX sockets. The recent man pages for netstat on linux state that netstat is “mostly obsolete” and use ss instead. The man page for ss, “another utility to investigate sockets”, says that is allows showing information similar to netstat. Some notes on using ss....

Functional Thinking

Published at November 16, 2018 ·  6 min read

Functional Thinking For functional programming. A Non Functional Aproach This is a sample program that processes a generated sample list of data. With the list of data it performs common operations such as find items, count types, sum things up etc. Do you see the duplicate code that is copy pasted with small changes? Can you tell what each loop is doing without thinking about what is going on in the loop or using the comments?...

Growing Frozen Particle Waves

Published at November 11, 2018 ·  1 min read

Growing Frozen Particle Waves I recently added docker support to Frozen Particle Waves. If you are looking for an OSS project where you can contribute to this is a great option. It isn’t finished so you have a great base to contribute updates and exhibit your skills. Some additions and updates that you can help with: Add a storage system and services to add users and cameras. Separate the UI into a more up to date framework such as Angular....

Process Slaughterhouse

Published at October 5, 2018 ·  3 min read

Cattle not pets If you are running a stateless scale out application the cattle not pets mantra will be stuck in your thoughts. Sick processes and whole container environments that misbehave are taken out back of the server and executed. For the benefit of those handling on call support and for immediate recovery the easy button is great. However, it ignores the real problem. If you had a leaky roof the long term solution is not get more buckets to catch the water....


Recent posts

Alter system calls with LD_PRELOAD

Mount a block device image

DevOps notes

Linux kernel module basics

zpool reimport


Archives

2021 (5)
2019 (2)
2018 (7)