Tagged articles
26 articles
Page 1 of 1
Deepin Linux
Deepin Linux
Mar 5, 2026 · Fundamentals

Unveiling malloc: How C Allocates Memory Behind the Scenes

This comprehensive guide explains the inner workings of the C malloc function, covering memory layout, stack vs heap, glibc memory pools, system calls like brk/sbrk and mmap, allocation strategies, fragmentation, alignment, multithreading safety, and comparisons with calloc, realloc, and C++ new.

C programmingglibcheap management
0 likes · 53 min read
Unveiling malloc: How C Allocates Memory Behind the Scenes
Deepin Linux
Deepin Linux
May 28, 2025 · Fundamentals

Understanding glibc malloc: Overview, Mechanisms, and Optimization Techniques

This article explains the role of glibc malloc in dynamic memory allocation, describes its internal data structures and allocation/free algorithms, provides a C code example, and offers practical optimization tips and common pitfalls for safe and efficient memory management.

C programmingMemory Managementdynamic allocation
0 likes · 13 min read
Understanding glibc malloc: Overview, Mechanisms, and Optimization Techniques
vivo Internet Technology
vivo Internet Technology
Dec 11, 2024 · Databases

RocksDB Memory Usage Analysis and Optimization: Troubleshooting Excessive Memory Consumption in Production

The article examines a production RocksDB memory‑usage problem where two instances consumed 59 GB on a 32‑CPU, 64‑GB server, identifies glibc ptmalloc’s unreclaimed free memory as the main cause, and shows that switching to jemalloc cuts usage by roughly 25 % while improving I/O and CPU efficiency.

Linux Memory ManagementRocksDBglibc
0 likes · 11 min read
RocksDB Memory Usage Analysis and Optimization: Troubleshooting Excessive Memory Consumption in Production
Wukong Talks Architecture
Wukong Talks Architecture
Jun 7, 2024 · Operations

Troubleshooting Node Installation Failure on Ubuntu Due to Missing GLIBC 2.28 and Recovery Steps

This article recounts a failed Node.js installation on an older Ubuntu server caused by a missing GLIBC 2.28 library, details the attempted GLIBC upgrade script that led to system-wide segmentation faults, and explains how reinstalling a newer Ubuntu version resolved the issue while emphasizing careful backup practices.

DeploymentNode.jsUbuntu
0 likes · 4 min read
Troubleshooting Node Installation Failure on Ubuntu Due to Missing GLIBC 2.28 and Recovery Steps
Open Source Tech Hub
Open Source Tech Hub
Apr 26, 2024 · Information Security

How to Safely Mitigate the glibc CVE‑2024‑2961 Iconv Overflow in PHP

This article explains the glibc CVE‑2024‑2961 buffer overflow in ISO‑2022‑CN‑EXT conversion, how it can be exploited through PHP's iconv extension, and provides practical mitigation steps such as applying distro patches, validating charset inputs, and removing vulnerable modules when patches are unavailable.

CVE-2024-2961IConvLinux
0 likes · 4 min read
How to Safely Mitigate the glibc CVE‑2024‑2961 Iconv Overflow in PHP
Baidu Geek Talk
Baidu Geek Talk
Dec 16, 2022 · Fundamentals

Exploring ptmalloc: Memory Management in Linux C++ Programs

The article explains how glibc’s default ptmalloc allocator structures memory into main and non‑main arenas, uses chunk‑based bins (fast, unsorted, small, large) for allocation and deallocation, details its locking and OS‑interaction mechanisms, and evaluates its design trade‑offs versus modern allocators.

CFreeLinux
0 likes · 12 min read
Exploring ptmalloc: Memory Management in Linux C++ Programs
Alibaba Cloud Native
Alibaba Cloud Native
Jun 18, 2022 · Fundamentals

Unraveling Java Agent Crashes: JVM, glibc, and Thread‑Local Pitfalls

Starting from mysterious Java Agent errors in Alibaba Cloud environments, this article traces the failure through the JVM’s Instrumentation.appendToSystemClassLoaderSearch call, examines glibc’s stat and iconv conversions, reveals thread‑local storage issues, and presents concrete fixes using pthread TLS and proxy wrappers.

IConvJVMJava Agent
0 likes · 12 min read
Unraveling Java Agent Crashes: JVM, glibc, and Thread‑Local Pitfalls
ITPUB
ITPUB
Dec 7, 2020 · Fundamentals

Run Newer glibc‑Dependent Binaries on CentOS 6 Without Upgrading glibc

This guide explains how to resolve glibc version errors on CentOS 6 by analyzing ELF symbol tables with objdump and readelf, editing .gnu.version_r entries via a hex editor, and using patchelf to add needed libraries, allowing older systems to run newer binaries safely.

ELFbinary compatibilitycentos6
0 likes · 15 min read
Run Newer glibc‑Dependent Binaries on CentOS 6 Without Upgrading glibc
Liangxu Linux
Liangxu Linux
Dec 5, 2020 · Operations

Run Newer glibc Binaries on Old CentOS 6 Without Upgrading glibc

This guide explains why a third‑party program compiled against glibc 2.14/2.17 fails on CentOS 6, how to inspect the ELF symbol versions with objdump and readelf, and how to patch the binary using a hex editor and patchelf so it can run with the system's older glibc.

ELFbinary compatibilitycentos6
0 likes · 16 min read
Run Newer glibc Binaries on Old CentOS 6 Without Upgrading glibc
ITFLY8 Architecture Home
ITFLY8 Architecture Home
Aug 29, 2018 · Fundamentals

Why Java Processes Show 50GB+ VIRT Memory and How to Control It

An investigation reveals that Java 8 processes can report virtual memory usage exceeding 50 GB due to extensive address space allocation by glibc’s arena mechanism, not actual physical memory, and explains how environment variables like MALLOC_ARENA_MAX can limit this VIRT growth.

MALLOC_ARENA_MAXVIRTVirtual Memory
0 likes · 5 min read
Why Java Processes Show 50GB+ VIRT Memory and How to Control It
ITPUB
ITPUB
Sep 15, 2017 · Fundamentals

How Linux and glibc Manage Memory: From Virtual Allocation to Physical Release

This article explains Linux's two‑level memory model, lazy physical allocation, the glibc malloc implementation, chunk metadata, large‑vs‑small allocations, memory holes, debugging hooks, leak detection with mtrace, and practical ways to measure a process's memory usage via /proc.

DebuggingMemory Managementglibc
0 likes · 15 min read
How Linux and glibc Manage Memory: From Virtual Allocation to Physical Release