unofficial mirror of help-guix@gnu.org 
 help / color / mirror / Atom feed
* Message by a novice
@ 2023-05-13 18:31 anguriamelone--- via
  2023-05-14  6:40 ` Edouard Klein
                   ` (3 more replies)
  0 siblings, 4 replies; 6+ messages in thread
From: anguriamelone--- via @ 2023-05-13 18:31 UTC (permalink / raw)
  To: help-guix@gnu.org

Hi to everyone.

I am a novice in GNU Guix, so far I used Trisquel GN-Linux 9.0.2 (i686), but at the end of April the support for the i686 version has been discontinued. Nevertheless I want to continue using free (as in freedom) software and, getting set to install the iso image, if I don't ask for too muchas an abosulte beginner, I would like to know what are the basic command lines corresponding to those of Trisquel GNU-Linux below:

sudo apt update

sudo apt upgrade

sudo apt install (package name)

sudo apt remove --purge (package name)

sudo apt search (package name)

sudo apt autoremove

sudo apt purge

sudo apt autoclean

sudo apt clean

   Thanks for the attention and kind regards.

                  Piriponzolo

 

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: Message by a novice
  2023-05-13 18:31 Message by a novice anguriamelone--- via
@ 2023-05-14  6:40 ` Edouard Klein
  2023-05-14  6:58 ` 宋文武
                   ` (2 subsequent siblings)
  3 siblings, 0 replies; 6+ messages in thread
From: Edouard Klein @ 2023-05-14  6:40 UTC (permalink / raw)
  To: anguriamelone; +Cc: help-guix

Hi !

First, drop sudo, guix can be run by unprivileged users once installed,
and will only affect them. Great for shared environments !

anguriamelone--- via <help-guix@gnu.org> writes:

> Hi to everyone.
>
> I am a novice in GNU Guix, so far I used Trisquel GN-Linux 9.0.2 (i686), but at the end of April the support for the i686 version has been discontinued. Nevertheless I want to continue using free (as in freedom) software and, getting set to install the iso image, if I don't ask for too muchas an abosulte beginner, I would like to know what are the basic command lines corresponding to those of Trisquel GNU-Linux below:
>
> sudo apt update
>

guix pull

> sudo apt upgrade
>

For the system:
sudo guix system reconfigure /etc/config.scm

For your user packages
guix package --upgrade

> sudo apt install (package name)
>

guix install <package-name>

>
> sudo apt remove --purge (package name)
>

guix remove <package-name>

Subtle differences with '--purge'. The package will be removed from your
profile, but still be available in the store, and local conf (typically
in ~/.conf/...) will still be there, and need to be removed manually.
But it would have been put manually by you if it exists there, so guix
is consistent.


> sudo apt search (package name)
>

Don't use sudo for apt search.

guix search <keywords>...

> sudo apt autoremove
>
> sudo apt purge
>
> sudo apt autoclean
>
> sudo apt clean
>

Guix is very different from apt, there is no direct mapping for those
last four.

To reclaim disk space, run guix gc more or less aggressively.

Here is the doc:
https://guix.gnu.org/manual/en/guix.html#Invoking-guix-gc
Here are some notes on very aggressively reclaiming disk space:

  See how much space the store uses
  : du -h -d0 /gnu/store
  : 26G     /gnu/store
  See all the roots that you have
  : guix gc --list-roots | sort
  : ...  a lot of generations from my different profiles
  : guix gc --list-roots | wc -l
  : 107
  Delete previous generations, you may be more or less aggresive with
  the options. Giving no options deletes all generations but the 0th one and the current one. Do this for every profile.
  List all existing profiles
  : guix gc --list-roots | sed 's/-[0-9]*-link$//' | sort | uniq
  Delete the maximum amount of generations from all the profiles
  : for profile in $(guix gc --list-roots | sed 's/-[0-9]*-link$//' | sort | uniq)
  : do
  : echo deleting generations in "$profile";
  : guix package --profile="$profile" --delete-generations;
  : done
  WARNING: you may want to keep all the genrations from =current-guix= (see [[sec:default-profiles]]), because they don't take up much space, and they will allow you to rebuild the packages from a previously installed and known-good version of guix, instead of having to bisect your way to a working version with =guix time-machine= as we did in [[sec:bisect]].
  You can also delete the profiles you are no longer interested in. Delete with =rm= the =guix_profile= (or whatever you called it) link and the =guix_profile-NN-link= that guix added. These will no longer appear in the roots, and therefore the packages they were referencing will be deleteable by the garbage collector.
  Then, run =guix pull=, and update the packages in all your profiles:
  : for profile in $(guix gc --list-roots | sed 's/-[0-9]*-link$//' | sort | uniq); do echo upgrading packages in  "$profile"; guix package --profile="$profile" --upgrade; done
  This will allow all common packages between your profiles to be de-duplicated in the store, because they will be at the same exact version, whereas if one was more recent than the other, both versions would be kept in the store, using up disk space. FIXME(ref the section that explain the store and the deduplication).
  Once all of this is done, the garbage collector can now be launched:
  : guix gc
  : du -h -d0 /gnu/store
  : 6,6G    /gnu/store

There are also some directories in .cache that you can remove manually.

Hope that helps.

Cheers,

Edouard.


>    Thanks for the attention and kind regards.
>
>                   Piriponzolo
>
>


^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: Message by a novice
  2023-05-13 18:31 Message by a novice anguriamelone--- via
  2023-05-14  6:40 ` Edouard Klein
@ 2023-05-14  6:58 ` 宋文武
  2023-05-14 12:49   ` Csepp
  2023-05-14  7:59 ` (
  2023-05-14 14:52 ` Felix Lechner via
  3 siblings, 1 reply; 6+ messages in thread
From: 宋文武 @ 2023-05-14  6:58 UTC (permalink / raw)
  To: anguriamelone--- via; +Cc: anguriamelone

anguriamelone--- via <help-guix@gnu.org> writes:

> Hi to everyone.
>
> I am a novice in GNU Guix, so far I used Trisquel GN-Linux 9.0.2
> (i686), but at the end of April the support for the i686 version has
> been discontinued.

Hello, while not abandoned, i686 support in Guix is not well maintained.
Which means less packages are available compare to x86_64, and require
more time build (and maybe fixing) packages yourself instead of download
prebuilt ones ('substitutes' in guix terms).


> I would like to know what are the basic command lines corresponding to
> those of Trisquel GNU-Linux below:

I'll give a quick answer, more info can be find in the guix manual and
online videos.

https://guix.gnu.org/en/manual/en/html_node/Package-Management.html#Package-Management
https://guix.gnu.org/en/videos/2020/everyday-use-of-gnu-guix-part-one/

>
> sudo apt update

guix package --upgrade

> sudo apt upgrade

guix pull

> sudo apt install (package name)

guix package --install

> sudo apt remove --purge (package name)

guix package --remove

> sudo apt search (package name)

guix search

> sudo apt autoremove
> sudo apt purge
> sudo apt autoclean
> sudo apt clean

guix package --delete-generations
guix gc

Underhood, it's very different to apt, see the manual for details.

Hope this will help!


^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: Message by a novice
  2023-05-13 18:31 Message by a novice anguriamelone--- via
  2023-05-14  6:40 ` Edouard Klein
  2023-05-14  6:58 ` 宋文武
@ 2023-05-14  7:59 ` (
  2023-05-14 14:52 ` Felix Lechner via
  3 siblings, 0 replies; 6+ messages in thread
From: ( @ 2023-05-14  7:59 UTC (permalink / raw)
  To: anguriamelone; +Cc: help-guix

anguriamelone--- via <help-guix@gnu.org> writes:
> I am a novice in GNU Guix, so far I used Trisquel GN-Linux 9.0.2 (i686), but at the end of April the support for the i686 version has been discontinued. Nevertheless I want to continue using free (as in freedom) software and, getting set to install the iso image, if I don't ask for too muchas an abosulte beginner, I would like to know what are the basic command lines corresponding to those of Trisquel GNU-Linux below:

Welcome!

The problem here is that Guix is not your average package manager, so
not everything will automatically correspond:

> sudo apt update

``guix pull'' (note: *no sudo*) which updates both guix itself and its
package collection (found in the same repo).

> sudo apt upgrade

``guix upgrade'' for user packages, if you're using the ``guix package''
style of package management.  ``sudo guix system reconfigure
/etc/config.scm'' for system packages, which essentially updates and
recreates your entire system from the manifest that is found by default
at ``/etc/config.scm''.
>
> sudo apt install (package name)

``guix install'' or ``guix package -i'' (the former is an alias for the
latter) for user packages if you're using the ``guix package`` style of
package management, or editing ``/etc/config.scm'' and reconfiguring as
above for system packages.

> sudo apt remove --purge (package name)

There's not really a way to do ``--purge'', but if you do ``guix
remove'' or ``guix package -r'', or reconfigure after removing a package
from ``/etc/config.scm'', and then do ``guix gc'', it'll remove all
unused files (specifically, it removes everything in ``/gnu/store'' that
isn't used in any guix 'profiles').

> sudo apt search (package name)

``guix search''.

> sudo apt autoremove

Removing packages from any profiles will also remove unused
dependencies, but will not delete them from the store.  ``guix gc'' will
remove unused store items.

> sudo apt purge
>
> sudo apt autoclean
>
> sudo apt clean
>
>    Thanks for the attention and kind regards.
>
>                   Piriponzolo
>
>  



^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: Message by a novice
  2023-05-14  6:58 ` 宋文武
@ 2023-05-14 12:49   ` Csepp
  0 siblings, 0 replies; 6+ messages in thread
From: Csepp @ 2023-05-14 12:49 UTC (permalink / raw)
  To: 宋文武; +Cc: anguriamelone, help-guix


宋文武 <iyzsong@envs.net> writes:

>> sudo apt update
>
> guix package --upgrade
>
>> sudo apt upgrade
>
> guix pull

These are flipped.  apt update is guix pull, apt upgrade is guix
upgrade.
But you also want to periodically run guix system reconfigure to upgrade
the base system, including the kernel.

Also: some people put all their packages in the system config, don't do
that.

Also also: i686 support is not very good on Guix.  I run it on an old
netbook and it's a pretty miserable experience.  I'm sticking with it
only because I want to improve the situation of Guix on low end
machines.
If you want a distro for old limited hardware, I'd recommend Alpine, or
maybe the 32bit Arch fork.  Alpine is especially very stable in my
experience and can run on a potato and also on a big server.
But do try Guix first, maybe it will work on your hardware better than
it worked on mine.
Just keep in mind that currently Guix is:
 * memory intensive, guix pull needs at least around 1GB RAM
 * IO intensive, due to lots of disk reads, noticably slow if you don't
 use an SSD or fast HDD with lots of RAM for cache
 * storage intensive, it doesn't yet do a good job of splitting packages
 like Alpine does, and there are often accidentally referenced
 dependencies that get installed, even though they are not needed, so
 packages can take up quite a lot of space.  The smallest install I
 could manage so far was around 3.5 GB.  Assume that an upgrade increase
 space usage by a factor of at least two, possibly more as packages
 themselves grow.  It usually won't actually need that much extra space
 due to deduplication, but if you haven't upgraded in a while, there
 might be very few common store items between profile generations.  Also
 this leads to it being:
 * network intensive, but this is being worked on as part of GSoC.
 Packages that didn't really change still need to be redownloaded,
 leading to very high bandwidth usage, which is exacerbarated by the
 substitute servers being pretty slow.  The distributed substitutes
 project will hopefully change that.


Still, it's a really cool distro, and I do recommend trying it out, but
as someone who has struggled to use it on old hardware, I thought you
should know the risks.


^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: Message by a novice
  2023-05-13 18:31 Message by a novice anguriamelone--- via
                   ` (2 preceding siblings ...)
  2023-05-14  7:59 ` (
@ 2023-05-14 14:52 ` Felix Lechner via
  3 siblings, 0 replies; 6+ messages in thread
From: Felix Lechner via @ 2023-05-14 14:52 UTC (permalink / raw)
  To: anguriamelone; +Cc: help-guix@gnu.org

Hi Piriponzolo,

On Sat, May 13, 2023 at 11:23 PM anguriamelone--- via <help-guix@gnu.org> wrote:
>
> I would like to know what are the basic command lines corresponding to those of
> Trisquel GNU-Linux below:

You already received a lot of quality advice, so I'll keep it brief:

Like many distributions, we nowadays have few users on i686. There is
vigorous opposition to dropping it however, and people are ready to
fix what is broken. The fix is then a 'guix pull' away.

Having come from Debian myself, I must point out that Guix is
radically different. Every computer, every user, and even every shell
has effectively a different "profile", by which we mean "purview of
installed files". Guix employs an ingenious combination of absolute
paths and symbolic links to achieve it.

The results are magical.

For example, the command 'guix install' will modify your user profile,
but that happens in an imperative way. I would instead recommend
managing that profile declaratively with Guix Home. You end up editing
a file like this [1] and run 'guix home reconfigure' on it.

Please ask all your questions here. Do not worry about burdening the
mailing list. We want to hear from you. You are also welcome to write
to me privately if needed. Thank you for trying Guix & welcome!

Kind regards
Felix Lechner

[1] https://codeberg.org/lechner/home-config/src/branch/history/desk.scm


^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2023-05-14 15:38 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-05-13 18:31 Message by a novice anguriamelone--- via
2023-05-14  6:40 ` Edouard Klein
2023-05-14  6:58 ` 宋文武
2023-05-14 12:49   ` Csepp
2023-05-14  7:59 ` (
2023-05-14 14:52 ` Felix Lechner via

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).