Language Selection

English French German Italian Portuguese Spanish

today's leftovers

Filed under
Misc
  • Daniel Stenberg: More on less curl memory

    Back in September 2020 I wrote about my work to trim curl allocations done for FTP transfers. Now I’m back again on the memory use in curl topic, from a different angle.

    This time, I learned about the awesome tool pahole, which can (among other things) show structs and their sizes from a built library – and when embracing this fun toy, I ran some scripts on a range of historic curl releases to get a sense of how we’re doing over time – memory size and memory allocations wise.

    The task I set out to myself was: figure out how the sizes of key structs in curl have changed over time, and correlate that with the number and size of allocations done at run-time. To make sure that trimming down the size of a specific struct doesn’t just get allocated by another one instead, thus nullifying the gain. I want to make sure we’re not slowly degrading – and if we do, we should at least know about it!

    Also: we keep developing curl at a fairly good pace and we’re adding features in almost every release. Some growth is to expected and should be tolerated I think. We also keep the build process very configurable so users with particular needs and requirements can switch off features and thus also gain memory.

    [...]

    The gain in 7.62.0 was mostly the removal of the default allocation of the upload buffer, which isn’t used in this test…

    The current size tells me several things. We’re at a memory consumption level that is probably at its lowest point in the last decade – while at the same time having more features and being better than ever before. If we deduct the download buffer we have 30427 additional bytes allocated. Compare this to 7.50.0 which allocated 68089 bytes on top of the download buffer!

    If I change my curl to use the smallest download buffer size allowed by libcurl (1KB) instead of the default 100KB, it ends up peaking at: 31451 bytes. That’s 37% of the memory needed by 7.50.0.

    In my opinion, this is very good.

    It might also be worth to reiterate that this is with a full featured libcurl build. We can shrink even further if we switch off undesired features or just go tiny-curl.

    I hope this goes without saying, but of course all of this work has been done with the API and ABI still intact.

  • Ubuntu Blog: Compact and Bijou

    Snaps are designed to be self-contained packages of binaries, libraries and other assets. A snap might end up being quite bulky if the primary application it contains has many additional dependencies. This is a by-product of the snap needing to run on any Linux distribution where dependencies cannot always be expected to be installed.

    This is offset by the snap being compressed on disk, and the Snap Store delivering delta updates rather than force a full download on each update. Furthermore the concept of “shared content” or “platform” snaps allows for common bundles of libraries to be installed only once and then reused across multiple snaps.

    Typically in documentation we detail building snaps with the command line tool snapcraft. Snapcraft has logic to pull in and stage any required dependencies. We generally recommend using snapcraft because it helps automate things, and make the snapping process more reliable.

    But what if your application has minimal, or no dependencies?. Your program might be a single binary written in a modern language like go or rust. Maybe it’s a simple shell or python script, which requires no additional dependencies. Well, there’s a couple of other interesting ways to build a snap we should look at.

  • Dev Interview: Launching a career as an enterprise developer in Austin, Chapter 4

    In our last Dev Interview chapter, our trio of young developers discussed what it was like joining the corporate world along with their first impressions. As a developer, you’ll often be part of a smaller squad or you may form your own squad around more personal reasons. Given Luc, Da-In and Diana all have recently moved to Austin and started working at IBM in the summer of 2019, it’s pretty natural for the three to bond together over shared experiences. And provide support to each other during such interesting times. Let’s see what Da-In, Diana, and Luc have been up to as they discuss some of the more personal aspects of life and office friendships in corporate America.

  • CUPS-PDF | Print to PDF from any Application

    I’m sure this isn’t new to anyone, certainly not to me but after using another operating system for a bit I was really annoyed and wanted to just highlight what a wonderful thing this “printer” is for openSUSE and any other Linux distribution, for that matter. Sometimes, I think it is good to reflect on the the great things we take for granted here in Linux land.

  • Libre Arts - This is 2021: what's coming in free/libre software

    The fork is just rebranding and no new features or UX fixes (unless removing the bell pepper brush is your idea of finally making it right for everyone), and then Glimpse-NX — at least for the public eye — exists only as UI mockups. They did get Bilal Elmoussaoui (GNOME team) to create Rust bindings to GEGL for them last autumn, but that’s all as far as I can tell.

    So the current pace of the project is not very impressive (again, as a GIMP contributor, I’m biased) and I’m not sure how much we are going to see in 2021.

    That said, I think having a whole new image editor based on GEGL would be lovely. I don’t see why Glimpse-NX couldn’t be that project. A proof-of-concept application that would load an image, apply a filter, and export it back sounds feasible. It’s something one could iterate upon. So maybe that’s how they are going to play it.

    The fine folks over at Krita posted a 2020 report where they listed major challenges they will be facing this year: the completion of resources management rewrite that currently blocks v5.0 release, the port to Apple M1, the launching of a new development fund (akin to that of Blender), and more.

  • This is 2021: what’s coming in free/libre software (Libre Arts)

    Libre Arts (formerly Libre Graphics World) has posted a comprehensive survey of what 2021 might hold for a wide range of free content-creation software.

More in Tux Machines

digiKam 7.7.0 is released

After three months of active maintenance and another bug triage, the digiKam team is proud to present version 7.7.0 of its open source digital photo manager. See below the list of most important features coming with this release. Read more

Dilution and Misuse of the "Linux" Brand

Samsung, Red Hat to Work on Linux Drivers for Future Tech

The metaverse is expected to uproot system design as we know it, and Samsung is one of many hardware vendors re-imagining data center infrastructure in preparation for a parallel 3D world. Samsung is working on new memory technologies that provide faster bandwidth inside hardware for data to travel between CPUs, storage and other computing resources. The company also announced it was partnering with Red Hat to ensure these technologies have Linux compatibility. Read more

today's howtos

  • How to install go1.19beta on Ubuntu 22.04 – NextGenTips

    In this tutorial, we are going to explore how to install go on Ubuntu 22.04 Golang is an open-source programming language that is easy to learn and use. It is built-in concurrency and has a robust standard library. It is reliable, builds fast, and efficient software that scales fast. Its concurrency mechanisms make it easy to write programs that get the most out of multicore and networked machines, while its novel-type systems enable flexible and modular program constructions. Go compiles quickly to machine code and has the convenience of garbage collection and the power of run-time reflection. In this guide, we are going to learn how to install golang 1.19beta on Ubuntu 22.04. Go 1.19beta1 is not yet released. There is so much work in progress with all the documentation.

  • molecule test: failed to connect to bus in systemd container - openQA bites

    Ansible Molecule is a project to help you test your ansible roles. I’m using molecule for automatically testing the ansible roles of geekoops.

  • How To Install MongoDB on AlmaLinux 9 - idroot

    In this tutorial, we will show you how to install MongoDB on AlmaLinux 9. For those of you who didn’t know, MongoDB is a high-performance, highly scalable document-oriented NoSQL database. Unlike in SQL databases where data is stored in rows and columns inside tables, in MongoDB, data is structured in JSON-like format inside records which are referred to as documents. The open-source attribute of MongoDB as a database software makes it an ideal candidate for almost any database-related project. This article assumes you have at least basic knowledge of Linux, know how to use the shell, and most importantly, you host your site on your own VPS. The installation is quite simple and assumes you are running in the root account, if not you may need to add ‘sudo‘ to the commands to get root privileges. I will show you the step-by-step installation of the MongoDB NoSQL database on AlmaLinux 9. You can follow the same instructions for CentOS and Rocky Linux.

  • An introduction (and how-to) to Plugin Loader for the Steam Deck. - Invidious
  • Self-host a Ghost Blog With Traefik

    Ghost is a very popular open-source content management system. Started as an alternative to WordPress and it went on to become an alternative to Substack by focusing on membership and newsletter. The creators of Ghost offer managed Pro hosting but it may not fit everyone's budget. Alternatively, you can self-host it on your own cloud servers. On Linux handbook, we already have a guide on deploying Ghost with Docker in a reverse proxy setup. Instead of Ngnix reverse proxy, you can also use another software called Traefik with Docker. It is a popular open-source cloud-native application proxy, API Gateway, Edge-router, and more. I use Traefik to secure my websites using an SSL certificate obtained from Let's Encrypt. Once deployed, Traefik can automatically manage your certificates and their renewals. In this tutorial, I'll share the necessary steps for deploying a Ghost blog with Docker and Traefik.