@Atemu@lemmy.ml avatar

Atemu

@Atemu@lemmy.ml

Interested in Linux, FOSS, data storage systems, unfucking our society and a bit of gaming.

I help maintain Nixpkgs.

github.com/Atemu
reddit.com/u/Atemu12 (Probably won’t be active much anymore.)

This profile is from a federated server and may be incomplete. Browse more on the original instance.

Atemu,
@Atemu@lemmy.ml avatar

If I am packaging software for gentoo, all I have to do is translate the build instructions from the project’s documentation to gentoo’s package recipe.

It’s the same for Nixpkgs.

In nix, it seems that it is not that simple and you’ll have to do some exploration. Am I wrong?

In well behaved build systems, it’s likely easier to package than most other distros. If it’s not as well behaved you will have to do some “exploration” and the complexity can get quite out of control if the build system is exceptionally terrible.

Here is the package for the GNU hello program which uses a well-behaved build system:

github.com/NixOS/nixpkgs/blob/…/package.nix

If you ignore the optional passthru.tests, this is very simple. You provide metadata, sources etc. to the generic mkDerivation function and that’s it. The most complex non-standard thing this derivation does is enable the build system’s tests.

You don’t even need to run the provided build instructions because Nixpkgs’ stdenv abstracts those away. If it finds a makefile, it’ll automatically run make and make install with the correct flags for instance. Same for other standard build systems; if you pass cmake into nativeBuildInputs, it’ll attempt to build, install, check etc. using cmake’s standardised interfaces.

If the build system is poorly behaved however (like for instance Anki’s), you will have to get into the weeds and do some rather advanced things:

github.com/NixOS/nixpkgs/blob/…/default.nix

Luckily though, most packages aren’t like this.

ajayiyer, to linux
@ajayiyer@mastodon.social avatar

Gentle reminder to everyone that support for ends in about 90 weeks. Many computers can't upgrade to Win 11 so here are your options:

  1. Continue on Win 10 but with higher security risks.
  2. Buy new and expensive hardware that supports Win11.
  3. Try a beginner friendly distro like . It only takes about two months to acclimate.

@nixCraft @linux @windowscentralbot

Atemu,
@Atemu@lemmy.ml avatar

Some Adobe stuff runs in a web browser nowadays through WASM but if you’ve submitted to Adobe, Linux likely won’t be a possibility.

I'm an idiot (arm)

EDIT: Putting this at the top because not everyone is seeing what I actually need. I can unpack the rar archive just fine. What I can’t do (on arm) is add to/update the files in the rar archive. I have unrar already installed. What I can’t install is the rar package to create/update rar archives....

Atemu, (edited )
@Atemu@lemmy.ml avatar

Cookie banners are not really about cookies.

What they’re actually asking for is consent to process your data for profit in unethical ways. That usually involves cookies but could theoretically be done entirely without. They’re just a technological standard.

You might aswell say: “We use https. [consent] [settings]”

Atemu,
@Atemu@lemmy.ml avatar

Depends. There was that one F2P COD clone which used TCP and IIRC it did fine?

Atemu,
@Atemu@lemmy.ml avatar

Not what you’re asking for but a potential solution: Your TV itself might support Miracast.

Atemu,
@Atemu@lemmy.ml avatar

There’s the WIP NixOS-based SnowflakeOS that aims to make NixOS approachable for mere mortals but that’s still declarative configuration and of course still NixOS under the hood.

There’s a bunch of immutable distros out there that use OStree or some other imperatively managed snapshotting mechanism such as Fedora Silverblue or VanillaOS.

Atemu,
@Atemu@lemmy.ml avatar

Is there a court case about this already? Because that’s clearly not the intention of the GPL.

Considering Gentoo

I have an old iMac that I am planning to install some flavor of Linux on and while I was looking at various distros it occurred to me that it might be a good exercise to install Gentoo on it. Other than a separate machine for documentation and downloading the necessary packages, what else should I have set up to try this? Has...

Atemu,
@Atemu@lemmy.ml avatar

I’d also add a build machine to the setup. Building a modern desktop system on such a machine would take days.

What's an elegant way of automatically backing up the contents of a large drive to multiple smaller drives that add up to the capacity of the large drive? (on Linux)

So I have a nearly full 4 TB hard drive in my server that I want to make an offline backup of. However, the only spare hard drives I have are a few 500 GB and 1 TB ones, so the entire contents will not fit all at once, but I do have enough total space for it. I also only have one USB hard drive dock so I can only plug in one...

Atemu,
@Atemu@lemmy.ml avatar

I don’t want to do any sort of RAID 0 or striping because the hard drives are old and I don’t want a single one of them failing to make the entire backup unrecoverable.

This will happen in any case unless you had enough capacity for redundancy.

What is in this 4TB drive? A Linux installation? A bunch of user data? Both? What kind of data?

The first step to this is to separate your concerns. If you had e.g. a 20GiB Linux install, 10GiB of loose home files, 1TiB of Movies, 500GiB of photos, 1TiB of games and 500GiB of Music for example, you could back each of those up separately onto separate drives.

Now, it’s likely that you’d still have more data of one category than what fits on your largest external drive (movies are a likely candidate).

For this purpose, I use git-annex.branchable.com. It’s a beast to get into and set up properly with plenty of footguns attached but it was designed to solve issues like this elegantly.
One of the most important things it does is separate file content from file metadata; making metadata available in all locations (“repos”) while data can be present in only a subset, thereby achieving distributed storage. I.e. you could have 4TiB of file contents distributed over a bunch of 500GiB drives but in each one of those repos you’d have the full file tree available (metadata of all files + content of present files) allowing you to manage your files in any place without having all the contents present (or even any). It’s quite magical.

Once configured properly, you can simply attach a drive, clone the git repo onto it and then run a git annex sync --content and it’ll fill that drive up with as much content as it can or until each “file”'s numcopies or other configured constraints are reached.

Atemu,
@Atemu@lemmy.ml avatar

I mean, comments have languages and you can filter but the automatic detection isn’t very good.

The ability to mark communities as being a certain language by default (applying to all posts and comments unless specified or detected otherwise) would be great though.

Atemu,
@Atemu@lemmy.ml avatar

These aren’t all versions per se but mostly variants, versions and versions of variants. For example, we have packaged the xanmod kernel which is a modified kernel optimised for desktop use but it has two variants: Main and LTS. We have packaged both.

Here are the names of all of our kernels currently to give you an idea (as a JSON list):


<span style="color:#323232;">[
</span><span style="color:#323232;">  </span><span style="color:#183691;">"linuxPackages"</span><span style="color:#323232;">,
</span><span style="color:#323232;">  </span><span style="color:#183691;">"linuxPackages-libre"</span><span style="color:#323232;">,
</span><span style="color:#323232;">  </span><span style="color:#183691;">"linuxPackages-rt"</span><span style="color:#323232;">,
</span><span style="color:#323232;">  </span><span style="color:#183691;">"linuxPackages-rt_latest"</span><span style="color:#323232;">,
</span><span style="color:#323232;">  </span><span style="color:#183691;">"linuxPackages_4_14"</span><span style="color:#323232;">,
</span><span style="color:#323232;">  </span><span style="color:#183691;">"linuxPackages_4_19"</span><span style="color:#323232;">,
</span><span style="color:#323232;">  </span><span style="color:#183691;">"linuxPackages_4_19_hardened"</span><span style="color:#323232;">,
</span><span style="color:#323232;">  </span><span style="color:#183691;">"linuxPackages_4_9"</span><span style="color:#323232;">,
</span><span style="color:#323232;">  </span><span style="color:#183691;">"linuxPackages_5_10"</span><span style="color:#323232;">,
</span><span style="color:#323232;">  </span><span style="color:#183691;">"linuxPackages_5_10_hardened"</span><span style="color:#323232;">,
</span><span style="color:#323232;">  </span><span style="color:#183691;">"linuxPackages_5_15"</span><span style="color:#323232;">,
</span><span style="color:#323232;">  </span><span style="color:#183691;">"linuxPackages_5_15_hardened"</span><span style="color:#323232;">,
</span><span style="color:#323232;">  </span><span style="color:#183691;">"linuxPackages_5_18"</span><span style="color:#323232;">,
</span><span style="color:#323232;">  </span><span style="color:#183691;">"linuxPackages_5_19"</span><span style="color:#323232;">,
</span><span style="color:#323232;">  </span><span style="color:#183691;">"linuxPackages_5_4"</span><span style="color:#323232;">,
</span><span style="color:#323232;">  </span><span style="color:#183691;">"linuxPackages_5_4_hardened"</span><span style="color:#323232;">,
</span><span style="color:#323232;">  </span><span style="color:#183691;">"linuxPackages_6_0"</span><span style="color:#323232;">,
</span><span style="color:#323232;">  </span><span style="color:#183691;">"linuxPackages_6_1"</span><span style="color:#323232;">,
</span><span style="color:#323232;">  </span><span style="color:#183691;">"linuxPackages_6_1_hardened"</span><span style="color:#323232;">,
</span><span style="color:#323232;">  </span><span style="color:#183691;">"linuxPackages_6_2"</span><span style="color:#323232;">,
</span><span style="color:#323232;">  </span><span style="color:#183691;">"linuxPackages_6_3"</span><span style="color:#323232;">,
</span><span style="color:#323232;">  </span><span style="color:#183691;">"linuxPackages_6_4"</span><span style="color:#323232;">,
</span><span style="color:#323232;">  </span><span style="color:#183691;">"linuxPackages_6_5"</span><span style="color:#323232;">,
</span><span style="color:#323232;">  </span><span style="color:#183691;">"linuxPackages_6_5_hardened"</span><span style="color:#323232;">,
</span><span style="color:#323232;">  </span><span style="color:#183691;">"linuxPackages_6_6"</span><span style="color:#323232;">,
</span><span style="color:#323232;">  </span><span style="color:#183691;">"linuxPackages_custom"</span><span style="color:#323232;">,
</span><span style="color:#323232;">  </span><span style="color:#183691;">"linuxPackages_custom_tinyconfig_kernel"</span><span style="color:#323232;">,
</span><span style="color:#323232;">  </span><span style="color:#183691;">"linuxPackages_hardened"</span><span style="color:#323232;">,
</span><span style="color:#323232;">  </span><span style="color:#183691;">"linuxPackages_latest"</span><span style="color:#323232;">,
</span><span style="color:#323232;">  </span><span style="color:#183691;">"linuxPackages_latest-libre"</span><span style="color:#323232;">,
</span><span style="color:#323232;">  </span><span style="color:#183691;">"linuxPackages_latest_hardened"</span><span style="color:#323232;">,
</span><span style="color:#323232;">  </span><span style="color:#183691;">"linuxPackages_latest_xen_dom0"</span><span style="color:#323232;">,
</span><span style="color:#323232;">  </span><span style="color:#183691;">"linuxPackages_latest_xen_dom0_hardened"</span><span style="color:#323232;">,
</span><span style="color:#323232;">  </span><span style="color:#183691;">"linuxPackages_lqx"</span><span style="color:#323232;">,
</span><span style="color:#323232;">  </span><span style="color:#183691;">"linuxPackages_rpi0"</span><span style="color:#323232;">,
</span><span style="color:#323232;">  </span><span style="color:#183691;">"linuxPackages_rpi02w"</span><span style="color:#323232;">,
</span><span style="color:#323232;">  </span><span style="color:#183691;">"linuxPackages_rpi1"</span><span style="color:#323232;">,
</span><span style="color:#323232;">  </span><span style="color:#183691;">"linuxPackages_rpi2"</span><span style="color:#323232;">,
</span><span style="color:#323232;">  </span><span style="color:#183691;">"linuxPackages_rpi3"</span><span style="color:#323232;">,
</span><span style="color:#323232;">  </span><span style="color:#183691;">"linuxPackages_rpi4"</span><span style="color:#323232;">,
</span><span style="color:#323232;">  </span><span style="color:#183691;">"linuxPackages_rt_5_10"</span><span style="color:#323232;">,
</span><span style="color:#323232;">  </span><span style="color:#183691;">"linuxPackages_rt_5_15"</span><span style="color:#323232;">,
</span><span style="color:#323232;">  </span><span style="color:#183691;">"linuxPackages_rt_5_4"</span><span style="color:#323232;">,
</span><span style="color:#323232;">  </span><span style="color:#183691;">"linuxPackages_rt_6_1"</span><span style="color:#323232;">,
</span><span style="color:#323232;">  </span><span style="color:#183691;">"linuxPackages_testing"</span><span style="color:#323232;">,
</span><span style="color:#323232;">  </span><span style="color:#183691;">"linuxPackages_testing_bcachefs"</span><span style="color:#323232;">,
</span><span style="color:#323232;">  </span><span style="color:#183691;">"linuxPackages_xanmod"</span><span style="color:#323232;">,
</span><span style="color:#323232;">  </span><span style="color:#183691;">"linuxPackages_xanmod_latest"</span><span style="color:#323232;">,
</span><span style="color:#323232;">  </span><span style="color:#183691;">"linuxPackages_xanmod_stable"</span><span style="color:#323232;">,
</span><span style="color:#323232;">  </span><span style="color:#183691;">"linuxPackages_xen_dom0"</span><span style="color:#323232;">,
</span><span style="color:#323232;">  </span><span style="color:#183691;">"linuxPackages_xen_dom0_hardened"</span><span style="color:#323232;">,
</span><span style="color:#323232;">  </span><span style="color:#183691;">"linuxPackages_zen"
</span><span style="color:#323232;">]
</span>

(Note that some of these are aliases; linuxPackages_latest is currently linuxPackages_6_6 for example.)

Each of these has the following nvidiaPackages (modulo incompatibilities):


<span style="color:#323232;">[
</span><span style="color:#323232;">  </span><span style="color:#183691;">"beta"</span><span style="color:#323232;">,
</span><span style="color:#323232;">  </span><span style="color:#183691;">"dc"</span><span style="color:#323232;">,
</span><span style="color:#323232;">  </span><span style="color:#183691;">"dc_520"</span><span style="color:#323232;">,
</span><span style="color:#323232;">  </span><span style="color:#183691;">"latest"</span><span style="color:#323232;">,
</span><span style="color:#323232;">  </span><span style="color:#183691;">"legacy_340"</span><span style="color:#323232;">,
</span><span style="color:#323232;">  </span><span style="color:#183691;">"legacy_390"</span><span style="color:#323232;">,
</span><span style="color:#323232;">  </span><span style="color:#183691;">"legacy_470"</span><span style="color:#323232;">,
</span><span style="color:#323232;">  </span><span style="color:#183691;">"production"</span><span style="color:#323232;">,
</span><span style="color:#323232;">  </span><span style="color:#183691;">"stable"</span><span style="color:#323232;">,
</span><span style="color:#323232;">  </span><span style="color:#183691;">"vulkan_beta"
</span><span style="color:#323232;">]
</span>

(Again, some of these are aliases.)

This is useful to have because users might have hardware constraints. It’s not hard to imagine a scenario where a user might have a WiFi chip that only works with kernel ABIs < 5.4 and require the 470 nvidia driver for their old GPU. Packaging just the latest kernel and just the latest Nvidia driver would make this user unable to use their system.

Atemu,
@Atemu@lemmy.ml avatar

GTK 4 does not, possibly in a future version

That would be news to me. Has GTK finally managed to switch away from using actual real hardware pixels as its base unit for measurement?

Atemu,
@Atemu@lemmy.ml avatar

Detecting extensions using web accessible resources is not possible on Firefox as Firefox extension ID’s are unique for every browser instance. Therefore the URL of the extension resources cannot be known by third parties.

and also for Chrome:

in manifest v3 extensions will be able to enable ‘use_dynamic_url’ option, which will change the resource URL for each session (browser restart). This will render this detection method unusable.

Though it should be noted that this method isn’t the only way to detect extensions.

Atemu,
@Atemu@lemmy.ml avatar

I use NixOS but I don’t bother with automatic deployment or even automatic formatting. I don’t feel it’s necessary in a homelab setting as hardware failure rarely happens at such small scale and the manual steps left aren’t that significant.

Atemu,
@Atemu@lemmy.ml avatar

It actually is. The file gets opened by bash and bash passes the file descriptor to cat but cat is the program which instructs the kernel to write to the device.

Modern cat even does reflink copies on supported filesystems.

Atemu,
@Atemu@lemmy.ml avatar

In regular FHS distros, an upgrade to libxyz can be done without an update to its dependants a, b and c. The libxyz.so is updated in-place and newly run processes of a, b and c will use the new shared object code.

In Nix’ model, changing a dependency in any way changes all of its dependants too. The package a that depends on libxyz 1.0.0 is treated as entirely different from the otherwise same package a that depends on libxyz 1.0.1 or libxyz 1.0.0 with a patch applied/new dependency/patch applied to the compiler/anything.

Nix encodes everything that could in any way influence a package’s content into that package’s “version”. That’s the hash in every Nix store path (i.e. /nix/store/5jlfqjgr34crcljr8r93kwg2rk5psj9a-bash-interactive-5.2-p15/bin/bash). The version number in the end is just there to inform humans of a path’s contents; as far as Nix is concerned, it’s just an arbitrary name string.

Therefore, any update to “core” dependencies requires a rebuild of all dependants. For very central core packages such as glibc, that means almost all packages in existence. Because those packages are “different” from the packages on your system without the update, you must download them all again and, because they have different hashes, they will be in separate paths in your Nix store.

This is what allows Nix to have parallel “installation” of any version of any package and roll back your entire config to a previous state because your entire system is treated as a “package” with the same semantics as described above.

Unless you have harsh data caps, extremely slow connections or are extremely tight on disk space, this isn’t much of a concern though.
Additionally, you can always “garbage collect” old paths that are no longer referenced and Nix can deduplicate whole files that are 1:1 the same across the whole Nix store.

Atemu,
@Atemu@lemmy.ml avatar

Any distro that ships relatively recent libraries and kernels.

With the exception of Debian, RHEL, SLES and the like, pretty much everything.

Atemu, (edited )
@Atemu@lemmy.ml avatar

Guix might also be able to do this but I don’t think the others can.

This relies on NixOS’ declarative configuration which Silverbluae and the like do not have; they are configured imperatively.

What are the rules of buying used storage?

I am currently expanding my Homelab setup, and want to buy a 10TB drive, for media storage. It’s a Seagate Ironwolf disk, so perfect for the job. But, it’s second hand. It was originally bought in 2019, but stopped being used after 2022. Only used for static storage, it’s been booted less than 50 times. I can get it for...

Atemu,
@Atemu@lemmy.ml avatar

Original price doesn’t matter, you need to compare it against current new offerings. A drive like that, I’d buy for 8-10€/TB at max. because current new HDD pricing is 15€/TB at the low end.

What you also need is SMART output. Watch out for high uncorrectable errors, writes and whatever. I’d never buy a drive without having seen its SMART data.

Atemu,
@Atemu@lemmy.ml avatar

I’m agnostic, so obviously my view on that is that we simply don’t know.

  • All
  • Subscribed
  • Moderated
  • Favorites
  • localhost
  • All magazines
  • Loading…
    Loading the web debug toolbar…
    Attempt #